summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <marcel-hollerbach@t-online.de>2017-05-03 11:36:31 +0200
committerMarcel Hollerbach <marcel-hollerbach@t-online.de>2017-05-03 11:36:31 +0200
commita1b19c29b4621c5aca219815aaad3e2b2147d1a1 (patch)
tree58a7a377e5fff1a66f939475108a4ee8669e27d0
parent7bdf0c8d01f2afbce31f3d2b40e1ac337ab048cd (diff)
-rw-r--r--src/bin/ui.c31
1 files changed, 13 insertions, 18 deletions
diff --git a/src/bin/ui.c b/src/bin/ui.c
index 8917110..6ec3144 100644
--- a/src/bin/ui.c
+++ b/src/bin/ui.c
@@ -9,7 +9,7 @@
9#endif 9#endif
10#include <Elementary.h> 10#include <Elementary.h>
11#include "ui.h" 11#include "ui.h"
12#if 0 12#if 1
13static void 13static void
14_pubs_free_cb(void *data, const Efl_Event *event EINA_UNUSED) 14_pubs_free_cb(void *data, const Efl_Event *event EINA_UNUSED)
15{ 15{
@@ -36,13 +36,13 @@ open_with2_main_win_create(Eo *__main_parent)
36 Eo *elm_bg1; 36 Eo *elm_bg1;
37 37
38 38
39 main_win = efl_add(EFL_UI_WIN_CLASS, __main_parent, efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC)); 39 main_win = elm_win_util_standard_add("Open with", "");
40 pub_widgets->main_win = main_win; 40 pub_widgets->main_win = main_win;
41 efl_gfx_size_hint_weight_set (main_win, 1.000000, 1.000000); 41 efl_gfx_size_hint_weight_set (main_win, 1.000000, 1.000000);
42 efl_gfx_size_set (main_win, 454, 379); 42 efl_gfx_size_set (main_win, 454, 379);
43 efl_ui_win_autodel_set (main_win, EINA_TRUE); 43 efl_ui_win_autodel_set (main_win, EINA_TRUE);
44 elm_win_title_set(main_win, "Open with"); 44 elm_win_title_set(main_win, "Open with");
45 elm_win1_main_menu = efl_add(ELM_MENU_CLASS, main_win); 45 elm_win1_main_menu = elm_menu_add(main_win);
46 46
47 elm_box1 = elm_box_add(main_win); 47 elm_box1 = elm_box_add(main_win);
48 efl_gfx_size_hint_weight_set (elm_box1, 1.000000, 1.000000); 48 efl_gfx_size_hint_weight_set (elm_box1, 1.000000, 1.000000);
@@ -50,7 +50,7 @@ open_with2_main_win_create(Eo *__main_parent)
50 efl_gfx_size_hint_align_set (elm_box1, -1.000000, -1.000000); 50 efl_gfx_size_hint_align_set (elm_box1, -1.000000, -1.000000);
51 efl_gfx_position_set (elm_box1, 72, 86); 51 efl_gfx_position_set (elm_box1, 72, 86);
52 52
53 elm_genlist1 = efl_add(ELM_GENLIST_CLASS, elm_box1); 53 elm_genlist1 = elm_genlist_add(elm_box1);
54 pub_widgets->elm_genlist1 = elm_genlist1; 54 pub_widgets->elm_genlist1 = elm_genlist1;
55 efl_gfx_visible_set (elm_genlist1, EINA_TRUE); 55 efl_gfx_visible_set (elm_genlist1, EINA_TRUE);
56 efl_gfx_size_set (elm_genlist1, 70, 60); 56 efl_gfx_size_set (elm_genlist1, 70, 60);
@@ -64,14 +64,15 @@ open_with2_main_win_create(Eo *__main_parent)
64 efl_gfx_size_hint_align_set (elm_box2, -1.000000, -1.000000); 64 efl_gfx_size_hint_align_set (elm_box2, -1.000000, -1.000000);
65 efl_gfx_size_hint_weight_set (elm_box2, 1.000000, 0.000000); 65 efl_gfx_size_hint_weight_set (elm_box2, 1.000000, 0.000000);
66 66
67 open = efl_add(ELM_BUTTON_CLASS, elm_box2); 67 open = elm_button_add(elm_box2);
68 pub_widgets->open = open; 68 pub_widgets->open = open;
69 efl_gfx_size_hint_weight_set (open, 1.000000, 1.000000); 69 efl_gfx_size_hint_weight_set (open, 1.000000, 1.000000);
70 efl_gfx_visible_set (open, EINA_TRUE); 70 efl_gfx_visible_set (open, EINA_TRUE);
71 efl_gfx_size_set (open, 73, 30); 71 efl_gfx_size_set (open, 73, 30);
72 efl_gfx_size_hint_align_set (open, -1.000000, -1.000000); 72 efl_gfx_size_hint_align_set (open, -1.000000, -1.000000);
73 elm_object_part_text_set (open, NULL, "Open"); 73 elm_object_part_text_set (open, NULL, "Open");
74 asdefault = efl_add(ELM_BUTTON_CLASS, elm_box2); 74
75 asdefault = elm_button_add(elm_box2);;
75 pub_widgets->asdefault = asdefault; 76 pub_widgets->asdefault = asdefault;
76 efl_gfx_size_hint_weight_set (asdefault, 1.000000, 1.000000); 77 efl_gfx_size_hint_weight_set (asdefault, 1.000000, 1.000000);
77 efl_gfx_visible_set (asdefault, EINA_TRUE); 78 efl_gfx_visible_set (asdefault, EINA_TRUE);
@@ -87,14 +88,14 @@ open_with2_main_win_create(Eo *__main_parent)
87 elm_box_horizontal_set (elm_box3, EINA_TRUE); 88 elm_box_horizontal_set (elm_box3, EINA_TRUE);
88 efl_gfx_size_hint_weight_set (elm_box3, 0.000000, 0.000000); 89 efl_gfx_size_hint_weight_set (elm_box3, 0.000000, 0.000000);
89 90
90 elm_label1 = efl_add(ELM_LABEL_CLASS, elm_box3); 91 elm_label1 = elm_label_add(elm_box3);
91 efl_gfx_visible_set (elm_label1, EINA_TRUE); 92 efl_gfx_visible_set (elm_label1, EINA_TRUE);
92 efl_gfx_size_set (elm_label1, 60, 30); 93 efl_gfx_size_set (elm_label1, 60, 30);
93 efl_gfx_size_hint_weight_set (elm_label1, 1.000000, 0.000000); 94 efl_gfx_size_hint_weight_set (elm_label1, 1.000000, 0.000000);
94 efl_gfx_size_hint_align_set (elm_label1, -1.000000, 0.500000); 95 efl_gfx_size_hint_align_set (elm_label1, -1.000000, 0.500000);
95 elm_object_part_text_set(elm_label1, NULL, "Current default:"); 96 elm_object_part_text_set(elm_label1, NULL, "Current default:");
96 97
97 current_app = efl_add(ELM_LABEL_CLASS, elm_box3); 98 current_app = elm_label_add(elm_box3);
98 pub_widgets->current_app = current_app; 99 pub_widgets->current_app = current_app;
99 efl_gfx_size_hint_weight_set (current_app, 1.000000, 1.000000); 100 efl_gfx_size_hint_weight_set (current_app, 1.000000, 1.000000);
100 efl_gfx_visible_set (current_app, EINA_TRUE); 101 efl_gfx_visible_set (current_app, EINA_TRUE);
@@ -103,7 +104,7 @@ open_with2_main_win_create(Eo *__main_parent)
103 elm_box_pack_end (elm_box3, elm_label1); 104 elm_box_pack_end (elm_box3, elm_label1);
104 elm_box_pack_end (elm_box3, current_app); 105 elm_box_pack_end (elm_box3, current_app);
105 106
106 search = efl_add(ELM_ENTRY_CLASS, elm_box1); 107 search = elm_entry_add(elm_box1);
107 pub_widgets->search = search; 108 pub_widgets->search = search;
108 efl_gfx_visible_set (search, EINA_TRUE); 109 efl_gfx_visible_set (search, EINA_TRUE);
109 efl_gfx_size_set (search, 60, 30); 110 efl_gfx_size_set (search, 60, 30);
@@ -125,21 +126,15 @@ open_with2_main_win_create(Eo *__main_parent)
125 elm_icon_standard_set (elm_icon1, "search"); 126 elm_icon_standard_set (elm_icon1, "search");
126 elm_object_part_content_set(search, "icon", elm_icon1); 127 elm_object_part_content_set(search, "icon", elm_icon1);
127 128
128 elm_bg1 = efl_add(ELM_BG_CLASS, main_win);
129 efl_gfx_size_hint_weight_set (elm_bg1, 1.000000, 1.000000);
130 efl_gfx_visible_set (elm_bg1, EINA_TRUE);
131 elm_win_resize_object_add (main_win, elm_bg1);
132 elm_win_resize_object_add (main_win, elm_box1);
133 efl_gfx_visible_set (main_win, EINA_TRUE);
134 efl_event_callback_add (main_win, EFL_EVENT_DEL, _pubs_free_cb, pub_widgets);
135
136 return pub_widgets; 129 return pub_widgets;
137} 130}
138 131
139#endif 132#else
140Open_With2_Main_Win_Widgets * 133Open_With2_Main_Win_Widgets *
141open_with2_main_win_create(Eo *__main_parent) 134open_with2_main_win_create(Eo *__main_parent)
142{ 135{
143 printf("NOP\n"); 136 printf("NOP\n");
144 return NULL; 137 return NULL;
145} 138}
139
140#endif