aboutsummaryrefslogtreecommitdiffstats
path: root/legacy/evas/src/lib/canvas/evas_layer.c
diff options
context:
space:
mode:
authorCarsten Haitzler <raster@rasterman.com>2012-07-24 04:59:22 +0000
committerCarsten Haitzler <raster@rasterman.com>2012-07-24 04:59:22 +0000
commita3d66cfed3cce0e5dba24d4e33e10495547b98fb (patch)
tree431181ab260c7f665740400d07f6950705530d19 /legacy/evas/src/lib/canvas/evas_layer.c
parentevas: handle proxy with the right context. (diff)
downloadefl-a3d66cfed3cce0e5dba24d4e33e10495547b98fb.tar.gz
fix long standing layer set bug
SVN revision: 74342
Diffstat (limited to 'legacy/evas/src/lib/canvas/evas_layer.c')
-rw-r--r--legacy/evas/src/lib/canvas/evas_layer.c36
1 files changed, 36 insertions, 0 deletions
diff --git a/legacy/evas/src/lib/canvas/evas_layer.c b/legacy/evas/src/lib/canvas/evas_layer.c
index 54e9907105..3c7bc84bf1 100644
--- a/legacy/evas/src/lib/canvas/evas_layer.c
+++ b/legacy/evas/src/lib/canvas/evas_layer.c
@@ -133,6 +133,31 @@ evas_layer_del(Evas_Layer *lay)
e->layers = (Evas_Layer *)eina_inlist_remove(EINA_INLIST_GET(e->layers), EINA_INLIST_GET(lay));
}
+static void
+_evas_object_layer_set_child(Evas_Object *obj, Evas_Object *par, short l)
+{
+ Evas *e;
+
+ if (obj->delete_me) return;
+ if (obj->cur.layer == l) return;
+ e = obj->layer->evas;
+ evas_object_release(obj, 1);
+ obj->cur.layer = l;
+ obj->layer = par->layer;
+ obj->layer->usage++;
+ if (obj->smart.smart)
+ {
+ Eina_Inlist *contained;
+ Evas_Object *member;
+
+ contained = (Eina_Inlist *)evas_object_smart_members_get_direct(obj);
+ EINA_INLIST_FOREACH(contained, member)
+ {
+ _evas_object_layer_set_child(member, obj, l);
+ }
+ }
+}
+
/* public functions */
EAPI void
@@ -176,6 +201,17 @@ evas_object_layer_set(Evas_Object *obj, short l)
obj->layer->evas->last_timestamp,
NULL);
}
+ else
+ {
+ Eina_Inlist *contained;
+ Evas_Object *member;
+
+ contained = (Eina_Inlist *)evas_object_smart_members_get_direct(obj);
+ EINA_INLIST_FOREACH(contained, member)
+ {
+ _evas_object_layer_set_child(member, obj, l);
+ }
+ }
evas_object_inform_call_restack(obj);
}