path: root/src/lib/emotion
diff options
authorJean-Philippe Andre <>2017-09-01 12:30:49 +0900
committerJean-Philippe Andre <>2017-09-13 09:57:05 +0900
commitf5a56789e062a47d0cf5141953c5d8a6071eecdf (patch)
treef6e8b548b29e29db6262a56d27913d3c039d6f11 /src/lib/emotion
parentc5a9e49a9bbcf2b7991b9bfbeb5041a30348bdde (diff)
evas: Add internal API to make smart obj (un)clipped
Introduction to the problem: - Efl.Canvas.Group has a method member_add() to add sub objects. - Efl.Canvas.Group (simple smart object) does NOT actually delete the objects on deletion. But: - Efl.Canvas.Group.Clipped is a direct subclass and WILL delete the sub objects on deletion. Semantically, all smart objects (at least in EO and Elementary) will own and delete sub objects automatically. Some exceptions are: - Edje object (smart clipped) does not delete swallowed objects. Edje object is a "clipped" smart object but it pops out all swallowed children before getting deleted. - Evas box/table/grid also pop out their children before deletion. Those classes are all legacy & internal only. - Elm.Widget will "manually" delete all its sub objects at deletion, as it inherits from Efl.Canvas.Group but basically takes full ownership of the sub objects. Note that member_add shouldn't be used on a widget, the widgets do it themselves. Also, smart clipped objects are much more convenient to use as they will handle some things for you: color, visibility, moving and ownership. So, the API member_add needs to be marked as own(). But right now Efl.Canvas.Group does not own. Thus, here's the plan: - Mark clipped objects as such with an internal API - Merge clipped smart object features directly inside the standard smart object. - Get rid of Efl.Canvas.Group.Clipped entirely and watch all hell break loose. Ref T5301
Diffstat (limited to 'src/lib/emotion')
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lib/emotion/emotion_smart.c b/src/lib/emotion/emotion_smart.c
index 9850c80090..5b2dbf2139 100644
--- a/src/lib/emotion/emotion_smart.c
+++ b/src/lib/emotion/emotion_smart.c
@@ -254,6 +254,7 @@ emotion_object_add(Evas *evas)
254EOLIAN static Eo * 254EOLIAN static Eo *
255_efl_canvas_video_efl_object_constructor(Eo *obj, Efl_Canvas_Video_Data *pd EINA_UNUSED) 255_efl_canvas_video_efl_object_constructor(Eo *obj, Efl_Canvas_Video_Data *pd EINA_UNUSED)
256{ 256{
257 efl_canvas_group_unclipped_set(obj, EINA_TRUE);
257 obj = efl_constructor(efl_super(obj, MY_CLASS)); 258 obj = efl_constructor(efl_super(obj, MY_CLASS));
258 efl_canvas_object_type_set(obj, E_OBJ_NAME); 259 efl_canvas_object_type_set(obj, E_OBJ_NAME);
259 260