efl_ui/pan: rename pan,position,changed -> pan,content_position,changed

Summary:
the pan object is not changing its position, it's moving the content

ref T7708
Depends on D9787

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T7708

Differential Revision: https://phab.enlightenment.org/D9788
This commit is contained in:
Mike Blumenkrantz 2019-08-30 14:47:52 -04:00
parent 23220764e2
commit ba0cd5d23d
6 changed files with 10 additions and 10 deletions

View File

@ -214,7 +214,7 @@ _pan_position_changed_cb(void *data, const Efl_Event *ev EINA_UNUSED)
}
EFL_CALLBACKS_ARRAY_DEFINE(pan_events_cb,
{EFL_UI_PAN_EVENT_PAN_POSITION_CHANGED, _pan_position_changed_cb},
{EFL_UI_PAN_EVENT_PAN_CONTENT_POSITION_CHANGED, _pan_position_changed_cb},
{EFL_UI_PAN_EVENT_PAN_VIEWPORT_CHANGED, _pan_viewport_changed_cb},
)

View File

@ -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_PAN_POSITION_CHANGED, NULL);
efl_event_callback_call(sd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_POSITION_CHANGED, NULL);
_sizing_eval(obj);
}
sd->calc_job = NULL;
@ -399,7 +399,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_PAN_POSITION_CHANGED, NULL);
efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_CONTENT_POSITION_CHANGED, NULL);
}
EOLIAN static Eina_Position2D

View File

@ -59,7 +59,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_PAN_POSITION_CHANGED, NULL);
efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_CONTENT_POSITION_CHANGED, NULL);
evas_object_smart_changed(psd->wobj);
}

View File

@ -69,7 +69,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_PAN_POSITION_CHANGED, NULL);
efl_event_callback_call(obj, EFL_UI_PAN_EVENT_PAN_CONTENT_POSITION_CHANGED, NULL);
}
EOLIAN static Eina_Position2D
@ -141,7 +141,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_PAN_POSITION_CHANGED, NULL);
efl_event_callback_call(pobj, EFL_UI_PAN_EVENT_PAN_CONTENT_POSITION_CHANGED, NULL);
}
EOLIAN static Eina_Bool

View File

@ -65,6 +65,6 @@ class @beta Efl.Ui.Pan extends Efl.Canvas.Group implements Efl.Content
}
events {
pan,viewport,changed: void; [[This widget's position or size has changed.]]
pan,position,changed: void; [[The content's position has changed.]]
pan,content_position,changed: void; [[The content's position has changed.]]
}
}

View File

@ -2278,7 +2278,7 @@ _efl_ui_scroll_manager_pan_set(Eo *obj, Efl_Ui_Scroll_Manager_Data *sd, Eo *pan)
efl_event_callback_del
(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_PAN_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd);
(sd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd);
_efl_ui_scroll_manager_pan_content_changed(sd, NULL);
}
@ -2291,7 +2291,7 @@ _efl_ui_scroll_manager_pan_set(Eo *obj, Efl_Ui_Scroll_Manager_Data *sd, Eo *pan)
efl_event_callback_add
(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_PAN_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd);
(sd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_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,
@ -2485,7 +2485,7 @@ _efl_ui_scroll_manager_efl_object_destructor(Eo *obj, Efl_Ui_Scroll_Manager_Data
efl_event_callback_del
(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_PAN_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd);
(sd->pan_obj, EFL_UI_PAN_EVENT_PAN_CONTENT_POSITION_CHANGED, _efl_ui_scroll_manager_pan_position_changed_cb, sd);
if (sd->pan_content)
efl_event_callback_del(sd->pan_content, EFL_GFX_ENTITY_EVENT_SIZE_CHANGED, _efl_ui_scroll_manager_pan_content_resized_cb, sd);
sd->pan_content = NULL;