summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2019-12-09 18:26:31 +0100
committerCedric BAIL <cedric.bail@free.fr>2019-12-11 11:11:05 -0800
commit42f56d0a0a77414db708dbb8b2d08ccc4aacab6f (patch)
tree5d6c9d3c4bdfe74115a2299c65da7570fcc4fb2b
parente097df41642cfb9a9ceb4dca5abcc56f275846f1 (diff)
downloadefl-42f56d0a0a77414db708dbb8b2d08ccc4aacab6f.tar.gz
efl_ui_popup: do not leak the backwall part
freeing it in the destructor is not enough. This has to be done at the invalidator stage, otherwise bindings might have a blocking element on the screen for the time the object is not gargabe collected. Reviewed-by: Jaehyun Cho <jae_hyun.cho@samsung.com> Differential Revision: https://phab.enlightenment.org/D10837
-rw-r--r--src/lib/elementary/efl_ui_popup.c8
-rw-r--r--src/lib/elementary/efl_ui_popup.eo1
2 files changed, 8 insertions, 1 deletions
diff --git a/src/lib/elementary/efl_ui_popup.c b/src/lib/elementary/efl_ui_popup.c
index edf71073aa..da152b4062 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -568,9 +568,15 @@ _efl_ui_popup_efl_object_constructor(Eo *obj, Efl_Ui_Popup_Data *pd)
}
EOLIAN static void
-_efl_ui_popup_efl_object_destructor(Eo *obj, Efl_Ui_Popup_Data *pd)
+_efl_ui_popup_efl_object_invalidate(Eo *obj, Efl_Ui_Popup_Data *pd)
{
ELM_SAFE_DEL(pd->backwall);
+ efl_invalidate(efl_super(obj, MY_CLASS));
+}
+
+EOLIAN static void
+_efl_ui_popup_efl_object_destructor(Eo *obj, Efl_Ui_Popup_Data *pd)
+{
_anchor_detach(obj, pd);
efl_event_callback_del(pd->win_parent, EFL_GFX_ENTITY_EVENT_SIZE_CHANGED, _parent_geom_cb,
diff --git a/src/lib/elementary/efl_ui_popup.eo b/src/lib/elementary/efl_ui_popup.eo
index 322a7f8faf..66d8829f96 100644
--- a/src/lib/elementary/efl_ui_popup.eo
+++ b/src/lib/elementary/efl_ui_popup.eo
@@ -125,6 +125,7 @@ class Efl.Ui.Popup extends Efl.Ui.Layout_Base implements Efl.Content, Efl.Ui.Foc
implements {
Efl.Object.constructor;
Efl.Object.destructor;
+ Efl.Object.invalidate;
Efl.Canvas.Group.group_calculate;
Efl.Gfx.Entity.position { set; }
Efl.Gfx.Entity.size { set;}