From 55c9696130ea58a93adcdac37bdc3060d5c03f81 Mon Sep 17 00:00:00 2001 From: Daniel Zaoui Date: Sun, 5 Jul 2015 19:09:45 +0300 Subject: [PATCH] Eo events: fix wrong event invocations Events were still created and used on high level classes when Evas interfaces events should have been used (e.g CLICKED, SELECTED). --- src/lib/elc_hoversel.c | 2 +- src/lib/elm_bubble.eo | 3 +-- src/lib/elm_flipselector.c | 2 +- src/lib/elm_flipselector.eo | 4 ++-- src/lib/elm_gengrid.c | 4 ++-- src/lib/elm_gengrid.eo | 2 -- src/lib/elm_hoversel.eo | 3 +-- src/lib/elm_image.eo | 1 - src/lib/elm_index.eo | 1 - src/lib/elm_map_pan.eo | 12 ------------ src/lib/elm_photocam_pan.eo | 12 ------------ 11 files changed, 8 insertions(+), 38 deletions(-) diff --git a/src/lib/elc_hoversel.c b/src/lib/elc_hoversel.c index 65a43de..a357b61 100644 --- a/src/lib/elc_hoversel.c +++ b/src/lib/elc_hoversel.c @@ -109,7 +109,7 @@ _on_item_clicked(void *data EINA_UNUSED, Elm_Object_Item *eo_it = EO_OBJ(item); if (item->func) item->func((void *)WIDGET_ITEM_DATA_GET(eo_it), obj2, eo_it); - eo_do(obj2, eo_event_callback_call(ELM_HOVERSEL_EVENT_SELECTED, eo_it)); + eo_do(obj2, eo_event_callback_call(EVAS_SELECTABLE_INTERFACE_EVENT_SELECTED, eo_it)); elm_hoversel_hover_end(obj2); return EINA_TRUE; diff --git a/src/lib/elm_bubble.eo b/src/lib/elm_bubble.eo index 8b231e0..d4f9b9a 100644 --- a/src/lib/elm_bubble.eo +++ b/src/lib/elm_bubble.eo @@ -1,4 +1,4 @@ -class Elm.Bubble (Elm.Layout) +class Elm.Bubble (Elm.Layout, Evas.Clickable_Interface) { eo_prefix: elm_obj_bubble; methods { @@ -44,7 +44,6 @@ class Elm.Bubble (Elm.Layout) Elm.Layout.sizing_eval; } events { - clicked; focused; unfocused; } diff --git a/src/lib/elm_flipselector.c b/src/lib/elm_flipselector.c index cb5f03a..6bc3f6f 100644 --- a/src/lib/elm_flipselector.c +++ b/src/lib/elm_flipselector.c @@ -231,7 +231,7 @@ _on_item_changed(Elm_Flipselector_Data *sd) if (item->func) item->func((void *)WIDGET_ITEM_DATA_GET(eo_item), WIDGET(item), eo_item); eo_do(sd->obj, eo_event_callback_call - (ELM_FLIPSELECTOR_EVENT_SELECTED, eo_item)); + (EVAS_SELECTABLE_INTERFACE_EVENT_SELECTED, eo_item)); } static void diff --git a/src/lib/elm_flipselector.eo b/src/lib/elm_flipselector.eo index 5ca349d..dd3e98e 100644 --- a/src/lib/elm_flipselector.eo +++ b/src/lib/elm_flipselector.eo @@ -1,4 +1,5 @@ -class Elm.Flipselector (Elm.Layout, Elm_Interface_Atspi_Widget_Action) +class Elm.Flipselector (Elm.Layout, Elm_Interface_Atspi_Widget_Action, + Evas.Selectable_Interface) { eo_prefix: elm_obj_flipselector; methods { @@ -203,7 +204,6 @@ class Elm.Flipselector (Elm.Layout, Elm_Interface_Atspi_Widget_Action) Elm_Interface_Atspi_Widget_Action.elm_actions.get; } events { - selected; underflowed; overflowed; language,changed; diff --git a/src/lib/elm_gengrid.c b/src/lib/elm_gengrid.c index da87292..e15fed4 100644 --- a/src/lib/elm_gengrid.c +++ b/src/lib/elm_gengrid.c @@ -535,7 +535,7 @@ _item_unselect(Elm_Gen_Item *it) it->selected = EINA_FALSE; sd->selected = eina_list_remove(sd->selected, eo_it); eo_do(WIDGET(it), eo_event_callback_call - (ELM_GENGRID_EVENT_UNSELECTED, eo_it)); + (EVAS_SELECTABLE_INTERFACE_EVENT_UNSELECTED, eo_it)); } } @@ -3978,7 +3978,7 @@ _item_select(Elm_Gen_Item *it) if (it->func.func) it->func.func((void *)it->func.data, WIDGET(it), eo_it); if (it->generation == sd->generation) { - eo_do(WIDGET(it), eo_event_callback_call(ELM_GENGRID_EVENT_SELECTED, eo_it)); + eo_do(WIDGET(it), eo_event_callback_call(EVAS_SELECTABLE_INTERFACE_EVENT_SELECTED, eo_it)); elm_object_item_focus_set(eo_it, EINA_TRUE); } diff --git a/src/lib/elm_gengrid.eo b/src/lib/elm_gengrid.eo index 5351978..e62eee9 100644 --- a/src/lib/elm_gengrid.eo +++ b/src/lib/elm_gengrid.eo @@ -737,8 +737,6 @@ class Elm.Gengrid (Elm.Layout, Elm_Interface_Scrollable, activated; highlighted; unhighlighted; - selected; - unselected; released; } diff --git a/src/lib/elm_hoversel.eo b/src/lib/elm_hoversel.eo index e76de41..5e7d05b 100644 --- a/src/lib/elm_hoversel.eo +++ b/src/lib/elm_hoversel.eo @@ -1,4 +1,5 @@ class Elm.Hoversel (Elm.Button, Evas.Selectable_Interface, + Evas.Clickable_Interface, Elm_Interface_Atspi_Widget_Action) { eo_prefix: elm_obj_hoversel; @@ -152,12 +153,10 @@ class Elm.Hoversel (Elm.Button, Evas.Selectable_Interface, Elm_Interface_Atspi_Widget_Action.elm_actions.get; } events { - selected; dismissed; expanded; item,focused; item,unfocused; - clicked; language,changed; access,changed; } diff --git a/src/lib/elm_image.eo b/src/lib/elm_image.eo index 07c01a2..2eb38e9 100644 --- a/src/lib/elm_image.eo +++ b/src/lib/elm_image.eo @@ -471,7 +471,6 @@ class Elm.Image (Elm.Widget, Efl.File, Efl.Image, Evas.Clickable_Interface, } events { drop; - clicked; download,start; download,progress; download,done; diff --git a/src/lib/elm_index.eo b/src/lib/elm_index.eo index ed3eba6..3aeddd1 100644 --- a/src/lib/elm_index.eo +++ b/src/lib/elm_index.eo @@ -357,7 +357,6 @@ class Elm.Index (Elm.Layout, Evas.Clickable_Interface, Evas.Selectable_Interface events { changed; delay,changed; - selected; level,up; level,down; language,changed; diff --git a/src/lib/elm_map_pan.eo b/src/lib/elm_map_pan.eo index b7d187b..cd61d25 100644 --- a/src/lib/elm_map_pan.eo +++ b/src/lib/elm_map_pan.eo @@ -13,18 +13,6 @@ class Elm.Map_Pan (Elm_Pan) Elm_Pan.pos_max.get; } events { - clicked; - clicked,double; - press; - longpressed; - scroll; - scroll,drag,start; - scroll,drag,stop; - scroll,anim,start; - scroll,anim,stop; - zoom,start; - zoom,stop; - zoom,change; loaded; tile,load; tile,loaded; diff --git a/src/lib/elm_photocam_pan.eo b/src/lib/elm_photocam_pan.eo index f369e77..53dc081 100644 --- a/src/lib/elm_photocam_pan.eo +++ b/src/lib/elm_photocam_pan.eo @@ -13,22 +13,10 @@ class Elm.Photocam_Pan (Elm_Pan) Elm_Pan.pos_max.get; } events { - clicked; - press; - longpressed; - clicked,double; load; loaded; load,detail; loaded,detail; - zoom,start; - zoom,stop; - zoom,change; - scroll; - scroll,anim,start; - scroll,anim,stop; - scroll,drag,start; - scroll,drag,stop; download,start; download,progress; download,done; -- 2.7.4