elemetary - notify, factory, frame, panel, mapbuf
[framework/uifw/elementary.git] / src / bin / test_notify.c
index 3f29d4c..37fffe3 100644 (file)
@@ -44,7 +44,7 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
 
    win = elm_win_add(NULL, "notify", ELM_WIN_BASIC);
    elm_win_title_set(win, "Notify");
-   elm_win_autodel_set(win, 1);
+   elm_win_autodel_set(win, EINA_TRUE);
 
    bg = elm_bg_add(win);
    elm_win_resize_object_add(win, bg);
@@ -60,23 +60,23 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    evas_object_size_hint_weight_set(notify, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "This position is the default.");
+   elm_object_text_set(lb, "This position is the default.");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close");
+   elm_object_text_set(bt, "Close");
    evas_object_smart_callback_add(bt, "clicked", _bt_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Top");
+   elm_object_text_set(bt, "Top");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 1, 0, 1, 1);
    evas_object_show(bt);
@@ -90,24 +90,24 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    evas_object_smart_callback_add(notify, "block,clicked", _notify_block, NULL);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "Bottom position. This notify use a timeout of 5 sec.<br>"
+   elm_object_text_set(lb, "Bottom position. This notify use a timeout of 5 sec.<br>"
         "<b>The events outside the window are blocked.</b>");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close");
+   elm_object_text_set(bt, "Close");
    evas_object_smart_callback_add(bt, "clicked", _bt_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Bottom");
+   elm_object_text_set(bt, "Bottom");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 1, 2, 1, 1);
    evas_object_show(bt);
@@ -119,23 +119,23 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    evas_object_smart_callback_add(notify, "timeout", _notify_timeout, NULL);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "Left position. This notify use a timeout of 10 sec.");
+   elm_object_text_set(lb, "Left position. This notify use a timeout of 10 sec.");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close");
+   elm_object_text_set(bt, "Close");
    evas_object_smart_callback_add(bt, "clicked", _bt_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Left");
+   elm_object_text_set(bt, "Left");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 0, 1, 1, 1);
    evas_object_show(bt);
@@ -143,28 +143,27 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    notify = elm_notify_add(win);
    evas_object_size_hint_weight_set(notify, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
    elm_notify_orient_set(notify, ELM_NOTIFY_ORIENT_CENTER);
-   elm_notify_timeout_set(notify, 10);
    elm_notify_timeout_set(notify, 10.0);
    evas_object_smart_callback_add(notify, "timeout", _notify_timeout, NULL);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "Center position. This notify use a timeout of 10 sec.");
+   elm_object_text_set(lb, "Center position. This notify use a timeout of 10 sec.");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close");
+   elm_object_text_set(bt, "Close");
    evas_object_smart_callback_add(bt, "clicked", _bt_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Center");
+   elm_object_text_set(bt, "Center");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 1, 1, 1, 1);
    evas_object_show(bt);
@@ -174,23 +173,23 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    elm_notify_orient_set(notify, ELM_NOTIFY_ORIENT_RIGHT);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "Right position.");
+   elm_object_text_set(lb, "Right position.");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close");
+   elm_object_text_set(bt, "Close");
    evas_object_smart_callback_add(bt, "clicked", _bt_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Right");
+   elm_object_text_set(bt, "Right");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 2, 1, 1, 1);
    evas_object_show(bt);
@@ -200,23 +199,23 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    elm_notify_orient_set(notify, ELM_NOTIFY_ORIENT_TOP_LEFT);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "Top Left position.");
+   elm_object_text_set(lb, "Top Left position.");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close");
+   elm_object_text_set(bt, "Close");
    evas_object_smart_callback_add(bt, "clicked", _bt_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Top Left");
+   elm_object_text_set(bt, "Top Left");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 0, 0, 1, 1);
    evas_object_show(bt);
@@ -226,23 +225,23 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    elm_notify_orient_set(notify, ELM_NOTIFY_ORIENT_TOP_RIGHT);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "Top Right position.");
+   elm_object_text_set(lb, "Top Right position.");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close");
+   elm_object_text_set(bt, "Close");
    evas_object_smart_callback_add(bt, "clicked", _bt_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Top Right");
+   elm_object_text_set(bt, "Top Right");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 2, 0, 1, 1);
    evas_object_show(bt);
@@ -252,23 +251,23 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    elm_notify_orient_set(notify, ELM_NOTIFY_ORIENT_BOTTOM_LEFT);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "Bottom Left position.");
+   elm_object_text_set(lb, "Bottom Left position.");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close");
+   elm_object_text_set(bt, "Close");
    evas_object_smart_callback_add(bt, "clicked", _bt_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Bottom Left");
+   elm_object_text_set(bt, "Bottom Left");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 0, 2, 1, 1);
    evas_object_show(bt);
@@ -278,23 +277,23 @@ test_notify(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
    elm_notify_orient_set(notify, ELM_NOTIFY_ORIENT_BOTTOM_RIGHT);
 
    bx = elm_box_add(win);
-   elm_notify_content_set(notify, bx);
-   elm_box_horizontal_set(bx, 1);
+   elm_object_content_set(notify, bx);
+   elm_box_horizontal_set(bx, EINA_TRUE);
    evas_object_show(bx);
 
    lb = elm_label_add(win);
-   elm_label_label_set(lb, "Bottom Right position.");
+   elm_object_text_set(lb, "Bottom Right position.");
    elm_box_pack_end(bx, lb);
    evas_object_show(lb);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Close in 2s");
+   elm_object_text_set(bt, "Close in 2s");
    evas_object_smart_callback_add(bt, "clicked", _bt_timer_close, notify);
    elm_box_pack_end(bx, bt);
    evas_object_show(bt);
 
    bt = elm_button_add(win);
-   elm_button_label_set(bt, "Bottom Right");
+   elm_object_text_set(bt, "Bottom Right");
    evas_object_smart_callback_add(bt, "clicked", _bt, notify);
    elm_table_pack(tb, bt, 2, 2, 1, 1);
    evas_object_show(bt);