}
}
+// FIXME : This function might be unnecessary, fix self deletion bug then remove this function.
+static void
+_del_pre_hook(Evas_Object *obj)
+{
+ Widget_Data *wd = elm_widget_data_get(obj);
+ if (!wd) return;
+
+ if (wd->scr)
+ evas_object_event_callback_del_full
+ (wd->scr, EVAS_CALLBACK_CHANGED_SIZE_HINTS, _changed_size_hints,
+ obj);
+ if (wd->box)
+ evas_object_event_callback_del_full
+ (wd->box, EVAS_CALLBACK_CHANGED_SIZE_HINTS, _changed_size_hints,
+ obj);
+}
+
static void
_del_hook(Evas_Object *obj)
{
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);