When calling clutter_behaviour_apply() the new actor is prepended
to the list of actors to which a behaviour is applied; this breaks
the rest of methods working on the actors list, e.g.:
# adding actors
apply(actor_0);
apply(actor_1);
apply(actor_2);
# expected: [ actor_0, actor_1, actor_2 ]
[ actor_2, actor_1, actor_0 ] = get_actors();
# expected: actor_2
actor_0 = get_nth_actor(2);
This commit fixes the inconsistency in the returned values.
return;
}
- priv->actors = g_slist_prepend (priv->actors, g_object_ref (actor));
+ priv->actors = g_slist_append (priv->actors, g_object_ref (actor));
g_signal_connect (actor, "destroy",
G_CALLBACK (remove_actor_on_destroy),
behave);
for (l = priv->actors; l != NULL; l = l->next)
retval = g_slist_prepend (retval, l->data);
- return retval;
+ return g_slist_reverse (retval);
}
/**