summaryrefslogtreecommitdiff
path: root/src/lib/eio
diff options
context:
space:
mode:
authorVitor Sousa <vitorsousasilva@gmail.com>2016-08-22 19:40:39 -0300
committerVitor Sousa <vitorsousasilva@gmail.com>2016-08-26 15:45:07 -0300
commit8356b16a49d4f653d61940763eff947466b44e24 (patch)
treeb5d8e533b3df4ad45f2ea97071b7a826ae5d04b5 /src/lib/eio
parent6b3ca899e8a60642466ddb6d7c7574b0c3ad9d9c (diff)
Efl Object: remove legacy callback calls from event_callback_call
Efl.Object.event_callback_call no longer calls legacy smart callbacks; calling only event callbacks registered with the given event description pointer. Create the method Efl.Object.event_callback_legacy_call to inherit the old behavior from Efl.Object.event_callback_call, calling both Efl.Object events and legacy smart callbacks. Update all other files accordingly in order to still supply legacy callbacks while they are necessary.
Diffstat (limited to 'src/lib/eio')
-rw-r--r--src/lib/eio/efl_io_manager.c4
-rw-r--r--src/lib/eio/eio_model.c6
-rw-r--r--src/lib/eio/eio_sentry.c2
3 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/eio/efl_io_manager.c b/src/lib/eio/efl_io_manager.c
index 181af8c567..81514f52c9 100644
--- a/src/lib/eio/efl_io_manager.c
+++ b/src/lib/eio/efl_io_manager.c
@@ -124,7 +124,7 @@ _file_ls_filter_cb_helper(const Efl_Event_Description *event, void *data, const
124 event_info->file = file; 124 event_info->file = file;
125 event_info->filter = EINA_FALSE; 125 event_info->filter = EINA_FALSE;
126 126
127 efl_event_callback_call(operation->pdata->object, event, event_info); 127 efl_event_callback_legacy_call(operation->pdata->object, event, event_info);
128 128
129 Eina_Bool filter = event_info->filter; 129 Eina_Bool filter = event_info->filter;
130 130
@@ -213,7 +213,7 @@ _file_direct_ls_filter_cb(void *data, Eio_File *handle EINA_UNUSED, const Eina_F
213 event_info.info = info; 213 event_info.info = info;
214 event_info.filter = EINA_FALSE; 214 event_info.filter = EINA_FALSE;
215 215
216 efl_event_callback_call(operation->pdata->object, EFL_IO_MANAGER_EVENT_FILTER_DIRECT, &event_info); 216 efl_event_callback_legacy_call(operation->pdata->object, EFL_IO_MANAGER_EVENT_FILTER_DIRECT, &event_info);
217 217
218 Eina_Bool filter = event_info.filter; 218 Eina_Bool filter = event_info.filter;
219 219
diff --git a/src/lib/eio/eio_model.c b/src/lib/eio/eio_model.c
index a7ab9495a6..be6f0942c6 100644
--- a/src/lib/eio/eio_model.c
+++ b/src/lib/eio/eio_model.c
@@ -95,7 +95,7 @@ _eio_move_done_cb(void *data, Eio_File *handler EINA_UNUSED)
95 eina_array_push(properties, _eio_model_prop_names[EIO_MODEL_PROP_FILENAME]); 95 eina_array_push(properties, _eio_model_prop_names[EIO_MODEL_PROP_FILENAME]);
96 evt.changed_properties = properties; 96 evt.changed_properties = properties;
97 97
98 efl_event_callback_call(priv->obj, EFL_MODEL_EVENT_PROPERTIES_CHANGED, &evt); 98 efl_event_callback_legacy_call(priv->obj, EFL_MODEL_EVENT_PROPERTIES_CHANGED, &evt);
99 eina_array_free(properties); 99 eina_array_free(properties);
100} 100}
101 101
@@ -180,7 +180,7 @@ _efl_model_evt_added_ecore_cb(void *data, int type, void *event)
180 eio_model_children_filter_set(cevt.child, priv->filter_cb, priv->filter_userdata); 180 eio_model_children_filter_set(cevt.child, priv->filter_cb, priv->filter_userdata);
181 eina_value_flush(&path); 181 eina_value_flush(&path);
182 182
183 efl_event_callback_call(priv->obj, EFL_MODEL_EVENT_CHILD_ADDED, &cevt); 183 efl_event_callback_legacy_call(priv->obj, EFL_MODEL_EVENT_CHILD_ADDED, &cevt);
184 184
185 return EINA_TRUE; 185 return EINA_TRUE;
186} 186}
@@ -213,7 +213,7 @@ _efl_model_evt_deleted_ecore_cb(void *data, int type, void *event)
213 cevt.index = i; 213 cevt.index = i;
214 cevt.child = cur->data; 214 cevt.child = cur->data;
215 215
216 efl_event_callback_call(priv->obj, EFL_MODEL_EVENT_CHILD_REMOVED, &cevt); 216 efl_event_callback_legacy_call(priv->obj, EFL_MODEL_EVENT_CHILD_REMOVED, &cevt);
217 217
218 priv->children_list = eina_list_remove_list(priv->children_list, cur); 218 priv->children_list = eina_list_remove_list(priv->children_list, cur);
219 efl_unref(cevt.child); 219 efl_unref(cevt.child);
diff --git a/src/lib/eio/eio_sentry.c b/src/lib/eio/eio_sentry.c
index c21b0c2052..153828ee8f 100644
--- a/src/lib/eio/eio_sentry.c
+++ b/src/lib/eio/eio_sentry.c
@@ -73,7 +73,7 @@ _handle_event(void *data, int type, void *event)
73 event_info->source = eio_monitor_path_get(monitor_event->monitor); 73 event_info->source = eio_monitor_path_get(monitor_event->monitor);
74 event_info->trigger = monitor_event->filename; 74 event_info->trigger = monitor_event->filename;
75 75
76 efl_event_callback_call(pd->object, translated_event, event_info); 76 efl_event_callback_legacy_call(pd->object, translated_event, event_info);
77 77
78 // If event was error, we must delete the monitor. 78 // If event was error, we must delete the monitor.
79 if (type == EIO_MONITOR_ERROR) 79 if (type == EIO_MONITOR_ERROR)