aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCedric BAIL <cedric@osg.samsung.com>2018-03-15 12:50:20 -0400
committerCedric Bail <cedric@osg.samsung.com>2018-03-20 17:20:56 -0700
commit4c4177ac207f982de8139c47c7afedd26ff9e15a (patch)
tree1913e890dc525621f4dec3ce281b340d81608a72
parenteo: start reporting abuse of efl_del (diff)
downloadefl-4c4177ac207f982de8139c47c7afedd26ff9e15a.tar.gz
efl: use efl_add_ref to create objects which have no parent
Signed-off-by: Mike Blumenkrantz <zmike@osg.samsung.com>
-rw-r--r--src/benchmarks/eo/eo_bench_callbacks.c4
-rw-r--r--src/benchmarks/eo/eo_bench_eo_add.c6
-rw-r--r--src/benchmarks/eo/eo_bench_eo_do.c12
-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.c6
-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.c2
-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/efl_model_composite_boolean.c2
-rw-r--r--src/lib/ecore/efl_model_composite_selection.c2
-rw-r--r--src/lib/ecore/efl_thread.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_con/efl_net_ip_address.c8
-rw-r--r--src/lib/ecore_con/efl_net_ssl_context.c2
-rw-r--r--src/lib/ector/cairo/ector_cairo_surface.c6
-rw-r--r--src/lib/ector/gl/ector_gl_surface.c6
-rw-r--r--src/lib/ector/software/ector_software_surface.c6
-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.c4
-rw-r--r--src/lib/elementary/efl_ui_list.c2
-rw-r--r--src/lib/elementary/elc_fileselector.c12
-rw-r--r--src/lib/elementary/elc_fileselector_button.c4
-rw-r--r--src/lib/elementary/elm_atspi_bridge.c4
-rw-r--r--src/lib/elementary/elm_config.c2
-rw-r--r--src/lib/elementary/elm_sys_notify.c2
-rw-r--r--src/lib/evas/canvas/efl_canvas_vg.c2
-rw-r--r--src/lib/evas/gesture/efl_canvas_gesture_manager.c10
-rw-r--r--src/modules/evas/engines/gl_generic/evas_engine.c8
-rw-r--r--src/modules/evas/engines/software_generic/evas_engine.c8
-rw-r--r--src/tests/ecore/ecore_test_ecore_audio.c60
-rw-r--r--src/tests/ecore/ecore_test_promise2.c4
-rw-r--r--src/tests/ecore_con/ecore_con_test_efl_net_ip_address.c110
-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.c14
-rw-r--r--src/tests/elementary/elm_test_config.c4
-rw-r--r--src/tests/elementary/elm_test_focus.c68
-rw-r--r--src/tests/elementary/elm_test_focus_common.c4
-rw-r--r--src/tests/elementary/elm_test_focus_sub.c38
-rw-r--r--src/tests/eo/access/access_main.c2
-rw-r--r--src/tests/eo/children/children_main.c2
-rw-r--r--src/tests/eo/composite_objects/composite_objects_main.c2
-rw-r--r--src/tests/eo/constructors/constructors_main.c20
-rw-r--r--src/tests/eo/function_overrides/function_overrides_main.c8
-rw-r--r--src/tests/eo/interface/interface_main.c2
-rw-r--r--src/tests/eo/mixin/mixin_main.c4
-rw-r--r--src/tests/eo/signals/signals_main.c2
-rw-r--r--src/tests/eo/suite/eo_test_class_singleton.c2
-rw-r--r--src/tests/eo/suite/eo_test_domain.c2
-rw-r--r--src/tests/eo/suite/eo_test_event.c6
-rw-r--r--src/tests/eo/suite/eo_test_general.c210
-rw-r--r--src/tests/eo/suite/eo_test_init.c2
-rw-r--r--src/tests/eo/suite/eo_test_threaded_calls.c2
-rw-r--r--src/tests/eo/suite/eo_test_value.c2
-rw-r--r--src/tests/eolian_js/eolian_js_test_constructor_method_impl.c4
102 files changed, 495 insertions, 489 deletions
diff --git a/src/benchmarks/eo/eo_bench_callbacks.c b/src/benchmarks/eo/eo_bench_callbacks.c
index 7fd145c31a..7168dabfe0 100644
--- a/src/benchmarks/eo/eo_bench_callbacks.c
+++ b/src/benchmarks/eo/eo_bench_callbacks.c
@@ -16,7 +16,7 @@ static void
bench_eo_callbacks_add(int request)
{
int i;
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
for (i = 0 ; i < request ; i++)
{
@@ -52,7 +52,7 @@ bench_eo_callbacks_call(int request)
Eo *obj[len];
for (i = 0 ; i < len ; i++)
{
- obj[i] = efl_add(SIMPLE_CLASS, NULL);
+ obj[i] = efl_add_ref(SIMPLE_CLASS, NULL);
for (j = 0 ; j < i ; j++)
{
diff --git a/src/benchmarks/eo/eo_bench_eo_add.c b/src/benchmarks/eo/eo_bench_eo_add.c
index 7bd10d8109..963cd3abb9 100644
--- a/src/benchmarks/eo/eo_bench_eo_add.c
+++ b/src/benchmarks/eo/eo_bench_eo_add.c
@@ -12,7 +12,7 @@ bench_efl_add_linear(int request)
int i;
Eo **objs = calloc(request, sizeof(Eo *));
for (i = 0 ; i < request ; i++)
- objs[i] = efl_add(SIMPLE_CLASS, NULL);
+ objs[i] = efl_add_ref(SIMPLE_CLASS, NULL);
for (i = 0 ; i < request ; i++)
efl_unref(objs[i]);
@@ -25,13 +25,13 @@ bench_efl_add_jump_by_2(int request)
int i;
Eo **objs = calloc(request, sizeof(Eo *));
for (i = 0 ; i < request ; i++)
- objs[i] = efl_add(SIMPLE_CLASS, NULL);
+ objs[i] = efl_add_ref(SIMPLE_CLASS, NULL);
for (i = 0 ; i < request ; i += 2)
efl_unref(objs[i]);
for (i = 0 ; i < request ; i += 2)
- objs[i] = efl_add(SIMPLE_CLASS, NULL);
+ objs[i] = efl_add_ref(SIMPLE_CLASS, NULL);
for (i = 0 ; i < request ; i++)
efl_unref(objs[i]);
diff --git a/src/benchmarks/eo/eo_bench_eo_do.c b/src/benchmarks/eo/eo_bench_eo_do.c
index ec69bf3145..2783b91b3c 100644
--- a/src/benchmarks/eo/eo_bench_eo_do.c
+++ b/src/benchmarks/eo/eo_bench_eo_do.c
@@ -10,7 +10,7 @@ static void
bench_eo_do_simple(int request)
{
int i;
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
for (i = 0 ; i < request ; i++)
{
simple_a_set(obj, i);
@@ -23,8 +23,8 @@ static void
bench_eo_do_two_objs(int request)
{
int i;
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj2 = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj2 = efl_add_ref(SIMPLE_CLASS, NULL);
for (i = 0 ; i < request ; i++)
{
simple_a_set(obj, i);
@@ -39,8 +39,8 @@ static void
bench_eo_do_two_objs_growing_stack(int request)
{
int i;
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj2 = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj2 = efl_add_ref(SIMPLE_CLASS, NULL);
for (i = 0 ; i < request ; i++)
{
simple_other_call(obj, obj2, 20);
@@ -83,7 +83,7 @@ bench_eo_do_super(int request)
cur_klass = efl_class_new(&class_desc, SIMPLE_CLASS, NULL);
int i;
- Eo *obj = efl_add(cur_klass, NULL);
+ Eo *obj = efl_add_ref(cur_klass, NULL);
for (i = 0 ; i < request ; i++)
{
simple_a_set(obj, i);
diff --git a/src/bin/elementary/test_bg.c b/src/bin/elementary/test_bg.c
index d6e8bc3065..b436e58d5b 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 5439234056..98ff767d2b 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 34064395ac..89ac92b48c 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 1f06dafda2..19e00d4c35 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 6f026cb028..8f870cc859 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 050158cd86..43b1586dd9 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 48cd8a38ea..a483e19900 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 f9b6b9b80d..918860c02d 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 afd38448e2..6a133e9fd0 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 ebc97d4f3c..dc9a8a03e7 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 5a68e33c41..6c8cfbd903 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 bda425dbd9..36f71eff0c 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_del(ev->object);
+ efl_unref(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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 0e8e2dea53..44fa967eb1 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 f0e39842fa..1d32e3f9b9 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 ad401c3bc9..2e667b5026 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 58a70f3c33..03b025bffb 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 e94c1b69ba..c0115cc9f0 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_del(p_data->panel_win);
+ efl_unref(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_del(p_data->win);
+ efl_unref(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(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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(EFL_UI_WIN_CLASS, NULL,
+ Eo *panel_win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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(EFL_UI_WIN_CLASS, NULL,
+ Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 0af6c6aaad..09a0e704c0 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_del(pd->win);
+ efl_unref(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(EFL_UI_WIN_CLASS, NULL,
+ pd->win = win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 275e9ee045..4899b7dda5 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 eea45b0096..ee4d198a40 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 46b202b0f7..60ff0003a3 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 ba0a166adf..b2ec5aad54 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 ddb93f302c..5befcb40fd 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 8681e7ae93..751453f0c9 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 7a10c258bf..22d4f35835 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(EFL_UI_WIN_CLASS, NULL,
+ dia = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 d459a9eeab..72fad0a875 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(EFL_UI_WIN_SOCKET_CLASS, NULL,
+ Eo *win = efl_add_ref(EFL_UI_WIN_SOCKET_CLASS, NULL,
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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 18f7c0fa7b..d13072d041 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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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(EFL_UI_WIN_CLASS, NULL,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL,
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 8089918089..b0d26a1e75 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(ECORE_AUDIO_OBJ_OUT_PULSE_CLASS, NULL);
+ out = efl_add_ref(ECORE_AUDIO_OBJ_OUT_PULSE_CLASS, NULL);
- in = efl_add(ECORE_AUDIO_OBJ_IN_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_OBJ_IN_CLASS, NULL);
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 31713031b4..c659f09d55 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_del(event->object);
+ efl_unref(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(ECORE_AUDIO_OBJ_IN_TONE_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_OBJ_IN_TONE_CLASS, NULL);
if (!in)
{
printf("error when creating ecore audio source.\n");
@@ -276,7 +276,7 @@ main(int argc, const char *argv[])
}
else
{
- in = efl_add(ECORE_AUDIO_OBJ_IN_SNDFILE_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_OBJ_IN_SNDFILE_CLASS, NULL);
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(ECORE_AUDIO_OBJ_OUT_PULSE_CLASS, NULL);
+ out = efl_add_ref(ECORE_AUDIO_OBJ_OUT_PULSE_CLASS, NULL);
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 194e31e648..756e69a209 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_del(event->object);
- efl_del(out);
+ efl_unref(event->object);
+ efl_unref(out);
ecore_main_loop_quit();
@@ -49,31 +49,31 @@ main(int argc, char *argv[])
ecore_audio_init();
- in = efl_add(ECORE_AUDIO_OBJ_IN_SNDFILE_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_OBJ_IN_SNDFILE_CLASS, NULL);
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_del(in);
+ efl_unref(in);
return 1;
}
efl_event_callback_add(in, ECORE_AUDIO_EV_IN_STOPPED, _play_finished, NULL);
- out = efl_add(ECORE_AUDIO_OBJ_OUT_SNDFILE_CLASS, NULL);
+ out = efl_add_ref(ECORE_AUDIO_OBJ_OUT_SNDFILE_CLASS, NULL);
ret = ecore_audio_obj_source_set(out, argv[2]);
if (!ret) {
printf("Could not set %s as output\n", argv[2]);
- efl_del(in);
- efl_del(out);
+ efl_unref(in);
+ efl_unref(out);
return 1;
}
ret = ecore_audio_obj_out_input_attach(out, in);
if (!ret) {
printf("Could not attach input\n");
- efl_del(out);
- efl_del(in);
+ efl_unref(out);
+ efl_unref(in);
return 1;
}
diff --git a/src/examples/ecore/ecore_idler_example.c b/src/examples/ecore/ecore_idler_example.c
index 53e7d6fed4..2185210763 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(ECORE_IDLER_CLASS, NULL, ecore_idler_constructor(efl_added, _idler_cb, &ctxt));
+// ctxt.idler = efl_add_ref(ECORE_IDLER_CLASS, NULL, 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 6c55dbc285..3cbbcc5f2e 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(ECORE_POLLER_CLASS, NULL, // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 4, _poller_print_cb, str1));
-// poller2 = efl_add(ECORE_POLLER_CLASS, NULL, // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 8, _poller_print_cb, str2));
-// poller3 = efl_add(ECORE_POLLER_CLASS, NULL, // ecore_poller_constructor(efl_added, ECORE_POLLER_CORE, 20, _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));
ecore_main_loop_begin();
diff --git a/src/examples/ecore/efl_io_copier_example.c b/src/examples/ecore/efl_io_copier_example.c
index 016b4486f5..b7e526bd3c 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(EFL_IO_STDIN_CLASS, NULL,
+ input = efl_add_ref(EFL_IO_STDIN_CLASS, NULL,
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(EFL_IO_FILE_CLASS, NULL,
+ input = efl_add_ref(EFL_IO_FILE_CLASS, NULL,
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(EFL_IO_STDOUT_CLASS, NULL,
+ output = efl_add_ref(EFL_IO_STDOUT_CLASS, NULL,
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(EFL_IO_STDERR_CLASS, NULL,
+ output = efl_add_ref(EFL_IO_STDERR_CLASS, NULL,
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(EFL_IO_BUFFER_CLASS, NULL,
+ output = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL,
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(EFL_IO_FILE_CLASS, NULL,
+ output = efl_add_ref(EFL_IO_FILE_CLASS, NULL,
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 9a9738859b..9367716729 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(EFL_IO_QUEUE_CLASS, NULL,
+ send_queue = efl_add_ref(EFL_IO_QUEUE_CLASS, NULL,
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(EFL_IO_QUEUE_CLASS, NULL,
+ receive_queue = efl_add_ref(EFL_IO_QUEUE_CLASS, NULL,
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_del(receive_queue);
+ efl_unref(receive_queue);
error_receive_queue:
- efl_del(send_queue);
+ efl_unref(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 df6e210add..6d5aa30e80 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(EFL_IO_BUFFER_CLASS, NULL,
+ send_buffer = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL,
efl_io_buffer_adopt_readonly(efl_added, hello_world_slice));
/* Unlimited buffer to store the received data. */
- recv_buffer = efl_add(EFL_IO_BUFFER_CLASS, NULL);
+ recv_buffer = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL);
/* 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(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
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 93ad6ba926..2d21352d03 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(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
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 fd228458e0..75acb0b42d 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_del(ssl_ctx);
+ efl_unref(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(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
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_del(ssl_ctx);
+ efl_unref(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 f8503c0d38..1010ca7fda 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_del(ssl_ctx);
+ efl_unref(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(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
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_del(ssl_ctx);
+ efl_unref(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 342df05ad9..e604e8900d 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(EIO_SENTRY_CLASS, NULL);
+ Eio_Sentry *sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
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 145861e286..eeb2f2329e 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(EFL_MODEL_ITEM_CLASS, NULL);
+ model = efl_add_ref(EFL_MODEL_ITEM_CLASS, NULL);
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 187cee0d54..9826487c78 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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
+ model = efl_add_ref(EIO_MODEL_CLASS, NULL, 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 32d5b1951d..0e211e03fe 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(EFL_MODEL_ITEM_CLASS, NULL);
+ model = efl_add_ref(EFL_MODEL_ITEM_CLASS, NULL);
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 b09756c272..64886337b2 100644
--- a/src/examples/elementary/efl_ui_scroller_example.c
+++ b/src/examples/elementary/efl_ui_scroller_example.c
@@ -15,7 +15,7 @@ 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(EFL_UI_WIN_CLASS, NULL, "TEST", ELM_WIN_BASIC,
+ win = efl_add_ref(EFL_UI_WIN_CLASS, NULL, "TEST", ELM_WIN_BASIC,
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
efl_gfx_size_set(win, EINA_SIZE2D(300, 400));
diff --git a/src/examples/elementary/filemvc.c b/src/examples/elementary/filemvc.c
index f09657bafc..657148c0e0 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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
+ model = efl_add_ref(EIO_MODEL_CLASS, NULL, 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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
+ priv.treemodel = efl_add_ref(EIO_MODEL_CLASS, NULL, 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(ELM_VIEW_LIST_CLASS, NULL, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_TREE, NULL));
+ priv.treeview = efl_add_ref(ELM_VIEW_LIST_CLASS, NULL, 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(ELM_VIEW_LIST_CLASS, NULL, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_NONE, "double_label"));
+ priv.fileview = efl_add_ref(ELM_VIEW_LIST_CLASS, NULL, 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(ELM_VIEW_FORM_CLASS, NULL);
+ priv.formview = efl_add_ref(ELM_VIEW_FORM_CLASS, NULL);
/*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 af14785118..39df4f87c0 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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
- priv.fileview = efl_add(ELM_VIEW_LIST_CLASS, NULL, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_TREE, "double_label"));
+ 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"));
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 5c6660eb1d..e93b34437d 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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
+ priv->model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dirname));
genlist = elm_genlist_add(win);
- priv->fileview = efl_add(ELM_VIEW_LIST_CLASS, NULL, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_NONE, NULL));
+ priv->fileview = efl_add_ref(ELM_VIEW_LIST_CLASS, NULL, 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/efl_model_composite_boolean.c b/src/lib/ecore/efl_model_composite_boolean.c
index d8c8e38376..bd6c5cf36f 100644
--- a/src/lib/ecore/efl_model_composite_boolean.c
+++ b/src/lib/ecore/efl_model_composite_boolean.c
@@ -313,7 +313,7 @@ efl_model_acessor_slice_get_at(Efl_Model_Accessor_Slice *acc, unsigned int idx,
if (child)
{
Efl_Model_Composite_Boolean_Children_Data *cpd;
- child_bool = efl_add(EFL_MODEL_COMPOSITE_BOOLEAN_CHILDREN_CLASS, NULL);
+ child_bool = efl_add_ref(EFL_MODEL_COMPOSITE_BOOLEAN_CHILDREN_CLASS, NULL);
cpd = efl_data_scope_get(child_bool, EFL_MODEL_COMPOSITE_BOOLEAN_CHILDREN_CLASS);
cpd->parent_pd = acc->parent_pd;
diff --git a/src/lib/ecore/efl_model_composite_selection.c b/src/lib/ecore/efl_model_composite_selection.c
index dbbe43fc45..68d47497f8 100644
--- a/src/lib/ecore/efl_model_composite_selection.c
+++ b/src/lib/ecore/efl_model_composite_selection.c
@@ -201,7 +201,7 @@ _efl_model_composite_selection_children_efl_model_property_set(Eo *obj EINA_UNUS
static Eo* _construct_children(void* pdata, Eo* child)
{
Efl_Model_Composite_Selection_Data* pd = pdata;
- Eo* new_child = efl_add(EFL_MODEL_COMPOSITE_SELECTION_CHILDREN_CLASS, NULL);
+ Eo* new_child = efl_add_ref(EFL_MODEL_COMPOSITE_SELECTION_CHILDREN_CLASS, NULL);
Efl_Model_Composite_Selection_Children_Data* data = efl_data_scope_get
(new_child, EFL_MODEL_COMPOSITE_SELECTION_CHILDREN_CLASS);
data->pd = pd;
diff --git a/src/lib/ecore/efl_thread.c b/src/lib/ecore/efl_thread.c
index 048a75e967..91e7ddb3f0 100644
--- a/src/lib/ecore/efl_thread.c
+++ b/src/lib/ecore/efl_thread.c
@@ -229,7 +229,7 @@ _efl_thread_main(void *data, Eina_Thread t)
if (thdat->name) eina_thread_name_set(t, thdat->name);
else eina_thread_name_set(t, "Eflthread");
- obj = efl_add(APPTHREAD_CLASS, NULL);
+ obj = efl_add_ref(APPTHREAD_CLASS, NULL);
ad = efl_data_scope_get(obj, APPTHREAD_CLASS);
efl_threadio_indata_set(obj, thdat->indata);
efl_threadio_outdata_set(obj, thdat->outdata);
@@ -294,7 +294,7 @@ _efl_thread_main(void *data, Eina_Thread t)
cmd.d.data = real;
write(thdat->ctrl.in, &cmd, sizeof(Control_Data));
- efl_del(obj);
+ efl_unref(obj);
thdat->fd.in_handler = NULL;
thdat->fd.out_handler = NULL;
diff --git a/src/lib/ecore_con/ecore_con_eet.c b/src/lib/ecore_con/ecore_con_eet.c
index f724aa8a67..134d691f4c 100644
--- a/src/lib/ecore_con/ecore_con_eet.c
+++ b/src/lib/ecore_con/ecore_con_eet.c
@@ -725,7 +725,7 @@ ecore_con_eet_server_new(Ecore_Con_Server *server)
if (!server) return NULL;
- ece_obj = efl_add(ECORE_CON_EET_SERVER_OBJ_CLASS, NULL, ecore_con_eet_base_server_set(efl_added, server));
+ ece_obj = efl_add_ref(ECORE_CON_EET_SERVER_OBJ_CLASS, NULL, ecore_con_eet_base_server_set(efl_added, server));
return ece_obj;
}
@@ -737,7 +737,7 @@ ecore_con_eet_client_new(Ecore_Con_Server *server)
if (!server) return NULL;
- ece_obj = efl_add(ECORE_CON_EET_CLIENT_OBJ_CLASS, NULL, ecore_con_eet_base_server_set(efl_added, server));
+ ece_obj = efl_add_ref(ECORE_CON_EET_CLIENT_OBJ_CLASS, NULL, 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)
EAPI void
ecore_con_eet_server_free(Ecore_Con_Eet *server)
{
- efl_del(server);
+ efl_unref(server);
}
EAPI void
diff --git a/src/lib/ecore_con/ecore_con_legacy.c b/src/lib/ecore_con/ecore_con_legacy.c
index ea8c31f6cd..ecdb187761 100644
--- a/src/lib/ecore_con/ecore_con_legacy.c
+++ b/src/lib/ecore_con/ecore_con_legacy.c
@@ -1590,7 +1590,7 @@ _ecore_con_server_ssl_ctx_create(const Ecore_Con_Server *svr)
/* legacy compatibility: server never verified peer, only dialer did */
- return efl_add(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ return efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
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)),
@@ -1645,7 +1645,7 @@ _ecore_con_server_server_ssl_job(void *data, const Eina_Value v,
error_server:
efl_del(inner_server);
error_inner_server:
- efl_del(ssl_ctx);
+ efl_unref(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);
@@ -1969,7 +1969,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(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
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)),
@@ -2024,7 +2024,7 @@ _ecore_con_server_dialer_ssl_job(void *data, const Eina_Value v,
error_dialer:
efl_del(inner_dialer);
error_inner_dialer:
- efl_del(ssl_ctx);
+ efl_unref(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);
@@ -2063,7 +2063,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(EFL_NET_SSL_CONTEXT_CLASS, NULL,
+ ssl_ctx = efl_add_ref(EFL_NET_SSL_CONTEXT_CLASS, NULL,
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)),
@@ -2110,7 +2110,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_del(ssl_ctx);
+ efl_unref(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 126ccdab65..fb43f943fc 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(EFL_NETWORK_CLIENT_CLASS, NULL);
+ Ecore_Con_Client *cl_obj = efl_add_ref(EFL_NETWORK_CLIENT_CLASS, NULL);
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_del(cl_obj);
+ efl_unref(cl_obj);
return ECORE_CALLBACK_CANCEL;
}
diff --git a/src/lib/ecore_con/efl_net_ip_address.c b/src/lib/ecore_con/efl_net_ip_address.c
index 13e14a052d..34cf4eff93 100644
--- a/src/lib/ecore_con/efl_net_ip_address.c
+++ b/src/lib/ecore_con/efl_net_ip_address.c
@@ -300,7 +300,7 @@ _efl_net_ip_address_create(Eo *cls, void *pd EINA_UNUSED, uint16_t port, const E
else
family = AF_INET;
- return efl_add(cls, NULL,
+ return efl_add_ref(cls, NULL,
efl_net_ip_address_family_set(efl_added, family),
efl_net_ip_address_port_set(efl_added, port),
efl_net_ip_address_set(efl_added, address));
@@ -314,7 +314,7 @@ _efl_net_ip_address_create_sockaddr(Eo *cls, void *pd EINA_UNUSED, const void *p
EINA_SAFETY_ON_NULL_RETURN_VAL(sockaddr, NULL);
EINA_SAFETY_ON_TRUE_RETURN_VAL((sockaddr->sa_family != AF_INET) && (sockaddr->sa_family != AF_INET6), NULL);
- return efl_add(cls, NULL,
+ return efl_add_ref(cls, NULL,
efl_net_ip_address_sockaddr_set(efl_added, sockaddr));
}
@@ -357,7 +357,7 @@ _efl_net_ip_address_parse(Eo *cls, void *pd EINA_UNUSED, const char *numeric_add
return NULL;
}
- return efl_add(cls, NULL,
+ return efl_add_ref(cls, NULL,
efl_net_ip_address_sockaddr_set(efl_added, &ss));
}
@@ -498,7 +498,7 @@ _efl_net_ip_address_resolve_done(void *data, const char *host, const char *port,
if (o)
{
if (!eina_array_push(r->results, o))
- efl_del(o);
+ efl_unref(o);
}
}
freeaddrinfo(result);
diff --git a/src/lib/ecore_con/efl_net_ssl_context.c b/src/lib/ecore_con/efl_net_ssl_context.c
index df20f472a6..0c350d3f29 100644
--- a/src/lib/ecore_con/efl_net_ssl_context.c
+++ b/src/lib/ecore_con/efl_net_ssl_context.c
@@ -361,7 +361,7 @@ _efl_net_ssl_context_default_dialer_get(Efl_Class *klass, void *pd EINA_UNUSED)
{
if (!_efl_net_ssl_context_default_dialer)
{
- _efl_net_ssl_context_default_dialer = efl_add(klass, NULL,
+ _efl_net_ssl_context_default_dialer = efl_add_ref(klass, NULL,
efl_net_ssl_context_verify_mode_set(efl_added, EFL_NET_SSL_VERIFY_MODE_REQUIRED),
efl_net_ssl_context_hostname_verify_set(efl_added, EINA_TRUE),
efl_net_ssl_context_default_paths_load_set(efl_added, EINA_TRUE),
diff --git a/src/lib/ector/cairo/ector_cairo_surface.c b/src/lib/ector/cairo/ector_cairo_surface.c
index b21f7ab817..3bc1d4f714 100644
--- a/src/lib/ector/cairo/ector_cairo_surface.c
+++ b/src/lib/ector/cairo/ector_cairo_surface.c
@@ -63,11 +63,11 @@ _ector_cairo_surface_ector_surface_renderer_factory_new(Eo *obj,
const Efl_Class *type)
{
if (type == ECTOR_RENDERER_SHAPE_MIXIN)
- return efl_add(ECTOR_RENDERER_CAIRO_SHAPE_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_CAIRO_SHAPE_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
else if (type == ECTOR_RENDERER_GRADIENT_LINEAR_MIXIN)
- return efl_add(ECTOR_RENDERER_CAIRO_GRADIENT_LINEAR_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_CAIRO_GRADIENT_LINEAR_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
else if (type == ECTOR_RENDERER_GRADIENT_RADIAL_MIXIN)
- return efl_add(ECTOR_RENDERER_CAIRO_GRADIENT_RADIAL_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_CAIRO_GRADIENT_RADIAL_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
ERR("Couldn't find class for type: %s\n", efl_class_name_get(type));
return NULL;
diff --git a/src/lib/ector/gl/ector_gl_surface.c b/src/lib/ector/gl/ector_gl_surface.c
index 60fba18fed..2f144e8612 100644
--- a/src/lib/ector/gl/ector_gl_surface.c
+++ b/src/lib/ector/gl/ector_gl_surface.c
@@ -45,11 +45,11 @@ _ector_gl_surface_ector_surface_renderer_factory_new(Eo *obj,
const Efl_Class *type)
{
if (type == ECTOR_RENDERER_SHAPE_MIXIN)
- return efl_add(ECTOR_RENDERER_GL_SHAPE_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_GL_SHAPE_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
else if (type == ECTOR_RENDERER_GRADIENT_LINEAR_MIXIN)
- return efl_add(ECTOR_RENDERER_GL_GRADIENT_LINEAR_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_GL_GRADIENT_LINEAR_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
else if (type == ECTOR_RENDERER_GRADIENT_RADIAL_MIXIN)
- return efl_add(ECTOR_RENDERER_GL_GRADIENT_RADIAL_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_GL_GRADIENT_RADIAL_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
ERR("Couldn't find class for type: %s\n", efl_class_name_get(type));
return NULL;
diff --git a/src/lib/ector/software/ector_software_surface.c b/src/lib/ector/software/ector_software_surface.c
index e3e72fbd2d..2907272f40 100644
--- a/src/lib/ector/software/ector_software_surface.c
+++ b/src/lib/ector/software/ector_software_surface.c
@@ -201,11 +201,11 @@ _ector_software_surface_ector_surface_renderer_factory_new(Eo *obj,
const Efl_Class *type)
{
if (type == ECTOR_RENDERER_SHAPE_MIXIN)
- return efl_add(ECTOR_RENDERER_SOFTWARE_SHAPE_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_SOFTWARE_SHAPE_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
else if (type == ECTOR_RENDERER_GRADIENT_LINEAR_MIXIN)
- return efl_add(ECTOR_RENDERER_SOFTWARE_GRADIENT_LINEAR_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_SOFTWARE_GRADIENT_LINEAR_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
else if (type == ECTOR_RENDERER_GRADIENT_RADIAL_MIXIN)
- return efl_add(ECTOR_RENDERER_SOFTWARE_GRADIENT_RADIAL_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
+ return efl_add_ref(ECTOR_RENDERER_SOFTWARE_GRADIENT_RADIAL_CLASS, NULL, ector_renderer_surface_set(efl_added, obj));
ERR("Couldn't find class for type: %s", efl_class_name_get(type));
return NULL;
diff --git a/src/lib/edje/edje_main.c b/src/lib/edje/edje_main.c
index bd49820179..338fb66c88 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_del(_edje_global_obj);
+ efl_unref(_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_del(_edje_global_obj);
+ efl_unref(_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_del(_edje_color_class_member);
+ efl_unref(_edje_color_class_member);
_edje_color_class_member = NULL;
}
if (_edje_text_class_member)
{
- efl_del(_edje_text_class_member);
+ efl_unref(_edje_text_class_member);
_edje_text_class_member = NULL;
}
if (_edje_size_class_member)
{
- efl_del(_edje_size_class_member);
+ efl_unref(_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 9227ff7bae..0d99826d22 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_del(event->object);
+ efl_unref(event->object);
}
static void
_out_fail(void *data EINA_UNUSED, const Efl_Event *event)
{
outfail = EINA_TRUE;
- efl_del(event->object);
+ efl_unref(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(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_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));
if (!out)
{
# ifdef _WIN32
- out = efl_add(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_ref(ECORE_AUDIO_OUT_WASAPI_CLASS, NULL, efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_WASAPI_EVENT_CONTEXT_FAIL, _out_fail, NULL));
# else
# ifdef HAVE_PULSE
- out = efl_add(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_ref(ECORE_AUDIO_OUT_PULSE_CLASS, NULL, 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_del(in);
+ efl_unref(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_del(in);
+ efl_unref(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(ECORE_AUDIO_IN_TONE_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_IN_TONE_CLASS, NULL);
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(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_ref(ECORE_AUDIO_OUT_WASAPI_CLASS, NULL, efl_event_callback_add(efl_added, ECORE_AUDIO_OUT_WASAPI_EVENT_CONTEXT_FAIL, _out_fail, NULL));
# else
# ifdef HAVE_PULSE
- out = efl_add(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_ref(ECORE_AUDIO_OUT_PULSE_CLASS, NULL, 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_del(in);
+ efl_unref(in);
return EINA_FALSE;
}
}
@@ -353,7 +353,7 @@ _edje_multisense_shutdown(void)
if (out)
{
// XXX: this causes an abort inside of pa!!!!!
- //efl_del(out);
+ //efl_unref(out);
out = NULL;
outs = 0;
}
diff --git a/src/lib/eio/eio_model.c b/src/lib/eio/eio_model.c
index ec2672d7f1..76cdc246c0 100644
--- a/src/lib/eio/eio_model.c
+++ b/src/lib/eio/eio_model.c
@@ -807,7 +807,7 @@ _eio_model_efl_object_parent_get(Eo *obj , Eio_Model_Data *priv)
char *path = ecore_file_dir_get(priv->path);
if (path != NULL && strcmp(priv->path, "/") != 0)
{
- model = efl_add(MY_CLASS, NULL, eio_model_path_set(efl_added, path));
+ model = efl_add_ref(MY_CLASS, NULL, eio_model_path_set(efl_added, path));
}
else
model = NULL;
diff --git a/src/lib/elementary/efl_ui_focus_composition.c b/src/lib/elementary/efl_ui_focus_composition.c
index 644821d898..9171aa2f74 100644
--- a/src/lib/elementary/efl_ui_focus_composition.c
+++ b/src/lib/elementary/efl_ui_focus_composition.c
@@ -77,7 +77,7 @@ _efl_ui_focus_composition_composition_elements_set(Eo *obj, Efl_Ui_Focus_Composi
//get rid of all adapter objects
EINA_LIST_FREE(pd->adapters, adapter)
{
- efl_del(adapter);
+ efl_unref(adapter);
}
//now build a composition_elements list
@@ -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(EFL_UI_FOCUS_COMPOSITION_ADAPTER_CLASS, NULL, efl_ui_focus_composition_adapter_canvas_object_set(efl_added, elem));
+ o = efl_add_ref(EFL_UI_FOCUS_COMPOSITION_ADAPTER_CLASS, NULL, 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 b0afa73242..49c94558c4 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(EFL_UI_LAYOUT_FACTORY_CLASS, NULL);
+ pd->factory = efl_add_ref(EFL_UI_LAYOUT_FACTORY_CLASS, NULL);
if(!pd->relayout)
{
diff --git a/src/lib/elementary/elc_fileselector.c b/src/lib/elementary/elc_fileselector.c
index 83ae8a62b7..f0a6d2c52a 100644
--- a/src/lib/elementary/elc_fileselector.c
+++ b/src/lib/elementary/elc_fileselector.c
@@ -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(EIO_MODEL_CLASS, NULL,
+ Eio_Model *model = efl_add_ref(EIO_MODEL_CLASS, NULL,
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(model_cls, NULL);
+ Efl_Model *model = efl_add_ref(model_cls, NULL);
_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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, _path));
+ Eio_Model *model = efl_add_ref(EIO_MODEL_CLASS, NULL, 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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
+ model = efl_add_ref(EIO_MODEL_CLASS, NULL, 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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
+ model = efl_add_ref(EIO_MODEL_CLASS, NULL, 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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, dir));
+ parent = efl_add_ref(EIO_MODEL_CLASS, NULL, 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 0ea039de10..4072c843e8 100644
--- a/src/lib/elementary/elc_fileselector_button.c
+++ b/src/lib/elementary/elc_fileselector_button.c
@@ -222,7 +222,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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, priv->fsd.path));
+ priv->fsd.model = efl_add_ref(EIO_MODEL_CLASS, NULL, 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 +321,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(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
+ Efl_Model *model = efl_add_ref(EIO_MODEL_CLASS, NULL, eio_model_path_set(efl_added, path));
if (!model)
{
ERR("Efl.Model allocation error");
diff --git a/src/lib/elementary/elm_atspi_bridge.c b/src/lib/elementary/elm_atspi_bridge.c
index 0e4f89abcd..af49766ecb 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(ELM_ATSPI_BRIDGE_CLASS, NULL);
+ _instance = efl_add_ref(ELM_ATSPI_BRIDGE_CLASS, NULL);
_init_count = 1;
}
}
@@ -4572,7 +4572,7 @@ _elm_atspi_bridge_shutdown(void)
{
if (_init_count)
{
- efl_del(_instance);
+ efl_unref(_instance);
_init_count = 0;
}
_efl_access_shutdown();
diff --git a/src/lib/elementary/elm_config.c b/src/lib/elementary/elm_config.c
index e7de3fc8aa..16063906c8 100644
--- a/src/lib/elementary/elm_config.c
+++ b/src/lib/elementary/elm_config.c
@@ -4622,7 +4622,7 @@ _elm_config_shutdown(void)
efl_del_intercept_set(_efl_config_obj, NULL);
efl_loop_unregister(efl_main_loop_get(), EFL_CONFIG_INTERFACE, _efl_config_obj);
efl_loop_unregister(efl_main_loop_get(), EFL_CONFIG_GLOBAL_CLASS, _efl_config_obj);
- ELM_SAFE_FREE(_efl_config_obj, efl_del);
+ ELM_SAFE_FREE(_efl_config_obj, efl_unref);
ELM_SAFE_FREE(_elm_config, _config_free);
ELM_SAFE_FREE(_elm_preferred_engine, eina_stringshare_del);
ELM_SAFE_FREE(_elm_accel_preference, eina_stringshare_del);
diff --git a/src/lib/elementary/elm_sys_notify.c b/src/lib/elementary/elm_sys_notify.c
index fb7c691f11..7db51add19 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_del(manager);
+ efl_unref(manager);
}
}
diff --git a/src/lib/evas/canvas/efl_canvas_vg.c b/src/lib/evas/canvas/efl_canvas_vg.c
index 77b0ca509a..c64a8fa28f 100644
--- a/src/lib/evas/canvas/efl_canvas_vg.c
+++ b/src/lib/evas/canvas/efl_canvas_vg.c
@@ -505,7 +505,7 @@ _cache_vg_entry_render(Evas_Object_Protected_Data *obj,
root,
buffer,
do_async);
- efl_del(dupe_root);
+ efl_unref(dupe_root);
}
else
{
diff --git a/src/lib/evas/gesture/efl_canvas_gesture_manager.c b/src/lib/evas/gesture/efl_canvas_gesture_manager.c
index af6cc5d805..88bcdd0d88 100644
--- a/src/lib/evas/gesture/efl_canvas_gesture_manager.c
+++ b/src/lib/evas/gesture/efl_canvas_gesture_manager.c
@@ -47,6 +47,12 @@ _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);
@@ -59,7 +65,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_free_cb));
+ pd->m_object_events = eina_hash_pointer_new(EINA_FREE_CB(_hash_unref_cb));
pd->m_object_gestures = NULL;
pd->m_gestures_to_delete = NULL;
@@ -144,7 +150,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(EFL_CANVAS_GESTURE_TOUCH_CLASS, NULL);
+ touch_event = efl_add_ref(EFL_CANVAS_GESTURE_TOUCH_CLASS, NULL);
eina_hash_add(pd->m_object_events, &target, touch_event);
}
diff --git a/src/modules/evas/engines/gl_generic/evas_engine.c b/src/modules/evas/engines/gl_generic/evas_engine.c
index 623e96aea4..8e49f4d4af 100644
--- a/src/modules/evas/engines/gl_generic/evas_engine.c
+++ b/src/modules/evas/engines/gl_generic/evas_engine.c
@@ -2513,16 +2513,16 @@ eng_ector_create(void *engine EINA_UNUSED)
efl_domain_current_push(EFL_ID_DOMAIN_SHARED);
if (ector_backend && !strcasecmp(ector_backend, "default"))
{
- ector = efl_add(ECTOR_SOFTWARE_SURFACE_CLASS, NULL);
+ ector = efl_add_ref(ECTOR_SOFTWARE_SURFACE_CLASS, NULL);
}
else if (ector_backend && !strcasecmp(ector_backend, "experimental"))
{
- ector = efl_add(ECTOR_GL_SURFACE_CLASS, NULL);
+ ector = efl_add_ref(ECTOR_GL_SURFACE_CLASS, NULL);
use_gl = EINA_TRUE;
}
else
{
- ector = efl_add(ECTOR_CAIRO_SOFTWARE_SURFACE_CLASS, NULL);
+ ector = efl_add_ref(ECTOR_CAIRO_SOFTWARE_SURFACE_CLASS, NULL);
use_cairo = EINA_TRUE;
}
efl_domain_current_pop();
@@ -2532,7 +2532,7 @@ eng_ector_create(void *engine EINA_UNUSED)
static void
eng_ector_destroy(void *engine EINA_UNUSED, Ector_Surface *ector)
{
- if (ector) efl_del(ector);
+ if (ector) efl_unref(ector);
}
static Ector_Buffer *
diff --git a/src/modules/evas/engines/software_generic/evas_engine.c b/src/modules/evas/engines/software_generic/evas_engine.c
index 46b6764081..991a371504 100644
--- a/src/modules/evas/engines/software_generic/evas_engine.c
+++ b/src/modules/evas/engines/software_generic/evas_engine.c
@@ -4327,12 +4327,12 @@ eng_ector_create(void *engine EINA_UNUSED)
efl_domain_current_push(EFL_ID_DOMAIN_SHARED);
if (ector_backend && !strcasecmp(ector_backend, "default"))
{
- ector = efl_add(ECTOR_SOFTWARE_SURFACE_CLASS, NULL);
+ ector = efl_add_ref(ECTOR_SOFTWARE_SURFACE_CLASS, NULL);
use_cairo = EINA_FALSE;
}
else
{
- ector = efl_add(ECTOR_CAIRO_SOFTWARE_SURFACE_CLASS, NULL);
+ ector = efl_add_ref(ECTOR_CAIRO_SOFTWARE_SURFACE_CLASS, NULL);
use_cairo = EINA_TRUE;
}
efl_domain_current_pop();
@@ -4387,7 +4387,7 @@ eng_ector_surface_cache_drop(void *engine, void *key)
static void
eng_ector_destroy(void *data EINA_UNUSED, Ector_Surface *ector)
{
- if (ector) efl_del(ector);
+ if (ector) efl_unref(ector);
}
static Ector_Buffer *
@@ -4400,7 +4400,7 @@ eng_ector_buffer_wrap(void *data, Evas *e EINA_UNUSED, void *engine_image)
if (!efl_domain_current_push(EFL_ID_DOMAIN_SHARED))
return NULL;
- buf = efl_add(EVAS_ECTOR_SOFTWARE_BUFFER_CLASS, NULL,
+ buf = efl_add_ref(EVAS_ECTOR_SOFTWARE_BUFFER_CLASS, NULL,
evas_ector_buffer_engine_image_set(efl_added, data, ie));
efl_domain_current_pop();
diff --git a/src/tests/ecore/ecore_test_ecore_audio.c b/src/tests/ecore/ecore_test_ecore_audio.c
index 23f638a3e5..c7e40062ed 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(ECORE_AUDIO_IN_SNDFILE_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_IN_SNDFILE_CLASS, NULL);
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(ECORE_AUDIO_OUT_PULSE_CLASS, NULL);
+ out = efl_add_ref(ECORE_AUDIO_OUT_PULSE_CLASS, NULL);
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_del(out);
- efl_del(in);
+ efl_unref(out);
+ efl_unref(in);
}
END_TEST
#endif
@@ -96,7 +96,7 @@ static Eina_Bool
_idle_del(void *data)
{
Eo *in = data;
- efl_del(in);
+ efl_unref(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(ECORE_AUDIO_IN_TONE_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_IN_TONE_CLASS, NULL);
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(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
+ out = efl_add_ref(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
fail_if(!out);
ret = ecore_audio_obj_format_set(out, ECORE_AUDIO_FORMAT_OGG);
fail_if(!ret);
@@ -139,7 +139,7 @@ START_TEST(ecore_test_ecore_audio_obj_tone)
Eina_Bool ret;
char *tmp;
- in = efl_add(ECORE_AUDIO_IN_TONE_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_IN_TONE_CLASS, NULL);
fail_if(!in);
efl_name_set(in, "tone");
@@ -197,7 +197,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(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
+ out = efl_add_ref(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
fail_if(!out);
efl_name_set(out, "tmp.wav");
@@ -214,8 +214,8 @@ START_TEST(ecore_test_ecore_audio_obj_tone)
ecore_main_loop_begin();
- efl_del(in);
- efl_del(out);
+ efl_unref(in);
+ efl_unref(out);
//TODO: Compare and fail
ecore_file_remove(TESTS_BUILD_DIR"/tmp.wav");
@@ -231,7 +231,7 @@ START_TEST(ecore_test_ecore_audio_obj_sndfile)
Ecore_Audio_Format fmt;
const char *src;
- in = efl_add(ECORE_AUDIO_IN_SNDFILE_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_IN_SNDFILE_CLASS, NULL);
fail_if(!in);
fmt = ecore_audio_obj_format_get(in);
@@ -277,7 +277,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(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
+ out = efl_add_ref(ECORE_AUDIO_OUT_SNDFILE_CLASS, NULL);
fail_if(!out);
efl_name_set(out, "tmp.wav");
@@ -304,8 +304,8 @@ START_TEST(ecore_test_ecore_audio_obj_sndfile)
ecore_main_loop_begin();
- efl_del(in);
- efl_del(out);
+ efl_unref(in);
+ efl_unref(out);
//TODO: Compare and fail
ecore_file_remove(TESTS_BUILD_DIR"/tmp.wav");
@@ -318,9 +318,9 @@ START_TEST(ecore_test_ecore_audio_obj_in_out)
Eina_List *in3;
Eina_Bool attached;
- Eo *in = efl_add(ECORE_AUDIO_IN_CLASS, NULL);
- Eo *in2 = efl_add(ECORE_AUDIO_IN_CLASS, NULL);
- Eo *out = efl_add(ECORE_AUDIO_OUT_CLASS, NULL);
+ 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);
fail_if(!in);
fail_if(!in2);
@@ -357,20 +357,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_del(in2);
+ efl_unref(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_del(out);
+ efl_unref(out);
out2 = ecore_audio_obj_in_output_get(in);
fail_if(out2);
- efl_del(in);
+ efl_unref(in);
}
END_TEST
@@ -416,10 +416,10 @@ START_TEST(ecore_test_ecore_audio_obj_vio)
{
Eo *in, *out;
- in = efl_add(ECORE_AUDIO_IN_CLASS, NULL);
+ in = efl_add_ref(ECORE_AUDIO_IN_CLASS, NULL);
fail_if(!in);
- out = efl_add(ECORE_AUDIO_OUT_CLASS, NULL);
+ out = efl_add_ref(ECORE_AUDIO_OUT_CLASS, NULL);
fail_if(!out);
ecore_audio_obj_vio_set(in, &in_vio, NULL, NULL);
@@ -429,8 +429,8 @@ START_TEST(ecore_test_ecore_audio_obj_vio)
ecore_main_loop_begin();
- efl_del(out);
- efl_del(in);
+ efl_unref(out);
+ efl_unref(in);
}
END_TEST
@@ -454,7 +454,7 @@ START_TEST(ecore_test_ecore_audio_obj_in)
Ecore_Audio_Vio vio;
Eina_Bool freed = EINA_FALSE;
- Eo *in = efl_add(ECORE_AUDIO_IN_CLASS, NULL);
+ Eo *in = efl_add_ref(ECORE_AUDIO_IN_CLASS, NULL);
fail_if(!in);
@@ -529,7 +529,7 @@ START_TEST(ecore_test_ecore_audio_obj_in)
fail_if(buf[i] != 0x00);
}
- efl_del(in);
+ efl_unref(in);
}
END_TEST
@@ -541,10 +541,10 @@ START_TEST(ecore_test_ecore_audio_obj)
double volume;
Eo *objs[2], *obj;
- objs[0] = efl_add(ECORE_AUDIO_IN_CLASS, NULL);
+ objs[0] = efl_add_ref(ECORE_AUDIO_IN_CLASS, NULL);
fail_if(!objs[0]);
- objs[1] = efl_add(ECORE_AUDIO_OUT_CLASS, NULL);
+ objs[1] = efl_add_ref(ECORE_AUDIO_OUT_CLASS, NULL);
fail_if(!objs[1]);
for (i=0; i<2; i++) {
@@ -577,7 +577,7 @@ START_TEST(ecore_test_ecore_audio_obj)
volume = ecore_audio_obj_volume_get(obj);
fail_if(volume != 0.5);
- efl_del(obj);
+ efl_unref(obj);
}
}
diff --git a/src/tests/ecore/ecore_test_promise2.c b/src/tests/ecore/ecore_test_promise2.c
index ff663f1685..bd9eec8158 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(EFL_IO_BUFFER_CLASS, NULL);
+ obj = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL);
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(EFL_IO_BUFFER_CLASS, NULL);
+ obj = efl_add_ref(EFL_IO_BUFFER_CLASS, NULL);
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 563af26c60..dc9b7e8989 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(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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_del(o);
+ efl_unref(o);
addr.sin_port = htons(8081);
addr.sin_addr.s_addr = htonl(0);
- o = efl_add(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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_del(o);
+ efl_unref(o);
addr.sin_port = htons(0);
addr.sin_addr.s_addr = htonl(0x12345678);
- o = efl_add(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
efl_net_ip_address_family_set(efl_added, AF_INET),
efl_net_ip_address_set(efl_added, slice));
_ipv4_check(o, &addr);
- efl_del(o);
+ efl_unref(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(EFL_NET_IP_ADDRESS_CLASS, NULL);
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL);
ck_assert_ptr_eq(o, NULL);
TRAP_ERRORS_FINISH(1);
TRAP_ERRORS_BEGIN(eina_safety, ERR, NULL);
- o = efl_add(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
efl_net_ip_address_family_set(efl_added, AF_INET),
efl_net_ip_address_set(efl_added, wrong_slice));
_ipv4_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
TRAP_ERRORS_FINISH(1);
addr.sin_port = htons(12345);
addr.sin_addr.s_addr = htonl(0xabcdefafU);
- o = efl_add(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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_del(o);
+ efl_unref(o);
ecore_con_shutdown();
}
@@ -439,7 +439,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_create_ok)
ntohs(addr.sin_port),
slice);
_ipv4_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
addr.sin_port = htons(8081);
addr.sin_addr.s_addr = htonl(0);
@@ -447,7 +447,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_create_ok)
ntohs(addr.sin_port),
slice);
_ipv4_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
addr.sin_port = htons(0);
addr.sin_addr.s_addr = htonl(0x12345678);
@@ -455,7 +455,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_create_ok)
ntohs(addr.sin_port),
slice);
_ipv4_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
ecore_con_shutdown();
}
@@ -494,14 +494,14 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_create_sockaddr_ok)
o = efl_net_ip_address_create_sockaddr(EFL_NET_IP_ADDRESS_CLASS, &addr);
ck_assert_ptr_ne(&addr, efl_net_ip_address_sockaddr_get(o));
_ipv4_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
addr.sin_port = htons(0);
addr.sin_addr.s_addr = htonl(0);
o = efl_net_ip_address_create_sockaddr(EFL_NET_IP_ADDRESS_CLASS, &addr);
ck_assert_ptr_ne(&addr, efl_net_ip_address_sockaddr_get(o));
_ipv4_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
ecore_con_shutdown();
}
@@ -539,22 +539,22 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_parse_ok)
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "127.0.0.1:12345");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "127.0.0.1:12345");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "127.0.0.1:0");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "127.0.0.1");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "127.0.0.1");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "127.0.0.1");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "192.168.0.123:80");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "192.168.0.123:80");
- efl_del(o);
+ efl_unref(o);
ecore_con_shutdown();
}
@@ -716,7 +716,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv4_checks)
ck_assert_int_eq(efl_net_ip_address_ipv6_local_link_check(o), EINA_FALSE);
ck_assert_int_eq(efl_net_ip_address_ipv6_local_site_check(o), EINA_FALSE);
- efl_del(o);
+ efl_unref(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(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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_del(o);
+ efl_unref(o);
addr.sin6_port = htons(8081);
_ipv6_set(&addr, 0, 0, 0, 0, 0, 0, 0, 0);
- o = efl_add(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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_del(o);
+ efl_unref(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(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
efl_net_ip_address_family_set(efl_added, AF_INET6),
efl_net_ip_address_set(efl_added, wrong_slice));
_ipv6_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
TRAP_ERRORS_FINISH(1);
addr.sin6_port = htons(12345);
_ipv6_set(&addr, 0, 0, 0, 0, 0, 0, 0, 1);
- o = efl_add(EFL_NET_IP_ADDRESS_CLASS, NULL,
+ o = efl_add_ref(EFL_NET_IP_ADDRESS_CLASS, NULL,
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_del(o);
+ efl_unref(o);
ecore_con_shutdown();
}
@@ -869,7 +869,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_create_ok)
ntohs(addr.sin6_port),
slice);
_ipv6_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
addr.sin6_port = htons(8081);
_ipv6_set(&addr, 0, 0, 0, 0, 0, 0, 0, 0);
@@ -877,7 +877,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_create_ok)
ntohs(addr.sin6_port),
slice);
_ipv6_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
addr.sin6_port = htons(0);
_ipv6_set(&addr, 0, 0, 0, 0, 0, 0, 0, 1);
@@ -885,7 +885,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_create_ok)
ntohs(addr.sin6_port),
slice);
_ipv6_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
ecore_con_shutdown();
}
@@ -905,14 +905,14 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_create_sockaddr_ok)
o = efl_net_ip_address_create_sockaddr(EFL_NET_IP_ADDRESS_CLASS, &addr);
ck_assert_ptr_ne(&addr, efl_net_ip_address_sockaddr_get(o));
_ipv6_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
addr.sin6_port = htons(0);
_ipv6_set(&addr, 0, 0, 0, 0, 0, 0, 0, 0);
o = efl_net_ip_address_create_sockaddr(EFL_NET_IP_ADDRESS_CLASS, &addr);
ck_assert_ptr_ne(&addr, efl_net_ip_address_sockaddr_get(o));
_ipv6_check(o, &addr);
- efl_del(o);
+ efl_unref(o);
ecore_con_shutdown();
}
@@ -927,86 +927,86 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_parse_ok)
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::1]:12345");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::1]:12345");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::1]:0");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::1]");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::1]");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::1]");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "::1");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::1]");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::]:12345");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::]:12345");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::]:0");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::]");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::]");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::]");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "::");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::]");
- efl_del(o);
+ efl_unref(o);
/* IPv4 Mapped */
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::ffff:192.168.0.1]:12345");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::ffff:192.168.0.1]:12345");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::ffff:192.168.0.1]");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::ffff:192.168.0.1]");
- efl_del(o);
+ efl_unref(o);
/* IPv4 Compatible */
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::192.168.0.1]:12345");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::192.168.0.1]:12345");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[::192.168.0.1]");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[::192.168.0.1]");
- efl_del(o);
+ efl_unref(o);
/* Link Local */
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[fe80::1]:12345");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[fe80::1]:12345");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[fe80::1]");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[fe80::1]");
- efl_del(o);
+ efl_unref(o);
/* Site Local */
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[fc00::1]:12345");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[fc00::1]:12345");
- efl_del(o);
+ efl_unref(o);
o = efl_net_ip_address_parse(EFL_NET_IP_ADDRESS_CLASS, "[fc00::1]");
ck_assert_ptr_ne(o, NULL);
ck_assert_str_eq(efl_net_ip_address_string_get(o), "[fc00::1]");
- efl_del(o);
+ efl_unref(o);
ecore_con_shutdown();
}
@@ -1253,7 +1253,7 @@ START_TEST(ecore_test_efl_net_ip_address_ipv6_checks)
ck_assert_int_eq(efl_net_ip_address_ipv6_local_link_check(o), IN6_IS_ADDR_LINKLOCAL(ia));
ck_assert_int_eq(efl_net_ip_address_ipv6_local_site_check(o), IN6_IS_ADDR_SITELOCAL(ia));
- efl_del(o);
+ efl_unref(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 175adee339..9f29468168 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(EFL_MODEL_ITEM_CLASS, NULL);
+ base_model = efl_add_ref(EFL_MODEL_ITEM_CLASS, NULL);
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(EFL_MODEL_COMPOSITE_BOOLEAN_CLASS, NULL,
+ model = efl_add_ref(EFL_MODEL_COMPOSITE_BOOLEAN_CLASS, NULL,
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(EFL_MODEL_ITEM_CLASS, NULL);
+ base_model = efl_add_ref(EFL_MODEL_ITEM_CLASS, NULL);
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(EFL_MODEL_COMPOSITE_SELECTION_CLASS, NULL,
+ model = efl_add_ref(EFL_MODEL_COMPOSITE_SELECTION_CLASS, NULL,
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 bfd1984d4d..127e250338 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(EFL_MODEL_CONTAINER_CLASS, NULL);
+ model = efl_add_ref(EFL_MODEL_CONTAINER_CLASS, NULL);
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 19fe984022..8981a042aa 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(TEST_NUMBERWRAPPER_CLASS, NULL, test_numberwrapper_number_set(efl_added, n));
+ return efl_add_ref(TEST_NUMBERWRAPPER_CLASS, NULL, 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 98e4863c5a..0ae402abc5 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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ Eo *sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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(EIO_SENTRY_CLASS, NULL);
+ sentry = efl_add_ref(EIO_SENTRY_CLASS, NULL);
//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 61c9c4ed62..0afddf3022 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(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
ck_assert(root != NULL);
@@ -106,7 +106,7 @@ START_TEST (test_efl_access_role_get)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
Efl_Access_Role role;
@@ -147,7 +147,7 @@ START_TEST (test_efl_access_role_name_get)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
const char *ret = NULL;
@@ -165,7 +165,7 @@ START_TEST (test_efl_access_localized_role_name_get)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
const char *ret = NULL;
@@ -183,7 +183,7 @@ START_TEST (test_efl_access_description_set)
char *args[] = { "exe" };
elm_init(1, args);
- Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
const char *ret = NULL;
@@ -231,7 +231,7 @@ START_TEST (test_efl_access_children_and_parent)
elm_init(1, args);
generate_app();
- Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
Eina_List *child_list = NULL;
@@ -259,7 +259,7 @@ START_TEST (test_efl_access_children_and_parent2)
elm_init(1, args);
generate_app();
- Eo* root = efl_add(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
+ Eo* root = efl_add_ref(ELM_ATSPI_APP_OBJECT_CLASS, NULL);
Eo *win = NULL;
diff --git a/src/tests/elementary/elm_test_config.c b/src/tests/elementary/elm_test_config.c
index 12813b0f2c..c7593bd1db 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(EFL_UI_WIN_CLASS, NULL);
+ Eo *win = efl_add_ref(EFL_UI_WIN_CLASS, NULL);
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_del(win);
+ efl_unref(win);
elm_shutdown();
}
END_TEST
diff --git a/src/tests/elementary/elm_test_focus.c b/src/tests/elementary/elm_test_focus.c
index b2adc256e0..405b2fc0e8 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(FOCUS_TEST_CLASS, NULL);
- Efl_Ui_Focus_Object *r2 = efl_add(FOCUS_TEST_CLASS, NULL);
+ 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_Manager *m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
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_del(r2);
- efl_del(r1);
- efl_del(m);
+ efl_unref(r2);
+ efl_unref(r1);
+ efl_unref(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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
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_del(r1);
- efl_del(m);
+ efl_unref(r1);
+ efl_unref(m);
elm_shutdown();
}
@@ -81,11 +81,11 @@ START_TEST(pos_check)
CHECK(north, east, west, NULL, middle)
CHECK(south, east, west, middle, NULL)
- efl_del(middle);
- efl_del(south);
- efl_del(north);
- efl_del(east);
- efl_del(west);
+ efl_unref(middle);
+ efl_unref(south);
+ efl_unref(north);
+ efl_unref(east);
+ efl_unref(west);
elm_shutdown();
}
@@ -155,11 +155,11 @@ START_TEST(pos_check2)
#undef ck_assert_set_eq
- efl_del(middle);
- efl_del(north_east);
- efl_del(north_west);
- efl_del(south_east);
- efl_del(south_west);
+ efl_unref(middle);
+ efl_unref(north_east);
+ efl_unref(north_west);
+ efl_unref(south_east);
+ efl_unref(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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root)
);
- Efl_Ui_Focus_Manager *m2 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *m2 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root2)
);
@@ -308,7 +308,7 @@ START_TEST(finalize_check)
char *args[] = { "exe" };
elm_init(1, args);
- m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL);
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL);
fail_if(m);
elm_shutdown();
@@ -326,11 +326,11 @@ START_TEST(redirect_param)
TEST_OBJ_NEW(root2, 0, 20, 20, 20);
TEST_OBJ_NEW(child, 0, 20, 20, 20);
- m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root)
);
- m2 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m2 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root2)
);
@@ -354,7 +354,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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root)
);
@@ -389,7 +389,7 @@ START_TEST(order_check)
TEST_OBJ_NEW(child2, 0, 20, 20, 20);
TEST_OBJ_NEW(child3, 0, 20, 20, 20);
- m = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root)
);
@@ -428,7 +428,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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root)
);
@@ -461,13 +461,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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root)
);
focus_test_manager_set(root2, m);
- m2 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m2 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root2)
);
@@ -492,21 +492,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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root)
);
focus_test_manager_set(root2, m);
- m2 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m2 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root2)
);
- m3 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m3 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root2)
);
- m4 = efl_add(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m4 = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root2)
);
@@ -536,7 +536,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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
efl_ui_focus_manager_root_set(efl_added, root)
);
diff --git a/src/tests/elementary/elm_test_focus_common.c b/src/tests/elementary/elm_test_focus_common.c
index 00a96b39cf..589c68246d 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(FOCUS_TEST_CLASS, NULL,
+ ret = efl_add_ref(FOCUS_TEST_CLASS, NULL,
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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ m = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
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 d091d2df05..397dfcf5f8 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(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
+ Efl_Ui_Focus_Manager *manager = efl_add_ref(EFL_UI_FOCUS_MANAGER_CALC_CLASS, NULL,
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(FOCUS_TEST_SUB_MAIN_CLASS, NULL);
+ Focus_Test_Sub_Main *focus_main = efl_add_ref(FOCUS_TEST_SUB_MAIN_CLASS, NULL);
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_del(child1);
- efl_del(child2);
- efl_del(child3);
- efl_del(sub);
- efl_del(manager);
+ efl_unref(child1);
+ efl_unref(child2);
+ efl_unref(child3);
+ efl_unref(sub);
+ efl_unref(manager);
elm_shutdown();
}
END_TEST
@@ -180,12 +180,12 @@ START_TEST(correct_unregister)
eina_list_free(unregistered);
unregistered = NULL;
- efl_del(sub);
- efl_del(manager);
- efl_del(root);
- efl_del(child1);
- efl_del(child2);
- efl_del(child3);
+ efl_unref(sub);
+ efl_unref(manager);
+ efl_unref(root);
+ efl_unref(child1);
+ efl_unref(child2);
+ efl_unref(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_del(sub);
- efl_del(manager);
- efl_del(root);
- efl_del(child1);
- efl_del(child2);
- efl_del(child3);
+ efl_unref(sub);
+ efl_unref(manager);
+ efl_unref(root);
+ efl_unref(child1);
+ efl_unref(child2);
+ efl_unref(child3);
elm_shutdown();
}
END_TEST
diff --git a/src/tests/eo/access/access_main.c b/src/tests/eo/access/access_main.c
index 1188a60694..4bc3db5bb2 100644
--- a/src/tests/eo/access/access_main.c
+++ b/src/tests/eo/access/access_main.c
@@ -13,7 +13,7 @@ main(int argc, char *argv[])
(void) argv;
efl_object_init();
- Eo *obj = efl_add(INHERIT_CLASS, NULL);
+ Eo *obj = efl_add_ref(INHERIT_CLASS, NULL);
simple_a_set(obj, 1);
inherit_prot_print(obj);
diff --git a/src/tests/eo/children/children_main.c b/src/tests/eo/children/children_main.c
index e9292f2c90..1af58f5c7f 100644
--- a/src/tests/eo/children/children_main.c
+++ b/src/tests/eo/children/children_main.c
@@ -22,7 +22,7 @@ main(int argc, char *argv[])
efl_object_init();
- Eo *parent = efl_add(SIMPLE_CLASS, NULL);
+ Eo *parent = efl_add_ref(SIMPLE_CLASS, NULL);
Eo *child1 = efl_add(SIMPLE_CLASS, parent);
Eo *child2 = efl_add(SIMPLE_CLASS, parent);
diff --git a/src/tests/eo/composite_objects/composite_objects_main.c b/src/tests/eo/composite_objects/composite_objects_main.c
index 438492e51c..4536af1a7a 100644
--- a/src/tests/eo/composite_objects/composite_objects_main.c
+++ b/src/tests/eo/composite_objects/composite_objects_main.c
@@ -26,7 +26,7 @@ main(int argc, char *argv[])
(void) argv;
efl_object_init();
- Eo *obj = efl_add(COMP_CLASS, NULL);
+ Eo *obj = efl_add_ref(COMP_CLASS, NULL);
efl_event_callback_add(obj, EV_A_CHANGED, _a_changed_cb, NULL);
fail_if(!efl_isa(obj, COMP_CLASS));
diff --git a/src/tests/eo/constructors/constructors_main.c b/src/tests/eo/constructors/constructors_main.c
index e3b0b93ad4..e13e4fdf33 100644
--- a/src/tests/eo/constructors/constructors_main.c
+++ b/src/tests/eo/constructors/constructors_main.c
@@ -24,7 +24,7 @@ main(int argc, char *argv[])
(void) argv;
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(my_init_count != 2);
@@ -42,14 +42,14 @@ main(int argc, char *argv[])
fail_if(my_init_count != 0);
- obj = efl_add(SIMPLE2_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE2_CLASS, NULL);
fail_if(obj);
- obj = efl_add(SIMPLE3_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE3_CLASS, NULL);
fail_if(obj);
my_init_count = 0;
- obj = efl_add(SIMPLE4_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE4_CLASS, NULL);
fail_if(my_init_count != 2);
@@ -57,33 +57,33 @@ main(int argc, char *argv[])
fail_if(my_init_count != 0);
- obj = efl_add(SIMPLE5_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE5_CLASS, NULL);
fail_if(!obj);
efl_unref(obj);
- obj = efl_add(SIMPLE6_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE6_CLASS, NULL);
fail_if(!obj);
efl_unref(obj);
- obj = efl_add(SIMPLE7_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE7_CLASS, NULL);
fail_if(obj);
my_init_count = 0;
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj);
fail_if(my_init_count != 2);
a = simple_a_get(obj);
fail_if(a != 0);
my_init_count = 0;
- obj = efl_add(SIMPLE_CLASS, NULL, simple_a_set(efl_added, 7));
+ obj = efl_add_ref(SIMPLE_CLASS, NULL, simple_a_set(efl_added, 7));
fail_if(!obj);
fail_if(my_init_count != 2);
a = simple_a_get(obj);
fail_if(a != 7);
my_init_count = 0;
- obj = efl_add(SIMPLE_CLASS, NULL, simple_b_set(efl_added, 6), simple_a_set(efl_added, -1), b = simple_b_get(efl_added));
+ obj = efl_add_ref(SIMPLE_CLASS, NULL, simple_b_set(efl_added, 6), simple_a_set(efl_added, -1), b = simple_b_get(efl_added));
fail_if(obj);
fail_if(b != 6);
fail_if(my_init_count != 0);
diff --git a/src/tests/eo/function_overrides/function_overrides_main.c b/src/tests/eo/function_overrides/function_overrides_main.c
index 091af5ebe1..5828b1aa45 100644
--- a/src/tests/eo/function_overrides/function_overrides_main.c
+++ b/src/tests/eo/function_overrides/function_overrides_main.c
@@ -18,7 +18,7 @@ main(int argc, char *argv[])
efl_object_init();
Eina_Bool called = EINA_FALSE;
- Eo *obj = efl_add(INHERIT2_CLASS, NULL);
+ Eo *obj = efl_add_ref(INHERIT2_CLASS, NULL);
simple_a_set(obj, 1);
Simple_Public_Data *pd = efl_data_scope_get(obj, SIMPLE_CLASS);
@@ -26,7 +26,7 @@ main(int argc, char *argv[])
efl_unref(obj);
- obj = efl_add(INHERIT3_CLASS, NULL);
+ obj = efl_add_ref(INHERIT3_CLASS, NULL);
simple_a_set(obj, 1);
pd = efl_data_scope_get(obj, SIMPLE_CLASS);
@@ -34,7 +34,7 @@ main(int argc, char *argv[])
efl_unref(obj);
- obj = efl_add(INHERIT2_CLASS, NULL);
+ obj = efl_add_ref(INHERIT2_CLASS, NULL);
called = inherit2_print(obj);
fail_if(!called);
called = inherit2_print(obj);
@@ -42,7 +42,7 @@ main(int argc, char *argv[])
fail_if(!called);
efl_unref(obj);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
called = inherit2_print(obj);
fail_if(called);
diff --git a/src/tests/eo/interface/interface_main.c b/src/tests/eo/interface/interface_main.c
index 8f07bb29e6..53142cfd7f 100644
--- a/src/tests/eo/interface/interface_main.c
+++ b/src/tests/eo/interface/interface_main.c
@@ -16,7 +16,7 @@ main(int argc, char *argv[])
(void) argv;
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
simple_a_set(obj, 1);
simple_b_set(obj, 2);
diff --git a/src/tests/eo/mixin/mixin_main.c b/src/tests/eo/mixin/mixin_main.c
index f3534cc7ed..2ef7b360a4 100644
--- a/src/tests/eo/mixin/mixin_main.c
+++ b/src/tests/eo/mixin/mixin_main.c
@@ -18,7 +18,7 @@ main(int argc, char *argv[])
(void) argv;
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
simple_a_set(obj, 1);
simple_b_set(obj, 2);
@@ -40,7 +40,7 @@ main(int argc, char *argv[])
efl_unref(obj);
- obj = efl_add(INHERIT_CLASS, NULL);
+ obj = efl_add_ref(INHERIT_CLASS, NULL);
simple_a_set(obj, 5);
a = simple_a_get(obj);
printf("%d\n", a);
diff --git a/src/tests/eo/signals/signals_main.c b/src/tests/eo/signals/signals_main.c
index 51fca1f39e..3639ff132d 100644
--- a/src/tests/eo/signals/signals_main.c
+++ b/src/tests/eo/signals/signals_main.c
@@ -65,7 +65,7 @@ main(int argc, char *argv[])
(void) argv;
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
Simple_Public_Data *pd = efl_data_scope_get(obj, SIMPLE_CLASS);
/* The order of these two is undetermined. */
diff --git a/src/tests/eo/suite/eo_test_class_singleton.c b/src/tests/eo/suite/eo_test_class_singleton.c
index e5db1ff62c..a38a52b915 100644
--- a/src/tests/eo/suite/eo_test_class_singleton.c
+++ b/src/tests/eo/suite/eo_test_class_singleton.c
@@ -15,7 +15,7 @@ _singleton_efl_constructor(Eo *eo_obj EINA_UNUSED, void *_pd EINA_UNUSED)
{
if (!singleton_obj)
{
- singleton_obj = efl_add(SIMPLE_CLASS, NULL);
+ singleton_obj = efl_add_ref(SIMPLE_CLASS, NULL);
}
else
{
diff --git a/src/tests/eo/suite/eo_test_domain.c b/src/tests/eo/suite/eo_test_domain.c
index 45a1fe377f..e864631b78 100644
--- a/src/tests/eo/suite/eo_test_domain.c
+++ b/src/tests/eo/suite/eo_test_domain.c
@@ -32,7 +32,7 @@ _a_get(Eo *obj EINA_UNUSED, void *class_data)
return pd->a;
}
-//return obj = efl_add(DOMAIN_CLASS, NULL);
+//return obj = efl_add_ref(DOMAIN_CLASS, NULL);
EFL_VOID_FUNC_BODYV(domain_recursive, EFL_FUNC_CALL(n), int n);
diff --git a/src/tests/eo/suite/eo_test_event.c b/src/tests/eo/suite/eo_test_event.c
index 66902db233..43420e3791 100644
--- a/src/tests/eo/suite/eo_test_event.c
+++ b/src/tests/eo/suite/eo_test_event.c
@@ -63,7 +63,7 @@ START_TEST(eo_event)
efl_object_init();
Eo *obj;
- obj = efl_add(efl_test_event_class_get(), NULL);
+ obj = efl_add_ref(efl_test_event_class_get(), NULL);
efl_event_callback_priority_add(obj, EFL_TEST_EVENT_EVENT_TESTER, EFL_CALLBACK_PRIORITY_BEFORE, _cb2, &data);
efl_event_callback_priority_add(obj, EFL_TEST_EVENT_EVENT_TESTER, EFL_CALLBACK_PRIORITY_BEFORE, _cb1, &data);
@@ -123,7 +123,7 @@ START_TEST(eo_event_call_in_call)
efl_object_init();
Eo *obj;
- obj = efl_add(efl_test_event_class_get(), NULL);
+ obj = efl_add_ref(efl_test_event_class_get(), NULL);
efl_event_callback_priority_add(obj, EFL_TEST_EVENT_EVENT_TESTER, EFL_CALLBACK_PRIORITY_BEFORE, _cb_rec_1, &data);
memset(&data, 0, sizeof(Test_Data));
@@ -179,7 +179,7 @@ START_TEST(eo_event_generation_bug)
Eo *obj;
- obj = efl_add(efl_test_event_class_get(), NULL);
+ obj = efl_add_ref(efl_test_event_class_get(), NULL);
emitted = 0;
efl_event_callback_priority_add(obj, EFL_TEST_EVENT_EVENT_TESTER, EFL_CALLBACK_PRIORITY_BEFORE, _generation_clamp_step1, NULL);
efl_event_callback_priority_add(obj, EFL_TEST_EVENT_EVENT_TESTER_SUBSCRIBE, EFL_CALLBACK_PRIORITY_BEFORE, _generation_clamp_subscribe, NULL);
diff --git a/src/tests/eo/suite/eo_test_general.c b/src/tests/eo/suite/eo_test_general.c
index c6bf035369..169db5b889 100644
--- a/src/tests/eo/suite/eo_test_general.c
+++ b/src/tests/eo/suite/eo_test_general.c
@@ -22,10 +22,10 @@
START_TEST(eo_simple)
{
efl_object_init();
- Eo *obj = efl_add(EO_CLASS, NULL);
+ Eo *obj = efl_add_ref(EO_CLASS, NULL);
fail_if(obj);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj);
efl_constructor(obj);
efl_destructor(obj);
@@ -39,10 +39,10 @@ START_TEST(eo_singleton)
{
efl_object_init();
- Eo *obj = efl_add(SINGLETON_CLASS, NULL);
+ Eo *obj = efl_add_ref(SINGLETON_CLASS, NULL);
fail_if(!obj);
- Eo *obj2 = efl_add(SINGLETON_CLASS, NULL);
+ Eo *obj2 = efl_add_ref(SINGLETON_CLASS, NULL);
fail_if(!obj2);
ck_assert_ptr_eq(obj, obj2);
@@ -72,7 +72,7 @@ START_TEST(efl_object_override_tests)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj);
/* First get the value before the override to make sure it works and to
@@ -201,7 +201,7 @@ START_TEST(eo_signals)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
Eina_Bool r;
efl_event_callback_add(obj, EFL_EVENT_CALLBACK_ADD, _eo_signals_cb_added_deled, &_eo_signals_callbacks);
@@ -231,7 +231,7 @@ START_TEST(eo_signals)
efl_unref(obj);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
/* Legacy support signals. */
{
const Efl_Event_Description *a_desc = efl_object_legacy_only_event_description_get("a,changed");
@@ -302,7 +302,7 @@ START_TEST(efl_data_fetch)
const Efl_Class *klass = efl_class_new(&class_desc, EO_CLASS, NULL);
fail_if(!klass);
- Eo *obj = efl_add(klass, NULL);
+ Eo *obj = efl_add_ref(klass, NULL);
fail_if(!obj);
#ifdef EO_DEBUG
fail_if(efl_data_scope_get(obj, SIMPLE_CLASS));
@@ -313,7 +313,7 @@ START_TEST(efl_data_fetch)
klass = efl_class_new(&class_desc, EO_CLASS, NULL);
fail_if(!klass);
- obj = efl_add(klass, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
fail_if(efl_data_scope_get(obj, klass));
fail_if(!efl_data_scope_get(obj, EFL_OBJECT_CLASS));
@@ -327,11 +327,11 @@ START_TEST(efl_data_safe_fetch)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE2_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE2_CLASS, NULL);
fail_if(!obj || !efl_data_scope_safe_get(obj, SIMPLE2_CLASS));
efl_unref(obj);
- obj = efl_add(SIMPLE3_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE3_CLASS, NULL);
fail_if(!obj);
fail_if(!efl_isa(obj, SIMPLE_CLASS));
fail_if(!efl_isa(obj, SIMPLE2_CLASS));
@@ -401,7 +401,7 @@ START_TEST(efl_isa_tests)
fail_if(!klass);
}
- Eo *obj = efl_add(klass, NULL);
+ Eo *obj = efl_add_ref(klass, NULL);
fail_if(!obj);
fail_if(efl_isa(obj, SIMPLE_CLASS));
fail_if(!efl_isa(obj, iface));
@@ -410,7 +410,7 @@ START_TEST(efl_isa_tests)
fail_if(!efl_isa(obj, EO_CLASS));
efl_unref(obj);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj);
fail_if(efl_isa(obj, klass));
fail_if(efl_isa(obj, iface));
@@ -428,11 +428,11 @@ START_TEST(efl_composite_tests)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj);
- Eo *obj2 = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj2 = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj2);
- Eo *obj3 = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj3 = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj3);
efl_composite_attach(obj, obj2);
@@ -443,11 +443,11 @@ START_TEST(efl_composite_tests)
fail_if(!efl_composite_part_is(obj2));
/* Check that a deletion of a child detaches from the parent. */
- efl_del(obj2);
+ efl_unref(obj2);
fail_if(!efl_composite_attach(obj3, obj));
/* Check that a deletion of the parent detaches the child. */
- efl_del(obj3);
+ efl_unref(obj3);
fail_if(efl_composite_part_is(obj));
efl_unref(obj);
@@ -506,11 +506,11 @@ START_TEST(eo_man_free)
fail_if(!klass);
cur_klass = klass;
- Eo *obj = efl_add(klass, NULL);
+ Eo *obj = efl_add_ref(klass, NULL);
fail_if(!obj);
efl_unref(obj);
- obj = efl_add(klass, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
fail_if(efl_manual_free(obj));
efl_unref(obj);
@@ -520,7 +520,7 @@ START_TEST(eo_man_free)
cur_klass = klass;
fail_if(!klass);
- obj = efl_add(klass, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
fail_if(efl_manual_free(obj));
fail_if(efl_destructed_is(obj));
@@ -528,7 +528,7 @@ START_TEST(eo_man_free)
fail_if(!efl_destructed_is(obj));
fail_if(!efl_manual_free(obj));
- obj = efl_add(klass, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
efl_unref(obj);
fail_if(!efl_destructed_is(obj));
@@ -539,12 +539,12 @@ START_TEST(eo_man_free)
cur_klass = klass;
fail_if(!klass);
- obj = efl_add(klass, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
fail_if(efl_manual_free(obj));
efl_unref(obj);
- obj = efl_add(klass, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
efl_manual_free_set(obj, EINA_TRUE);
efl_unref(obj);
@@ -553,7 +553,7 @@ START_TEST(eo_man_free)
efl_unref(obj);
fail_if(!efl_manual_free(obj));
- obj = efl_add(klass, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
efl_manual_free_set(obj, EINA_TRUE);
efl_unref(obj);
@@ -571,9 +571,9 @@ END_TEST
START_TEST(efl_refs)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj2 = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj3 = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj2 = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj3 = efl_add_ref(SIMPLE_CLASS, NULL);
efl_xref(obj, obj2);
fail_if(efl_ref_count(obj) != 2);
@@ -608,7 +608,7 @@ START_TEST(efl_refs)
efl_unref(obj3);
/* Check hierarchy */
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
obj2 = efl_ref(efl_add(SIMPLE_CLASS, obj));
Eo *wref = NULL;
@@ -624,7 +624,7 @@ START_TEST(efl_refs)
fail_if(wref);
/* efl_add_ref and normal efl_add */
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
obj2 = efl_add(SIMPLE_CLASS, obj);
obj3 = efl_add_ref(SIMPLE_CLASS, obj);
@@ -632,15 +632,15 @@ START_TEST(efl_refs)
ck_assert_int_eq(efl_ref_count(obj2), 1);
ck_assert_int_eq(efl_ref_count(obj3), 2);
- efl_del(obj);
+ efl_unref(obj);
efl_del(obj2);
efl_unref(obj3);
efl_del(obj3);
/* Setting and removing parents. */
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
obj2 = efl_ref(efl_add(SIMPLE_CLASS, obj));
- obj3 = efl_ref(efl_add(SIMPLE_CLASS, NULL));
+ obj3 = efl_add_ref(SIMPLE_CLASS, NULL);
efl_parent_set(obj2, obj3);
efl_parent_set(obj3, obj);
@@ -655,12 +655,12 @@ START_TEST(efl_refs)
fail_if(!efl_invalidated_get(obj2));
fail_if(!efl_invalidated_get(obj3));
- efl_del(obj);
+ efl_unref(obj);
efl_del(obj2);
- efl_del(obj3);
+ efl_unref(obj3);
/* Setting and removing parents for add_ref */
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
obj2 = efl_add_ref(SIMPLE_CLASS, obj);
obj3 = efl_add_ref(SIMPLE_CLASS, NULL);
@@ -680,17 +680,17 @@ START_TEST(efl_refs)
fail_if(!efl_invalidated_get(obj2));
fail_if(!efl_invalidated_get(obj3));
- efl_del(obj);
+ efl_unref(obj);
efl_del(obj2);
- efl_del(obj3);
+ efl_unref(obj3);
/* Just check it doesn't seg atm. */
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
efl_ref(obj);
efl_unref(obj);
efl_unref(obj);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
obj2 = efl_add(SIMPLE_CLASS, obj);
efl_unref(obj2);
efl_ref(obj2);
@@ -705,8 +705,8 @@ START_TEST(efl_weak_reference)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj2 = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj2 = efl_add_ref(SIMPLE_CLASS, NULL);
Eo *wref = NULL, *wref2 = NULL, *wref3 = NULL;
efl_wref_add(obj, &wref);
fail_if(!wref);
@@ -714,7 +714,7 @@ START_TEST(efl_weak_reference)
efl_unref(obj);
fail_if(wref);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
efl_wref_add(obj, &wref);
efl_ref(obj);
@@ -726,7 +726,7 @@ START_TEST(efl_weak_reference)
efl_unref(obj);
fail_if(wref);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
efl_wref_add(obj, &wref);
efl_wref_del(obj, &wref);
@@ -775,9 +775,9 @@ END_TEST
START_TEST(eo_generic_data)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj2 = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj3 = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj2 = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj3 = efl_add_ref(SIMPLE_CLASS, NULL);
Eo *objtmp;
void *data = NULL;
Eina_Value *value;
@@ -857,10 +857,10 @@ START_TEST(eo_generic_data)
efl_key_ref_set(obj, "test1", obj2);
efl_key_ref_set(obj, "test2", obj3);
- efl_del(obj2);
- efl_del(obj2);
- efl_del(obj3);
- efl_del(obj3);
+ efl_unref(obj2);
+ efl_unref(obj2);
+ efl_unref(obj3);
+ efl_unref(obj3);
objtmp = efl_key_ref_get(obj, "test1");
fail_if(objtmp);
@@ -869,8 +869,8 @@ START_TEST(eo_generic_data)
- obj2 = efl_add(SIMPLE_CLASS, NULL);
- obj3 = efl_add(SIMPLE_CLASS, NULL);
+ obj2 = efl_add_ref(SIMPLE_CLASS, NULL);
+ obj3 = efl_add_ref(SIMPLE_CLASS, NULL);
efl_key_wref_set(obj, "test1", obj2);
objtmp = efl_key_wref_get(obj, "test1");
@@ -912,8 +912,8 @@ START_TEST(eo_generic_data)
efl_key_wref_set(obj, "test1", obj2);
efl_key_wref_set(obj, "test2", obj3);
- efl_del(obj2);
- efl_del(obj3);
+ efl_unref(obj2);
+ efl_unref(obj3);
objtmp = efl_key_wref_get(obj, "test1");
fail_if(objtmp);
@@ -967,7 +967,7 @@ START_TEST(eo_magic_checks)
obj = efl_add((Efl_Class *) buf, NULL);
fail_if(obj);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj);
simple_a_set((Eo *) buf, ++i);
@@ -1077,12 +1077,12 @@ START_TEST(efl_func_resolve)
const Efl_Class *klass = efl_class_new(&class_desc, SIMPLE_CLASS, NULL);
fail_if(!klass);
- Eo *obj = efl_add(klass, NULL);
+ Eo *obj = efl_add_ref(klass, NULL);
fail_if(!resolve_a_print(obj));
efl_unref(obj);
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj);
efl_manual_free_set(obj, EINA_TRUE);
@@ -1103,24 +1103,24 @@ START_TEST(efl_add_do_and_custom)
Eo *obj = NULL;
efl_object_init();
- obj = efl_add(SIMPLE_CLASS, NULL, efl_constructor(efl_added));
+ obj = efl_add_ref(SIMPLE_CLASS, NULL, efl_constructor(efl_added));
fail_if(!obj);
efl_unref(obj);
- obj = efl_add(SIMPLE_CLASS, NULL, simple_a_set(efl_added, 7));
+ obj = efl_add_ref(SIMPLE_CLASS, NULL, simple_a_set(efl_added, 7));
fail_if(!obj);
pd = efl_data_scope_get(obj, SIMPLE_CLASS);
fail_if(pd->a != 7);
efl_unref(obj);
- obj = efl_add(SIMPLE_CLASS, NULL, efl_constructor(efl_added), simple_a_set(efl_added, 7));
+ obj = efl_add_ref(SIMPLE_CLASS, NULL, efl_constructor(efl_added), simple_a_set(efl_added, 7));
fail_if(!obj);
pd = efl_data_scope_get(obj, SIMPLE_CLASS);
fail_if(pd->a != 7);
efl_unref(obj);
Eina_Bool finalized;
- obj = efl_add(SIMPLE_CLASS, NULL, finalized = efl_finalized_get(efl_added));
+ obj = efl_add_ref(SIMPLE_CLASS, NULL, finalized = efl_finalized_get(efl_added));
fail_if(finalized);
finalized = efl_finalized_get(obj);
@@ -1150,7 +1150,7 @@ START_TEST(eo_pointers_indirection)
fail_if(!klass);
/* Check simple id validity */
- Eo *obj = efl_add(klass, NULL);
+ Eo *obj = efl_add_ref(klass, NULL);
fail_if(!obj);
fail_if(!efl_isa(obj, klass));
obj = (Eo *)((char *)(obj) + 1);
@@ -1161,17 +1161,17 @@ START_TEST(eo_pointers_indirection)
fail_if(efl_isa(obj, klass));
/* Check id invalidity after deletion */
- Eo *obj1 = efl_add(klass, NULL);
+ Eo *obj1 = efl_add_ref(klass, NULL);
fail_if(!obj1);
efl_unref(obj1);
- Eo *obj2 = efl_add(klass, NULL);
+ Eo *obj2 = efl_add_ref(klass, NULL);
fail_if(!obj2);
fail_if(!efl_isa(obj2, klass));
fail_if(efl_isa(obj1, klass));
efl_unref(obj2);
/* Check id sanity checks for "close enough" ids. */
- obj1 = efl_add(klass, NULL);
+ obj1 = efl_add_ref(klass, NULL);
fail_if(!obj1);
obj2 = (Eo *) (((Eo_Id) obj1) & ~MASK_OBJ_TAG);
fail_if(efl_class_get(obj2));
@@ -1184,7 +1184,7 @@ START_TEST(eo_pointers_indirection)
/* Creation of the objects */
for ( obj_id = 0; obj_id < NB_OBJS; obj_id++)
{
- objs[obj_id] = efl_add(klass, NULL);
+ objs[obj_id] = efl_add_ref(klass, NULL);
if(!objs[obj_id])
fail_if(!objs[obj_id]);
if(!efl_isa(objs[obj_id], klass))
@@ -1200,7 +1200,7 @@ START_TEST(eo_pointers_indirection)
/* Creation of the deleted objects */
for ( obj_id = 0; obj_id < NB_OBJS; obj_id+=2000)
{
- objs[obj_id] = efl_add(klass, NULL);
+ objs[obj_id] = efl_add_ref(klass, NULL);
if(!objs[obj_id])
fail_if(!objs[obj_id]);
if(!efl_isa(objs[obj_id], klass))
@@ -1251,7 +1251,7 @@ START_TEST(efl_add_failures)
const Efl_Class *klass = efl_class_new(&class_desc, EO_CLASS, NULL);
- Eo *obj = efl_add(klass, NULL);
+ Eo *obj = efl_add_ref(klass, NULL);
fail_if(obj);
@@ -1297,7 +1297,7 @@ START_TEST(efl_del_intercept)
/* Check unref interception */
intercepted = EINA_FALSE;
- Eo *obj = efl_add(klass, NULL);
+ Eo *obj = efl_add_ref(klass, NULL);
fail_if(!obj);
fail_if(!efl_isa(obj, klass));
efl_del_intercept_set(obj, _del_intercept);
@@ -1307,17 +1307,17 @@ START_TEST(efl_del_intercept)
/* Check del interception */
intercepted = EINA_FALSE;
- obj = efl_add(klass, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
fail_if(!efl_isa(obj, klass));
efl_del_intercept_set(obj, _del_intercept);
- efl_del(obj);
+ efl_unref(obj);
fail_if(!intercepted);
fail_if(efl_isa(obj, klass));
/* Check reuse works as expected. */
- Eo *parent = efl_add(SIMPLE_CLASS, NULL);
- obj = efl_add(klass, NULL);
+ Eo *parent = efl_add_ref(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(klass, NULL);
fail_if(!obj);
ck_assert_int_eq(efl_ref_count(obj), 1);
efl_parent_set(obj, parent);
@@ -1328,7 +1328,7 @@ START_TEST(efl_del_intercept)
ck_assert_int_eq(efl_ref_count(obj), 1);
efl_parent_set(obj, parent);
ck_assert_int_eq(efl_ref_count(obj), 1);
- efl_del(obj);
+ efl_unref(obj);
efl_object_shutdown();
#endif
@@ -1338,9 +1338,9 @@ END_TEST
START_TEST(efl_name)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj2 = efl_add(SIMPLE_CLASS, NULL);
- Eo *obj3 = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj2 = efl_add_ref(SIMPLE_CLASS, NULL);
+ Eo *obj3 = efl_add_ref(SIMPLE_CLASS, NULL);
Eo *objtmp;
const char *id;
@@ -1386,7 +1386,7 @@ START_TEST(efl_name)
objtmp = efl_name_find(obj, "*mple:joe");
fail_if(objtmp != obj2);
- efl_del(obj);
+ efl_unref(obj);
efl_object_shutdown();
}
@@ -1395,7 +1395,7 @@ END_TEST
START_TEST(eo_comment)
{
efl_object_init();
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
const char *comment;
comment = efl_comment_get(obj);
@@ -1416,7 +1416,7 @@ START_TEST(eo_comment)
comment = efl_comment_get(obj);
fail_if(NULL != comment);
- efl_del(obj);
+ efl_unref(obj);
efl_object_shutdown();
}
@@ -1425,7 +1425,7 @@ END_TEST
START_TEST(eo_rec_interface)
{
efl_object_init();
- Eo *s = efl_add(SEARCHABLE_CLASS, NULL);
+ Eo *s = efl_add_ref(SEARCHABLE_CLASS, NULL);
Eo *obj = efl_add(SIMPLE_CLASS, s);
Eo *obj2 = efl_add(SIMPLE_CLASS, obj);
Eo *objtmp;
@@ -1455,7 +1455,7 @@ thr1(void *data, Eina_Thread t EINA_UNUSED)
fail_if(efl_domain_switch(EFL_ID_DOMAIN_THREAD) != EINA_TRUE);
fail_if(efl_domain_get() != EFL_ID_DOMAIN_THREAD);
printf("ADD2\n");
- Eo *obj = efl_add(DOMAIN_CLASS, NULL);
+ Eo *obj = efl_add_ref(DOMAIN_CLASS, NULL);
printf("ADD2 DONE = %p\n", obj);
printf("VERIFY finalized_get()\n");
@@ -1463,16 +1463,16 @@ thr1(void *data, Eina_Thread t EINA_UNUSED)
printf("VERIFY parent_set(invalid) -- WILL SHOW ERRORS\n");
efl_domain_current_push(EFL_ID_DOMAIN_SHARED);
- s1 = efl_add(DOMAIN_CLASS, NULL);
+ s1 = efl_add_ref(DOMAIN_CLASS, NULL);
efl_domain_current_pop();
- efl_del(s1);
+ efl_unref(s1);
efl_parent_set(d->objs, s1);
printf("END OF ERRORS\n");
printf("VERIFY composite\n");
efl_domain_current_push(EFL_ID_DOMAIN_SHARED);
- s1 = efl_add(SIMPLE_CLASS, NULL, simple_a_set(efl_added, 7));
- s2 = efl_add(SIMPLE_CLASS, NULL, simple_a_set(efl_added, 42));
+ s1 = efl_add_ref(SIMPLE_CLASS, NULL, simple_a_set(efl_added, 7));
+ s2 = efl_add_ref(SIMPLE_CLASS, NULL, simple_a_set(efl_added, 42));
efl_domain_current_pop();
efl_composite_attach(d->objs, s1);
@@ -1480,9 +1480,9 @@ thr1(void *data, Eina_Thread t EINA_UNUSED)
int i2 = simple_a_get(s1);
fail_if(i1 != i2);
fail_if(efl_composite_attach(d->objs, s2));
- efl_del(s1);
+ efl_unref(s1);
fail_if(!efl_composite_attach(d->objs, s2));
- efl_del(s2);
+ efl_unref(s2);
printf("SET ON LOCAL\n");
domain_a_set(obj, 1234);
@@ -1517,7 +1517,7 @@ thr1(void *data, Eina_Thread t EINA_UNUSED)
fail_if(efl_domain_data_return(dom) != EINA_TRUE);
printf("RETURN DOMAIN DATA DONE\n");
- efl_del(obj);
+ efl_unref(obj);
return NULL;
}
@@ -1579,12 +1579,12 @@ START_TEST(eo_domain)
fail_if(efl_domain_current_get() != EFL_ID_DOMAIN_MAIN);
printf("ADD1\n");
- obj = efl_add(DOMAIN_CLASS, NULL);
+ obj = efl_add_ref(DOMAIN_CLASS, NULL);
printf("ADD1 DONE = %p\n", obj);
efl_domain_current_push(EFL_ID_DOMAIN_SHARED);
printf("ADDS\n");
- objs = efl_add(DOMAIN_CLASS, NULL, domain_a_set(efl_added, 42));
+ objs = efl_add_ref(DOMAIN_CLASS, NULL, domain_a_set(efl_added, 42));
printf("ADDS DONE = %p\n", objs);
efl_domain_current_pop();
@@ -1610,8 +1610,8 @@ START_TEST(eo_domain)
printf("JOIN DONE\n");
printf("DELETING OBJECTS\n");
- efl_del(obj);
- efl_del(objs);
+ efl_unref(obj);
+ efl_unref(objs);
efl_object_shutdown();
printf("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\n");
@@ -1685,30 +1685,30 @@ START_TEST(efl_cast_test)
Eo *obj;
// Testing normal calls
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(!obj);
ck_assert_int_eq(inherit_value(obj), 0);
efl_unref(obj);
- obj = efl_add(klass1, NULL);
+ obj = efl_add_ref(klass1, NULL);
fail_if(!obj);
ck_assert_int_eq(inherit_value(obj), 1);
efl_unref(obj);
- obj = efl_add(klass2, NULL);
+ obj = efl_add_ref(klass2, NULL);
fail_if(!obj);
ck_assert_int_eq(inherit_value(obj), 2);
efl_unref(obj);
// Testing efl_super
- obj = efl_add(klass2, NULL);
+ obj = efl_add_ref(klass2, NULL);
fail_if(!obj);
ck_assert_int_eq(inherit_value(efl_super(obj, klass2)), 1);
ck_assert_int_eq(inherit_value(efl_super(obj, klass1)), 0);
efl_unref(obj);
// Testing efl_cast
- obj = efl_add(klass2, NULL);
+ obj = efl_add_ref(klass2, NULL);
fail_if(!obj);
ck_assert_int_eq(inherit_value(efl_cast(obj, klass2)), 2);
ck_assert_int_eq(inherit_value(efl_cast(obj, klass1)), 1);
@@ -1744,11 +1744,11 @@ START_TEST(efl_object_destruct_test)
efl_object_init();
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(efl_ref_count(obj) != 1);
efl_event_callback_add(obj, EFL_EVENT_DEL, _destruct_test_del_cb, &var);
efl_event_callback_add(obj, EFL_EVENT_DESTRUCT, _destruct_test_destruct_cb, &var);
- efl_del(obj);
+ efl_unref(obj);
// var should be 2 if del then destruct, 0 otherwise
ck_assert_int_eq(var, 2);
@@ -1772,7 +1772,7 @@ START_TEST(efl_object_auto_unref_test)
// Test unref after valid call
_auto_unref_del = 0;
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(efl_ref_count(obj) != 1);
efl_event_callback_add(obj, EFL_EVENT_DEL, _auto_unref_del_cb, &_auto_unref_del);
___efl_auto_unref_set(obj, 1);
@@ -1783,7 +1783,7 @@ START_TEST(efl_object_auto_unref_test)
// Test unref after invalid call
_auto_unref_del = 0;
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
fail_if(efl_ref_count(obj) != 1);
efl_event_callback_add(obj, EFL_EVENT_DEL, _auto_unref_del_cb, &_auto_unref_del);
___efl_auto_unref_set(obj, 1);
@@ -1794,7 +1794,7 @@ START_TEST(efl_object_auto_unref_test)
// Same with a parent
_auto_unref_del = 0;
- parent = efl_add(SIMPLE_CLASS, NULL);
+ parent = efl_add_ref(SIMPLE_CLASS, NULL);
obj = efl_add(SIMPLE_CLASS, parent);
fail_if(efl_ref_count(obj) != 1);
efl_allow_parent_unref_set(obj, 1);
@@ -1804,7 +1804,7 @@ START_TEST(efl_object_auto_unref_test)
fail_if(efl_ref_count(obj) != 1);
efl_name_set(obj, "name");
fail_if(!_auto_unref_del);
- efl_del(parent);
+ efl_unref(parent);
efl_object_shutdown();
}
diff --git a/src/tests/eo/suite/eo_test_init.c b/src/tests/eo/suite/eo_test_init.c
index 1f82be4a07..a625847b7d 100644
--- a/src/tests/eo/suite/eo_test_init.c
+++ b/src/tests/eo/suite/eo_test_init.c
@@ -24,7 +24,7 @@ START_TEST(eo_test_init_shutdown)
ck_assert_str_eq("Efl.Object", efl_class_name_get(EFL_OBJECT_CLASS));
/* XXX-1: Essential for the next test to assign the wrong op. */
- obj = efl_add(SIMPLE_CLASS, NULL);
+ obj = efl_add_ref(SIMPLE_CLASS, NULL);
simple_a_set(obj, 1);
ck_assert_int_eq(1, simple_a_get(obj));
diff --git a/src/tests/eo/suite/eo_test_threaded_calls.c b/src/tests/eo/suite/eo_test_threaded_calls.c
index bbbc3746ca..a42de16352 100644
--- a/src/tests/eo/suite/eo_test_threaded_calls.c
+++ b/src/tests/eo/suite/eo_test_threaded_calls.c
@@ -99,7 +99,7 @@ _thread_job(void *data, Eina_Thread t EINA_UNUSED)
fail_if(EINA_LOCK_SUCCEED != eina_spinlock_take(&locks[0]));
}
- obj = efl_add(THREAD_TEST_CLASS, NULL, thread_test_constructor(efl_added, v));
+ obj = efl_add_ref(THREAD_TEST_CLASS, NULL, thread_test_constructor(efl_added, v));
thread_test_try_swap_stack(obj);
v = thread_test_v_get(obj);
diff --git a/src/tests/eo/suite/eo_test_value.c b/src/tests/eo/suite/eo_test_value.c
index 7daaf60c47..19ce91c331 100644
--- a/src/tests/eo/suite/eo_test_value.c
+++ b/src/tests/eo/suite/eo_test_value.c
@@ -17,7 +17,7 @@ START_TEST(eo_value)
Eina_Value val2, eo_val;
void *tmpp = NULL;
Efl_Dbg_Info *eo_dbg_info;
- Eo *obj = efl_add(SIMPLE_CLASS, NULL);
+ Eo *obj = efl_add_ref(SIMPLE_CLASS, NULL);
eo_dbg_info = EFL_DBG_INFO_LIST_APPEND(NULL, "Root");
efl_dbg_info_get(obj, eo_dbg_info);
diff --git a/src/tests/eolian_js/eolian_js_test_constructor_method_impl.c b/src/tests/eolian_js/eolian_js_test_constructor_method_impl.c
index 6fe2cb4b9b..ae50c33459 100644
--- a/src/tests/eolian_js/eolian_js_test_constructor_method_impl.c
+++ b/src/tests/eolian_js/eolian_js_test_constructor_method_impl.c
@@ -132,7 +132,7 @@ _constructor_method_class_classoutmethod1(Eo* obj EINA_UNUSED, Constructor_Metho
{
fprintf(stderr, "classoutmethod1\n");
fflush(stderr);
- return efl_add(MY_CLASS, NULL, constructor_method_class_constructor1(efl_added, one), constructor_method_class_constructor2(efl_added, two));
+ return efl_add_ref(MY_CLASS, NULL, constructor_method_class_constructor1(efl_added, one), constructor_method_class_constructor2(efl_added, two));
}
EOLIAN static void
@@ -140,7 +140,7 @@ _constructor_method_class_classoutmethod2(Eo* obj EINA_UNUSED, Constructor_Metho
{
fprintf(stderr, "classoutmethod2\n");
fflush(stderr);
- *out_class = efl_add(MY_CLASS, NULL, constructor_method_class_constructor1(efl_added, one), constructor_method_class_constructor2(efl_added, two));
+ *out_class = efl_add_ref(MY_CLASS, NULL, constructor_method_class_constructor1(efl_added, one), constructor_method_class_constructor2(efl_added, two));
}