"Features"
elm_object_icon_s/get() should be implemented for most widgets to reduce api
+
+callbacks add/del
+ pager, panes
static const char *widtype = NULL;
+static void _del_pre_hook(Evas_Object *obj);
static void _del_hook(Evas_Object *obj);
static void _theme_hook(Evas_Object *obj);
static void _disable_hook(Evas_Object *obj);
Evas *e,
Evas_Object *obj,
void *event_info);
+static void _button_clicked(void *data,
+ Evas_Object *obj,
+ void *event_info);
static void _on_focus_hook(void *data,
Evas_Object *obj);
static void _selection_done(void *data,
};
static void
+_del_pre_hook(Evas_Object *obj)
+{
+ Widget_Data *wd = elm_widget_data_get(obj);
+ if (!wd) return;
+ evas_object_event_callback_del_full(wd->btn, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
+ evas_object_smart_callback_del(wd->btn, "clicked", _button_clicked);
+}
+
+static void
_del_hook(Evas_Object *obj)
{
Evas_Object *win;
elm_widget_sub_object_add(parent, obj);
elm_widget_on_focus_hook_set(obj, _on_focus_hook, NULL);
elm_widget_data_set(obj, wd);
+ elm_widget_del_pre_hook_set(obj, _del_pre_hook);
elm_widget_del_hook_set(obj, _del_hook);
elm_widget_theme_hook_set(obj, _theme_hook);
elm_widget_disable_hook_set(obj, _disable_hook);
SIG_FWD(UNPRESSED)
#undef SIG_FWD
+static void _del_pre_hook(Evas_Object *obj);
+static void _changed_size_hints(void *data, Evas *e, Evas_Object *obj, void *event_info);
static void _mirrored_set(Evas_Object *obj, Eina_Bool rtl);
static void
}
static void
+_del_pre_hook(Evas_Object *obj)
+{
+ Widget_Data *wd = elm_widget_data_get(obj);
+ if (!wd) return;
+ evas_object_event_callback_del_full
+ (wd->button, EVAS_CALLBACK_CHANGED_SIZE_HINTS, _changed_size_hints, obj);
+ evas_object_event_callback_del_full
+ (wd->entry, EVAS_CALLBACK_CHANGED_SIZE_HINTS, _changed_size_hints, obj);
+}
+
+static void
_del_hook(Evas_Object *obj)
{
Widget_Data *wd = elm_widget_data_get(obj);
elm_widget_type_set(obj, "fileselector_entry");
elm_widget_sub_object_add(parent, obj);
elm_widget_data_set(obj, wd);
+ elm_widget_del_pre_hook_set(obj, _del_pre_hook);
elm_widget_del_hook_set(obj, _del_hook);
elm_widget_disable_hook_set(obj, _disable_hook);
elm_widget_focus_next_hook_set(obj, _elm_fileselector_entry_focus_next_hook);
Elm_Hoversel_Item *item;
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return;
+ evas_object_event_callback_del_full(wd->btn, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
elm_hoversel_hover_end(obj);
elm_hoversel_hover_parent_set(obj, NULL);
EINA_LIST_FREE(wd->items, item)
if (!wd->content) return NULL;
content = wd->content;
elm_widget_sub_object_del(obj, content);
+ evas_object_event_callback_del_full(content, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->bbl, content);
wd->content = NULL;
return content;
if (!wd->icon) return NULL;
icon = wd->icon;
elm_widget_sub_object_del(obj, icon);
+ evas_object_event_callback_del_full(icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->bbl, icon);
wd->icon = NULL;
return icon;
if (!wd->icon) return NULL;
Evas_Object *icon = wd->icon;
elm_widget_sub_object_del(obj, wd->icon);
+ evas_object_event_callback_del_full(wd->icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->btn, wd->icon);
wd->icon = NULL;
return icon;
if (!wd->icon) return NULL;
Evas_Object *icon = wd->icon;
elm_widget_sub_object_del(obj, wd->icon);
+ evas_object_event_callback_del_full(wd->icon,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->chk, wd->icon);
wd->icon = NULL;
return icon;
if ((!wd) || (!wd->content)) return NULL;
content = wd->content;
elm_widget_sub_object_del(obj, wd->content);
+ evas_object_event_callback_del_full(wd->content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->base, wd->content);
wd->content = NULL;
return content;
Evas_Object *content = wd->front.content;
evas_object_clip_unset(content);
elm_widget_sub_object_del(obj, content);
+ evas_object_event_callback_del_full(content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
evas_object_smart_member_del(content);
wd->front.content = NULL;
return content;
Evas_Object *content = wd->back.content;
evas_object_clip_unset(content);
elm_widget_sub_object_del(obj, content);
+ evas_object_event_callback_del_full(content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
evas_object_smart_member_del(content);
wd->back.content = NULL;
return content;
if (!wd->content) return NULL;
content = wd->content;
elm_widget_sub_object_del(obj, wd->content);
+ evas_object_event_callback_del_full(wd->content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->frm, wd->content);
wd->content = NULL;
return content;
if (!si->obj) return NULL;
content = si->obj; /* si will die in _sub_del due elm_widget_sub_object_del() */
elm_widget_sub_object_del(obj, content);
+ evas_object_event_callback_del_full(content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, wd);
edje_object_part_unswallow(wd->lay, content);
return content;
}
elm_scroller_content_set(group->sc, group->bx);
- evas_object_event_callback_add(group->sc, EVAS_CALLBACK_RESIZE,
+ evas_object_event_callback_add(group->sc, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
_bubble_sc_hits_changed_cb, group);
}
if (!wd->content) return NULL;
content = wd->content;
elm_widget_sub_object_del(obj, content);
+ evas_object_event_callback_add(content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
evas_object_smart_member_del(content);
evas_object_color_set(wd->clip, 0, 0, 0, 0);
evas_object_clip_unset(content);
if (!wd->content) return NULL;
content = wd->content;
elm_widget_sub_object_del(obj, wd->content);
+ evas_object_event_callback_del_full(wd->content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
+ evas_object_event_callback_del_full(wd->content, EVAS_CALLBACK_RESIZE,
+ _content_resize, obj);
edje_object_part_unswallow(wd->notify, wd->content);
wd->content = NULL;
return content;
if (!wd->icon) return NULL;
Evas_Object *icon = wd->icon;
elm_widget_sub_object_del(obj, wd->icon);
+ evas_object_event_callback_del_full(wd->icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->progressbar, wd->icon);
wd->icon = NULL;
return icon;
if (!wd->icon) return NULL;
Evas_Object *icon = wd->icon;
elm_widget_sub_object_del(obj, wd->icon);
+ evas_object_event_callback_del_full(wd->icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->radio, wd->icon);
wd->icon = NULL;
return icon;
if (!wd->content) return NULL;
content = wd->content;
elm_widget_sub_object_del(obj, wd->content);
+ evas_object_event_callback_del_full(wd->content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(elm_smart_scroller_edje_object_get(wd->scr), wd->content);
wd->content = NULL;
return content;
if (wd->icon)
{
elm_widget_sub_object_del(obj, wd->icon);
+ evas_object_event_callback_del_full(wd->icon,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
ret = wd->icon;
edje_object_part_unswallow(wd->slider, wd->icon);
edje_object_signal_emit(wd->slider, "elm,state,icon,hidden", "elm");
if (wd->end)
{
elm_widget_sub_object_del(obj, wd->end);
+ evas_object_event_callback_del_full(wd->end,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
ret = wd->end;
edje_object_part_unswallow(wd->slider, wd->end);
edje_object_signal_emit(wd->slider, "elm,state,end,hidden", "elm");
};
static const char *widtype = NULL;
+static void _del_pre_hook(Evas_Object *obj);
static void _del_hook(Evas_Object *obj);
static void _mirrored_set(Evas_Object *obj, Eina_Bool rtl);
static void _theme_hook(Evas_Object *obj);
}
static void
+_del_pre_hook(Evas_Object *obj)
+{
+ Widget_Data *wd = elm_widget_data_get(obj);
+ if (!wd) return;
+ evas_object_event_callback_del_full(obj, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
+}
+
+static void
_del_hook(Evas_Object *obj)
{
const char *layout;
elm_widget_sub_object_add(parent, obj);
elm_widget_on_focus_hook_set(obj, _on_focus_hook, NULL);
elm_widget_data_set(obj, wd);
+ elm_widget_del_pre_hook_set(obj, _del_pre_hook);
elm_widget_del_hook_set(obj, _del_hook);
elm_widget_theme_hook_set(obj, _theme_hook);
elm_widget_can_focus_set(obj, EINA_TRUE);
if (!wd->content) return NULL;
Evas_Object *content = wd->content;
elm_widget_sub_object_del(obj, wd->content);
+ evas_object_event_callback_del_full(wd->content,
+ EVAS_CALLBACK_CHANGED_SIZE_HINTS,
+ _changed_size_hints, obj);
edje_object_part_unswallow(wd->frm, wd->content);
wd->content = NULL;
return content;