summaryrefslogtreecommitdiff
path: root/src/bin/elementary/test_popup.c
diff options
context:
space:
mode:
authorAlastair Poole <netstar@gmail.com>2020-07-13 13:21:35 +0100
committerAlastair Poole <netstar@gmail.com>2020-07-13 13:21:35 +0100
commit6cc6aacbaccd4b6e876ae9b54d93cd6fe73c0fe4 (patch)
treeb385afbe5767507366b25cdfee8cb748b205f9d0 /src/bin/elementary/test_popup.c
parentcf884dccdab331ae671b094e8448e877a3862faa (diff)
tests: remove popup test.
This was put here due to a miscommunication. It was for resolving an issue with one of our applications. It wasn't meant to be in this part of testing anyway. Remove as the popup in the application itself was broken.
Diffstat (limited to '')
-rw-r--r--src/bin/elementary/test_popup.c76
1 files changed, 0 insertions, 76 deletions
diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index 747b8432fe..da9bbca934 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -845,80 +845,6 @@ _popup_scroll_cb(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA
845 is_popup_scroll = elm_check_state_get(obj); 845 is_popup_scroll = elm_check_state_get(obj);
846} 846}
847 847
848static void
849_popup_scrollable_scroller_content_list_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
850{
851 Evas_Object *win, *popup, *box, *btn, *scroller, *table, *list, *ic;
852 Evas_Object *box2, *label;
853 Elm_Object_Item *ex1;
854
855 win = data;
856
857 popup = elm_popup_add(win);
858 elm_popup_scrollable_set(popup, EINA_TRUE);
859 elm_object_part_text_set(popup, "title,text", "Title");
860 elm_popup_orient_set(popup, ELM_POPUP_ORIENT_CENTER);
861 evas_object_show(popup);
862
863 box = elm_box_add(popup);
864 evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
865 evas_object_size_hint_align_set(box, EVAS_HINT_FILL, EVAS_HINT_FILL);
866 evas_object_size_hint_min_set(box, 200 * elm_config_scale_get(), 200 * elm_config_scale_get());
867 evas_object_show(box);
868
869 scroller = elm_scroller_add(box);
870 evas_object_size_hint_weight_set(scroller, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
871 evas_object_size_hint_align_set(scroller, EVAS_HINT_FILL, EVAS_HINT_FILL);
872 elm_box_pack_end(box, scroller);
873 evas_object_show(scroller);
874
875 table = elm_table_add(scroller);
876 elm_table_homogeneous_set(table, EINA_FALSE);
877 evas_object_size_hint_weight_set(table, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
878 evas_object_size_hint_align_set(table, EVAS_HINT_FILL, EVAS_HINT_FILL);
879 evas_object_show(table);
880
881 list = elm_list_add(table);
882 elm_list_select_mode_set(list, ELM_OBJECT_SELECT_MODE_ALWAYS);
883 elm_scroller_content_min_limit(list, 1, 1);
884 evas_object_size_hint_align_set(list, EVAS_HINT_FILL, EVAS_HINT_FILL);
885 evas_object_size_hint_weight_set(list, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
886 elm_table_pack(table, list, 0, 0, 1, 1);
887 evas_object_show(list);
888
889 box2 = elm_box_add(table);
890 evas_object_size_hint_weight_set(box2, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
891 evas_object_size_hint_align_set(box2, EVAS_HINT_FILL, EVAS_HINT_FILL);
892 elm_table_pack(table, box2, 1, 0, 2, 1);
893 evas_object_show(box2);
894
895 label = elm_label_add(popup);
896 elm_object_text_set(label, "Wash the soap<br>rub it on your<br>hands.");
897 evas_object_show(label);
898 elm_box_pack_end(box2, label);
899
900 ic = elm_icon_add(list);
901 evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1);
902 elm_icon_standard_set(ic, "input-keyboard");
903 evas_object_show(ic);
904
905 ex1 = elm_list_item_append(list, "Jambalaya", ic, NULL, NULL, NULL);
906 elm_list_item_append(list, "Mississippi", ic, NULL, NULL, NULL);
907
908 elm_list_go(list);
909 elm_list_item_selected_set(ex1, EINA_TRUE);
910
911 btn = elm_button_add(popup);
912 elm_object_text_set(btn, "Close");
913 evas_object_smart_callback_add(btn, "clicked", _popup_close_cb, popup);
914 elm_object_part_content_set(popup, "button1", btn);
915
916 elm_object_content_set(scroller, table);
917 elm_object_content_set(popup, box);
918
919 evas_object_show(popup);
920}
921
922void 848void
923test_popup(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, 849test_popup(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
924 void *event_info EINA_UNUSED) 850 void *event_info EINA_UNUSED)
@@ -985,8 +911,6 @@ test_popup(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
985 win); 911 win);
986 elm_list_item_append(list, "popup-center-title + text + 1 button + hide effect", NULL, 912 elm_list_item_append(list, "popup-center-title + text + 1 button + hide effect", NULL,
987 NULL, _popup_center_title_text_1button_hide_effect_cb, win); 913 NULL, _popup_center_title_text_1button_hide_effect_cb, win);
988 elm_list_item_append(list, "popup-scrollable-with-scroller-as-content-and-list",
989 NULL, NULL, _popup_scrollable_scroller_content_list_cb, win);
990 elm_list_go(list); 914 elm_list_go(list);
991 evas_object_show(list); 915 evas_object_show(list);
992 916