[group] Use floating point in sort_z_order

This commit is contained in:
Øyvind Kolås 2009-08-25 17:32:42 +01:00
parent d8d344f529
commit f1d5881207

View File

@ -531,12 +531,16 @@ static gint
sort_z_order (gconstpointer a,
gconstpointer b)
{
int depth_a, depth_b;
float depth_a, depth_b;
depth_a = clutter_actor_get_depth (CLUTTER_ACTOR(a));
depth_b = clutter_actor_get_depth (CLUTTER_ACTOR(b));
return (depth_a - depth_b);
if (depth_a < depth_b)
return -1;
if (depth_a > depth_b)
return 1;
return 0;
}
static void