From: Mike Blumenkrantz Date: Fri, 8 Mar 2019 15:53:04 +0000 (-0500) Subject: efl.ui.pan: namespace events to avoid conflicts X-Git-Tag: submit/tizen/20190318.043110~46 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cc580324db44590fc718ebbf05c73e24127260b2;p=platform%2Fupstream%2Fefl.git efl.ui.pan: namespace events to avoid conflicts Reviewed-by: Cedric BAIL Differential Revision: https://phab.enlightenment.org/D8262 --- diff --git a/src/lib/elementary/efl_ui_image_zoomable.c b/src/lib/elementary/efl_ui_image_zoomable.c index 0947ad8..f346ee3 100644 --- a/src/lib/elementary/efl_ui_image_zoomable.c +++ b/src/lib/elementary/efl_ui_image_zoomable.c @@ -143,7 +143,7 @@ _calc_job_cb(void *data) sd->minw = minw; sd->minh = minh; - efl_event_callback_call(sd->pan_obj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, NULL); + efl_event_callback_call(sd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, NULL); _sizing_eval(obj); } sd->calc_job = NULL; @@ -408,7 +408,7 @@ _efl_ui_image_zoomable_pan_efl_ui_pan_pan_position_set(Eo *obj, Efl_Ui_Image_Zoo psd->wsd->pan_y = pos.y; evas_object_smart_changed(obj); - efl_event_callback_call(obj, EFL_UI_PAN_EVENT_POSITION_CHANGED, NULL); + efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_POSITION_CHANGED, NULL); } EOLIAN static Eina_Position2D diff --git a/src/lib/elementary/efl_ui_list_view.c b/src/lib/elementary/efl_ui_list_view.c index 9a563df..1e418fb 100644 --- a/src/lib/elementary/efl_ui_list_view.c +++ b/src/lib/elementary/efl_ui_list_view.c @@ -58,7 +58,7 @@ _efl_ui_list_view_pan_efl_ui_pan_pan_position_set(Eo *obj EINA_UNUSED, Efl_Ui_Li psd->gmt.x = pos.x; psd->gmt.y = pos.y; - efl_event_callback_call(obj, EFL_UI_PAN_EVENT_POSITION_CHANGED, NULL); + efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_POSITION_CHANGED, NULL); evas_object_smart_changed(psd->wobj); } @@ -864,7 +864,7 @@ _efl_ui_list_view_efl_ui_list_view_model_min_size_set(Eo *obj, Efl_Ui_List_View_ pd->min.h = min.h; evas_object_size_hint_min_set(wd->resize_obj, pd->min.w, pd->min.h); - efl_event_callback_call(pd->pan_obj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, NULL); + efl_event_callback_call(pd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, NULL); } EOLIAN static void diff --git a/src/lib/elementary/efl_ui_pan.c b/src/lib/elementary/efl_ui_pan.c index fcbe6dd..f56cae3 100644 --- a/src/lib/elementary/efl_ui_pan.c +++ b/src/lib/elementary/efl_ui_pan.c @@ -47,7 +47,7 @@ _efl_ui_pan_efl_gfx_entity_size_set(Eo *obj, Efl_Ui_Pan_Data *psd, Eina_Size2D s psd->h = sz.h; evas_object_smart_changed(obj); - efl_event_callback_call(obj, EFL_UI_PAN_EVENT_VIEWPORT_CHANGED, NULL); + efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_VIEWPORT_CHANGED, NULL); } EOLIAN static void @@ -68,7 +68,7 @@ _efl_ui_pan_pan_position_set(Eo *obj EINA_UNUSED, Efl_Ui_Pan_Data *psd, Eina_Pos psd->py = pos.y; evas_object_smart_changed(obj); - efl_event_callback_call(obj, EFL_UI_PAN_EVENT_POSITION_CHANGED, NULL); + efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_POSITION_CHANGED, NULL); } EOLIAN static Eina_Position2D @@ -126,7 +126,7 @@ _efl_ui_pan_content_del_cb(void *data, psd->content = NULL; psd->content_w = psd->content_h = psd->px = psd->py = 0; - efl_event_callback_call(pobj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, NULL); + efl_event_callback_call(pobj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, NULL); } static void @@ -145,7 +145,7 @@ _efl_ui_pan_content_resize_cb(void *data, psd->content_h = sz.h; evas_object_smart_changed(pobj); } - efl_event_callback_call(pobj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, NULL); + efl_event_callback_call(pobj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, NULL); } EOLIAN static Eina_Bool @@ -179,7 +179,7 @@ _efl_ui_pan_efl_content_content_set(Evas_Object *obj, Efl_Ui_Pan_Data *psd, Evas end: efl_event_callback_call(obj, EFL_CONTENT_EVENT_CONTENT_CHANGED, content); - efl_event_callback_call(obj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, NULL); + efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, NULL); return EINA_TRUE; } @@ -203,7 +203,7 @@ _efl_ui_pan_efl_content_content_unset(Eo *obj EINA_UNUSED, Efl_Ui_Pan_Data *pd) pd->content = NULL; pd->content_w = pd->content_h = pd->px = pd->py = 0; efl_event_callback_call(obj, EFL_CONTENT_EVENT_CONTENT_CHANGED, NULL); - efl_event_callback_call(obj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, NULL); + efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, NULL); return old_content; } diff --git a/src/lib/elementary/efl_ui_pan.eo b/src/lib/elementary/efl_ui_pan.eo index 84d2e0d..9923a39 100644 --- a/src/lib/elementary/efl_ui_pan.eo +++ b/src/lib/elementary/efl_ui_pan.eo @@ -48,8 +48,8 @@ class @beta Efl.Ui.Pan extends Efl.Canvas.Group implements Efl.Content Efl.Canvas.Group.group_calculate; } events { - content,changed: void; [[Called when pan content changed]] - viewport,changed: void; [[Called when pan viewport changed]] - position,changed: void; [[Called when pan position changed]] + pan,content,changed: void; [[Called when pan content changed]] + pan,viewport,changed: void; [[Called when pan viewport changed]] + pan,position,changed: void; [[Called when pan position changed]] } } diff --git a/src/lib/elementary/efl_ui_scroll_manager.c b/src/lib/elementary/efl_ui_scroll_manager.c index e371110..98da2fd 100644 --- a/src/lib/elementary/efl_ui_scroll_manager.c +++ b/src/lib/elementary/efl_ui_scroll_manager.c @@ -2247,11 +2247,11 @@ _efl_ui_scroll_manager_pan_set(Eo *obj, Efl_Ui_Scroll_Manager_Data *sd, Eo *pan) if (sd->pan_obj) { efl_event_callback_del - (sd->pan_obj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, _efl_ui_scroll_manager_pan_content_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, _efl_ui_scroll_manager_pan_content_changed_cb, sd); efl_event_callback_del - (sd->pan_obj, EFL_UI_PAN_EVENT_VIEWPORT_CHANGED, _efl_ui_scroll_manager_pan_viewport_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_VIEWPORT_CHANGED, _efl_ui_scroll_manager_pan_viewport_changed_cb, sd); efl_event_callback_del - (sd->pan_obj, EFL_UI_PAN_EVENT_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd); } if (!pan) @@ -2260,11 +2260,11 @@ _efl_ui_scroll_manager_pan_set(Eo *obj, Efl_Ui_Scroll_Manager_Data *sd, Eo *pan) sd->pan_obj = pan; efl_event_callback_add - (sd->pan_obj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, _efl_ui_scroll_manager_pan_content_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, _efl_ui_scroll_manager_pan_content_changed_cb, sd); efl_event_callback_add - (sd->pan_obj, EFL_UI_PAN_EVENT_VIEWPORT_CHANGED, _efl_ui_scroll_manager_pan_viewport_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_VIEWPORT_CHANGED, _efl_ui_scroll_manager_pan_viewport_changed_cb, sd); efl_event_callback_add - (sd->pan_obj, EFL_UI_PAN_EVENT_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd); evas_object_event_callback_add(sd->pan_obj, EVAS_CALLBACK_RESIZE, _efl_ui_scroll_manager_pan_resized_cb, obj); evas_object_event_callback_add(sd->pan_obj, EVAS_CALLBACK_MOVE, @@ -2452,11 +2452,11 @@ _efl_ui_scroll_manager_efl_object_destructor(Eo *obj, Efl_Ui_Scroll_Manager_Data evas_object_event_callback_del_full(sd->pan_obj, EVAS_CALLBACK_MOVE, _efl_ui_scroll_manager_pan_moved_cb, obj); efl_event_callback_del - (sd->pan_obj, EFL_UI_PAN_EVENT_CONTENT_CHANGED, _efl_ui_scroll_manager_pan_content_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_CHANGED, _efl_ui_scroll_manager_pan_content_changed_cb, sd); efl_event_callback_del - (sd->pan_obj, EFL_UI_PAN_EVENT_VIEWPORT_CHANGED, _efl_ui_scroll_manager_pan_viewport_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_VIEWPORT_CHANGED, _efl_ui_scroll_manager_pan_viewport_changed_cb, sd); efl_event_callback_del - (sd->pan_obj, EFL_UI_PAN_EVENT_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd); + (sd->pan_obj, EFL_UI_PAN_EVENT_PAN_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd); } efl_destructor(efl_super(obj, MY_CLASS)); }