From: discomfitor Date: Mon, 3 Oct 2011 04:12:40 +0000 (+0000) Subject: fix bug where window-type tooltip deletion caused infinite recursion X-Git-Tag: BUILDME~6 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=71ac86f6da5f808cdf6c64180eede34307808889;p=framework%2Fuifw%2Felementary.git fix bug where window-type tooltip deletion caused infinite recursion git-svn-id: https://svn.enlightenment.org/svn/e/trunk/elementary@63761 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/lib/elm_win.c b/src/lib/elm_win.c index 027632a..0171432 100644 --- a/src/lib/elm_win.c +++ b/src/lib/elm_win.c @@ -468,6 +468,8 @@ _elm_win_obj_callback_del(void *data, Evas *e, Evas_Object *obj, void *event_inf if (win->deferred_child_eval_job) ecore_job_del(win->deferred_child_eval_job); if (win->shot.info) eina_stringshare_del(win->shot.info); if (win->shot.timer) ecore_timer_del(win->shot.timer); + evas_object_event_callback_del_full(win->win_obj, EVAS_CALLBACK_DEL, + _elm_win_obj_callback_del, win); while (((child = evas_object_bottom_get(win->evas))) && (child != obj)) { diff --git a/src/lib/els_tooltip.c b/src/lib/els_tooltip.c index 036c8a7..5db46e0 100644 --- a/src/lib/els_tooltip.c +++ b/src/lib/els_tooltip.c @@ -67,7 +67,7 @@ _elm_tooltip_content_del_cb(void *data, Evas *e __UNUSED__, Evas_Object *obj __U Elm_Tooltip *tt = data; tt->content = NULL; tt->visible_lock = EINA_FALSE; - _elm_tooltip_hide(tt); + if (tt->tooltip) _elm_tooltip_hide(tt); } static void @@ -153,6 +153,7 @@ _elm_tooltip_content_del(Elm_Tooltip *tt) static void _elm_tooltip_hide(Elm_Tooltip *tt) { + Evas_Object *del; _elm_tooltip_show_timer_stop(tt); _elm_tooltip_hide_anim_stop(tt); _elm_tooltip_reconfigure_job_stop(tt); @@ -169,12 +170,12 @@ _elm_tooltip_hide(Elm_Tooltip *tt) evas_object_event_callback_del_full (tt->eventarea, EVAS_CALLBACK_MOUSE_MOVE, _elm_tooltip_obj_mouse_move_cb, tt); - if (tt->tt_win) evas_object_del(tt->tt_win); - else evas_object_del(tt->tooltip); + del = tt->tt_win ?: tt->tooltip; tt->tt_win = NULL; tt->tt_evas = NULL; tt->tooltip = NULL; + evas_object_del(del); } static void