2007-09-25 Ross Burton <ross@openedhand.com>

Merge from stable.
	
	* clutter/clutter-group.c:
	Optimise sort_z_order.
This commit is contained in:
Ross Burton 2007-09-25 13:22:24 +00:00
parent c7ff2b7651
commit bc7b1b3a16
2 changed files with 13 additions and 4 deletions

View File

@ -1,3 +1,10 @@
2007-09-25 Ross Burton <ross@openedhand.com>
Merge from stable.
* clutter/clutter-group.c:
Optimise sort_z_order.
2007-09-17 Emmanuele Bassi <ebassi@openedhand.com>
Merge from stable

View File

@ -404,13 +404,15 @@ static gint
sort_z_order (gconstpointer a,
gconstpointer b)
{
ClutterActor *actor_a = CLUTTER_ACTOR (a);
ClutterActor *actor_b = CLUTTER_ACTOR (b);
int depth_a, depth_b;
if (clutter_actor_get_depth (actor_a) == clutter_actor_get_depth (actor_b))
depth_a = clutter_actor_get_depth (a);
depth_b = clutter_actor_get_depth (b);
if (depth_a == depth_b)
return 0;
if (clutter_actor_get_depth (actor_a) > clutter_actor_get_depth (actor_b))
if (depth_a > depth_b)
return 1;
return -1;