forked from enlightenment/efl
* evas_object_smart: Prevent adding a child from another Evas.
**** WARNING **** E is bugged in some place, it does swallow object from another Evas in some place. With this patch, it will abort sooner. If you find situation where it abort, please report. This are nasty bug hidden in our code base. And yes, you will the white box of death, this is expected. SVN revision: 39528
This commit is contained in:
parent
5378f8d4d6
commit
bdc54a6afd
|
@ -184,6 +184,14 @@ evas_object_smart_member_add(Evas_Object *obj, Evas_Object *smart_obj)
|
|||
abort();
|
||||
return;
|
||||
}
|
||||
if (obj->layer && smart_obj->layer
|
||||
&& obj->layer->evas == smart_obj->layer->evas)
|
||||
{
|
||||
printf("EVAS ERROR: Adding object %p from Evas (%p) from another Evas (%p)\n", obj, obj->layer->evas, smart_obj->layer->evas);
|
||||
abort();
|
||||
return;
|
||||
}
|
||||
|
||||
if (obj->smart.parent == smart_obj) return;
|
||||
|
||||
if (obj->smart.parent) evas_object_smart_member_del(obj);
|
||||
|
|
Loading…
Reference in New Issue