aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2018-03-29 00:42:10 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2018-03-29 13:30:55 +0900
commit2fb5cc3ad09f6aaf82b5d1131ac5ed22ed848bd4 (patch)
tree7a2c2c0371789ae4b139ebdf4a9ef60f82d324aa /src
parentelm_code: Remove a render test and complex workarounds required (diff)
downloadefl-2fb5cc3ad09f6aaf82b5d1131ac5ed22ed848bd4.tar.gz
efl_add_ref - fis to use efl_add properly with a parent.
Diffstat (limited to 'src')
-rw-r--r--src/bin/elementary/test_bg.c4
-rw-r--r--src/bin/elementary/test_box.c2
-rw-r--r--src/bin/elementary/test_calendar.c2
-rw-r--r--src/bin/elementary/test_efl_gfx_map.c2
-rw-r--r--src/bin/elementary/test_evas_map.c2
-rw-r--r--src/bin/elementary/test_evas_mask.c2
-rw-r--r--src/bin/elementary/test_evas_snapshot.c2
-rw-r--r--src/bin/elementary/test_gfx_filters.c2
-rw-r--r--src/bin/elementary/test_glview.c2
-rw-r--r--src/bin/elementary/test_nstate.c2
-rw-r--r--src/bin/elementary/test_part_bg.c2
-rw-r--r--src/bin/elementary/test_part_shadow.c4
-rw-r--r--src/bin/elementary/test_photocam.c2
-rw-r--r--src/bin/elementary/test_ui_button.c2
-rw-r--r--src/bin/elementary/test_ui_clock.c2
-rw-r--r--src/bin/elementary/test_ui_panes.c2
-rw-r--r--src/bin/elementary/test_ui_popup.c16
-rw-r--r--src/bin/elementary/test_ui_progressbar.c4
-rw-r--r--src/bin/elementary/test_ui_scroller.c2
-rw-r--r--src/bin/elementary/test_ui_slider.c2
-rw-r--r--src/bin/elementary/test_ui_slider_interval.c2
-rw-r--r--src/bin/elementary/test_ui_spin.c2
-rw-r--r--src/bin/elementary/test_ui_spin_button.c2
-rw-r--r--src/bin/elementary/test_ui_table_static.c2
-rw-r--r--src/bin/elementary/test_win_dialog.c2
-rw-r--r--src/bin/elementary/test_win_indicator.c4
-rw-r--r--src/bin/elementary/test_win_stack.c4
-rw-r--r--src/examples/ecore/ecore_audio_custom.c4
-rw-r--r--src/examples/ecore/ecore_audio_playback.c8
-rw-r--r--src/examples/ecore/ecore_audio_to_ogg.c18
-rw-r--r--src/examples/ecore/ecore_idler_example.c2
-rw-r--r--src/examples/ecore/ecore_poller_example.c12
-rw-r--r--src/examples/ecore/efl_io_copier_example.c12
-rw-r--r--src/examples/ecore/efl_io_queue_example.c8
-rw-r--r--src/examples/ecore/efl_net_server_example.c6
-rw-r--r--src/examples/ecore/efl_net_server_simple_example.c2
-rw-r--r--src/examples/ecore/efl_net_socket_ssl_dialer_example.c6
-rw-r--r--src/examples/ecore/efl_net_socket_ssl_server_example.c6
-rw-r--r--src/examples/eio/eio_sentry.c2
-rw-r--r--src/examples/elementary/efl_ui_list_example_1.c2
-rw-r--r--src/examples/elementary/efl_ui_list_example_2.c2
-rw-r--r--src/examples/elementary/efl_ui_list_example_3.c2
-rw-r--r--src/examples/elementary/efl_ui_scroller_example.c4
-rw-r--r--src/examples/elementary/filemvc.c10
-rw-r--r--src/examples/elementary/fileviewlist.c4
-rw-r--r--src/examples/elementary/layout_model_connect.c4
-rw-r--r--src/lib/ecore_con/ecore_con_eet.c6
-rw-r--r--src/lib/ecore_con/ecore_con_legacy.c12
-rw-r--r--src/lib/ecore_con/ecore_con_local_win32.c4
-rw-r--r--src/lib/ecore_evas/ecore_evas.c12
-rw-r--r--src/lib/edje/edje_main.c10
-rw-r--r--src/lib/edje/edje_multisense.c24
-rw-r--r--src/lib/eio/eio_model.c2
-rw-r--r--src/lib/elementary/efl_ui_focus_composition.c2
-rw-r--r--src/lib/elementary/efl_ui_list.c2
-rw-r--r--src/lib/elementary/elc_fileselector.c14
-rw-r--r--src/lib/elementary/elc_fileselector_button.c6
-rw-r--r--src/lib/elementary/elm_atspi_bridge.c4
-rw-r--r--src/lib/elementary/elm_sys_notify.c2
-rw-r--r--src/lib/evas/gesture/efl_canvas_gesture_manager.c10
-rw-r--r--src/tests/ecore/ecore_test_ecore_audio.c61
-rw-r--r--src/tests/ecore/ecore_test_promise2.c4
-rw-r--r--src/tests/ecore_con/ecore_con_test_efl_net_ip_address.c46
-rw-r--r--src/tests/efl/efl_test_model_composite.c8
-rw-r--r--src/tests/efl/efl_test_model_container.c2
-rw-r--r--src/tests/efl_mono/libefl_mono_native_test.c2
-rw-r--r--src/tests/eio/eio_test_sentry.c40
-rw-r--r--src/tests/elementary/elm_test_atspi.c28
-rw-r--r--src/tests/elementary/elm_test_config.c4
-rw-r--r--src/tests/elementary/elm_test_focus.c83
-rw-r--r--src/tests/elementary/elm_test_focus_common.c4
-rw-r--r--src/tests/elementary/elm_test_focus_sub.c38
72 files changed, 317 insertions, 305 deletions
diff --git a/src/bin/elementary/test_bg.c b/src/bin/elementary/test_bg.c
index b436e58d5b..b1b1cf5aeb 100644
--- a/src/bin/elementary/test_bg.c
+++ b/src/bin/elementary/test_bg.c
@@ -330,7 +330,7 @@ test_bg_window(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event
Evas_Object *win, *box, *cs;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Bg EOAPI (Efl.Ui.Win)"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE),
efl_ui_win_alpha_set(efl_added, 1));
@@ -403,7 +403,7 @@ test_bg_scale_type(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *e
Evas_Object *rd, *rdg;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Bg EOAPI (Efl.Ui.Bg)"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE),
efl_ui_win_alpha_set(efl_added, EINA_FALSE));
diff --git a/src/bin/elementary/test_box.c b/src/bin/elementary/test_box.c
index 98ff767d2b..cc98eb2065 100644
--- a/src/bin/elementary/test_box.c
+++ b/src/bin/elementary/test_box.c
@@ -889,7 +889,7 @@ test_box_stack(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
Evas_Object *win, *bx, *o;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl.Ui.Box_Stack"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_calendar.c b/src/bin/elementary/test_calendar.c
index 89ac92b48c..49a527ec62 100644
--- a/src/bin/elementary/test_calendar.c
+++ b/src/bin/elementary/test_calendar.c
@@ -431,7 +431,7 @@ test_efl_ui_calendar(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void
current_date = time(NULL) + SEC_PER_YEAR;
localtime_r(&current_date, &max_date);
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl Ui Calendar"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_efl_gfx_map.c b/src/bin/elementary/test_efl_gfx_map.c
index 19e00d4c35..9287683ac2 100644
--- a/src/bin/elementary/test_efl_gfx_map.c
+++ b/src/bin/elementary/test_efl_gfx_map.c
@@ -45,7 +45,7 @@ test_efl_gfx_map(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
Evas_Object *win, *img;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl Gfx Map"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_evas_map.c b/src/bin/elementary/test_evas_map.c
index 8f870cc859..90d2b0de65 100644
--- a/src/bin/elementary/test_evas_map.c
+++ b/src/bin/elementary/test_evas_map.c
@@ -53,7 +53,7 @@ test_evas_map(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
Evas_Object *win, *img;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Evas Map"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_evas_mask.c b/src/bin/elementary/test_evas_mask.c
index 43b1586dd9..d0cf93e68e 100644
--- a/src/bin/elementary/test_evas_mask.c
+++ b/src/bin/elementary/test_evas_mask.c
@@ -108,7 +108,7 @@ test_evas_mask(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event
Elm_Genlist_Item_Class *itc;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Evas masking demo"),
efl_ui_win_autodel_set(efl_added, 1));
diff --git a/src/bin/elementary/test_evas_snapshot.c b/src/bin/elementary/test_evas_snapshot.c
index a483e19900..9eb5dca932 100644
--- a/src/bin/elementary/test_evas_snapshot.c
+++ b/src/bin/elementary/test_evas_snapshot.c
@@ -118,7 +118,7 @@ test_evas_snapshot(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *e
Eo *win, *table, *o, *snap, *box;
const char *path;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Evas Snapshot"),
efl_ui_win_autodel_set(efl_added, 1));
diff --git a/src/bin/elementary/test_gfx_filters.c b/src/bin/elementary/test_gfx_filters.c
index 918860c02d..69abf59f28 100644
--- a/src/bin/elementary/test_gfx_filters.c
+++ b/src/bin/elementary/test_gfx_filters.c
@@ -333,7 +333,7 @@ test_gfx_filters(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *eve
{
Eo *win, *box, *box2, *o, *text = NULL, *spinner, *code, *split, *flip, *tb;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Gfx Filter Editor"),
efl_ui_win_autodel_set(efl_added, 1));
diff --git a/src/bin/elementary/test_glview.c b/src/bin/elementary/test_glview.c
index 6a133e9fd0..2a69dae495 100644
--- a/src/bin/elementary/test_glview.c
+++ b/src/bin/elementary/test_glview.c
@@ -644,7 +644,7 @@ _test_glview_do(Evas_GL_Context_Version version)
elm_config_accel_preference_set(accel);
eina_stringshare_del(accel);
#else
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_name_set(efl_added, "glview"),
efl_text_set(efl_added, "GLView"),
efl_ui_win_accel_preference_set(efl_added, "gl:depth"));
diff --git a/src/bin/elementary/test_nstate.c b/src/bin/elementary/test_nstate.c
index dc9a8a03e7..27a75e4fe7 100644
--- a/src/bin/elementary/test_nstate.c
+++ b/src/bin/elementary/test_nstate.c
@@ -15,7 +15,7 @@ test_nstate(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in
{
Evas_Object *win, *bx, *nstate;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "N-state widget"),
elm_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_part_bg.c b/src/bin/elementary/test_part_bg.c
index 6c8cfbd903..ce54e105f7 100644
--- a/src/bin/elementary/test_part_bg.c
+++ b/src/bin/elementary/test_part_bg.c
@@ -143,7 +143,7 @@ test_part_background(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void
content_class[17] = EFL_UI_SPIN_CLASS;
content_class[18] = EFL_UI_SPIN_BUTTON_CLASS;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Widget Part Background"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_part_shadow.c b/src/bin/elementary/test_part_shadow.c
index 36f71eff0c..d0cc2d112a 100644
--- a/src/bin/elementary/test_part_shadow.c
+++ b/src/bin/elementary/test_part_shadow.c
@@ -71,7 +71,7 @@ _delete_cb(void *data, const Efl_Event *ev)
Test_Data *td = data;
pulse_stop(td, NULL);
- efl_unref(ev->object);
+ efl_del(ev->object);
free(td);
}
@@ -85,7 +85,7 @@ test_part_shadow(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *eve
td = calloc(1, sizeof(*td));
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_name_set(efl_added, "shadow"),
efl_text_set(efl_added, "Shadow effects"));
efl_event_callback_add(win, EFL_UI_WIN_EVENT_DELETE_REQUEST, _delete_cb, td);
diff --git a/src/bin/elementary/test_photocam.c b/src/bin/elementary/test_photocam.c
index 44fa967eb1..cb31d31e01 100644
--- a/src/bin/elementary/test_photocam.c
+++ b/src/bin/elementary/test_photocam.c
@@ -804,7 +804,7 @@ test_image_zoomable_animated(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSE
Eo *win, *bx, *zoomable, *rect;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Image_Zoomable animation"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_ui_button.c b/src/bin/elementary/test_ui_button.c
index 1d32e3f9b9..64332bb10c 100644
--- a/src/bin/elementary/test_ui_button.c
+++ b/src/bin/elementary/test_ui_button.c
@@ -27,7 +27,7 @@ test_ui_button(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event
Eo *win, *bx, *btn;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Button"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE)
diff --git a/src/bin/elementary/test_ui_clock.c b/src/bin/elementary/test_ui_clock.c
index 2e667b5026..4a60345621 100644
--- a/src/bin/elementary/test_ui_clock.c
+++ b/src/bin/elementary/test_ui_clock.c
@@ -47,7 +47,7 @@ test_ui_clock(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_
{
Evas_Object *win, *bx;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Clock"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_ui_panes.c b/src/bin/elementary/test_ui_panes.c
index 03b025bffb..4a19e00eed 100644
--- a/src/bin/elementary/test_ui_panes.c
+++ b/src/bin/elementary/test_ui_panes.c
@@ -8,7 +8,7 @@ test_panes_minsize(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *e
{
Eo *win, *panes, *panes_h;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Panes"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE)
diff --git a/src/bin/elementary/test_ui_popup.c b/src/bin/elementary/test_ui_popup.c
index c0115cc9f0..67318c9a6f 100644
--- a/src/bin/elementary/test_ui_popup.c
+++ b/src/bin/elementary/test_ui_popup.c
@@ -213,7 +213,7 @@ static void
_win_del(void *data, const Efl_Event *ev EINA_UNUSED)
{
efl_ui_popup_data *p_data = data;
- efl_unref(p_data->panel_win);
+ efl_del(p_data->panel_win);
free(p_data);
printf("window is deleted\n");
}
@@ -222,7 +222,7 @@ static void
_panel_win_del(void *data, const Efl_Event *ev EINA_UNUSED)
{
efl_ui_popup_data *p_data = data;
- efl_unref(p_data->win);
+ efl_del(p_data->win);
free(p_data);
printf("window is deleted\n");
}
@@ -232,14 +232,14 @@ test_ui_popup(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_
{
efl_ui_popup_data *p_data = (efl_ui_popup_data*)calloc(1, sizeof(efl_ui_popup_data));
- Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl.Ui.Popup"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
efl_event_callback_add(win, EFL_UI_WIN_EVENT_DELETE_REQUEST, _win_del, p_data);
efl_gfx_size_set(win, EINA_SIZE2D(500, 500));
- Eo *panel_win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ Eo *panel_win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl.Ui.Popup Panel"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
efl_event_callback_add(panel_win, EFL_UI_WIN_EVENT_DELETE_REQUEST, _panel_win_del, p_data);
@@ -351,7 +351,7 @@ test_ui_popup_alert(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *
{
char buf[PATH_MAX];
- Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl.Ui.Popup.Alert"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
@@ -506,7 +506,7 @@ _alert_scroll_case5_cb(void *data, const Efl_Event *ev EINA_UNUSED)
void
test_ui_popup_alert_scroll(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl.Ui.Popup.Alert.Scroll"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
@@ -889,7 +889,7 @@ _alert_text_case14_cb(void *data, const Efl_Event *ev EINA_UNUSED)
void
test_ui_popup_alert_text(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl.Ui.Popup.Alert.Text"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
@@ -999,7 +999,7 @@ test_ui_popup_anchor(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void
char buf[PATH_MAX];
- Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "Efl.Ui.Popup.Anchor"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
efl_event_callback_add(win, EFL_UI_WIN_EVENT_DELETE_REQUEST, _win_del, p_data);
diff --git a/src/bin/elementary/test_ui_progressbar.c b/src/bin/elementary/test_ui_progressbar.c
index 09a0e704c0..ac00c722a3 100644
--- a/src/bin/elementary/test_ui_progressbar.c
+++ b/src/bin/elementary/test_ui_progressbar.c
@@ -104,7 +104,7 @@ _win_delete_req_cb(void *d, const Efl_Event *ev EINA_UNUSED)
pbdata *pd = d;
if (pd->timer) ecore_timer_del(pd->timer);
- efl_unref(pd->win);
+ efl_del(pd->win);
free(pd);
}
@@ -117,7 +117,7 @@ test_ui_progressbar(void *data EINA_UNUSED, Eo *obj EINA_UNUSED, void *event_inf
pd = (pbdata *)calloc(1, sizeof(pbdata));
- pd->win = win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ pd->win = win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Progressbar"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE),
diff --git a/src/bin/elementary/test_ui_scroller.c b/src/bin/elementary/test_ui_scroller.c
index 4899b7dda5..cf3f0e75b6 100644
--- a/src/bin/elementary/test_ui_scroller.c
+++ b/src/bin/elementary/test_ui_scroller.c
@@ -28,7 +28,7 @@ test_efl_ui_scroller(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void
Eo *win, *sc, *sc2, *sc3, *bx, *bx2, *gd, *gd2;
int i, j;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl Ui Scroller"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_ui_slider.c b/src/bin/elementary/test_ui_slider.c
index ee4d198a40..3433a1d899 100644
--- a/src/bin/elementary/test_ui_slider.c
+++ b/src/bin/elementary/test_ui_slider.c
@@ -33,7 +33,7 @@ test_ui_slider(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event
double step;
char buf[PATH_MAX];
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Slider"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_ui_slider_interval.c b/src/bin/elementary/test_ui_slider_interval.c
index 60ff0003a3..f57858718f 100644
--- a/src/bin/elementary/test_ui_slider_interval.c
+++ b/src/bin/elementary/test_ui_slider_interval.c
@@ -32,7 +32,7 @@ test_slider_interval(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void
Eo *win, *bx, *hbx;
double step;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Slider_Interval"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_ui_spin.c b/src/bin/elementary/test_ui_spin.c
index b2ec5aad54..1321b75a0d 100644
--- a/src/bin/elementary/test_ui_spin.c
+++ b/src/bin/elementary/test_ui_spin.c
@@ -36,7 +36,7 @@ test_ui_spin(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_i
{
Eo *win, *bx, *sp;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Spin"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_ui_spin_button.c b/src/bin/elementary/test_ui_spin_button.c
index 5befcb40fd..27e513fa0e 100644
--- a/src/bin/elementary/test_ui_spin_button.c
+++ b/src/bin/elementary/test_ui_spin_button.c
@@ -14,7 +14,7 @@ test_ui_spin_button(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *
{
Eo *win, *bx;
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Ui.Spin_Button"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/bin/elementary/test_ui_table_static.c b/src/bin/elementary/test_ui_table_static.c
index 751453f0c9..629b021d54 100644
--- a/src/bin/elementary/test_ui_table_static.c
+++ b/src/bin/elementary/test_ui_table_static.c
@@ -104,7 +104,7 @@ test_ui_table_static(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void
Eo *win, *table, *bt, *rc, *en;
api_data *api = calloc(1, sizeof(*api));
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_name_set(efl_added, "table"),
efl_text_set(efl_added, "Table"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE),
diff --git a/src/bin/elementary/test_win_dialog.c b/src/bin/elementary/test_win_dialog.c
index 22d4f35835..84679b6714 100644
--- a/src/bin/elementary/test_win_dialog.c
+++ b/src/bin/elementary/test_win_dialog.c
@@ -101,7 +101,7 @@ _bt4_clicked_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *even
{
Efl_Canvas_Object *dia, *lb;
- dia = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ dia = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_DIALOG_BASIC),
efl_ui_win_name_set(efl_added, "window-dia-4"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE),
diff --git a/src/bin/elementary/test_win_indicator.c b/src/bin/elementary/test_win_indicator.c
index 72fad0a875..e7e6c207ba 100644
--- a/src/bin/elementary/test_win_indicator.c
+++ b/src/bin/elementary/test_win_indicator.c
@@ -14,7 +14,7 @@ _create_indicator(void)
{
const char *indi_name;
- Eo *win = efl_add_ref(EFL_UI_WIN_SOCKET_CLASS, NULL,
+ Eo *win = efl_add(EFL_UI_WIN_SOCKET_CLASS, efl_main_loop_get(),
efl_text_set(efl_added, "indicator"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE),
efl_ui_win_alpha_set(efl_added, EINA_TRUE));
@@ -91,7 +91,7 @@ test_win_indicator(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *e
indicator = _create_indicator();
// FIXME: Resizing window should no cause sizing issues!
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
efl_text_set(efl_added, "Efl.Win.Indicator"),
efl_gfx_size_hint_max_set(efl_added, EINA_SIZE2D(300, -1)),
diff --git a/src/bin/elementary/test_win_stack.c b/src/bin/elementary/test_win_stack.c
index d13072d041..de16e7bb83 100644
--- a/src/bin/elementary/test_win_stack.c
+++ b/src/bin/elementary/test_win_stack.c
@@ -18,13 +18,13 @@ _win_new(Evas_Object *stack_top, const char *title)
Evas_Object *bg, *bx, *bt, *lb, *win;
if (level >= 3)
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_name_set(efl_added, "window-stack"),
efl_ui_win_type_set(efl_added, ELM_WIN_NAVIFRAME_BASIC),
efl_text_set(efl_added, title),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
else
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
efl_ui_win_name_set(efl_added, "window-stack"),
efl_ui_win_type_set(efl_added, ELM_WIN_DIALOG_BASIC),
efl_text_set(efl_added, title),
diff --git a/src/examples/ecore/ecore_audio_custom.c b/src/examples/ecore/ecore_audio_custom.c
index b0d26a1e75..abd174b78e 100644
--- a/src/examples/ecore/ecore_audio_custom.c
+++ b/src/examples/ecore/ecore_audio_custom.c
@@ -56,9 +56,9 @@ main(int argc, const char *argv[])
ecore_app_args_set(argc, argv);
- out = efl_add_ref(ECORE_AUDIO_OBJ_OUT_PULSE_CLASS, NULL);
+ out = efl_add(ECORE_AUDIO_OBJ_OUT_PULSE_CLASS, efl_main_loop_get());
- in = efl_add_ref(ECORE_AUDIO_OBJ_IN_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_OBJ_IN_CLASS, efl_main_loop_get());
if (!in)
{
printf("error when creating ecore audio source.\n");
diff --git a/src/examples/ecore/ecore_audio_playback.c b/src/examples/ecore/ecore_audio_playback.c
index c659f09d55..1c322738d3 100644
--- a/src/examples/ecore/ecore_audio_playback.c
+++ b/src/examples/ecore/ecore_audio_playback.c
@@ -201,7 +201,7 @@ static void _play_finished(void *data EINA_UNUSED, const Efl_Event *event)
inputs = eina_list_remove(inputs, event->object);
ret = ecore_audio_obj_out_input_detach(out, event->object);
- efl_unref(event->object);
+ efl_del(event->object);
if (!ret)
printf("Could not detach input %s\n", name);
@@ -252,7 +252,7 @@ main(int argc, const char *argv[])
{
if (!strncmp(argv[i], "tone:", 5))
{
- in = efl_add_ref(ECORE_AUDIO_OBJ_IN_TONE_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_OBJ_IN_TONE_CLASS, efl_main_loop_get());
if (!in)
{
printf("error when creating ecore audio source.\n");
@@ -276,7 +276,7 @@ main(int argc, const char *argv[])
}
else
{
- in = efl_add_ref(ECORE_AUDIO_OBJ_IN_SNDFILE_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_OBJ_IN_SNDFILE_CLASS, efl_main_loop_get());
if (!in)
{
printf("error when creating ecore audio source.\n");
@@ -307,7 +307,7 @@ main(int argc, const char *argv[])
printf("Start: %s (%0.2fs)\n", name, length);
- out = efl_add_ref(ECORE_AUDIO_OBJ_OUT_PULSE_CLASS, NULL);
+ out = efl_add(ECORE_AUDIO_OBJ_OUT_PULSE_CLASS, efl_main_loop_get());
ret = ecore_audio_obj_out_input_attach(out, in);
if (!ret)
printf("Could not attach input %s\n", name);
diff --git a/src/examples/ecore/ecore_audio_to_ogg.c b/src/examples/ecore/ecore_audio_to_ogg.c
index 756e69a209..63c7f66904 100644
--- a/src/examples/ecore/ecore_audio_to_ogg.c
+++ b/src/examples/ecore/ecore_audio_to_ogg.c
@@ -24,8 +24,8 @@ static void _play_finished(void *data EINA_UNUSED, const Efl_Event *event)
printf("Done: %s\n", name);
ecore_audio_obj_in_output_get(event->object, &out);
- efl_unref(event->object);
- efl_unref(out);
+ efl_del(event->object);
+ efl_del(out);
ecore_main_loop_quit();
@@ -49,31 +49,31 @@ main(int argc, char *argv[])
ecore_audio_init();
- in = efl_add_ref(ECORE_AUDIO_OBJ_IN_SNDFILE_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_OBJ_IN_SNDFILE_CLASS, efl_main_loop_get());
efl_name_set(in, basename(argv[1]));
ret = ecore_audio_obj_source_set(in, argv[1]);
if (!ret) {
printf("Could not set %s as input\n", argv[1]);
- efl_unref(in);
+ efl_del(in);
return 1;
}
efl_event_callback_add(in, ECORE_AUDIO_EV_IN_STOPPED, _play_finished, NULL);
- out = efl_add_ref(ECORE_AUDIO_OBJ_OUT_SNDFILE_CLASS, NULL);
+ out = efl_add(ECORE_AUDIO_OBJ_OUT_SNDFILE_CLASS, efl_main_loop_get());
ret = ecore_audio_obj_source_set(out, argv[2]);
if (!ret) {
printf("Could not set %s as output\n", argv[2]);
- efl_unref(in);
- efl_unref(out);
+ efl_del(in);
+ efl_del(out);
return 1;
}
ret = ecore_audio_obj_out_input_attach(out, in);
if (!ret) {
printf("Could not attach input\n");
- efl_unref(out);
- efl_unref(in);
+ efl_del(out);
+ efl_del(in);
return 1;
}
diff --git a/src/examples/ecore/ecore_idler_example.c b/src/examples/ecore/ecore_idler_example.c
index 2185210763..a88a0029c8 100644
--- a/src/examples/ecore/ecore_idler_example.c
+++ b/src/examples/ecore/ecore_idler_example.c
@@ -110,7 +110,7 @@ main(void)
ctxt.enterer = ecore_idle_enterer_add(_enterer_cb, &ctxt);
ctxt.exiter = ecore_idle_exiter_add(_exiter_cb, &ctxt);
ctxt.idler = ecore_idler_add(_idler_cb, &ctxt);
-// ctxt.idler = efl_add_ref(ECORE_IDLER_CLASS, NULL, ecore_idler_constructor(efl_added, _idler_cb, &ctxt));
+// ctxt.idler = efl_add(ECORE_IDLER_CLASS, efl_main_loop_get(), ecore_idler_constructor(efl_added, _idler_cb, &ctxt));
ctxt.handler = ecore_event_handler_add(_event_type,
_event_handler_cb,
&ctxt);
diff --git a/src/examples/ecore/ecore_poller_example.c b/src/examples/ecore/ecore_poller_example.c
index 3cbbcc5f2e..928b937599 100644
--- a/src/examples/ecore/ecore_poller_example.c
+++ b/src/examples/ecore/ecore_poller_example.c
@@ -48,9 +48,9 @@ main(void)
poller2 = ecore_poller_add(ECORE_POLLER_CORE, 8, _poller_print_cb, str2);
poller3 = ecore_poller_add(ECORE_POLLER_CORE, 30, _poller_quit_cb, str3);
-// poller1 = efl_add_ref(ECORE_POLLER_CLASS, NULL, // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 4, _poller_print_cb, str1));
-// poller2 = efl_add_ref(ECORE_POLLER_CLASS, NULL, // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 8, _poller_print_cb, str2));
-// poller3 = efl_add_ref(ECORE_POLLER_CLASS, NULL, // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 20, _poller_quit_cb, str3));
+// poller1 = efl_add(ECORE_POLLER_CLASS, efl_main_loop_get(), // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 4, _poller_print_cb, str1));
+// poller2 = efl_add(ECORE_POLLER_CLASS, efl_main_loop_get(), // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 8, _poller_print_cb, str2));
+// poller3 = efl_add(ECORE_POLLER_CLASS, efl_main_loop_get(), // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 20, _poller_quit_cb, str3));
ecore_main_loop_begin();
@@ -61,9 +61,9 @@ main(void)
// ecore_poller_interval_set(poller2, 16, NULL);
ecore_main_loop_begin();
-// efl_unref(poller1);
-// efl_unref(poller2);
-// efl_unref(poller3);
+// efl_del(poller1);
+// efl_del(poller2);
+// efl_del(poller3);
ecore_poller_del(poller1);
ecore_poller_del(poller2);
ecore_poller_del(poller3);
diff --git a/src/examples/ecore/efl_io_copier_example.c b/src/examples/ecore/efl_io_copier_example.c
index b7e526bd3c..a07b79186a 100644
--- a/src/examples/ecore/efl_io_copier_example.c
+++ b/src/examples/ecore/efl_io_copier_example.c
@@ -452,7 +452,7 @@ efl_main(void *data EINA_UNUSED,
if (strcmp(input_fname, ":stdin:") == 0)
{
- input = efl_add_ref(EFL_IO_STDIN_CLASS, NULL,
+ input = efl_add(EFL_IO_STDIN_CLASS, ev->object,
efl_event_callback_array_add(efl_added, input_cbs(), NULL));
if (!input)
{
@@ -662,7 +662,7 @@ efl_main(void *data EINA_UNUSED,
else
{
/* regular file, open with flags: read-only and close-on-exec */
- input = efl_add_ref(EFL_IO_FILE_CLASS, NULL,
+ input = efl_add(EFL_IO_FILE_CLASS, ev->object,
efl_file_set(efl_added, input_fname, NULL), /* mandatory */
efl_io_file_flags_set(efl_added, O_RDONLY), /* default */
efl_io_closer_close_on_exec_set(efl_added, EINA_TRUE), /* recommended, set *after* flags, or include O_CLOEXEC in flags -- be careful with _WIN32 that doesn't support it. */
@@ -679,7 +679,7 @@ efl_main(void *data EINA_UNUSED,
if (strcmp(output_fname, ":stdout:") == 0)
{
- output = efl_add_ref(EFL_IO_STDOUT_CLASS, NULL,
+ output = efl_add(EFL_IO_STDOUT_CLASS, ev->object,
efl_event_callback_array_add(efl_added, output_cbs(), NULL) /* optional */
);
if (!output)
@@ -691,7 +691,7 @@ efl_main(void *data EINA_UNUSED,
}
else if (strcmp(output_fname, ":stderr:") == 0)
{
- output = efl_add_ref(EFL_IO_STDERR_CLASS, NULL,
+ output = efl_add(EFL_IO_STDERR_CLASS, ev->object,
efl_event_callback_array_add(efl_added, output_cbs(), NULL) /* optional */
);
if (!output)
@@ -718,7 +718,7 @@ efl_main(void *data EINA_UNUSED,
* When finished get the efl_io_buffer_slice_get(), see
* _copier_done().
*/
- output = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL,
+ output = efl_add(EFL_IO_BUFFER_CLASS, ev->object,
efl_event_callback_array_add(efl_added, output_cbs(), NULL), /* optional */
efl_event_callback_array_add(efl_added, output_buffer_cbs(), NULL) /* optional */
);
@@ -938,7 +938,7 @@ efl_main(void *data EINA_UNUSED,
/* regular file, open with flags: write-only, close-on-exec,
* create if did not exist and truncate if exist.
*/
- output = efl_add_ref(EFL_IO_FILE_CLASS, NULL,
+ output = efl_add(EFL_IO_FILE_CLASS, ev->object,
efl_file_set(efl_added, output_fname, NULL), /* mandatory */
efl_io_file_flags_set(efl_added, O_WRONLY | O_CREAT | O_TRUNC), /* mandatory for write */
efl_io_closer_close_on_exec_set(efl_added, EINA_TRUE), /* recommended, set *after* flags, or include O_CLOEXEC in flags -- be careful with _WIN32 that doesn't support it. */
diff --git a/src/examples/ecore/efl_io_queue_example.c b/src/examples/ecore/efl_io_queue_example.c
index 9367716729..1abd3b71b6 100644
--- a/src/examples/ecore/efl_io_queue_example.c
+++ b/src/examples/ecore/efl_io_queue_example.c
@@ -258,7 +258,7 @@ efl_main(void *data EINA_UNUSED,
* the line_delimiter, then wait for a reply from the server, then
* write another.
*/
- send_queue = efl_add_ref(EFL_IO_QUEUE_CLASS, NULL,
+ send_queue = efl_add(EFL_IO_QUEUE_CLASS, ev->object,
efl_name_set(efl_added, "send_queue"),
efl_io_queue_limit_set(efl_added, buffer_limit));
if (!send_queue)
@@ -279,7 +279,7 @@ efl_main(void *data EINA_UNUSED,
* Our example's usage is to peek its data with slice_get() then
* clear().
*/
- receive_queue = efl_add_ref(EFL_IO_QUEUE_CLASS, NULL,
+ receive_queue = efl_add(EFL_IO_QUEUE_CLASS, ev->object,
efl_name_set(efl_added, "receive_queue"),
efl_io_queue_limit_set(efl_added, buffer_limit),
efl_event_callback_add(efl_added, EFL_IO_QUEUE_EVENT_SLICE_CHANGED, _receiver_data, NULL));
@@ -359,9 +359,9 @@ efl_main(void *data EINA_UNUSED,
error_sender:
efl_del(dialer);
error_dialer:
- efl_unref(receive_queue);
+ efl_del(receive_queue);
error_receive_queue:
- efl_unref(send_queue);
+ efl_del(send_queue);
end:
EINA_LIST_FREE(commands, cmd)
{
diff --git a/src/examples/ecore/efl_net_server_example.c b/src/examples/ecore/efl_net_server_example.c
index 6d5aa30e80..694ce76418 100644
--- a/src/examples/ecore/efl_net_server_example.c
+++ b/src/examples/ecore/efl_net_server_example.c
@@ -350,11 +350,11 @@ _server_client_add(void *data EINA_UNUSED, const Efl_Event *event)
return;
}
- send_buffer = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL,
+ send_buffer = efl_add(EFL_IO_BUFFER_CLASS, efl_main_loop_get(),
efl_io_buffer_adopt_readonly(efl_added, hello_world_slice));
/* Unlimited buffer to store the received data. */
- recv_buffer = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL);
+ recv_buffer = efl_add(EFL_IO_BUFFER_CLASS, efl_main_loop_get());
/* an input copier that takes data from send_buffer and pushes to client */
d->send_copier = efl_add(EFL_IO_COPIER_CLASS, efl_parent_get(client),
@@ -712,7 +712,7 @@ efl_main(void *data EINA_UNUSED,
cipher = EFL_NET_SSL_CIPHER_TLSV1_2;
}
- ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add(EFL_NET_SSL_CONTEXT_CLASS, efl_main_loop_get(),
efl_net_ssl_context_certificates_set(efl_added, eina_list_iterator_new(certificates)),
efl_net_ssl_context_private_keys_set(efl_added, eina_list_iterator_new(private_keys)),
efl_net_ssl_context_certificate_revocation_lists_set(efl_added, eina_list_iterator_new(crls)),
diff --git a/src/examples/ecore/efl_net_server_simple_example.c b/src/examples/ecore/efl_net_server_simple_example.c
index 2d21352d03..485dc81476 100644
--- a/src/examples/ecore/efl_net_server_simple_example.c
+++ b/src/examples/ecore/efl_net_server_simple_example.c
@@ -520,7 +520,7 @@ efl_main(void *data EINA_UNUSED,
cipher = EFL_NET_SSL_CIPHER_TLSV1_2;
}
- ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add(EFL_NET_SSL_CONTEXT_CLASS, ev->object,
efl_net_ssl_context_certificates_set(efl_added, eina_list_iterator_new(certificates)),
efl_net_ssl_context_private_keys_set(efl_added, eina_list_iterator_new(private_keys)),
efl_net_ssl_context_certificate_revocation_lists_set(efl_added, eina_list_iterator_new(crls)),
diff --git a/src/examples/ecore/efl_net_socket_ssl_dialer_example.c b/src/examples/ecore/efl_net_socket_ssl_dialer_example.c
index 75acb0b42d..e3579b471a 100644
--- a/src/examples/ecore/efl_net_socket_ssl_dialer_example.c
+++ b/src/examples/ecore/efl_net_socket_ssl_dialer_example.c
@@ -311,7 +311,7 @@ efl_terminate(void *data EINA_UNUSED,
efl_del(dialer);
dialer = NULL;
- efl_unref(ssl_ctx);
+ efl_del(ssl_ctx);
ssl_ctx = NULL;
EINA_LIST_FREE(pending_send, str) free(str);
@@ -456,7 +456,7 @@ efl_main(void *data EINA_UNUSED,
/* create a new SSL context with command line configurations.
* another option would be to use the default dialer context */
#ifndef USE_DEFAULT_CONTEXT
- ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add(EFL_NET_SSL_CONTEXT_CLASS, ev->object,
efl_net_ssl_context_certificates_set(efl_added, eina_list_iterator_new(certificates)),
efl_net_ssl_context_private_keys_set(efl_added, eina_list_iterator_new(private_keys)),
efl_net_ssl_context_certificate_revocation_lists_set(efl_added, eina_list_iterator_new(crls)),
@@ -528,7 +528,7 @@ efl_main(void *data EINA_UNUSED,
efl_io_closer_close(dialer); /* just del won't do as ssl has an extra ref */
efl_del(dialer);
no_ssl_ctx:
- efl_unref(ssl_ctx);
+ efl_del(ssl_ctx);
end:
EINA_LIST_FREE(pending_send, str) free(str);
diff --git a/src/examples/ecore/efl_net_socket_ssl_server_example.c b/src/examples/ecore/efl_net_socket_ssl_server_example.c
index 1010ca7fda..77d435e107 100644
--- a/src/examples/ecore/efl_net_socket_ssl_server_example.c
+++ b/src/examples/ecore/efl_net_socket_ssl_server_example.c
@@ -227,7 +227,7 @@ efl_terminate(void *data EINA_UNUSED,
efl_del(server);
server = NULL;
- efl_unref(ssl_ctx);
+ efl_del(ssl_ctx);
ssl_ctx = NULL;
EINA_LIST_FREE(certificates, str) free(str);
@@ -301,7 +301,7 @@ efl_main(void *data EINA_UNUSED,
cipher = EFL_NET_SSL_CIPHER_TLSV1_2;
}
- ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add(EFL_NET_SSL_CONTEXT_CLASS, ev->object,
efl_net_ssl_context_certificates_set(efl_added, eina_list_iterator_new(certificates)),
efl_net_ssl_context_private_keys_set(efl_added, eina_list_iterator_new(private_keys)),
efl_net_ssl_context_certificate_revocation_lists_set(efl_added, eina_list_iterator_new(crls)),
@@ -363,7 +363,7 @@ efl_main(void *data EINA_UNUSED,
efl_del(server);
server = NULL;
end_ctx:
- efl_unref(ssl_ctx);
+ efl_del(ssl_ctx);
end:
EINA_LIST_FREE(certificates, str) free(str);
diff --git a/src/examples/eio/eio_sentry.c b/src/examples/eio/eio_sentry.c
index e604e8900d..f6b3e8ac51 100644
--- a/src/examples/eio/eio_sentry.c
+++ b/src/examples/eio/eio_sentry.c
@@ -27,7 +27,7 @@ void
monitor_stuff(void *data)
{
const char *path = data;
- Eio_Sentry *sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ Eio_Sentry *sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
efl_event_callback_add(sentry, EIO_SENTRY_EVENT_FILE_CREATED, (Efl_Event_Cb)&sentry_cb, NULL);
printf("Starting monitoring path %s\n", path);
diff --git a/src/examples/elementary/efl_ui_list_example_1.c b/src/examples/elementary/efl_ui_list_example_1.c
index eeb2f2329e..9a44853d64 100644
--- a/src/examples/elementary/efl_ui_list_example_1.c
+++ b/src/examples/elementary/efl_ui_list_example_1.c
@@ -49,7 +49,7 @@ _make_model()
unsigned int i, s;
char buf[256];
- model = efl_add_ref(EFL_MODEL_ITEM_CLASS, NULL);
+ model = efl_add(EFL_MODEL_ITEM_CLASS, efl_main_loop_get());
eina_value_setup(&vtext, EINA_VALUE_TYPE_STRING);
for (i = 0; i < (NUM_ITEMS); i++)
diff --git a/src/examples/elementary/efl_ui_list_example_2.c b/src/examples/elementary/efl_ui_list_example_2.c
index 9826487c78..59a0eacd95 100644
--- a/src/examples/elementary/efl_ui_list_example_2.c
+++ b/src/examples/elementary/efl_ui_list_example_2.c
@@ -43,7 +43,7 @@ elm_main(int argc, char **argv)
if (argv[1] != NULL) dirname = argv[1];
else dirname = EFL_MODEL_TEST_FILENAME_PATH;
- model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
+ model = efl_add(EIO_MODEL_CLASS, efl_main_loop_get(), eio_model_path_set(efl_added, dirname));
factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win);
efl_ui_model_connect(factory, "elm.text", "filename");
efl_ui_layout_factory_theme_config(factory, "list", "item", "default");
diff --git a/src/examples/elementary/efl_ui_list_example_3.c b/src/examples/elementary/efl_ui_list_example_3.c
index 0e211e03fe..5f516e6476 100644
--- a/src/examples/elementary/efl_ui_list_example_3.c
+++ b/src/examples/elementary/efl_ui_list_example_3.c
@@ -173,7 +173,7 @@ _make_model()
Efl_Model_Item *model, *child;
unsigned int i, len;
- model = efl_add_ref(EFL_MODEL_ITEM_CLASS, NULL);
+ model = efl_add(EFL_MODEL_ITEM_CLASS, efl_main_loop_get());
eina_value_setup(&vtext, EINA_VALUE_TYPE_STRING);
eina_value_setup(&value, EINA_VALUE_TYPE_UCHAR);
diff --git a/src/examples/elementary/efl_ui_scroller_example.c b/src/examples/elementary/efl_ui_scroller_example.c
index 64886337b2..e5588ab34e 100644
--- a/src/examples/elementary/efl_ui_scroller_example.c
+++ b/src/examples/elementary/efl_ui_scroller_example.c
@@ -15,8 +15,8 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev)
elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);
elm_app_info_set(efl_main, "elementary", "images/plant_01.jpg");
- win = efl_add_ref(EFL_UI_WIN_CLASS, NULL, "TEST", ELM_WIN_BASIC,
- efl_ui_win_autodel_set(efl_added, EINA_TRUE));
+ win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(), "TEST", ELM_WIN_BASIC,
+ efl_ui_win_autodel_set(efl_added, EINA_TRUE));
efl_gfx_size_set(win, EINA_SIZE2D(300, 400));
scroller = efl_add(EFL_UI_SCROLLER_CLASS, win);
diff --git a/src/examples/elementary/filemvc.c b/src/examples/elementary/filemvc.c
index 657148c0e0..92646a73ee 100644
--- a/src/examples/elementary/filemvc.c
+++ b/src/examples/elementary/filemvc.c
@@ -67,7 +67,7 @@ _promise_then(void *data, const Efl_Event *event)
Eina_Value* value = info->value;
eina_value_get(value, &path);
- model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
+ model = efl_add(EIO_MODEL_CLASS, efl_main_loop_get(), eio_model_path_set(efl_added, path));
elm_view_list_model_set(priv->fileview, model);
}
@@ -150,12 +150,12 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
else dirname = EFL_MODEL_TEST_FILENAME_PATH;
//treemodel
- priv.treemodel = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
+ priv.treemodel = efl_add(EIO_MODEL_CLASS, efl_main_loop_get(), eio_model_path_set(efl_added, dirname));
eio_model_children_filter_set(priv.treemodel, _filter_cb, NULL);
//treeview
genlist = elm_genlist_add(win);
- priv.treeview = efl_add_ref(ELM_VIEW_LIST_CLASS, NULL, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_TREE, NULL));
+ priv.treeview = efl_add(ELM_VIEW_LIST_CLASS, efl_main_loop_get(), elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_TREE, NULL));
elm_view_list_property_connect(priv.treeview, "filename", "elm.text");
elm_view_list_property_connect(priv.treeview, "icon", "elm.swallow.icon");
elm_view_list_model_set(priv.treeview, priv.treemodel);
@@ -170,7 +170,7 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
//listview
genlist = elm_genlist_add(win);
- priv.fileview = efl_add_ref(ELM_VIEW_LIST_CLASS, NULL, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_NONE, "double_label"));
+ priv.fileview = efl_add(ELM_VIEW_LIST_CLASS, efl_main_loop_get(), elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_NONE, "double_label"));
elm_view_list_property_connect(priv.fileview, "filename", "elm.text");
elm_view_list_property_connect(priv.fileview, "mime_type", "elm.text.sub");
@@ -184,7 +184,7 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
bxr = elm_box_add(win);
_widget_init(bxr);
elm_object_part_content_set(vpanes, "right", bxr);
- priv.formview = efl_add_ref(ELM_VIEW_FORM_CLASS, NULL);
+ priv.formview = efl_add(ELM_VIEW_FORM_CLASS, efl_main_loop_get());
/*Label widget */
elm_view_form_widget_add(priv.formview, "filename", _label_init(win, bxr, "File Name"));
diff --git a/src/examples/elementary/fileviewlist.c b/src/examples/elementary/fileviewlist.c
index 39df4f87c0..d36295f017 100644
--- a/src/examples/elementary/fileviewlist.c
+++ b/src/examples/elementary/fileviewlist.c
@@ -54,8 +54,8 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
evas_object_size_hint_weight_set(genlist, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
evas_object_show(genlist);
- priv.filemodel = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
- priv.fileview = efl_add_ref(ELM_VIEW_LIST_CLASS, NULL, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_TREE, "double_label"));
+ priv.filemodel = efl_add(EIO_MODEL_CLASS, efl_main_loop_get(), eio_model_path_set(efl_added, dirname));
+ priv.fileview = efl_add(ELM_VIEW_LIST_CLASS, efl_main_loop_get(), elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_TREE, "double_label"));
elm_view_list_model_set(priv.fileview, priv.filemodel);
evas_object_event_callback_add(win, EVAS_CALLBACK_DEL, _cleanup_cb, &priv);
diff --git a/src/examples/elementary/layout_model_connect.c b/src/examples/elementary/layout_model_connect.c
index e93b34437d..7021a2cca5 100644
--- a/src/examples/elementary/layout_model_connect.c
+++ b/src/examples/elementary/layout_model_connect.c
@@ -111,10 +111,10 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
if (argv[1] != NULL) dirname = argv[1];
else dirname = EFL_MODEL_TEST_FILENAME_PATH;
- priv->model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
+ priv->model = efl_add(EIO_MODEL_CLASS, efl_main_loop_get(), eio_model_path_set(efl_added, dirname));
genlist = elm_genlist_add(win);
- priv->fileview = efl_add_ref(ELM_VIEW_LIST_CLASS, NULL, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_NONE, NULL));
+ priv->fileview = efl_add(ELM_VIEW_LIST_CLASS, efl_main_loop_get(), elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_NONE, NULL));
elm_view_list_property_connect(priv->fileview, "filename", "elm.text");
elm_view_list_model_set(priv->fileview, priv->model);
_widget_init(genlist);
diff --git a/src/lib/ecore_con/ecore_con_eet.c b/src/lib/ecore_con/ecore_con_eet.c
index 4fa79b7736..3239bcaa89 100644
--- a/src/lib/ecore_con/ecore_con_eet.c
+++ b/src/lib/ecore_con/ecore_con_eet.c
@@ -733,7 +733,7 @@ ecore_con_eet_server_new(Ecore_Con_Server *server)
if (!server) return NULL;
- ece_obj = efl_add_ref(ECORE_CON_EET_SERVER_OBJ_CLASS, NULL, ecore_con_eet_base_server_set(efl_added, server));
+ ece_obj = efl_add(ECORE_CON_EET_SERVER_OBJ_CLASS, efl_main_loop_get(), ecore_con_eet_base_server_set(efl_added, server));
return ece_obj;
}
@@ -745,7 +745,7 @@ ecore_con_eet_client_new(Ecore_Con_Server *server)
if (!server) return NULL;
- ece_obj = efl_add_ref(ECORE_CON_EET_CLIENT_OBJ_CLASS, NULL, ecore_con_eet_base_server_set(efl_added, server));
+ ece_obj = efl_add(ECORE_CON_EET_CLIENT_OBJ_CLASS, efl_main_loop_get(), ecore_con_eet_base_server_set(efl_added, server));
return ece_obj;
}
@@ -753,7 +753,7 @@ ecore_con_eet_client_new(Ecore_Con_Server *server)
EAPI void
ecore_con_eet_server_free(Ecore_Con_Eet *server)
{
- efl_unref(server);
+ efl_del(server);
}
EAPI void
diff --git a/src/lib/ecore_con/ecore_con_legacy.c b/src/lib/ecore_con/ecore_con_legacy.c
index 8b5055589c..356b25422a 100644
--- a/src/lib/ecore_con/ecore_con_legacy.c
+++ b/src/lib/ecore_con/ecore_con_legacy.c
@@ -1591,7 +1591,7 @@ _ecore_con_server_ssl_ctx_create(const Ecore_Con_Server *svr)
/* legacy compatibility: server never verified peer, only dialer did */
- return efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ return efl_add(EFL_NET_SSL_CONTEXT_CLASS, efl_main_loop_get(),
efl_net_ssl_context_certificates_set(efl_added, eina_list_iterator_new(svr->ssl.certs)),
efl_net_ssl_context_private_keys_set(efl_added, eina_list_iterator_new(svr->ssl.privkeys)),
efl_net_ssl_context_certificate_revocation_lists_set(efl_added, eina_list_iterator_new(svr->ssl.crls)),
@@ -1646,7 +1646,7 @@ _ecore_con_server_server_ssl_job(void *data, const Eina_Value v,
error_server:
efl_del(inner_server);
error_inner_server:
- efl_unref(ssl_ctx);
+ efl_del(ssl_ctx);
error_ssl_ctx:
if (_ecore_con_post_event_server_error(svr, "Couldn't finish SSL setup"))
_ecore_con_post_event_server_del(svr);
@@ -1970,7 +1970,7 @@ _ecore_con_server_dialer_ssl_job(void *data, const Eina_Value v,
if (svr->ssl.verify)
verify_mode = EFL_NET_SSL_VERIFY_MODE_REQUIRED;
- ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add(EFL_NET_SSL_CONTEXT_CLASS, efl_main_loop_get(),
efl_net_ssl_context_certificates_set(efl_added, eina_list_iterator_new(svr->ssl.certs)),
efl_net_ssl_context_private_keys_set(efl_added, eina_list_iterator_new(svr->ssl.privkeys)),
efl_net_ssl_context_certificate_revocation_lists_set(efl_added, eina_list_iterator_new(svr->ssl.crls)),
@@ -2025,7 +2025,7 @@ _ecore_con_server_dialer_ssl_job(void *data, const Eina_Value v,
error_dialer:
efl_del(inner_dialer);
error_inner_dialer:
- efl_unref(ssl_ctx);
+ efl_del(ssl_ctx);
error_ssl_ctx:
if (_ecore_con_post_event_server_error(svr, "Couldn't finish SSL setup"))
_ecore_con_post_event_server_del(svr);
@@ -2064,7 +2064,7 @@ _ecore_con_server_dialer_ssl_upgrade_job(void *data, const Eina_Value v,
if (svr->ssl.verify)
verify_mode = EFL_NET_SSL_VERIFY_MODE_REQUIRED;
- ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add(EFL_NET_SSL_CONTEXT_CLASS, efl_main_loop_get(),
efl_net_ssl_context_certificates_set(efl_added, eina_list_iterator_new(svr->ssl.certs)),
efl_net_ssl_context_private_keys_set(efl_added, eina_list_iterator_new(svr->ssl.privkeys)),
efl_net_ssl_context_certificate_revocation_lists_set(efl_added, eina_list_iterator_new(svr->ssl.crls)),
@@ -2111,7 +2111,7 @@ _ecore_con_server_dialer_ssl_upgrade_job(void *data, const Eina_Value v,
efl_del(inner_dialer);
error_inner_dialer:
svr->dialer = tcp_dialer; /* put it back */
- efl_unref(ssl_ctx);
+ efl_del(ssl_ctx);
error_ssl_ctx:
if (_ecore_con_post_event_server_error(svr, "Couldn't finish SSL setup"))
_ecore_con_post_event_server_del(svr);
diff --git a/src/lib/ecore_con/ecore_con_local_win32.c b/src/lib/ecore_con/ecore_con_local_win32.c
index fb43f943fc..86593a2ffa 100644
--- a/src/lib/ecore_con/ecore_con_local_win32.c
+++ b/src/lib/ecore_con/ecore_con_local_win32.c
@@ -262,7 +262,7 @@ _ecore_con_local_win32_client_add(void *data, Ecore_Win32_Handler *wh)
(svr->client_count >= (unsigned int)svr->client_limit))
return ECORE_CALLBACK_CANCEL;
- Ecore_Con_Client *cl_obj = efl_add_ref(EFL_NETWORK_CLIENT_CLASS, NULL);
+ Ecore_Con_Client *cl_obj = efl_add(EFL_NETWORK_CLIENT_CLASS, efl_main_loop_get());
Efl_Network_Client_Data *cl = efl_data_scope_get(obj, EFL_NETWORK_CLIENT_CLASS);
if (!cl)
{
@@ -332,7 +332,7 @@ del_handler_read:
close_event_read:
CloseHandle(svr->event_read);
free_cl:
- efl_unref(cl_obj);
+ efl_del(cl_obj);
return ECORE_CALLBACK_CANCEL;
}
diff --git a/src/lib/ecore_evas/ecore_evas.c b/src/lib/ecore_evas/ecore_evas.c
index 9f3293af7e..8e90539d59 100644
--- a/src/lib/ecore_evas/ecore_evas.c
+++ b/src/lib/ecore_evas/ecore_evas.c
@@ -3533,7 +3533,7 @@ _ecore_evas_mouse_move_process_internal(Ecore_Evas *ee,
efl_event_callback_legacy_call(ee->evas,
_event_description_get(ev->action), evt);
- efl_del(evt);
+ efl_unref(evt);
}
EAPI void
@@ -4756,7 +4756,7 @@ _direct_mouse_move_cb(Ecore_Evas *ee, const Ecore_Event_Mouse_Move *info)
efl_event_callback_legacy_call(e, _event_description_get(ev->action), evt);
processed = ev->evas_done;
- efl_del(evt);
+ efl_unref(evt);
return processed;
}
@@ -4791,7 +4791,7 @@ _direct_mouse_wheel_cb(Ecore_Evas *ee, const Ecore_Event_Mouse_Wheel *info)
efl_event_callback_legacy_call(e, _event_description_get(ev->action), evt);
processed = ev->evas_done;
- efl_del(evt);
+ efl_unref(evt);
return processed;
}
@@ -4821,7 +4821,7 @@ _direct_mouse_inout(Ecore_Evas *ee, const Ecore_Event_Mouse_IO *info, Efl_Pointe
efl_event_callback_legacy_call(e, _event_description_get(ev->action), evt);
processed = ev->evas_done;
- efl_del(evt);
+ efl_unref(evt);
return processed;
}
@@ -4951,7 +4951,7 @@ _direct_axis_update_cb(Ecore_Evas *ee, const Ecore_Event_Axis_Update *info)
efl_event_callback_legacy_call(e, _event_description_get(ev->action), evt);
processed = ev->evas_done;
- efl_del(evt);
+ efl_unref(evt);
return processed;
}
@@ -4993,7 +4993,7 @@ _direct_key_updown_cb(Ecore_Evas *ee, const Ecore_Event_Key *info, Eina_Bool dow
efl_event_callback_legacy_call(e, EFL_EVENT_KEY_UP, evt);
processed = ev->evas_done;
- efl_del(evt);
+ efl_unref(evt);
return processed;
}
diff --git a/src/lib/edje/edje_main.c b/src/lib/edje/edje_main.c
index 338fb66c88..bd49820179 100644
--- a/src/lib/edje/edje_main.c
+++ b/src/lib/edje/edje_main.c
@@ -153,7 +153,7 @@ shutdown_all:
efl_loop_unregister(efl_main_loop_get(), EFL_GFX_COLOR_CLASS_INTERFACE, _edje_global_obj);
efl_loop_unregister(efl_main_loop_get(), EFL_GFX_TEXT_CLASS_INTERFACE, _edje_global_obj);
efl_loop_unregister(efl_main_loop_get(), EFL_GFX_SIZE_CLASS_INTERFACE, _edje_global_obj);
- efl_unref(_edje_global_obj);
+ efl_del(_edje_global_obj);
_edje_global_obj = NULL;
}
shutdown_efreet:
@@ -212,7 +212,7 @@ _edje_shutdown_core(void)
efl_loop_unregister(efl_main_loop_get(), EFL_GFX_COLOR_CLASS_INTERFACE, _edje_global_obj);
efl_loop_unregister(efl_main_loop_get(), EFL_GFX_TEXT_CLASS_INTERFACE, _edje_global_obj);
efl_loop_unregister(efl_main_loop_get(), EFL_GFX_SIZE_CLASS_INTERFACE, _edje_global_obj);
- efl_unref(_edje_global_obj);
+ efl_del(_edje_global_obj);
_edje_global_obj = NULL;
eina_cow_del(_edje_calc_params_map_cow);
@@ -286,17 +286,17 @@ _edje_class_shutdown(void)
{
if (_edje_color_class_member)
{
- efl_unref(_edje_color_class_member);
+ efl_del(_edje_color_class_member);
_edje_color_class_member = NULL;
}
if (_edje_text_class_member)
{
- efl_unref(_edje_text_class_member);
+ efl_del(_edje_text_class_member);
_edje_text_class_member = NULL;
}
if (_edje_size_class_member)
{
- efl_unref(_edje_size_class_member);
+ efl_del(_edje_size_class_member);
_edje_size_class_member = NULL;
}
}
diff --git a/src/lib/edje/edje_multisense.c b/src/lib/edje/edje_multisense.c
index 0d99826d22..0af6ec453b 100644
--- a/src/lib/edje/edje_multisense.c
+++ b/src/lib/edje/edje_multisense.c
@@ -10,14 +10,14 @@ static Eina_Bool outfail = EINA_FALSE;
static void
_play_finished(void *data EINA_UNUSED, const Efl_Event *event)
{
- efl_unref(event->object);
+ efl_del(event->object);
}
static void
_out_fail(void *data EINA_UNUSED, const Efl_Event *event)
{
outfail = EINA_TRUE;
- efl_unref(event->object);
+ efl_del(event->object);
out = NULL;
}
@@ -199,15 +199,15 @@ _edje_multisense_internal_sound_sample_play(Edje *ed, const char *sample_name, c
eet_data->vio.tell = eet_snd_file_tell;
eet_data->offset = 0;
- in = efl_add_ref(ECORE_AUDIO_IN_SNDFILE_CLASS, NULL, efl_name_set(efl_added, snd_id_str), ecore_audio_obj_in_speed_set(efl_added, speed), ecore_audio_obj_vio_set(efl_added, &eet_data->vio, eet_data, _free), efl_event_callback_add(efl_added, ECORE_AUDIO_IN_EVENT_IN_STOPPED, _play_finished, NULL));
+ in = efl_add(ECORE_AUDIO_IN_SNDFILE_CLASS, efl_main_loop_get(), efl_name_set(efl_added, snd_id_str), ecore_audio_obj_in_speed_set(efl_added, speed), ecore_audio_obj_vio_set(efl_added, &eet_data->vio, eet_data, _free), efl_event_callback_add(efl_added, ECORE_AUDIO_IN_EVENT_IN_STOPPED, _play_finished, NULL));
if (!out)
{
# ifdef _WIN32
- out = efl_add_ref(ECORE_AUDIO_OUT_WASAPI_CLASS, NULL, efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_WASAPI_EVENT_CONTEXT_FAIL, _out_fail, NULL));
+ out = efl_add(ECORE_AUDIO_OUT_WASAPI_CLASS, efl_main_loop_get(), efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_WASAPI_EVENT_CONTEXT_FAIL, _out_fail, NULL));
# else
# ifdef HAVE_PULSE
- out = efl_add_ref(ECORE_AUDIO_OUT_PULSE_CLASS, NULL, efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_PULSE_EVENT_CONTEXT_FAIL, _out_fail, NULL));
+ out = efl_add(ECORE_AUDIO_OUT_PULSE_CLASS, efl_main_loop_get(), efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_PULSE_EVENT_CONTEXT_FAIL, _out_fail, NULL));
# endif
# endif
if (out) outs++;
@@ -227,7 +227,7 @@ _edje_multisense_internal_sound_sample_play(Edje *ed, const char *sample_name, c
# endif
# endif
}
- efl_unref(in);
+ efl_del(in);
return EINA_FALSE;
}
ret = ecore_audio_obj_out_input_attach(out, in);
@@ -240,7 +240,7 @@ _edje_multisense_internal_sound_sample_play(Edje *ed, const char *sample_name, c
complained = EINA_TRUE;
ERR("Could not attach input");
}
- efl_unref(in);
+ efl_del(in);
return EINA_FALSE;
}
}
@@ -283,7 +283,7 @@ _edje_multisense_internal_sound_tone_play(Edje *ed, const char *tone_name, const
tone = &ed->file->sound_dir->tones[i];
if (!strcmp(tone->name, tone_name))
{
- in = efl_add_ref(ECORE_AUDIO_IN_TONE_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_IN_TONE_CLASS, efl_main_loop_get());
efl_name_set(in, "tone");
efl_key_data_set(in, ECORE_AUDIO_ATTR_TONE_FREQ, &tone->value);
ecore_audio_obj_in_length_set(in, duration);
@@ -292,10 +292,10 @@ _edje_multisense_internal_sound_tone_play(Edje *ed, const char *tone_name, const
if (!out)
{
# ifdef _WIN32
- out = efl_add_ref(ECORE_AUDIO_OUT_WASAPI_CLASS, NULL, efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_WASAPI_EVENT_CONTEXT_FAIL, _out_fail, NULL));
+ out = efl_add(ECORE_AUDIO_OUT_WASAPI_CLASS, efl_main_loop_get(), efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_WASAPI_EVENT_CONTEXT_FAIL, _out_fail, NULL));
# else
# ifdef HAVE_PULSE
- out = efl_add_ref(ECORE_AUDIO_OUT_PULSE_CLASS, NULL, efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_PULSE_EVENT_CONTEXT_FAIL, _out_fail, NULL));
+ out = efl_add(ECORE_AUDIO_OUT_PULSE_CLASS, efl_main_loop_get(), efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_PULSE_EVENT_CONTEXT_FAIL, _out_fail, NULL));
# endif
# endif
if (out) outs++;
@@ -305,7 +305,7 @@ _edje_multisense_internal_sound_tone_play(Edje *ed, const char *tone_name, const
if (!ret)
{
ERR("Could not attach input");
- efl_unref(in);
+ efl_del(in);
return EINA_FALSE;
}
}
@@ -353,7 +353,7 @@ _edje_multisense_shutdown(void)
if (out)
{
// XXX: this causes an abort inside of pa!!!!!
- //efl_unref(out);
+ //efl_del(out);
out = NULL;
outs = 0;
}
diff --git a/src/lib/eio/eio_model.c b/src/lib/eio/eio_model.c
index 76cdc246c0..c34257fa38 100644
--- a/src/lib/eio/eio_model.c
+++ b/src/lib/eio/eio_model.c
@@ -175,7 +175,7 @@ _efl_model_evt_added_ecore_cb(void *data, int type, void *event)
eina_stringshare_del(spath);
}
- cevt.child = efl_add_ref(EIO_MODEL_CLASS, priv->obj, eio_model_path_set(efl_added, evt->filename));
+ cevt.child = efl_add(EIO_MODEL_CLASS, priv->obj, eio_model_path_set(efl_added, evt->filename));
priv->children_list = eina_list_append(priv->children_list, cevt.child);
cevt.index = eina_list_count(priv->children_list);
diff --git a/src/lib/elementary/efl_ui_focus_composition.c b/src/lib/elementary/efl_ui_focus_composition.c
index 9171aa2f74..c1a76ef271 100644
--- a/src/lib/elementary/efl_ui_focus_composition.c
+++ b/src/lib/elementary/efl_ui_focus_composition.c
@@ -95,7 +95,7 @@ _efl_ui_focus_composition_composition_elements_set(Eo *obj, Efl_Ui_Focus_Composi
}
else if (efl_isa(elem, EFL_GFX_INTERFACE))
{
- o = efl_add_ref(EFL_UI_FOCUS_COMPOSITION_ADAPTER_CLASS, NULL, efl_ui_focus_composition_adapter_canvas_object_set(efl_added, elem));
+ o = efl_add(EFL_UI_FOCUS_COMPOSITION_ADAPTER_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS), efl_ui_focus_composition_adapter_canvas_object_set(efl_added, elem));
pd->adapters = eina_list_append(pd->adapters, o);
pd->register_target = eina_list_append(pd->register_target , o);
diff --git a/src/lib/elementary/efl_ui_list.c b/src/lib/elementary/efl_ui_list.c
index 49c94558c4..83397cbbed 100644
--- a/src/lib/elementary/efl_ui_list.c
+++ b/src/lib/elementary/efl_ui_list.c
@@ -699,7 +699,7 @@ _efl_ui_list_efl_object_finalize(Eo *obj, Efl_Ui_List_Data *pd)
{
if (!pd->factory)
- pd->factory = efl_add_ref(EFL_UI_LAYOUT_FACTORY_CLASS, NULL);
+ pd->factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS));
if(!pd->relayout)
{
diff --git a/src/lib/elementary/elc_fileselector.c b/src/lib/elementary/elc_fileselector.c
index f0a6d2c52a..19441f377f 100644
--- a/src/lib/elementary/elc_fileselector.c
+++ b/src/lib/elementary/elc_fileselector.c
@@ -1289,7 +1289,7 @@ _on_dir_up(void *data, const Efl_Event *event EINA_UNUSED)
}
static void
-_home(void *data, const Efl_Event *event EINA_UNUSED)
+_home(void *data, const Efl_Event *event)
{
Evas_Object *fs = data;
ELM_FILESELECTOR_DATA_GET(fs, sd);
@@ -1297,7 +1297,7 @@ _home(void *data, const Efl_Event *event EINA_UNUSED)
// FIXME: maybe use vpath
if (!sd->model || efl_isa(sd->model, EIO_MODEL_CLASS))
{
- Eio_Model *model = efl_add_ref(EIO_MODEL_CLASS, NULL,
+ Eio_Model *model = efl_add(EIO_MODEL_CLASS, efl_provider_find(event->object, EFL_LOOP_CLASS),
eio_model_path_set(efl_added, eina_environment_home_get()));
_populate(fs, model, NULL, NULL);
efl_unref(model);
@@ -2103,7 +2103,7 @@ _from_legacy_event_call(Elm_Fileselector *fs, Elm_Fileselector_Data *sd, const E
else
model_cls = efl_class_get(sd->model);
- Efl_Model *model = efl_add_ref(model_cls, NULL);
+ Efl_Model *model = efl_add(model_cls, efl_provider_find(sd->obj, EFL_LOOP_CLASS));
_model_str_property_set(model, "path", path);
// Call Eo event with model
@@ -2312,7 +2312,7 @@ elm_fileselector_path_set(Evas_Object *obj,
void
_elm_fileselector_path_set_internal(Evas_Object *obj, const char *_path)
{
- Eio_Model *model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, _path));
+ Eio_Model *model = efl_add(EIO_MODEL_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS), eio_model_path_set(efl_added, _path));
if (!model)
{
ERR("Efl.Model allocation error");
@@ -2570,7 +2570,7 @@ _elm_fileselector_selected_set_internal(Evas_Object *obj, const char *_path)
if (ecore_file_is_dir(path))
{
- model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
+ model = efl_add(EIO_MODEL_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS), eio_model_path_set(efl_added, path));
if (!model)
{
ERR("Efl.Model allocation error");
@@ -2588,7 +2588,7 @@ _elm_fileselector_selected_set_internal(Evas_Object *obj, const char *_path)
goto clean_up;
}
- model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
+ model = efl_add(EIO_MODEL_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS), eio_model_path_set(efl_added, path));
if (!model)
{
ERR("Efl.Model allocation error");
@@ -2596,7 +2596,7 @@ _elm_fileselector_selected_set_internal(Evas_Object *obj, const char *_path)
}
dir = ecore_file_dir_get(path);
- parent = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dir));
+ parent = efl_add(EIO_MODEL_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS), eio_model_path_set(efl_added, dir));
if (parent)
{
_schedule_populate(obj, sd, parent, model);
diff --git a/src/lib/elementary/elc_fileselector_button.c b/src/lib/elementary/elc_fileselector_button.c
index 4072c843e8..9a89da5f00 100644
--- a/src/lib/elementary/elc_fileselector_button.c
+++ b/src/lib/elementary/elc_fileselector_button.c
@@ -106,6 +106,7 @@ _selection_done(void *data, const Efl_Event *event)
Efl_Future *future = NULL;
if (sd->fsd.model)
efl_unref(sd->fsd.model);
+ // XXX: the efl_ref here smells wrong. fsd.model is only unreffed ONCE so this obj leaks...
sd->fsd.model = efl_ref(model);
future = efl_model_property_get(model, "path");
efl_future_then(future, _replace_path_then, _replace_path_then_error, NULL, sd);
@@ -222,7 +223,7 @@ _elm_fileselector_button_efl_canvas_group_group_add(Eo *obj, Elm_Fileselector_Bu
if (path) priv->fsd.path = eina_stringshare_add(path);
else priv->fsd.path = eina_stringshare_add("/");
- priv->fsd.model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, priv->fsd.path));
+ priv->fsd.model = efl_add(EIO_MODEL_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS), eio_model_path_set(efl_added, priv->fsd.path));
priv->fsd.expandable = _elm_config->fileselector_expand_enable;
priv->inwin_mode = _elm_config->inwin_dialogs_enable;
@@ -321,7 +322,7 @@ _elm_fileselector_button_path_set_internal(Evas_Object *obj, const char *path)
{
ELM_FILESELECTOR_BUTTON_DATA_GET_OR_RETURN(obj, sd);
- Efl_Model *model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
+ Efl_Model *model = efl_add(EIO_MODEL_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS), eio_model_path_set(efl_added, path));
if (!model)
{
ERR("Efl.Model allocation error");
@@ -330,6 +331,7 @@ _elm_fileselector_button_path_set_internal(Evas_Object *obj, const char *path)
if (sd->fsd.model)
efl_unref(sd->fsd.model);
+ // XXX: the efl_ref here smells wrong. fsd.model is only unreffed ONCE so this obj leaks...
sd->fsd.model = efl_ref(model);
eina_stringshare_replace(&sd->fsd.path, path);
diff --git a/src/lib/elementary/elm_atspi_bridge.c b/src/lib/elementary/elm_atspi_bridge.c
index af49766ecb..0c7ab5c67b 100644
--- a/src/lib/elementary/elm_atspi_bridge.c
+++ b/src/lib/elementary/elm_atspi_bridge.c
@@ -4556,7 +4556,7 @@ _elm_atspi_bridge_init(void)
{
if (!_init_count)
{
- _instance = efl_add_ref(ELM_ATSPI_BRIDGE_CLASS, NULL);
+ _instance = efl_add(ELM_ATSPI_BRIDGE_CLASS, efl_main_loop_get());
_init_count = 1;
}
}
@@ -4572,7 +4572,7 @@ _elm_atspi_bridge_shutdown(void)
{
if (_init_count)
{
- efl_unref(_instance);
+ efl_del(_instance);
_init_count = 0;
}
_efl_access_shutdown();
diff --git a/src/lib/elementary/elm_sys_notify.c b/src/lib/elementary/elm_sys_notify.c
index 7db51add19..fb7c691f11 100644
--- a/src/lib/elementary/elm_sys_notify.c
+++ b/src/lib/elementary/elm_sys_notify.c
@@ -228,7 +228,7 @@ _elm_unneed_sys_notify(void)
if (manager)
{
elm_obj_sys_notify_servers_set(manager, ELM_SYS_NOTIFY_SERVER_NONE);
- efl_unref(manager);
+ efl_del(manager);
}
}
diff --git a/src/lib/evas/gesture/efl_canvas_gesture_manager.c b/src/lib/evas/gesture/efl_canvas_gesture_manager.c
index 88bcdd0d88..ebd40d074d 100644
--- a/src/lib/evas/gesture/efl_canvas_gesture_manager.c
+++ b/src/lib/evas/gesture/efl_canvas_gesture_manager.c
@@ -47,12 +47,6 @@ _cleanup_object(Eina_List *list)
}
static void
-_hash_unref_cb(Eo *obj)
-{
- efl_unref(obj);
-}
-
-static void
_hash_free_cb(Eo *obj)
{
efl_del(obj);
@@ -65,7 +59,7 @@ _efl_canvas_gesture_manager_efl_object_constructor(Eo *obj, Efl_Canvas_Gesture_M
pd->m_recognizers = eina_hash_pointer_new(EINA_FREE_CB(_hash_free_cb));
pd->m_gesture_contex = eina_hash_pointer_new(NULL);
- pd->m_object_events = eina_hash_pointer_new(EINA_FREE_CB(_hash_unref_cb));
+ pd->m_object_events = eina_hash_pointer_new(EINA_FREE_CB(_hash_free_cb));
pd->m_object_gestures = NULL;
pd->m_gestures_to_delete = NULL;
@@ -150,7 +144,7 @@ _efl_canvas_gesture_manager_filter_event(Eo *obj, Eo *target, void *event)
touch_event = eina_hash_find(pd->m_object_events, &target);
if (!touch_event)
{
- touch_event = efl_add_ref(EFL_CANVAS_GESTURE_TOUCH_CLASS, NULL);
+ touch_event = efl_add(EFL_CANVAS_GESTURE_TOUCH_CLASS, efl_provider_find(obj, EFL_LOOP_CLASS));
eina_hash_add(pd->m_object_events, &target, touch_event);
}
diff --git a/src/tests/ecore/ecore_test_ecore_audio.c b/src/tests/ecore/ecore_test_ecore_audio.c
index c7e40062ed..7969be0e0a 100644
--- a/src/tests/ecore/ecore_test_ecore_audio.c
+++ b/src/tests/ecore/ecore_test_ecore_audio.c
@@ -57,14 +57,14 @@ START_TEST(ecore_test_ecore_audio_obj_pulse)
Eina_Bool ret = EINA_FALSE;
Eina_Bool pulse_context_failed = EINA_FALSE;
- in = efl_add_ref(ECORE_AUDIO_IN_SNDFILE_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_IN_SNDFILE_CLASS, efl_main_loop_get());
fail_if(!in);
efl_name_set(in, "sample.wav");
ret = ecore_audio_obj_source_set(in, TESTS_SRC_DIR"/sample.wav");
fail_if(!ret);
- out = efl_add_ref(ECORE_AUDIO_OUT_PULSE_CLASS, NULL);
+ out = efl_add(ECORE_AUDIO_OUT_PULSE_CLASS, efl_main_loop_get());
fail_if(!out);
ecore_timer_add(1.8, _seek_vol, in);
@@ -78,8 +78,8 @@ START_TEST(ecore_test_ecore_audio_obj_pulse)
ecore_main_loop_begin();
fail_if(pulse_context_failed);
- efl_unref(out);
- efl_unref(in);
+ efl_del(out);
+ efl_del(in);
}
END_TEST
#endif
@@ -96,7 +96,7 @@ static Eina_Bool
_idle_del(void *data)
{
Eo *in = data;
- efl_unref(in);
+ efl_del(in);
ecore_idler_add(_quit, NULL);
return EINA_FALSE;
@@ -108,12 +108,12 @@ START_TEST(ecore_test_ecore_audio_cleanup)
int freq = 1000;
Eina_Bool ret = EINA_FALSE;
- in = efl_add_ref(ECORE_AUDIO_IN_TONE_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_IN_TONE_CLASS, efl_main_loop_get());
fail_if(!in);
efl_key_data_set(in, ECORE_AUDIO_ATTR_TONE_FREQ, &freq);
ecore_audio_obj_in_length_set(in, 2);
- out = efl_add_ref(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
+ out = efl_add(ECORE_AUDIO_OUT_SNDFILE_CLASS, efl_main_loop_get());
fail_if(!out);
ret = ecore_audio_obj_format_set(out, ECORE_AUDIO_FORMAT_OGG);
fail_if(!ret);
@@ -124,6 +124,7 @@ START_TEST(ecore_test_ecore_audio_cleanup)
fail_if(!ret);
ecore_idler_add(_idle_del, in);
+ ecore_idler_add(_idle_del, out);
ecore_main_loop_begin();
@@ -139,7 +140,7 @@ START_TEST(ecore_test_ecore_audio_obj_tone)
Eina_Bool ret;
char *tmp;
- in = efl_add_ref(ECORE_AUDIO_IN_TONE_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_IN_TONE_CLASS, efl_main_loop_get());
fail_if(!in);
efl_name_set(in, "tone");
@@ -197,7 +198,7 @@ START_TEST(ecore_test_ecore_audio_obj_tone)
len = ecore_audio_obj_in_remaining_get(in);
fail_if(len != 1.0);
- out = efl_add_ref(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
+ out = efl_add(ECORE_AUDIO_OUT_SNDFILE_CLASS, efl_main_loop_get());
fail_if(!out);
efl_name_set(out, "tmp.wav");
@@ -214,8 +215,8 @@ START_TEST(ecore_test_ecore_audio_obj_tone)
ecore_main_loop_begin();
- efl_unref(in);
- efl_unref(out);
+ efl_del(in);
+ efl_del(out);
//TODO: Compare and fail
ecore_file_remove(TESTS_BUILD_DIR"/tmp.wav");
@@ -231,7 +232,7 @@ START_TEST(ecore_test_ecore_audio_obj_sndfile)
Ecore_Audio_Format fmt;
const char *src;
- in = efl_add_ref(ECORE_AUDIO_IN_SNDFILE_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_IN_SNDFILE_CLASS, efl_main_loop_get());
fail_if(!in);
fmt = ecore_audio_obj_format_get(in);
@@ -277,7 +278,7 @@ START_TEST(ecore_test_ecore_audio_obj_sndfile)
len = ecore_audio_obj_in_seek(in, -1.5, SEEK_END);
fail_if(fabs(rem - 1 - len) > 0.6);
- out = efl_add_ref(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
+ out = efl_add(ECORE_AUDIO_OUT_SNDFILE_CLASS, efl_main_loop_get());
fail_if(!out);
efl_name_set(out, "tmp.wav");
@@ -304,8 +305,8 @@ START_TEST(ecore_test_ecore_audio_obj_sndfile)
ecore_main_loop_begin();
- efl_unref(in);
- efl_unref(out);
+ efl_del(in);
+ efl_del(out);
//TODO: Compare and fail
ecore_file_remove(TESTS_BUILD_DIR"/tmp.wav");
@@ -318,9 +319,9 @@ START_TEST(ecore_test_ecore_audio_obj_in_out)
Eina_List *in3;
Eina_Bool attached;
- Eo *in = efl_add_ref(ECORE_AUDIO_IN_CLASS, NULL);
- Eo *in2 = efl_add_ref(ECORE_AUDIO_IN_CLASS, NULL);
- Eo *out = efl_add_ref(ECORE_AUDIO_OUT_CLASS, NULL);
+ Eo *in = efl_add(ECORE_AUDIO_IN_CLASS, efl_main_loop_get());
+ Eo *in2 = efl_add(ECORE_AUDIO_IN_CLASS, efl_main_loop_get());
+ Eo *out = efl_add(ECORE_AUDIO_OUT_CLASS, efl_main_loop_get());
fail_if(!in);
fail_if(!in2);
@@ -357,20 +358,20 @@ START_TEST(ecore_test_ecore_audio_obj_in_out)
fail_if(eina_list_count(in3) != 2);
fail_if(eina_list_data_get(in3) != in);
- efl_unref(in2);
+ efl_del(in2);
in3 = ecore_audio_obj_out_inputs_get(out);
fail_if(eina_list_count(in3) != 1);
fail_if(eina_list_data_get(in3) != in);
- efl_unref(out);
+ efl_del(out);
out2 = ecore_audio_obj_in_output_get(in);
fail_if(out2);
- efl_unref(in);
+ efl_del(in);
}
END_TEST
@@ -416,10 +417,10 @@ START_TEST(ecore_test_ecore_audio_obj_vio)
{
Eo *in, *out;
- in = efl_add_ref(ECORE_AUDIO_IN_CLASS, NULL);
+ in = efl_add(ECORE_AUDIO_IN_CLASS, efl_main_loop_get());
fail_if(!in);
- out = efl_add_ref(ECORE_AUDIO_OUT_CLASS, NULL);
+ out = efl_add(ECORE_AUDIO_OUT_CLASS, efl_main_loop_get());
fail_if(!out);
ecore_audio_obj_vio_set(in, &in_vio, NULL, NULL);
@@ -429,8 +430,8 @@ START_TEST(ecore_test_ecore_audio_obj_vio)
ecore_main_loop_begin();
- efl_unref(out);
- efl_unref(in);
+ efl_del(out);
+ efl_del(in);
}
END_TEST
@@ -454,7 +455,7 @@ START_TEST(ecore_test_ecore_audio_obj_in)
Ecore_Audio_Vio vio;
Eina_Bool freed = EINA_FALSE;
- Eo *in = efl_add_ref(ECORE_AUDIO_IN_CLASS, NULL);
+ Eo *in = efl_add(ECORE_AUDIO_IN_CLASS, efl_main_loop_get());
fail_if(!in);
@@ -529,7 +530,7 @@ START_TEST(ecore_test_ecore_audio_obj_in)
fail_if(buf[i] != 0x00);
}
- efl_unref(in);
+ efl_del(in);
}
END_TEST
@@ -541,10 +542,10 @@ START_TEST(ecore_test_ecore_audio_obj)
double volume;
Eo *objs[2], *obj;
- objs[0] = efl_add_ref(ECORE_AUDIO_IN_CLASS, NULL);
+ objs[0] = efl_add(ECORE_AUDIO_IN_CLASS, efl_main_loop_get());
fail_if(!objs[0]);
- objs[1] = efl_add_ref(ECORE_AUDIO_OUT_CLASS, NULL);
+ objs[1] = efl_add(ECORE_AUDIO_OUT_CLASS, efl_main_loop_get());
fail_if(!objs[1]);
for (i=0; i<2; i++) {
@@ -577,7 +578,7 @@ START_TEST(ecore_test_ecore_audio_obj)
volume = ecore_audio_obj_volume_get(obj);
fail_if(volume != 0.5);
- efl_unref(obj);
+ efl_del(obj);
}
}
diff --git a/src/tests/ecore/ecore_test_promise2.c b/src/tests/ecore/ecore_test_promise2.c
index bd9eec8158..52ae594193 100644
--- a/src/tests/ecore/ecore_test_promise2.c
+++ b/src/tests/ecore/ecore_test_promise2.c
@@ -871,7 +871,7 @@ START_TEST(efl_test_promise_eo)
fail_if(!ecore_init());
//Use a random object..
- obj = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL);
+ obj = efl_add(EFL_IO_BUFFER_CLASS, efl_main_loop_get());
fail_if(!obj);
efl_key_data_set(obj, "free_called", &free_called);
f = eina_future_chain(_int_future_get(),
@@ -930,7 +930,7 @@ START_TEST(efl_test_promise_eo_link)
fail_if(!ecore_init());
//Use a random object..
- obj = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL);
+ obj = efl_add(EFL_IO_BUFFER_CLASS, efl_main_loop_get());
fail_if(!obj);
efl_key_data_set(obj, "err_called", &err_called);
diff --git a/src/tests/ecore_con/ecore_con_test_efl_net_ip_address.c b/src/tests/ecore_con/ecore_con_test_efl_net_ip_address.c
index dc9b7e8989..4a54c98bb8 100644
--- a/src/tests/ecore_con/ecore_con_test_efl_net_ip_address.c
+++ b/src/tests/ecore_con/ecore_con_test_efl_net_ip_address.c
@@ -307,29 +307,29 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_manual_ok)
addr.sin_port = htons(12345);
addr.sin_addr.s_addr = htonl(0xabcdefafU);
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET),
efl_net_ip_address_port_set(efl_added, ntohs(addr.sin_port)),
efl_net_ip_address_set(efl_added, slice));
_ipv4_check(o, &addr);
- efl_unref(o);
+ efl_del(o);
addr.sin_port = htons(8081);
addr.sin_addr.s_addr = htonl(0);
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET),
efl_net_ip_address_port_set(efl_added, ntohs(addr.sin_port)),
efl_net_ip_address_set(efl_added, slice));
_ipv4_check(o, &addr);
- efl_unref(o);
+ efl_del(o);
addr.sin_port = htons(0);
addr.sin_addr.s_addr = htonl(0x12345678);
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET),
efl_net_ip_address_set(efl_added, slice));
_ipv4_check(o, &addr);
- efl_unref(o);
+ efl_del(o);
ecore_con_shutdown();
}
@@ -348,46 +348,46 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_manual_fail)
ecore_con_init();
TRAP_ERRORS_BEGIN(eina_safety, ERR, "safety check failed: pd->addr.sa_family == 0 is true");
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL);
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get());
ck_assert_ptr_eq(o, NULL);
TRAP_ERRORS_FINISH(1);
TRAP_ERRORS_BEGIN(eina_safety, ERR, NULL);
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, 12345));
ck_assert_ptr_eq(o, NULL);
TRAP_ERRORS_FINISH(2);
TRAP_ERRORS_BEGIN(eina_safety, ERR, "safety check failed: pd->addr.sa_family == 0 is true");
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_set(efl_added, wrong_slice));
ck_assert_ptr_eq(o, NULL);
TRAP_ERRORS_FINISH(2);
TRAP_ERRORS_BEGIN(eina_safety, ERR, "safety check failed: pd->addr.sa_family == 0 is true");
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_port_set(efl_added, 1234));
ck_assert_ptr_eq(o, NULL);
TRAP_ERRORS_FINISH(2);
TRAP_ERRORS_BEGIN(eina_safety, ERR, "safety check failed: pd->addr.sa_family == 0 is true");
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_port_set(efl_added, 1234),
efl_net_ip_address_set(efl_added, wrong_slice));
ck_assert_ptr_eq(o, NULL);
TRAP_ERRORS_FINISH(3);
TRAP_ERRORS_BEGIN(eina_safety, ERR, "safety check failed: rw_slice.len != address.len is true");
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET),
efl_net_ip_address_set(efl_added, wrong_slice));
_ipv4_check(o, &addr);
- efl_unref(o);
+ efl_del(o);
TRAP_ERRORS_FINISH(1);
addr.sin_port = htons(12345);
addr.sin_addr.s_addr = htonl(0xabcdefafU);
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET),
efl_net_ip_address_port_set(efl_added, ntohs(addr.sin_port)),
efl_net_ip_address_set(efl_added, slice));
@@ -417,7 +417,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_manual_fail)
efl_net_ip_address_set(o, slice);
TRAP_ERRORS_FINISH(1);
- efl_unref(o);
+ efl_del(o);
ecore_con_shutdown();
}
@@ -773,21 +773,21 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_manual_ok)
addr.sin6_port = htons(12345);
_ipv6_set(&addr, 1, 2, 3, 4, 5, 6, 7, 8);
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET6),
efl_net_ip_address_port_set(efl_added, ntohs(addr.sin6_port)),
efl_net_ip_address_set(efl_added, slice));
_ipv6_check(o, &addr);
- efl_unref(o);
+ efl_del(o);
addr.sin6_port = htons(8081);
_ipv6_set(&addr, 0, 0, 0, 0, 0, 0, 0, 0);
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET6),
efl_net_ip_address_port_set(efl_added, ntohs(addr.sin6_port)),
efl_net_ip_address_set(efl_added, slice));
_ipv6_check(o, &addr);
- efl_unref(o);
+ efl_del(o);
ecore_con_shutdown();
}
@@ -808,16 +808,16 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_manual_fail)
/* generic errors checked at ecore_test_efl_net_ip_address_ipv4_manual_fail */
TRAP_ERRORS_BEGIN(eina_safety, ERR, "safety check failed: rw_slice.len != address.len is true");
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET6),
efl_net_ip_address_set(efl_added, wrong_slice));
_ipv6_check(o, &addr);
- efl_unref(o);
+ efl_del(o);
TRAP_ERRORS_FINISH(1);
addr.sin6_port = htons(12345);
_ipv6_set(&addr, 0, 0, 0, 0, 0, 0, 0, 1);
- o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add(EFL_NET_IP_ADDRESS_CLASS, efl_main_loop_get(),
efl_net_ip_address_family_set(efl_added, AF_INET6),
efl_net_ip_address_port_set(efl_added, ntohs(addr.sin6_port)),
efl_net_ip_address_set(efl_added, slice));
@@ -847,7 +847,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_manual_fail)
efl_net_ip_address_set(o, slice);
TRAP_ERRORS_FINISH(1);
- efl_unref(o);
+ efl_del(o);
ecore_con_shutdown();
}
diff --git a/src/tests/efl/efl_test_model_composite.c b/src/tests/efl/efl_test_model_composite.c
index 9f29468168..882d72de60 100644
--- a/src/tests/efl/efl_test_model_composite.c
+++ b/src/tests/efl/efl_test_model_composite.c
@@ -183,7 +183,7 @@ START_TEST(efl_test_model_composite_boolean)
eina_value_setup(&v, EINA_VALUE_TYPE_INT);
- base_model = efl_add_ref(EFL_MODEL_ITEM_CLASS, NULL);
+ base_model = efl_add(EFL_MODEL_ITEM_CLASS, efl_main_loop_get());
ck_assert(!!base_model);
for (i = 0; i < child_number; ++i)
@@ -194,7 +194,7 @@ START_TEST(efl_test_model_composite_boolean)
efl_model_property_set(child, "test_p_int", &v);
}
- model = efl_add_ref(EFL_MODEL_COMPOSITE_BOOLEAN_CLASS, NULL,
+ model = efl_add(EFL_MODEL_COMPOSITE_BOOLEAN_CLASS, efl_main_loop_get(),
efl_ui_view_model_set(efl_added, base_model),
efl_model_composite_boolean_property_add(efl_added, "test_p_true", EINA_TRUE),
efl_model_composite_boolean_property_add(efl_added, "test_p_false", EINA_FALSE));
@@ -226,7 +226,7 @@ START_TEST(efl_test_model_composite_selection)
eina_value_setup(&v, EINA_VALUE_TYPE_INT);
- base_model = efl_add_ref(EFL_MODEL_ITEM_CLASS, NULL);
+ base_model = efl_add(EFL_MODEL_ITEM_CLASS, efl_main_loop_get());
ck_assert(!!base_model);
for (i = 0; i < child_number; ++i)
@@ -237,7 +237,7 @@ START_TEST(efl_test_model_composite_selection)
efl_model_property_set(child, "test_p_int", &v);
}
- model = efl_add_ref(EFL_MODEL_COMPOSITE_SELECTION_CLASS, NULL,
+ model = efl_add(EFL_MODEL_COMPOSITE_SELECTION_CLASS, efl_main_loop_get(),
efl_ui_view_model_set(efl_added, base_model));
ck_assert(!!model);
efl_model_composite_selection_select(model, 2);
diff --git a/src/tests/efl/efl_test_model_container.c b/src/tests/efl/efl_test_model_container.c
index 127e250338..8044795a47 100644
--- a/src/tests/efl/efl_test_model_container.c
+++ b/src/tests/efl/efl_test_model_container.c
@@ -130,7 +130,7 @@ START_TEST(efl_test_model_container_values)
cmp_str[i] = strdup(base_str[i]);
}
- model = efl_add_ref(EFL_MODEL_CONTAINER_CLASS, NULL);
+ model = efl_add(EFL_MODEL_CONTAINER_CLASS, efl_main_loop_get());
efl_model_container_child_property_add(model, "test_p_int", EINA_VALUE_TYPE_INT,
eina_carray_iterator_new((void**)cmp_int));
diff --git a/src/tests/efl_mono/libefl_mono_native_test.c b/src/tests/efl_mono/libefl_mono_native_test.c
index 8981a042aa..b53582e44a 100644
--- a/src/tests/efl_mono/libefl_mono_native_test.c
+++ b/src/tests/efl_mono/libefl_mono_native_test.c
@@ -85,7 +85,7 @@ char **_new_str_ref(const char* str)
static
Test_Numberwrapper *_new_obj(int n)
{
- return efl_add_ref(TEST_NUMBERWRAPPER_CLASS, NULL, test_numberwrapper_number_set(efl_added, n));
+ return efl_add(TEST_NUMBERWRAPPER_CLASS, efl_main_loop_get(), test_numberwrapper_number_set(efl_added, n));
}
static
diff --git a/src/tests/eio/eio_test_sentry.c b/src/tests/eio/eio_test_sentry.c
index 0ae402abc5..c3e512973a 100644
--- a/src/tests/eio/eio_test_sentry.c
+++ b/src/tests/eio/eio_test_sentry.c
@@ -146,7 +146,7 @@ START_TEST(eio_test_sentry_add_and_remove)
usleep(500000);
//monitor directory
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
fail_if(!eio_sentry_add(sentry, filename));
usleep(500000);
@@ -172,7 +172,7 @@ START_TEST(eio_test_sentry_add_remove_add)
usleep(500000);
//monitor directory
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
fail_if(!eio_sentry_add(sentry, filename));
eio_sentry_remove(sentry, filename);
@@ -202,7 +202,7 @@ START_TEST(eio_test_sentry_add_add_remove_remove)
//sleep to avoid catching event generated by above manipulations
usleep(500000);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//monitor directory
fail_if(!eio_sentry_add(sentry, filename1));
@@ -232,7 +232,7 @@ START_TEST(eio_test_sentry_directory_file_created_notify)
Eo* sentry;
filename = eina_stringshare_printf("%s/eio_test_sentry_directory_file_created_notify", dirname);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -259,7 +259,7 @@ START_TEST(eio_test_sentry_directory_file_deleted_notify)
filename = eina_stringshare_printf("%s/eio_test_sentry_directory_file_deleted_notify", dirname);
_create_file((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -286,7 +286,7 @@ START_TEST(eio_test_sentry_directory_file_modified_notify)
filename = eina_stringshare_printf("%s/eio_test_sentry_directory_file_modified_notify", dirname);
_create_file((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -314,7 +314,7 @@ START_TEST(eio_test_sentry_directory_file_closed_notify)
filename = eina_stringshare_printf("%s/eio_test_sentry_directory_file_closed_notify", dirname);
_create_file((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -339,7 +339,7 @@ START_TEST(eio_test_sentry_directory_directory_created_notify)
Eo *sentry;
filename = eina_stringshare_printf("%s/eio_test_sentry_directory_directory_created_notify", dirname);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -366,7 +366,7 @@ START_TEST(eio_test_sentry_directory_directory_deleted_notify)
filename = eina_stringshare_printf("%s/eio_test_sentry_directory_directory_deleted_notify", dirname);
_create_directory((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -393,7 +393,7 @@ START_TEST(eio_test_sentry_directory_directory_modified_notify)
filename = eina_stringshare_printf("%s/eio_test_sentry_directory_directory_modified_notify", dirname);
_create_directory((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -415,7 +415,7 @@ END_TEST
START_TEST(eio_test_sentry_directory_directory_self_deleted_notify)
{
Eina_Tmpstr *dirname = _common_init();
- Eo *sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ Eo *sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -444,7 +444,7 @@ START_TEST(eio_test_sentry_file_file_modified_notify)
filename = eina_stringshare_printf("%s/filecreated", dirname);
_create_file((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -472,7 +472,7 @@ START_TEST(eio_test_sentry_file_file_attrib_modified_notify)
filename = eina_stringshare_printf("%s/eio_test_sentry_file_file_attrib_modified_notify", dirname);
_create_file((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -500,7 +500,7 @@ START_TEST(eio_test_sentry_file_file_closed_notify)
filename = eina_stringshare_printf("%s/eio_test_sentry_file_file_closed_notify", dirname);
_create_file((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -526,7 +526,7 @@ START_TEST(eio_test_sentry_file_file_self_deleted_notify)
filename = eina_stringshare_printf("%s/eio_test_sentry_file_file_self_deleted_notify", dirname);
_create_file((void*)filename);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -555,7 +555,7 @@ START_TEST(eio_test_sentry_two_monitors_one_event)
eina_file_mkdtemp("checkFileCreationXXXXXX", &dirname2);
filename = eina_stringshare_printf("%s/eio_test_sentry_two_monitors_one_event", dirname);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -587,7 +587,7 @@ START_TEST(eio_test_sentry_two_monitors_one_removed_one_event)
eina_file_mkdtemp("checkFileCreationXXXXXX", &dirname2);
filename = eina_stringshare_printf("%s/eio_test_sentry_two_monitors_one_removed", dirname);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -624,7 +624,7 @@ START_TEST(eio_test_sentry_two_monitors_one_removed_no_event)
eina_file_mkdtemp("checkFileCreationXXXXXX", &dirname2);
filename = eina_stringshare_printf("%s/eio_test_sentry_two_monitors_one_removed", dirname);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -658,7 +658,7 @@ START_TEST(eio_test_sentry_two_files_in_same_directory)
filename2 = eina_stringshare_printf("%s/eio_test_sentry_two_files_in_same_directory_2", dirname);
_create_file((void*)filename);
_create_file((void*)filename2);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
@@ -691,7 +691,7 @@ START_TEST(eio_test_sentry_two_files_in_same_directory_one_removed)
filename2 = eina_stringshare_printf("%s/eio_test_sentry_two_files_in_same_directory_one_removed_2", dirname);
_create_file((void*)filename);
_create_file((void*)filename2);
- sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add(EIO_SENTRY_CLASS, efl_main_loop_get());
//sleep to avoid catching event generated by above manipulations
usleep(500000);
diff --git a/src/tests/elementary/elm_test_atspi.c b/src/tests/elementary/elm_test_atspi.c
index 0afddf3022..adf1599112 100644
--- a/src/tests/elementary/elm_test_atspi.c
+++ b/src/tests/elementary/elm_test_atspi.c
@@ -31,7 +31,7 @@ START_TEST (test_efl_access_app_obj_name_get)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, efl_main_loop_get());
ck_assert(root != NULL);
@@ -43,7 +43,7 @@ START_TEST (test_efl_access_app_obj_name_get)
ck_assert_str_eq(ret, "Test name");
- efl_unref(root);
+ efl_del(root);
elm_shutdown();
}
END_TEST
@@ -106,7 +106,7 @@ START_TEST (test_efl_access_role_get)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, efl_main_loop_get());
Efl_Access_Role role;
@@ -114,7 +114,7 @@ START_TEST (test_efl_access_role_get)
ck_assert(role == EFL_ACCESS_ROLE_APPLICATION);
- efl_unref(root);
+ efl_del(root);
elm_shutdown();
}
END_TEST
@@ -147,7 +147,7 @@ START_TEST (test_efl_access_role_name_get)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, efl_main_loop_get());
const char *ret = NULL;
@@ -155,7 +155,7 @@ START_TEST (test_efl_access_role_name_get)
ck_assert(ret != NULL);
- efl_unref(root);
+ efl_del(root);
elm_shutdown();
}
END_TEST
@@ -165,7 +165,7 @@ START_TEST (test_efl_access_localized_role_name_get)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, efl_main_loop_get());
const char *ret = NULL;
@@ -173,7 +173,7 @@ START_TEST (test_efl_access_localized_role_name_get)
ck_assert(ret != NULL);
- efl_unref(root);
+ efl_del(root);
elm_shutdown();
}
END_TEST
@@ -183,7 +183,7 @@ START_TEST (test_efl_access_description_set)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, efl_main_loop_get());
const char *ret = NULL;
@@ -204,7 +204,7 @@ START_TEST (test_efl_access_description_set)
ck_assert(ret == NULL);
- efl_unref(root);
+ efl_del(root);
elm_shutdown();
}
END_TEST
@@ -231,7 +231,7 @@ START_TEST (test_efl_access_children_and_parent)
elm_init(1, args);
generate_app();
- Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, efl_main_loop_get());
Eina_List *child_list = NULL;
@@ -248,7 +248,7 @@ START_TEST (test_efl_access_children_and_parent)
ck_assert(win != NULL);
ck_assert(win == g_win);
- efl_unref(root);
+ efl_del(root);
elm_shutdown();
}
END_TEST
@@ -259,7 +259,7 @@ START_TEST (test_efl_access_children_and_parent2)
elm_init(1, args);
generate_app();
- Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, efl_main_loop_get());
Eo *win = NULL;
@@ -278,7 +278,7 @@ START_TEST (test_efl_access_children_and_parent2)
ck_assert(btn != NULL);
ck_assert(btn == g_btn);
- efl_unref(root);
+ efl_del(root);
elm_shutdown();
}
END_TEST
diff --git a/src/tests/elementary/elm_test_config.c b/src/tests/elementary/elm_test_config.c
index c7593bd1db..c7e5089730 100644
--- a/src/tests/elementary/elm_test_config.c
+++ b/src/tests/elementary/elm_test_config.c
@@ -155,14 +155,14 @@ START_TEST (elm_config_win)
Eo *cfg = efl_provider_find(efl_main_loop_get(), EFL_CONFIG_INTERFACE);
fail_if(!cfg);
- Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL);
+ Eo *win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get());
Eo *cfg2 = efl_provider_find(win, EFL_CONFIG_INTERFACE);
fail_if(cfg != cfg2);
elm_config_cache_flush_interval_set(42);
fail_if(efl_config_int_get(win, "cache_flush_interval") != 42);
- efl_unref(win);
+ efl_del(win);
elm_shutdown();
}
END_TEST
diff --git a/src/tests/elementary/elm_test_focus.c b/src/tests/elementary/elm_test_focus.c
index 405b2fc0e8..e6a4388af5 100644
--- a/src/tests/elementary/elm_test_focus.c
+++ b/src/tests/elementary/elm_test_focus.c
@@ -4,10 +4,10 @@ START_TEST(focus_unregister_twice)
{
char *args[] = { "exe" };
elm_init(1, args);
- Efl_Ui_Focus_Object *r1 = efl_add_ref(FOCUS_TEST_CLASS, NULL);
- Efl_Ui_Focus_Object *r2 = efl_add_ref(FOCUS_TEST_CLASS, NULL);
+ Efl_Ui_Focus_Object *r1 = efl_add(FOCUS_TEST_CLASS, efl_main_loop_get());
+ Efl_Ui_Focus_Object *r2 = efl_add(FOCUS_TEST_CLASS, efl_main_loop_get());
- Efl_Ui_Focus_Manager *m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, r1)
);
@@ -17,9 +17,9 @@ START_TEST(focus_unregister_twice)
efl_ui_focus_manager_calc_unregister(m, r1);
efl_ui_focus_manager_calc_unregister(m, r1);
- efl_unref(r2);
- efl_unref(r1);
- efl_unref(m);
+ efl_del(r2);
+ efl_del(r1);
+ efl_del(m);
elm_shutdown();
}
@@ -33,15 +33,15 @@ START_TEST(focus_register_twice)
Efl_Ui_Focus_Object *r1 = elm_focus_test_object_new("r1", 0, 0, 10, 10);
Efl_Ui_Focus_Object *r2 = elm_focus_test_object_new("r2", 0, 10, 10, 10);
- Efl_Ui_Focus_Manager *m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, r1)
);
fail_if(!efl_ui_focus_manager_calc_register(m, r2, r1, NULL));
fail_if(efl_ui_focus_manager_calc_register(m, r2, r1, NULL));
- efl_unref(r1);
- efl_unref(m);
+ efl_del(r1);
+ efl_del(m);
elm_shutdown();
}
@@ -81,11 +81,11 @@ START_TEST(pos_check)
CHECK(north, east, west, NULL, middle)
CHECK(south, east, west, middle, NULL)
- efl_unref(middle);
- efl_unref(south);
- efl_unref(north);
- efl_unref(east);
- efl_unref(west);
+ efl_del(middle);
+ efl_del(south);
+ efl_del(north);
+ efl_del(east);
+ efl_del(west);
elm_shutdown();
}
@@ -155,11 +155,11 @@ START_TEST(pos_check2)
#undef ck_assert_set_eq
- efl_unref(middle);
- efl_unref(north_east);
- efl_unref(north_west);
- efl_unref(south_east);
- efl_unref(south_west);
+ efl_del(middle);
+ efl_del(north_east);
+ efl_del(north_west);
+ efl_del(south_east);
+ efl_del(south_west);
elm_shutdown();
}
@@ -174,11 +174,11 @@ START_TEST(redirect)
TEST_OBJ_NEW(one, 0, 0, 20, 20);
TEST_OBJ_NEW(two, 20, 0, 20, 20);
- Efl_Ui_Focus_Manager *m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
- Efl_Ui_Focus_Manager *m2 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *m2 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root2)
);
@@ -190,6 +190,9 @@ START_TEST(redirect)
ck_assert_ptr_eq(efl_ui_focus_manager_move(m, EFL_UI_FOCUS_DIRECTION_RIGHT), two);
+ efl_del(m);
+ efl_del(m2);
+
elm_shutdown();
}
END_TEST
@@ -308,9 +311,10 @@ START_TEST(finalize_check)
char *args[] = { "exe" };
elm_init(1, args);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL);
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get());
fail_if(m);
+ efl_del(m);
elm_shutdown();
}
END_TEST
@@ -326,11 +330,11 @@ START_TEST(redirect_param)
TEST_OBJ_NEW(root2, 0, 20, 20, 20);
TEST_OBJ_NEW(child, 0, 20, 20, 20);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
- m2 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m2 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root2)
);
@@ -339,6 +343,8 @@ START_TEST(redirect_param)
ck_assert_ptr_eq(efl_ui_focus_manager_redirect_get(m), m2);
+ efl_del(m);
+ efl_del(m2);
elm_shutdown();
}
END_TEST
@@ -354,7 +360,7 @@ START_TEST(invalid_args_check)
TEST_OBJ_NEW(child, 0, 20, 20, 20);
TEST_OBJ_NEW(child2, 0, 20, 20, 20);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
@@ -372,6 +378,7 @@ START_TEST(invalid_args_check)
ck_assert_int_eq(efl_ui_focus_manager_calc_register(m, child2, root, NULL), 1);
ck_assert_int_eq(efl_ui_focus_manager_calc_update_parent(m, child, child2), 1);
+ efl_del(m);
elm_shutdown();
}
END_TEST
@@ -389,7 +396,7 @@ START_TEST(order_check)
TEST_OBJ_NEW(child2, 0, 20, 20, 20);
TEST_OBJ_NEW(child3, 0, 20, 20, 20);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
@@ -411,6 +418,7 @@ START_TEST(order_check)
order = eina_list_append(order, child2);
ck_assert_int_eq(efl_ui_focus_manager_calc_update_children(m, root, order), 0);
+ efl_del(m);
elm_shutdown();
}
END_TEST
@@ -428,7 +436,7 @@ START_TEST(logical_shift)
TEST_OBJ_NEW(sub_sub, 0, 0, 10, 10);
TEST_OBJ_NEW(sub_child, 0, 0, 10, 10);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
@@ -446,6 +454,7 @@ START_TEST(logical_shift)
efl_ui_focus_manager_focus_set(m, sub_sub);
ck_assert_ptr_eq(efl_ui_focus_manager_focus_get(m), sub_child);
+ efl_del(m);
elm_shutdown();
}
END_TEST
@@ -461,13 +470,13 @@ START_TEST(root_redirect_chain)
TEST_OBJ_NEW(root2, 0, 20, 20, 20);
TEST_OBJ_NEW(child, 0, 20, 20, 20);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
focus_test_manager_set(root2, m);
- m2 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m2 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root2)
);
@@ -477,6 +486,7 @@ START_TEST(root_redirect_chain)
ck_assert_ptr_eq(efl_ui_focus_manager_redirect_get(m), m2);
+ efl_del(m);
elm_shutdown();
}
END_TEST
@@ -492,21 +502,21 @@ START_TEST(root_redirect_chain_unset)
TEST_OBJ_NEW(root2, 0, 20, 20, 20);
TEST_OBJ_NEW(child, 0, 20, 20, 20);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
focus_test_manager_set(root2, m);
- m2 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m2 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root2)
);
- m3 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m3 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root2)
);
- m4 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m4 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root2)
);
@@ -523,6 +533,10 @@ START_TEST(root_redirect_chain_unset)
ck_assert_ptr_eq(efl_ui_focus_manager_redirect_get(m3), NULL);
ck_assert_ptr_eq(efl_ui_focus_manager_redirect_get(m4), NULL);
+ efl_del(m);
+ efl_del(m2);
+ efl_del(m3);
+ efl_del(m4);
elm_shutdown();
}
END_TEST
@@ -536,7 +550,7 @@ _recursive_triangle_manager(int recusion_depth, Efl_Ui_Focus_Object **most_right
TEST_OBJ_NEW(root, 0, 20, 20, 20);
TEST_OBJ_NEW(child2, 0, 20, 20, 20);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
@@ -617,6 +631,7 @@ START_TEST(first_touch_check)
printf("%s\n", efl_name_get(efl_ui_focus_manager_focus_get(_get_highest_redirect(m))));
ck_assert_ptr_eq(efl_ui_focus_manager_focus_get(_get_highest_redirect(m)), most_right);
+ efl_del(m);
elm_shutdown();
}
END_TEST
diff --git a/src/tests/elementary/elm_test_focus_common.c b/src/tests/elementary/elm_test_focus_common.c
index 589c68246d..c09dd59ed6 100644
--- a/src/tests/elementary/elm_test_focus_common.c
+++ b/src/tests/elementary/elm_test_focus_common.c
@@ -17,7 +17,7 @@ elm_focus_test_object_new(const char *name, int x, int y, int w, int h)
{
Efl_Ui_Focus_Object *ret;
- ret = efl_add_ref(FOCUS_TEST_CLASS, NULL,
+ ret = efl_add(FOCUS_TEST_CLASS, efl_main_loop_get(),
efl_name_set(efl_added, name)
);
Q(ret, x, y, w, h);
@@ -48,7 +48,7 @@ elm_focus_test_manager_new(Efl_Ui_Focus_Object **middle)
Efl_Ui_Focus_Manager *m;
root = elm_focus_test_object_new("middle", 40, 40, 20, 20);
- m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root)
);
if (middle)
diff --git a/src/tests/elementary/elm_test_focus_sub.c b/src/tests/elementary/elm_test_focus_sub.c
index 397dfcf5f8..45449252a7 100644
--- a/src/tests/elementary/elm_test_focus_sub.c
+++ b/src/tests/elementary/elm_test_focus_sub.c
@@ -75,7 +75,7 @@ _setup(Efl_Ui_Focus_Manager **m, Efl_Ui_Focus_Manager_Sub **sub, Efl_Ui_Focus_Ob
EFL_OBJECT_OP_FUNC(efl_ui_focus_manager_calc_unregister, _unregister),
);
- Efl_Ui_Focus_Manager *manager = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *manager = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, efl_main_loop_get(),
efl_ui_focus_manager_root_set(efl_added, root_manager)
);
//flush now all changes
@@ -85,7 +85,7 @@ _setup(Efl_Ui_Focus_Manager **m, Efl_Ui_Focus_Manager_Sub **sub, Efl_Ui_Focus_Ob
efl_object_override(manager, &manager_tracker);
- Focus_Test_Sub_Main *focus_main = efl_add_ref(FOCUS_TEST_SUB_MAIN_CLASS, NULL);
+ Focus_Test_Sub_Main *focus_main = efl_add(FOCUS_TEST_SUB_MAIN_CLASS, efl_main_loop_get());
efl_key_data_set(focus_main, "__user_manager", manager);
efl_key_data_set(focus_main, "__user_parent", root_manager);
@@ -137,11 +137,11 @@ START_TEST(correct_register)
efl_ui_focus_manager_calc_unregister(sub, child1);
efl_ui_focus_manager_calc_unregister(sub, child2);
efl_ui_focus_manager_calc_unregister(sub, child3);
- efl_unref(child1);
- efl_unref(child2);
- efl_unref(child3);
- efl_unref(sub);
- efl_unref(manager);
+ efl_del(child1);
+ efl_del(child2);
+ efl_del(child3);
+ efl_del(sub);
+ efl_del(manager);
elm_shutdown();
}
END_TEST
@@ -180,12 +180,12 @@ START_TEST(correct_unregister)
eina_list_free(unregistered);
unregistered = NULL;
- efl_unref(sub);
- efl_unref(manager);
- efl_unref(root);
- efl_unref(child1);
- efl_unref(child2);
- efl_unref(child3);
+ efl_del(sub);
+ efl_del(manager);
+ efl_del(root);
+ efl_del(child1);
+ efl_del(child2);
+ efl_del(child3);
elm_shutdown();
}
END_TEST
@@ -222,12 +222,12 @@ START_TEST(correct_un_register)
fail_if(!_set_equal(registered, set_add));
fail_if(!_set_equal(unregistered, set_del));
- efl_unref(sub);
- efl_unref(manager);
- efl_unref(root);
- efl_unref(child1);
- efl_unref(child2);
- efl_unref(child3);
+ efl_del(sub);
+ efl_del(manager);
+ efl_del(root);
+ efl_del(child1);
+ efl_del(child2);
+ efl_del(child3);
elm_shutdown();
}
END_TEST