From: Enlightenment S. <no-...@en...> - 2012-10-18 19:18:08
|
Log: EPhysics: avoid restacking objects on different layers If the two objects are not in the same layer avoid restacking it. Patch by: Leandro Dorileo <do...@pr...> Author: bdilly Date: 2012-10-18 12:18:00 -0700 (Thu, 18 Oct 2012) New Revision: 78193 Trac: http://trac.enlightenment.org/e/changeset/78193 Modified: trunk/ephysics/src/lib/ephysics_body.cpp Modified: trunk/ephysics/src/lib/ephysics_body.cpp =================================================================== --- trunk/ephysics/src/lib/ephysics_body.cpp 2012-10-18 17:00:28 UTC (rev 78192) +++ trunk/ephysics/src/lib/ephysics_body.cpp 2012-10-18 19:18:00 UTC (rev 78193) @@ -380,6 +380,16 @@ { stacking = (EPhysics_Body_Evas_Stacking *)data; + if (prev_obj && evas_object_layer_get(prev_obj) != + evas_object_layer_get(stacking->evas)) + { + INF("The world %p has bodies with associated evas objects on" + " different layers, skipping the restaking for %p and %p", + world, prev_obj, stacking->evas); + free(stacking); + continue; + } + if (prev_obj) evas_object_stack_above(stacking->evas, prev_obj); |