aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJaehyun Cho <jae_hyun.cho@samsung.com>2019-04-17 15:00:58 +0900
committerJaehyun Cho <jae_hyun.cho@samsung.com>2019-04-17 15:22:54 +0900
commit382520fda450f22f0256b3a57a9b90c4d49e7cca (patch)
tree1116f0915258bcfcff2189ed14fc3d17ea5222be
parentRevert "Revert "elm - fix harmless warning for clean build"" (diff)
downloadefl-382520fda450f22f0256b3a57a9b90c4d49e7cca.tar.gz
efl_ui_pager: fix to delete component objects when pager is deleted
Pager creates Efl.Canvas.Rectangle objects when pager is constructed. Since the parent of these component objects is evas, these component objects are not deleted automatically when pager is deleted. These component objects cause event block after pager is deleted. (e.g. click event is blocked) To resolve this issue, these component objects are deleted manually when pager is deleted.
-rw-r--r--src/lib/elementary/efl_ui_pager.c13
-rw-r--r--src/lib/elementary/efl_ui_pager.eo1
2 files changed, 14 insertions, 0 deletions
diff --git a/src/lib/elementary/efl_ui_pager.c b/src/lib/elementary/efl_ui_pager.c
index 0ce1488d8c..a37d0fd8f6 100644
--- a/src/lib/elementary/efl_ui_pager.c
+++ b/src/lib/elementary/efl_ui_pager.c
@@ -379,6 +379,19 @@ _efl_ui_pager_efl_object_constructor(Eo *obj,
return obj;
}
+EOLIAN static void
+_efl_ui_pager_efl_object_invalidate(Eo *obj,
+ Efl_Ui_Pager_Data *pd)
+{
+ efl_invalidate(efl_super(obj, MY_CLASS));
+
+ /* Since the parent of foreclip and backclip is evas, foreclip and backclip
+ * are not deleted automatically when pager is deleted.
+ * Therefore, foreclip and backclip are deleted manually here. */
+ efl_del(pd->foreclip);
+ efl_del(pd->backclip);
+}
+
EOLIAN static int
_efl_ui_pager_efl_container_content_count(Eo *obj EINA_UNUSED,
Efl_Ui_Pager_Data *pd)
diff --git a/src/lib/elementary/efl_ui_pager.eo b/src/lib/elementary/efl_ui_pager.eo
index 5a3a974adf..646be5accd 100644
--- a/src/lib/elementary/efl_ui_pager.eo
+++ b/src/lib/elementary/efl_ui_pager.eo
@@ -90,6 +90,7 @@ class @beta Efl.Ui.Pager extends Efl.Ui.Layout_Base implements Efl.Pack_Linear
}
implements {
Efl.Object.constructor;
+ Efl.Object.invalidate;
Efl.Container.content_count;
Efl.Pack.pack_clear; //TODO
Efl.Pack.unpack_all; //TODO