From fe0aa085f94682df6fa2d03b2b44157c6bbe828f Mon Sep 17 00:00:00 2001 From: Daniel Juyung Seo Date: Sun, 15 Dec 2013 05:45:57 +0900 Subject: [PATCH] elm_test: call evas_object_show(win) after its content creation. - refer commit 64fd5a825b24591aedb9cac695d03f5b4d867442 for the detail explanation. - also move evas_object_resize(win, xx) alongside evas_object_show(win). --- src/bin/test.c | 7 ++++--- src/bin/test_box.c | 5 +++-- src/bin/test_button.c | 1 + src/bin/test_calendar.c | 3 ++- src/bin/test_entry.c | 5 +++-- src/bin/test_fileselector.c | 5 +++-- src/bin/test_gengrid.c | 33 ++++++++++++++++++++------------- src/bin/test_genlist.c | 20 ++++++++++++-------- src/bin/test_glview_simple.c | 5 +++-- src/bin/test_hover.c | 15 +++++++++------ src/bin/test_icon.c | 5 +++-- src/bin/test_icon_animated.c | 3 ++- src/bin/test_index.c | 15 +++++++++------ src/bin/test_list.c | 15 +++++++++------ src/bin/test_main_menu.c | 5 +++-- src/bin/test_menu.c | 10 ++++++---- src/bin/test_notify.c | 2 +- src/bin/test_popup.c | 5 +++-- src/bin/test_progressbar.c | 3 ++- src/bin/test_radio.c | 3 ++- src/bin/test_slider.c | 3 ++- src/bin/test_task_switcher.c | 2 +- 22 files changed, 103 insertions(+), 67 deletions(-) diff --git a/src/bin/test.c b/src/bin/test.c index f9afaf9..77a5a5c 100755 --- a/src/bin/test.c +++ b/src/bin/test.c @@ -865,9 +865,6 @@ add_tests: if (tests) _menu_create(NULL); - /* set an initial window size */ - evas_object_resize(win, 480, 480); - evas_object_show(win); /* bring in autorun frame */ if (autorun) { @@ -875,6 +872,10 @@ add_tests: evas_object_geometry_get(tt, &x, &y, NULL, NULL); elm_scroller_region_bring_in(sc, x, y, 0, 0); } + + /* set an initial window size */ + evas_object_resize(win, 480, 480); + evas_object_show(win); } /* this is your elementary main function - it MUST be called IMMEDIATELY diff --git a/src/bin/test_box.c b/src/bin/test_box.c index 42cbca3..f5430ad 100644 --- a/src/bin/test_box.c +++ b/src/bin/test_box.c @@ -695,10 +695,11 @@ test_box_transition(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void * tdata->transitions = eina_list_append(tdata->transitions, evas_object_box_layout_stack); - evas_object_resize(win, 300, 300); evas_object_resize(bx, 300, 300); evas_object_smart_callback_add(win, "delete,request", _win_del, tdata); - evas_object_show(win); elm_box_layout_set(bx, evas_object_box_layout_horizontal, NULL, NULL); _test_box_transition_change(tdata); + + evas_object_resize(win, 300, 300); + evas_object_show(win); } diff --git a/src/bin/test_button.c b/src/bin/test_button.c index 0028863..d64e10b 100644 --- a/src/bin/test_button.c +++ b/src/bin/test_button.c @@ -208,6 +208,7 @@ test_button(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in elm_box_pack_end(bx, bt); evas_object_show(bt); evas_object_show(ic); + evas_object_resize(win, 320, 480); evas_object_show(win); } diff --git a/src/bin/test_calendar.c b/src/bin/test_calendar.c index 2b7c289..1d0248d 100644 --- a/src/bin/test_calendar.c +++ b/src/bin/test_calendar.c @@ -280,7 +280,6 @@ test_calendar2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event evas_object_show(en); elm_box_pack_end(bx, en); elm_entry_editable_set(en, EINA_FALSE); - evas_object_show(win); elm_calendar_min_max_year_set(cal3, -1, -1); @@ -316,6 +315,8 @@ test_calendar2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event _print_cal_info(cal, en); evas_object_smart_callback_add(cal, "changed", _print_cal_info_cb, en); + + evas_object_show(win); } diff --git a/src/bin/test_entry.c b/src/bin/test_entry.c index e1b8e0e..1478ba5 100644 --- a/src/bin/test_entry.c +++ b/src/bin/test_entry.c @@ -2290,8 +2290,6 @@ test_entry_emoticon(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win = elm_win_util_standard_add("entry-emoticon", "Entry Emoticon"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 400, 500); - evas_object_show(win); en = elm_entry_add(win); evas_object_size_hint_weight_set(en, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -2338,5 +2336,8 @@ test_entry_emoticon(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, ); evas_object_show(en); elm_object_focus_set(en, EINA_TRUE); + + evas_object_resize(win, 400, 500); + evas_object_show(win); } diff --git a/src/bin/test_fileselector.c b/src/bin/test_fileselector.c index f22a6e9..1e3e8a9 100644 --- a/src/bin/test_fileselector.c +++ b/src/bin/test_fileselector.c @@ -431,8 +431,6 @@ test_fileselector(void *data EINA_UNUSED, win = elm_win_util_standard_add("fileselector", "File Selector"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 700); - evas_object_show(win); vbox = elm_box_add(win); evas_object_size_hint_weight_set(vbox, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -475,5 +473,8 @@ test_fileselector(void *data EINA_UNUSED, elm_box_pack_end(vbox, _getter_option_create(vbox, fs)); elm_box_pack_end(vbox, _mode_option_create(vbox, fs)); elm_box_pack_end(vbox, _thumbnail_size_option_create(vbox, fs)); + + evas_object_resize(win, 320, 700); + evas_object_show(win); } diff --git a/src/bin/test_gengrid.c b/src/bin/test_gengrid.c index d01f35d..80f1937 100644 --- a/src/bin/test_gengrid.c +++ b/src/bin/test_gengrid.c @@ -384,8 +384,6 @@ filled_bt_clicked(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *ev win = elm_win_util_standard_add("test filled", "Test Filled"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 450, 200); - evas_object_show(win); box = elm_box_add(win); evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -407,6 +405,9 @@ filled_bt_clicked(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *ev evas_object_smart_callback_add(tg, "changed", filled_cb, content_box); elm_box_pack_end(box, tg); evas_object_show(tg); + + evas_object_resize(win, 450, 200); + evas_object_show(win); } static void @@ -438,8 +439,6 @@ cursor_bt_clicked(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *ev win = elm_win_util_standard_add("test cursor", "Test Cursor"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 450, 450); - evas_object_show(win); box = elm_box_add(win); evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -467,6 +466,9 @@ cursor_bt_clicked(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *ev elm_box_pack_end(box, hbox); evas_object_show(hbox); + + evas_object_resize(win, 450, 450); + evas_object_show(win); } static void @@ -496,8 +498,6 @@ test_gengrid(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_i win = elm_win_util_standard_add("gengrid", "GenGrid"); elm_win_autodel_set(win, EINA_TRUE); evas_object_event_callback_add(win, EVAS_CALLBACK_FREE, _cleanup_cb, api); - evas_object_resize(win, 600, 600); - evas_object_show(win); api->box = bxx = elm_box_add(win); evas_object_size_hint_weight_set(bxx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -583,6 +583,9 @@ test_gengrid(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_i evas_object_smart_callback_add(bt, "clicked", _btn_show_clicked_cb, api->grid); elm_box_pack_end(bx, bt); evas_object_show(bt); + + evas_object_resize(win, 600, 600); + evas_object_show(win); } static void @@ -709,8 +712,6 @@ test_gengrid2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_ win = elm_win_util_standard_add("gengrid2", "GenGrid 2"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 600, 600); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -795,6 +796,9 @@ test_gengrid2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_ /* item_class_ref is needed for gic. some items can be added in callbacks */ elm_gengrid_item_class_ref(gic); elm_gengrid_item_class_free(gic); + + evas_object_resize(win, 600, 600); + evas_object_show(win); } void @@ -807,8 +811,6 @@ test_gengrid3(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_ win = elm_win_util_standard_add("gengrid_group", "GenGrid Group"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 600, 600); - evas_object_show(win); grid = elm_gengrid_add(win); evas_object_size_hint_weight_set(grid, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -864,6 +866,9 @@ test_gengrid3(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_ elm_gengrid_item_class_free(ggic); evas_object_show(grid); + + evas_object_resize(win, 600, 600); + evas_object_show(win); } /* test gengrid item styles */ @@ -975,8 +980,6 @@ test_gengrid_item_styles(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win = elm_win_util_standard_add("gengrid-styles", "Gengrid Item Styles"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 600, 600); - evas_object_show(win); box = elm_box_add(win); elm_box_horizontal_set(box, EINA_TRUE); @@ -996,6 +999,9 @@ test_gengrid_item_styles(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, gengrid = _gengrid_create(win, (12 * 12), NULL); elm_box_pack_end(box, gengrid); evas_object_show(gengrid); + + evas_object_resize(win, 600, 600); + evas_object_show(win); } static void @@ -1232,7 +1238,6 @@ test_gengrid4(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_ win = elm_win_util_standard_add("gengrid-show-bringin", "GenGrid Show/Bring_in"); elm_win_autodel_set(win, EINA_TRUE); evas_object_event_callback_add(win, EVAS_CALLBACK_FREE, _cleanup_cb, sd); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -1266,4 +1271,6 @@ test_gengrid4(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_ evas_object_smart_callback_add(bt, "clicked", _bring_in_clicked_cb, sd); elm_box_pack_end(bx2, bt); evas_object_show(bt); + + evas_object_show(win); } diff --git a/src/bin/test_genlist.c b/src/bin/test_genlist.c index fdf1480..b6db28a 100644 --- a/src/bin/test_genlist.c +++ b/src/bin/test_genlist.c @@ -3317,8 +3317,6 @@ test_genlist20(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event win = elm_win_util_standard_add("genlist-focus", "Genlist Focus"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 300, 500); - evas_object_show(win); bxx = elm_box_add(win); evas_object_size_hint_weight_set(bxx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -3390,6 +3388,9 @@ test_genlist20(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event elm_genlist_item_class_free(itc1); elm_genlist_item_class_free(itc4); + + evas_object_resize(win, 300, 500); + evas_object_show(win); } @@ -3469,8 +3470,6 @@ test_genlist_item_styles(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win = elm_win_util_standard_add("genlist-item-styles", "Gengrid Item Styles"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 600, 600); - evas_object_show(win); box = elm_box_add(win); elm_box_horizontal_set(box, EINA_TRUE); @@ -3500,6 +3499,9 @@ test_genlist_item_styles(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, evas_object_data_set(gl, "check", check); evas_object_data_set(list, "genlist", gl); + + evas_object_resize(win, 600, 600); + evas_object_show(win); } /***********/ @@ -3595,8 +3597,6 @@ test_genlist_multi_select(void *data EINA_UNUSED, win = elm_win_util_standard_add("genlist-multi-select", "Genlist Multi Select"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 500); - evas_object_show(win); evas_object_event_callback_add(win, EVAS_CALLBACK_FREE, _cleanup_cb, gd); bx = elm_box_add(win); @@ -3629,6 +3629,9 @@ test_genlist_multi_select(void *data EINA_UNUSED, (void *)(uintptr_t)(i * 10)/* func data */); } elm_genlist_item_class_free(itc); + + evas_object_resize(win, 320, 500); + evas_object_show(win); } /* test genlist deletion */ @@ -3738,8 +3741,6 @@ test_genlist_del(void *data EINA_UNUSED, win = elm_win_util_standard_add("genlist-del", "Genlist Del"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 500); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -3774,4 +3775,7 @@ test_genlist_del(void *data EINA_UNUSED, gl = _gl_del_genlist_add(bx); _gl_del_item_append(gl, itc); + + evas_object_resize(win, 320, 500); + evas_object_show(win); } diff --git a/src/bin/test_glview_simple.c b/src/bin/test_glview_simple.c index 6a1996a..b224a57 100644 --- a/src/bin/test_glview_simple.c +++ b/src/bin/test_glview_simple.c @@ -234,8 +234,6 @@ test_glview_simple(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *e win = elm_win_util_standard_add("glview-simple", "GLView Simple"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 480); - evas_object_show(win); evas_object_event_callback_add(win, EVAS_CALLBACK_FREE, _win_free_cb, gld); bx = elm_box_add(win); @@ -270,4 +268,7 @@ test_glview_simple(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *e elm_box_pack_end(bx, bt); evas_object_show(bt); evas_object_smart_callback_add(bt, "clicked", _close_cb, NULL); + + evas_object_resize(win, 320, 480); + evas_object_show(win); } diff --git a/src/bin/test_hover.c b/src/bin/test_hover.c index 4edc81d..40b2c47 100644 --- a/src/bin/test_hover.c +++ b/src/bin/test_hover.c @@ -34,8 +34,6 @@ test_hover(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_inf win = elm_win_util_standard_add("hover", "Hover"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 440, 440); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -98,6 +96,9 @@ test_hover(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_inf elm_object_text_set(bt, "Right"); elm_object_part_content_set(hv, "right", bt); evas_object_show(bt); + + evas_object_resize(win, 440, 440); + evas_object_show(win); } void @@ -108,8 +109,6 @@ test_hover2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in win = elm_win_util_standard_add("hover2", "Hover 2"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 440, 440); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -169,6 +168,9 @@ test_hover2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in elm_object_text_set(bt, "Right"); elm_object_part_content_set(hv, "right", bt); evas_object_show(bt); + + evas_object_resize(win, 440, 440); + evas_object_show(win); } static void @@ -201,8 +203,6 @@ test_hover3(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win = elm_win_util_standard_add("hover3", "Hover 3"); elm_win_focus_highlight_enabled_set(win, EINA_TRUE); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 440, 440); - evas_object_show(win); rect = evas_object_rectangle_add(evas_object_evas_get(win)); evas_object_size_hint_weight_set(rect, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -245,5 +245,8 @@ test_hover3(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, elm_box_pack_end(bx, bt); evas_object_show(bt); evas_object_smart_callback_add(bt, "clicked", _dismiss_hover, hv); + + evas_object_resize(win, 440, 440); + evas_object_show(win); } diff --git a/src/bin/test_icon.c b/src/bin/test_icon.c index d4a5919..3ed99b3 100644 --- a/src/bin/test_icon.c +++ b/src/bin/test_icon.c @@ -59,8 +59,6 @@ test_icon(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info win = elm_win_util_standard_add("icon-test", "Icon Test"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 400, 400); - evas_object_show(win); box = elm_box_add(win); evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -111,6 +109,9 @@ test_icon(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info evas_object_smart_callback_add(bt, "clicked", bt_clicked, NULL); elm_box_pack_end(hbox, bt); evas_object_show(bt); + + evas_object_resize(win, 400, 400); + evas_object_show(win); } static void diff --git a/src/bin/test_icon_animated.c b/src/bin/test_icon_animated.c index 8ad1a53..3ecfa26 100644 --- a/src/bin/test_icon_animated.c +++ b/src/bin/test_icon_animated.c @@ -25,7 +25,6 @@ test_icon_animated(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *e win = elm_win_add(NULL, "icon-animated-gif", ELM_WIN_BASIC); elm_win_title_set(win, "Icon Animated Gif"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -53,4 +52,6 @@ test_icon_animated(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *e evas_object_show(ic); evas_object_smart_callback_add(ic, "clicked", _icon_clicked_cb, ic); + + evas_object_show(win); } diff --git a/src/bin/test_index.c b/src/bin/test_index.c index 2fea084..df20d0e 100644 --- a/src/bin/test_index.c +++ b/src/bin/test_index.c @@ -188,8 +188,6 @@ test_index(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_inf win = elm_win_util_standard_add("index", "Index"); elm_win_autodel_set(win, EINA_TRUE); evas_object_event_callback_add(win, EVAS_CALLBACK_FREE, _cleanup_cb, api); - evas_object_resize(win, 320, 270); - evas_object_show(win); bxx = elm_box_add(win); evas_object_size_hint_weight_set(bxx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -260,6 +258,9 @@ test_index(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_inf evas_object_smart_callback_add(id, "changed", _index_changed_cb, NULL); evas_object_smart_callback_add(id, "selected", _index_selected_cb, NULL); elm_index_level_go(id, 0); + + evas_object_resize(win, 320, 270); + evas_object_show(win); } /***********/ @@ -380,8 +381,6 @@ test_index2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in win = elm_win_util_standard_add("sorted-index-list", "Sorted Index and List"); evas_object_smart_callback_add(win, "delete,request", _test_index2_del, gui); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 480); - evas_object_show(win); box = elm_box_add(win); evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -430,6 +429,9 @@ test_index2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in gui); elm_list_go(gui->lst); evas_object_show(gui->lst); + + evas_object_resize(win, 320, 480); + evas_object_show(win); } /***** Index Horizontal Mode ******/ @@ -455,8 +457,6 @@ test_index_horizontal(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win = elm_win_util_standard_add("index-horizontal", "Index Horizontal"); elm_win_autodel_set(win, EINA_TRUE); evas_object_event_callback_add(win, EVAS_CALLBACK_FREE, _cleanup_cb, api); - evas_object_resize(win, 480, 320); - evas_object_show(win); tb = elm_table_add(win); evas_object_size_hint_weight_set(tb, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -486,5 +486,8 @@ test_index_horizontal(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, } evas_object_smart_callback_add(id, "changed", _index_list_changed_cb, NULL); elm_index_level_go(id, 0); + + evas_object_resize(win, 480, 320); + evas_object_show(win); } diff --git a/src/bin/test_list.c b/src/bin/test_list.c index 44ff67c..0fa541d 100644 --- a/src/bin/test_list.c +++ b/src/bin/test_list.c @@ -595,8 +595,6 @@ test_list2(void *data EINA_UNUSED, win = elm_win_add(NULL, "list2", ELM_WIN_BASIC); elm_win_title_set(win, "List 2"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 500); - evas_object_show(win); bg = elm_bg_add(win); snprintf(buf, sizeof(buf), "%s/images/plant_01.jpg", elm_app_data_dir_get()); @@ -685,6 +683,9 @@ test_list2(void *data EINA_UNUSED, evas_object_size_hint_align_set(bt, EVAS_HINT_FILL, EVAS_HINT_FILL); elm_box_pack_end(bx, bt); evas_object_show(bt); + + evas_object_resize(win, 320, 500); + evas_object_show(win); } /***********/ @@ -1295,8 +1296,6 @@ void test_list_focus(const char *name, const char *title, Eina_Bool horiz) win = elm_win_util_standard_add(name, title); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 300); - evas_object_show(win); elm_win_focus_highlight_enabled_set(win, EINA_TRUE); elm_win_focus_highlight_animate_set(win, EINA_TRUE); @@ -1356,6 +1355,9 @@ void test_list_focus(const char *name, const char *title, Eina_Bool horiz) elm_list_go(li); evas_object_show(li); + + evas_object_resize(win, 320, 300); + evas_object_show(win); } void @@ -1575,8 +1577,6 @@ test_list_multi_select(void *data EINA_UNUSED, win = elm_win_util_standard_add("list-multi-select", "List Multi Select"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 500); - evas_object_show(win); evas_object_event_callback_add(win, EVAS_CALLBACK_FREE, _cleanup_cb, ld); bx = elm_box_add(win); @@ -1606,4 +1606,7 @@ test_list_multi_select(void *data EINA_UNUSED, elm_list_item_append(li, "Longer label.", NULL, NULL, NULL, NULL); elm_list_go(li); + + evas_object_resize(win, 320, 500); + evas_object_show(win); } diff --git a/src/bin/test_main_menu.c b/src/bin/test_main_menu.c index 38554b6..da93eca 100644 --- a/src/bin/test_main_menu.c +++ b/src/bin/test_main_menu.c @@ -26,8 +26,6 @@ test_main_menu(void *data EINA_UNUSED, win = elm_win_util_standard_add("menu", "Menu"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 250, 350); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -73,5 +71,8 @@ test_main_menu(void *data EINA_UNUSED, elm_menu_item_add(menu, menu_it, "applications-email-panel", "third item", NULL, NULL); menu_it1 = elm_menu_item_add(menu, menu_it, NULL, "sub menu", NULL, NULL); elm_menu_item_add(menu, menu_it1, NULL, "first item", NULL, NULL); + + evas_object_resize(win, 250, 350); + evas_object_show(win); } diff --git a/src/bin/test_menu.c b/src/bin/test_menu.c index bade0d8..5c8d4e5 100644 --- a/src/bin/test_menu.c +++ b/src/bin/test_menu.c @@ -109,8 +109,6 @@ test_menu(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win = elm_win_util_standard_add("menu", "Menu"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 350, 200); - evas_object_show(win); lbl = elm_label_add(win); elm_object_text_set(lbl, "Click background to populate menu!"); @@ -137,6 +135,9 @@ test_menu(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, evas_object_event_callback_add(rect, EVAS_CALLBACK_MOUSE_DOWN, _menu_show_cb, menu); + + evas_object_resize(win, 350, 200); + evas_object_show(win); } static void @@ -230,8 +231,6 @@ test_menu2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_inf win = elm_win_util_standard_add("menu2", "Menu 2"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 320, 320); - evas_object_show(win); bx = elm_box_add(win); elm_box_horizontal_set(bx, EINA_TRUE); @@ -308,5 +307,8 @@ test_menu2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_inf elm_box_pack_end(vbx, bt); evas_object_smart_callback_add(bt, "clicked", _close_bt_clicked, mn); evas_object_show(bt); + + evas_object_resize(win, 320, 320); + evas_object_show(win); } diff --git a/src/bin/test_notify.c b/src/bin/test_notify.c index ea56910..1f430a8 100644 --- a/src/bin/test_notify.c +++ b/src/bin/test_notify.c @@ -430,7 +430,7 @@ test_notify(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in elm_table_pack(tb, bt, 4, 1, 1, 3); evas_object_show(bt); - evas_object_show(win); evas_object_resize(win, 400, 400); + evas_object_show(win); } diff --git a/src/bin/test_popup.c b/src/bin/test_popup.c index 0b01b67..6e6d5b4 100644 --- a/src/bin/test_popup.c +++ b/src/bin/test_popup.c @@ -600,8 +600,6 @@ test_popup(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win = elm_win_util_standard_add("popup", "Popup"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_resize(win, 480, 400); - evas_object_show(win); list = elm_list_add(win); evas_object_size_hint_weight_set(list, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -645,5 +643,8 @@ test_popup(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win); elm_list_go(list); evas_object_show(list); + + evas_object_resize(win, 480, 400); + evas_object_show(win); } diff --git a/src/bin/test_progressbar.c b/src/bin/test_progressbar.c index 997a9f4..0e03474 100644 --- a/src/bin/test_progressbar.c +++ b/src/bin/test_progressbar.c @@ -325,7 +325,6 @@ test_progressbar2(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *even win = elm_win_util_standard_add("progressbar", "Progressbar2"); evas_object_smart_callback_add(win, "delete,request", _progressbar_destroy_cb, pd); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -392,4 +391,6 @@ test_progressbar2(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *even elm_box_pack_end(bt_bx, bt); evas_object_show(bt); pd->btn_stop = bt; + + evas_object_show(win); } diff --git a/src/bin/test_radio.c b/src/bin/test_radio.c index 92ed955..b7ea605 100644 --- a/src/bin/test_radio.c +++ b/src/bin/test_radio.c @@ -20,7 +20,6 @@ test_radio(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, win = elm_win_util_standard_add("radios", "Radios"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_show(win); bx = elm_box_add(win); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -103,4 +102,6 @@ test_radio(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, evas_object_smart_callback_add(rd, "changed", _rd_changed_cb, NULL); elm_radio_value_set(rdg, 2); + + evas_object_show(win); } diff --git a/src/bin/test_slider.c b/src/bin/test_slider.c index e537825..5b74a0e 100644 --- a/src/bin/test_slider.c +++ b/src/bin/test_slider.c @@ -68,7 +68,6 @@ test_slider(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in win = elm_win_util_standard_add("slider", "Slider"); elm_win_autodel_set(win, EINA_TRUE); - evas_object_show(win); fr = elm_frame_add(win); evas_object_size_hint_weight_set(fr, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); @@ -308,4 +307,6 @@ test_slider(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in evas_object_smart_callback_add(bt, "clicked", _bt_m1, sl); evas_object_show(bt); elm_box_pack_end(bx2, bt); + + evas_object_show(win); } diff --git a/src/bin/test_task_switcher.c b/src/bin/test_task_switcher.c index a2158d8..f8d3abf 100644 --- a/src/bin/test_task_switcher.c +++ b/src/bin/test_task_switcher.c @@ -402,6 +402,6 @@ test_task_switcher(void *data EINA_UNUSED, _apps_list_update(); evas_object_show(table); - evas_object_show(win); evas_object_resize(win, 1024, 768); + evas_object_show(win); } -- 2.7.4