From: cedric Date: Fri, 6 Jan 2012 10:07:45 +0000 (+0000) Subject: edje: unswallow object that are about to be swallowed. X-Git-Tag: submit/2.0alpha-wayland/20121127.221958~448 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d66354a05a6b9dabd17e69329d2227468e716223;p=profile%2Fivi%2Fedje.git edje: unswallow object that are about to be swallowed. git-svn-id: http://svn.enlightenment.org/svn/e/trunk/edje@66934 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/ChangeLog b/ChangeLog index b042d09..ef648ab 100644 --- a/ChangeLog +++ b/ChangeLog @@ -266,3 +266,7 @@ 2012-01-05 Cedric Bail * Reduce call to stat during edje_object_file_set. + +2012-01-06 Cedric Bail + + * Unswallow object that are about to be swallowed if necessary. diff --git a/NEWS b/NEWS index 40f14cc..c73e711 100644 --- a/NEWS +++ b/NEWS @@ -11,6 +11,7 @@ Improvements: * speedup load time of Edje file. * check existence of group at compile time also. * reduce number of call to stat during edje_object_file_set. + * unswallow object about to be swallowed if necessary. Changes since Edje 1.0.0: ------------------------- diff --git a/src/lib/edje_util.c b/src/lib/edje_util.c index 6e0da6a..0e2aa8f 100644 --- a/src/lib/edje_util.c +++ b/src/lib/edje_util.c @@ -1908,6 +1908,13 @@ edje_object_part_swallow(Evas_Object *obj, const char *part, Evas_Object *obj_sw // XXX: by Sachiel, January 21th 2009, 19:30 UTC _edje_recalc_do(ed); + rp = evas_object_data_get(obj_swallow, "\377 edje.swallowing_part"); + if (rp) + { + /* The object is already swallowed somewhere, unswallow it first */ + edje_object_part_unswallow(rp->edje->obj, obj_swallow); + } + rp = _edje_real_part_recursive_get(ed, (char *)part); if (!rp) return EINA_FALSE; if (rp->part->type != EDJE_PART_TYPE_SWALLOW)