summaryrefslogtreecommitdiff
path: root/src/bin/e_widget_toolbar.c
diff options
context:
space:
mode:
authorCedric BAIL <cedric.bail@free.fr>2009-06-17 13:46:54 +0000
committerCedric BAIL <cedric.bail@free.fr>2009-06-17 13:46:54 +0000
commitc82f19e052c520555d6b92d7c4a2389471a3128c (patch)
tree43f7abfcc10c3c0d0a99dc4c51f345585e684995 /src/bin/e_widget_toolbar.c
parentaf7451ff79c1ebbfa24bd9bb9a7842efd15d13d8 (diff)
* e: Remove all reference to Evas_Data and move to Eina_Bool.
SVN revision: 41080
Diffstat (limited to 'src/bin/e_widget_toolbar.c')
-rw-r--r--src/bin/e_widget_toolbar.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/bin/e_widget_toolbar.c b/src/bin/e_widget_toolbar.c
index ac322e6..acbc94b 100644
--- a/src/bin/e_widget_toolbar.c
+++ b/src/bin/e_widget_toolbar.c
@@ -10,8 +10,8 @@ struct _E_Widget_Data
10 Evas_Object *o_base, *o_box, *o_scrollframe0; 10 Evas_Object *o_base, *o_box, *o_scrollframe0;
11 int icon_w, icon_h; 11 int icon_w, icon_h;
12 Eina_List *items; 12 Eina_List *items;
13 Evas_Bool scrollable : 1; 13 Eina_Bool scrollable : 1;
14 Evas_Bool focus_steal : 1; 14 Eina_Bool focus_steal : 1;
15}; 15};
16 16
17struct _Item 17struct _Item
@@ -19,7 +19,7 @@ struct _Item
19 Evas_Object *o_toolbar, *o_base, *o_icon; 19 Evas_Object *o_toolbar, *o_base, *o_icon;
20 void (*func) (void *data1, void *data2); 20 void (*func) (void *data1, void *data2);
21 const void *data1, *data2; 21 const void *data1, *data2;
22 Evas_Bool selected : 1; 22 Eina_Bool selected : 1;
23}; 23};
24 24
25static void _e_wid_del_hook(Evas_Object *obj); 25static void _e_wid_del_hook(Evas_Object *obj);
@@ -50,7 +50,7 @@ e_widget_toolbar_add(Evas *evas, int icon_w, int icon_h)
50 e_widget_data_set(obj, wd); 50 e_widget_data_set(obj, wd);
51 wd->icon_w = icon_w; 51 wd->icon_w = icon_w;
52 wd->icon_h = icon_h; 52 wd->icon_h = icon_h;
53 wd->focus_steal = 1; 53 wd->focus_steal = EINA_TRUE;
54 54
55 o = e_scrollframe_add(evas); 55 o = e_scrollframe_add(evas);
56 wd->o_base = o; 56 wd->o_base = o;
@@ -167,7 +167,7 @@ e_widget_toolbar_item_select(Evas_Object *obj, int num)
167 { 167 {
168 if (!it->selected) 168 if (!it->selected)
169 { 169 {
170 it->selected = 1; 170 it->selected = EINA_TRUE;
171 edje_object_signal_emit(it->o_base, "e,state,selected", "e"); 171 edje_object_signal_emit(it->o_base, "e,state,selected", "e");
172 edje_object_signal_emit(it->o_icon, "e,state,selected", "e"); 172 edje_object_signal_emit(it->o_icon, "e,state,selected", "e");
173 _item_show(it); 173 _item_show(it);
@@ -178,7 +178,7 @@ e_widget_toolbar_item_select(Evas_Object *obj, int num)
178 { 178 {
179 if (it->selected) 179 if (it->selected)
180 { 180 {
181 it->selected = 0; 181 it->selected = EINA_FALSE;
182 edje_object_signal_emit(it->o_base, "e,state,unselected", "e"); 182 edje_object_signal_emit(it->o_base, "e,state,unselected", "e");
183 edje_object_signal_emit(it->o_icon, "e,state,unselected", "e"); 183 edje_object_signal_emit(it->o_icon, "e,state,unselected", "e");
184 } 184 }
@@ -211,7 +211,7 @@ e_widget_toolbar_item_label_set(Evas_Object *obj, int num, const char *label)
211} 211}
212 212
213EAPI void 213EAPI void
214e_widget_toolbar_scrollable_set(Evas_Object *obj, Evas_Bool scrollable) 214e_widget_toolbar_scrollable_set(Evas_Object *obj, Eina_Bool scrollable)
215{ 215{
216 E_Widget_Data *wd; 216 E_Widget_Data *wd;
217 Evas_Coord mw = 0, mh = 0, vw = 0, vh = 0; 217 Evas_Coord mw = 0, mh = 0, vw = 0, vh = 0;
@@ -229,7 +229,7 @@ e_widget_toolbar_scrollable_set(Evas_Object *obj, Evas_Bool scrollable)
229} 229}
230 230
231EAPI void 231EAPI void
232e_widget_toolbar_focus_steal_set(Evas_Object *obj, Evas_Bool steal) 232e_widget_toolbar_focus_steal_set(Evas_Object *obj, Eina_Bool steal)
233{ 233{
234 E_Widget_Data *wd; 234 E_Widget_Data *wd;
235 235
@@ -240,14 +240,14 @@ e_widget_toolbar_focus_steal_set(Evas_Object *obj, Evas_Bool steal)
240 evas_object_event_callback_add(e_scrollframe_edje_object_get(wd->o_base), 240 evas_object_event_callback_add(e_scrollframe_edje_object_get(wd->o_base),
241 EVAS_CALLBACK_MOUSE_DOWN, 241 EVAS_CALLBACK_MOUSE_DOWN,
242 _e_wid_focus_steal, obj); 242 _e_wid_focus_steal, obj);
243 wd->focus_steal = 1; 243 wd->focus_steal = EINA_TRUE;
244 } 244 }
245 else 245 else
246 { 246 {
247 evas_object_event_callback_del(e_scrollframe_edje_object_get(wd->o_base), 247 evas_object_event_callback_del(e_scrollframe_edje_object_get(wd->o_base),
248 EVAS_CALLBACK_MOUSE_DOWN, 248 EVAS_CALLBACK_MOUSE_DOWN,
249 _e_wid_focus_steal); 249 _e_wid_focus_steal);
250 wd->focus_steal = 0; 250 wd->focus_steal = EINA_FALSE;
251 } 251 }
252} 252}
253 253
@@ -299,13 +299,13 @@ _e_wid_signal_cb1(void *data, Evas_Object *obj, const char *emission, const char
299 it2 = l->data; 299 it2 = l->data;
300 if (it2->selected) 300 if (it2->selected)
301 { 301 {
302 it2->selected = 0; 302 it2->selected = EINA_FALSE;
303 edje_object_signal_emit(it2->o_base, "e,state,unselected", "e"); 303 edje_object_signal_emit(it2->o_base, "e,state,unselected", "e");
304 edje_object_signal_emit(it2->o_icon, "e,state,unselected", "e"); 304 edje_object_signal_emit(it2->o_icon, "e,state,unselected", "e");
305 break; 305 break;
306 } 306 }
307 } 307 }
308 it->selected = 1; 308 it->selected = EINA_TRUE;
309 edje_object_signal_emit(it->o_base, "e,state,selected", "e"); 309 edje_object_signal_emit(it->o_base, "e,state,selected", "e");
310 edje_object_signal_emit(it->o_icon, "e,state,selected", "e"); 310 edje_object_signal_emit(it->o_icon, "e,state,selected", "e");
311 _item_show(it); 311 _item_show(it);
@@ -407,10 +407,10 @@ _e_wid_cb_key_down(void *data, Evas *evas, Evas_Object *obj, void *event_info)
407 } 407 }
408 if ((it) && (it2) && (it != it2)) 408 if ((it) && (it2) && (it != it2))
409 { 409 {
410 it->selected = 0; 410 it->selected = EINA_FALSE;
411 edje_object_signal_emit(it->o_base, "e,state,unselected", "e"); 411 edje_object_signal_emit(it->o_base, "e,state,unselected", "e");
412 edje_object_signal_emit(it->o_icon, "e,state,unselected", "e"); 412 edje_object_signal_emit(it->o_icon, "e,state,unselected", "e");
413 it2->selected = 1; 413 it2->selected = EINA_TRUE;
414 edje_object_signal_emit(it2->o_base, "e,state,selected", "e"); 414 edje_object_signal_emit(it2->o_base, "e,state,selected", "e");
415 edje_object_signal_emit(it2->o_icon, "e,state,selected", "e"); 415 edje_object_signal_emit(it2->o_icon, "e,state,selected", "e");
416 _item_show(it2); 416 _item_show(it2);