seoz pushed a commit to branch master.
commit 2bb32fd1ca8557bfbf4172abf7fe901855898993
Author: Daniel Juyung Seo <[email protected]>
Date: Wed Apr 3 11:28:53 2013 +0900
elm: print the error message inside elm_widget_sub_object_add().
1. Do not need to print the same error message from all the widget codes.
2. Even though elm_widget_sub_object_add() can be used internally, there
should be no error message at all.
Elm devs should fix it beforehand.
So it looks ok to print the error message in elm_widget_sub_object_add()
to force elm devs to fix it.
3. Got additional code cleanups.
---
src/lib/elc_ctxpopup.c | 3 +--
src/lib/elc_fileselector.c | 4 +---
src/lib/elc_fileselector_button.c | 4 +---
src/lib/elc_fileselector_entry.c | 3 +--
src/lib/elc_hoversel.c | 4 +---
src/lib/elc_multibuttonentry.c | 3 +--
src/lib/elc_naviframe.c | 3 +--
src/lib/elc_player.c | 4 +---
src/lib/elc_popup.c | 3 +--
src/lib/elm_access.c | 4 +---
src/lib/elm_actionslider.c | 4 +---
src/lib/elm_bg.c | 5 +----
src/lib/elm_box.c | 3 +--
src/lib/elm_bubble.c | 4 +---
src/lib/elm_button.c | 4 +---
src/lib/elm_calendar.c | 4 +---
src/lib/elm_check.c | 4 +---
src/lib/elm_clock.c | 4 +---
src/lib/elm_colorselector.c | 4 +---
src/lib/elm_conform.c | 4 +---
src/lib/elm_datetime.c | 4 +---
src/lib/elm_dayselector.c | 4 +---
src/lib/elm_diskselector.c | 4 +---
src/lib/elm_entry.c | 4 +---
src/lib/elm_flip.c | 3 +--
src/lib/elm_flipselector.c | 4 +---
src/lib/elm_frame.c | 4 +---
src/lib/elm_gengrid.c | 4 +---
src/lib/elm_genlist.c | 4 +---
src/lib/elm_gesture_layer.c | 3 +--
src/lib/elm_glview.c | 3 +--
src/lib/elm_grid.c | 3 +--
src/lib/elm_hover.c | 4 +---
src/lib/elm_icon.c | 3 +--
src/lib/elm_image.c | 3 +--
src/lib/elm_index.c | 3 +--
src/lib/elm_inwin.c | 3 +--
src/lib/elm_label.c | 4 +---
src/lib/elm_layout.c | 13 ++-----------
src/lib/elm_list.c | 4 +---
src/lib/elm_map.c | 4 +---
src/lib/elm_mapbuf.c | 3 +--
src/lib/elm_menu.c | 3 +--
src/lib/elm_notify.c | 3 +--
src/lib/elm_panel.c | 3 +--
src/lib/elm_panes.c | 4 +---
src/lib/elm_photocam.c | 4 +---
src/lib/elm_plug.c | 4 +---
src/lib/elm_prefs.c | 5 +----
src/lib/elm_progressbar.c | 4 +---
src/lib/elm_radio.c | 4 +---
src/lib/elm_route.c | 3 +--
src/lib/elm_scroller.c | 4 +---
src/lib/elm_segment_control.c | 4 +---
src/lib/elm_separator.c | 4 +---
src/lib/elm_slider.c | 4 +---
src/lib/elm_slideshow.c | 4 +---
src/lib/elm_spinner.c | 4 +---
src/lib/elm_table.c | 3 +--
src/lib/elm_thumb.c | 3 +--
src/lib/elm_toolbar.c | 4 +---
src/lib/elm_video.c | 4 +---
src/lib/elm_web.c | 3 +--
src/lib/elm_web2.c | 3 +--
src/lib/elm_widget.c | 9 +++++++--
src/lib/elm_win.c | 3 +--
66 files changed, 73 insertions(+), 183 deletions(-)
diff --git a/src/lib/elc_ctxpopup.c b/src/lib/elc_ctxpopup.c
index d67a894..2662a01 100644
--- a/src/lib/elc_ctxpopup.c
+++ b/src/lib/elc_ctxpopup.c
@@ -1153,8 +1153,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elc_fileselector.c b/src/lib/elc_fileselector.c
index 68baa04..f1fecf9 100644
--- a/src/lib/elc_fileselector.c
+++ b/src/lib/elc_fileselector.c
@@ -914,9 +914,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elc_fileselector_button.c
b/src/lib/elc_fileselector_button.c
index de244e9..549d75a 100644
--- a/src/lib/elc_fileselector_button.c
+++ b/src/lib/elc_fileselector_button.c
@@ -218,9 +218,7 @@ _constructor(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elc_fileselector_entry.c b/src/lib/elc_fileselector_entry.c
index db06356..b3a57f2 100644
--- a/src/lib/elc_fileselector_entry.c
+++ b/src/lib/elc_fileselector_entry.c
@@ -417,8 +417,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elc_hoversel.c b/src/lib/elc_hoversel.c
index 3c5caa4..bc9faa4 100644
--- a/src/lib/elc_hoversel.c
+++ b/src/lib/elc_hoversel.c
@@ -264,9 +264,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elc_multibuttonentry.c b/src/lib/elc_multibuttonentry.c
index 81763e3..82d672f 100644
--- a/src/lib/elc_multibuttonentry.c
+++ b/src/lib/elc_multibuttonentry.c
@@ -1674,8 +1674,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Evas_Object *
diff --git a/src/lib/elc_naviframe.c b/src/lib/elc_naviframe.c
index e2410f4..1943780 100644
--- a/src/lib/elc_naviframe.c
+++ b/src/lib/elc_naviframe.c
@@ -1283,8 +1283,7 @@ _elm_naviframe_smart_add(Eo *obj, void *_pd, va_list
*list EINA_UNUSED)
_on_obj_size_hints_changed, obj);
elm_widget_can_focus_set(obj, EINA_TRUE);
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
static Eina_Bool
diff --git a/src/lib/elc_player.c b/src/lib/elc_player.c
index 2e6257a..7fe372e 100644
--- a/src/lib/elc_player.c
+++ b/src/lib/elc_player.c
@@ -580,9 +580,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
#else
eo_error_set(obj);
#endif
diff --git a/src/lib/elc_popup.c b/src/lib/elc_popup.c
index 045b9ac..74b3ff3 100644
--- a/src/lib/elc_popup.c
+++ b/src/lib/elc_popup.c
@@ -1453,8 +1453,7 @@ _elm_popup_smart_add(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
(wd->resize_obj, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
evas_object_size_hint_align_set
(wd->resize_obj, EVAS_HINT_FILL, EVAS_HINT_FILL);
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
if (!elm_layout_theme_set(obj, "popup", "base", elm_widget_style_get(obj)))
CRITICAL("Failed to set layout!");
diff --git a/src/lib/elm_access.c b/src/lib/elm_access.c
index 5c170fa..a672bee 100644
--- a/src/lib/elm_access.c
+++ b/src/lib/elm_access.c
@@ -918,9 +918,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Evas_Object *
diff --git a/src/lib/elm_actionslider.c b/src/lib/elm_actionslider.c
index 3aa218a..ee7a9bf 100644
--- a/src/lib/elm_actionslider.c
+++ b/src/lib/elm_actionslider.c
@@ -441,9 +441,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_bg.c b/src/lib/elm_bg.c
index 7accd31..6260224 100644
--- a/src/lib/elm_bg.c
+++ b/src/lib/elm_bg.c
@@ -103,10 +103,7 @@ _elm_bg_smart_add(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
eo_do_super(obj, MY_CLASS, evas_obj_smart_add());
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
-
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
elm_widget_can_focus_set(obj, EINA_FALSE);
priv->option = ELM_BG_OPTION_SCALE;
diff --git a/src/lib/elm_box.c b/src/lib/elm_box.c
index 61efce4..9e8dfc7 100644
--- a/src/lib/elm_box.c
+++ b/src/lib/elm_box.c
@@ -462,8 +462,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_bubble.c b/src/lib/elm_bubble.c
index 7a651da..3af00fb 100644
--- a/src/lib/elm_bubble.c
+++ b/src/lib/elm_bubble.c
@@ -250,9 +250,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_button.c b/src/lib/elm_button.c
index ec30cba..869b110 100644
--- a/src/lib/elm_button.c
+++ b/src/lib/elm_button.c
@@ -294,9 +294,7 @@ _elm_button_smart_add(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
eo_do_super(obj, MY_CLASS, evas_obj_smart_add());
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
edje_object_signal_callback_add
(wd->resize_obj, "elm,action,click", "",
diff --git a/src/lib/elm_calendar.c b/src/lib/elm_calendar.c
index de9a8ad..b7d4287 100644
--- a/src/lib/elm_calendar.c
+++ b/src/lib/elm_calendar.c
@@ -1181,9 +1181,7 @@ _constructor(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_check.c b/src/lib/elm_check.c
index 2558c4e..9f07db3 100644
--- a/src/lib/elm_check.c
+++ b/src/lib/elm_check.c
@@ -345,9 +345,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_clock.c b/src/lib/elm_clock.c
index 37a50f3..9b7a4ba 100644
--- a/src/lib/elm_clock.c
+++ b/src/lib/elm_clock.c
@@ -830,9 +830,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
static void
diff --git a/src/lib/elm_colorselector.c b/src/lib/elm_colorselector.c
index 02c809a..9321ca3 100644
--- a/src/lib/elm_colorselector.c
+++ b/src/lib/elm_colorselector.c
@@ -1772,9 +1772,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_conform.c b/src/lib/elm_conform.c
index 76fe7e4..aa5ef14 100644
--- a/src/lib/elm_conform.c
+++ b/src/lib/elm_conform.c
@@ -985,9 +985,7 @@ _constructor(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
Elm_Conformant_Smart_Data *sd = _pd;
diff --git a/src/lib/elm_datetime.c b/src/lib/elm_datetime.c
index 12724d2..663220e 100644
--- a/src/lib/elm_datetime.c
+++ b/src/lib/elm_datetime.c
@@ -850,9 +850,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI const char *
diff --git a/src/lib/elm_dayselector.c b/src/lib/elm_dayselector.c
index ded2350..5d61b4d 100644
--- a/src/lib/elm_dayselector.c
+++ b/src/lib/elm_dayselector.c
@@ -473,9 +473,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_diskselector.c b/src/lib/elm_diskselector.c
index 69aef04..bf52f0c 100644
--- a/src/lib/elm_diskselector.c
+++ b/src/lib/elm_diskselector.c
@@ -1468,9 +1468,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Eina_Bool
diff --git a/src/lib/elm_entry.c b/src/lib/elm_entry.c
index 253a3fc..aa16c4d 100644
--- a/src/lib/elm_entry.c
+++ b/src/lib/elm_entry.c
@@ -3094,9 +3094,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_flip.c b/src/lib/elm_flip.c
index 223ad51..adf3024 100644
--- a/src/lib/elm_flip.c
+++ b/src/lib/elm_flip.c
@@ -1871,8 +1871,7 @@ _constructor(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Eina_Bool
diff --git a/src/lib/elm_flipselector.c b/src/lib/elm_flipselector.c
index daecc9f..e23cc23 100644
--- a/src/lib/elm_flipselector.c
+++ b/src/lib/elm_flipselector.c
@@ -611,9 +611,7 @@ _constructor(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_frame.c b/src/lib/elm_frame.c
index 4ad00eb..9d0875d 100644
--- a/src/lib/elm_frame.c
+++ b/src/lib/elm_frame.c
@@ -217,9 +217,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_gengrid.c b/src/lib/elm_gengrid.c
index 57b8d78..dd1d789 100644
--- a/src/lib/elm_gengrid.c
+++ b/src/lib/elm_gengrid.c
@@ -2534,9 +2534,7 @@ _constructor(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_genlist.c b/src/lib/elm_genlist.c
index 47c05db..d9317c3 100644
--- a/src/lib/elm_genlist.c
+++ b/src/lib/elm_genlist.c
@@ -4915,9 +4915,7 @@ _constructor(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
static void
diff --git a/src/lib/elm_gesture_layer.c b/src/lib/elm_gesture_layer.c
index 2349739..c19e498 100644
--- a/src/lib/elm_gesture_layer.c
+++ b/src/lib/elm_gesture_layer.c
@@ -3659,8 +3659,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
eo_do_super(obj, MY_CLASS, eo_constructor());
eo_do(obj, evas_obj_type_set(MY_CLASS_NAME));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Eina_Bool
diff --git a/src/lib/elm_glview.c b/src/lib/elm_glview.c
index 29ed414..e181b78 100644
--- a/src/lib/elm_glview.c
+++ b/src/lib/elm_glview.c
@@ -291,8 +291,7 @@ _constructor(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
return;
}
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Evas_GL_API *
diff --git a/src/lib/elm_grid.c b/src/lib/elm_grid.c
index d456305..e1a22b3 100644
--- a/src/lib/elm_grid.c
+++ b/src/lib/elm_grid.c
@@ -176,8 +176,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do_super(obj, MY_CLASS, eo_constructor());
eo_do(obj, evas_obj_type_set(MY_CLASS_NAME));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_hover.c b/src/lib/elm_hover.c
index 92e058d..5f63480 100644
--- a/src/lib/elm_hover.c
+++ b/src/lib/elm_hover.c
@@ -648,9 +648,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_icon.c b/src/lib/elm_icon.c
index 2075ce3..ef04191 100644
--- a/src/lib/elm_icon.c
+++ b/src/lib/elm_icon.c
@@ -759,8 +759,7 @@ _constructor(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Eina_Bool
diff --git a/src/lib/elm_image.c b/src/lib/elm_image.c
index 4cf3bb8..535e50c 100644
--- a/src/lib/elm_image.c
+++ b/src/lib/elm_image.c
@@ -1103,8 +1103,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Eina_Bool
diff --git a/src/lib/elm_index.c b/src/lib/elm_index.c
index dec1694..92c7020 100644
--- a/src/lib/elm_index.c
+++ b/src/lib/elm_index.c
@@ -1117,8 +1117,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_inwin.c b/src/lib/elm_inwin.c
index 5561697..8846878 100644
--- a/src/lib/elm_inwin.c
+++ b/src/lib/elm_inwin.c
@@ -120,8 +120,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do_super(obj, MY_CLASS, eo_constructor());
eo_do(obj, evas_obj_type_set(MY_CLASS_NAME));
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(parent, obj);
}
EAPI void
diff --git a/src/lib/elm_label.c b/src/lib/elm_label.c
index 90deac4..2616697 100644
--- a/src/lib/elm_label.c
+++ b/src/lib/elm_label.c
@@ -378,9 +378,7 @@ _elm_label_smart_add(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
eo_do_super(obj, MY_CLASS, evas_obj_smart_add());
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
priv->linewrap = ELM_WRAP_NONE;
priv->wrap_w = -1;
diff --git a/src/lib/elm_layout.c b/src/lib/elm_layout.c
index 06a7b6f..4049bd5 100644
--- a/src/lib/elm_layout.c
+++ b/src/lib/elm_layout.c
@@ -797,10 +797,7 @@ _elm_layout_smart_content_set(Eo *obj, void *_pd, va_list
*list)
if (content)
{
if (!elm_widget_sub_object_add(obj, content))
- {
- ERR("could not add %p as sub object of %p", content, obj);
- return;
- }
+ return;
if (!edje_object_part_swallow
(wd->resize_obj, part, content))
@@ -914,7 +911,6 @@ _elm_layout_smart_box_append(Eo *obj, void *_pd, va_list
*list)
if (!elm_widget_sub_object_add(obj, child))
{
- ERR("could not add %p as sub object of %p", child, obj);
edje_object_part_box_remove
(wd->resize_obj, part, child);
return;
@@ -955,7 +951,6 @@ _elm_layout_smart_box_prepend(Eo *obj, void *_pd, va_list
*list)
if (!elm_widget_sub_object_add(obj, child))
{
- ERR("could not add %p as sub object of %p", child, obj);
edje_object_part_box_remove
(wd->resize_obj, part, child);
return;
@@ -1008,7 +1003,6 @@ _elm_layout_smart_box_insert_before(Eo *obj, void *_pd,
va_list *list)
if (!elm_widget_sub_object_add(obj, child))
{
- ERR("could not add %p as sub object of %p", child, obj);
edje_object_part_box_remove
(wd->resize_obj, part, child);
return;
@@ -1055,7 +1049,6 @@ _elm_layout_smart_box_insert_at(Eo *obj, void *_pd,
va_list *list)
if (!elm_widget_sub_object_add(obj, child))
{
- ERR("could not add %p as sub object of %p", child, obj);
edje_object_part_box_remove
(wd->resize_obj, part, child);
return;
@@ -1212,7 +1205,6 @@ _elm_layout_smart_table_pack(Eo *obj, void *_pd, va_list
*list)
if (!elm_widget_sub_object_add(obj, child))
{
- ERR("could not add %p as sub object of %p", child, obj);
edje_object_part_table_unpack
(wd->resize_obj, part, child);
return;
@@ -2157,8 +2149,7 @@ _constructor(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
static void
diff --git a/src/lib/elm_list.c b/src/lib/elm_list.c
index 382db09..f9bfcdd 100644
--- a/src/lib/elm_list.c
+++ b/src/lib/elm_list.c
@@ -1755,9 +1755,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_map.c b/src/lib/elm_map.c
index cb7121a..99de4b9 100644
--- a/src/lib/elm_map.c
+++ b/src/lib/elm_map.c
@@ -4199,9 +4199,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
#else
eo_error_set(obj);
#endif
diff --git a/src/lib/elm_mapbuf.c b/src/lib/elm_mapbuf.c
index 7f2598a..3a6157d 100644
--- a/src/lib/elm_mapbuf.c
+++ b/src/lib/elm_mapbuf.c
@@ -266,8 +266,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_menu.c b/src/lib/elm_menu.c
index 2dcccc4..c42e3d0 100644
--- a/src/lib/elm_menu.c
+++ b/src/lib/elm_menu.c
@@ -678,8 +678,7 @@ _constructor(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
elm_menu_parent_set(obj, eo_parent_get(obj));
elm_hover_target_set(sd->hv, sd->location);
diff --git a/src/lib/elm_notify.c b/src/lib/elm_notify.c
index 365fd62..ccc036a 100644
--- a/src/lib/elm_notify.c
+++ b/src/lib/elm_notify.c
@@ -486,8 +486,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_panel.c b/src/lib/elm_panel.c
index 10760e6..dd12461 100644
--- a/src/lib/elm_panel.c
+++ b/src/lib/elm_panel.c
@@ -414,8 +414,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_panes.c b/src/lib/elm_panes.c
index bb91377..ee9aabc 100644
--- a/src/lib/elm_panes.c
+++ b/src/lib/elm_panes.c
@@ -228,9 +228,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EINA_DEPRECATED EAPI void
diff --git a/src/lib/elm_photocam.c b/src/lib/elm_photocam.c
index 71c386c..e59b66a 100644
--- a/src/lib/elm_photocam.c
+++ b/src/lib/elm_photocam.c
@@ -1443,9 +1443,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Evas_Load_Error
diff --git a/src/lib/elm_plug.c b/src/lib/elm_plug.c
index ba259fd..d48a9b9 100644
--- a/src/lib/elm_plug.c
+++ b/src/lib/elm_plug.c
@@ -124,9 +124,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Evas_Object *
diff --git a/src/lib/elm_prefs.c b/src/lib/elm_prefs.c
index cb3983e..f235ba2 100644
--- a/src/lib/elm_prefs.c
+++ b/src/lib/elm_prefs.c
@@ -527,10 +527,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_smart_callbacks_descriptions_set(_elm_prefs_smart_callbacks,
NULL));
- Evas_Object *parent = eo_parent_get(obj);
-
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
static Eina_Bool
diff --git a/src/lib/elm_progressbar.c b/src/lib/elm_progressbar.c
index 411301a..3cd0bee 100644
--- a/src/lib/elm_progressbar.c
+++ b/src/lib/elm_progressbar.c
@@ -312,9 +312,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_radio.c b/src/lib/elm_radio.c
index cf507e3..7ebd092 100644
--- a/src/lib/elm_radio.c
+++ b/src/lib/elm_radio.c
@@ -334,9 +334,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_route.c b/src/lib/elm_route.c
index c7354e9..b6fe1bf 100644
--- a/src/lib/elm_route.c
+++ b/src/lib/elm_route.c
@@ -189,8 +189,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do_super(obj, MY_CLASS, eo_constructor());
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
#ifdef ELM_EMAP
diff --git a/src/lib/elm_scroller.c b/src/lib/elm_scroller.c
index bfac382..39a581a 100644
--- a/src/lib/elm_scroller.c
+++ b/src/lib/elm_scroller.c
@@ -841,9 +841,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
/* deprecated */
diff --git a/src/lib/elm_segment_control.c b/src/lib/elm_segment_control.c
index ecef2a5..c10a953 100644
--- a/src/lib/elm_segment_control.c
+++ b/src/lib/elm_segment_control.c
@@ -699,9 +699,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Elm_Object_Item *
diff --git a/src/lib/elm_separator.c b/src/lib/elm_separator.c
index 3d28e39..0e1e1a2 100644
--- a/src/lib/elm_separator.c
+++ b/src/lib/elm_separator.c
@@ -73,9 +73,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_slider.c b/src/lib/elm_slider.c
index 2878416..cc8d81e 100644
--- a/src/lib/elm_slider.c
+++ b/src/lib/elm_slider.c
@@ -872,9 +872,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_slideshow.c b/src/lib/elm_slideshow.c
index 58c489c..fcc07a5 100644
--- a/src/lib/elm_slideshow.c
+++ b/src/lib/elm_slideshow.c
@@ -377,9 +377,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Elm_Object_Item *
diff --git a/src/lib/elm_spinner.c b/src/lib/elm_spinner.c
index db31af2..f0a97d5 100644
--- a/src/lib/elm_spinner.c
+++ b/src/lib/elm_spinner.c
@@ -805,9 +805,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_table.c b/src/lib/elm_table.c
index 9975fa8..e159647 100644
--- a/src/lib/elm_table.c
+++ b/src/lib/elm_table.c
@@ -236,8 +236,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do_super(obj, MY_CLASS, eo_constructor());
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_thumb.c b/src/lib/elm_thumb.c
index c869e12..7cf9b07 100644
--- a/src/lib/elm_thumb.c
+++ b/src/lib/elm_thumb.c
@@ -636,8 +636,7 @@ _constructor(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
Elm_Thumb_Smart_Data *sd = _pd;
sd->obj = obj;
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_toolbar.c b/src/lib/elm_toolbar.c
index 3d3d178..36cc59d 100644
--- a/src/lib/elm_toolbar.c
+++ b/src/lib/elm_toolbar.c
@@ -2548,9 +2548,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list
*list EINA_UNUSED)
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_smart_callbacks, NULL));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI void
diff --git a/src/lib/elm_video.c b/src/lib/elm_video.c
index ab6c40b..5e1a7b0 100644
--- a/src/lib/elm_video.c
+++ b/src/lib/elm_video.c
@@ -308,9 +308,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME));
- Evas_Object *parent = eo_parent_get(obj);
- if (!elm_widget_sub_object_add(parent, obj))
- ERR("could not add %p as sub object of %p", obj, parent);
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
#else
eo_error_set(obj);
#endif
diff --git a/src/lib/elm_web.c b/src/lib/elm_web.c
index 1365232..5f52c4d 100644
--- a/src/lib/elm_web.c
+++ b/src/lib/elm_web.c
@@ -1223,8 +1223,7 @@ _constructor(Eo *obj, void *_pd, va_list *list
EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_elm_web_smart_callbacks,
NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Evas_Object *
diff --git a/src/lib/elm_web2.c b/src/lib/elm_web2.c
index 8c207cc..3f10601 100644
--- a/src/lib/elm_web2.c
+++ b/src/lib/elm_web2.c
@@ -143,8 +143,7 @@ _constructor(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
eo_do(obj,
evas_obj_type_set(MY_CLASS_NAME),
evas_obj_smart_callbacks_descriptions_set(_elm_web_smart_callbacks,
NULL));
- if (!elm_widget_sub_object_add(eo_parent_get(obj), obj))
- ERR("could not add %p as sub object of %p", obj, eo_parent_get(obj));
+ elm_widget_sub_object_add(eo_parent_get(obj), obj);
}
EAPI Evas_Object *
diff --git a/src/lib/elm_widget.c b/src/lib/elm_widget.c
index 7a62a8a..13b5ff2 100644
--- a/src/lib/elm_widget.c
+++ b/src/lib/elm_widget.c
@@ -934,11 +934,16 @@ elm_widget_sub_object_add(Evas_Object *obj,
ELM_WIDGET_CHECK(obj) EINA_FALSE;
EINA_SAFETY_ON_TRUE_RETURN_VAL(obj == sobj, EINA_FALSE);
- if (!sobj) return EINA_FALSE;
+ if (!sobj) goto err;
Eina_Bool ret = EINA_FALSE;
eo_do(obj, elm_wdg_sub_object_add(sobj, &ret));
- return ret;
+
+ if (ret) return EINA_TRUE;
+
+err:
+ ERR("could not add %p as sub object of %p", obj, sobj);
+ return EINA_FALSE;
}
static void
diff --git a/src/lib/elm_win.c b/src/lib/elm_win.c
index e7fe5d7..eeef06e 100644
--- a/src/lib/elm_win.c
+++ b/src/lib/elm_win.c
@@ -3033,8 +3033,7 @@ _resize_object_add(Eo *obj, void *_pd, va_list *list)
Elm_Win_Smart_Data *sd = _pd;
- if (!elm_widget_sub_object_add(obj, subobj))
- ERR("could not add %p as sub object of %p", subobj, obj);
+ elm_widget_sub_object_add(obj, subobj);
if (!evas_object_box_append(sd->box, subobj))
ERR("could not append %p to box", subobj);
--
------------------------------------------------------------------------------
Minimize network downtime and maximize team effectiveness.
Reduce network management and security costs.Learn how to hire
the most talented Cisco Certified professionals. Visit the
Employer Resources Portal
http://www.cisco.com/web/learning/employer_resources/index.html