mirror of
https://github.com/brl/mutter.git
synced 2024-12-25 12:32:05 +00:00
interactive/test-actors: Constraint the hands group
Use constraints to align and size the ClutterGroup containing the spinning hands so that resizing the stage doesn't look like arse.
This commit is contained in:
parent
8402e41332
commit
df107fc5ba
@ -216,6 +216,9 @@ test_actors_main (int argc, char *argv[])
|
||||
oh->group = clutter_group_new();
|
||||
clutter_actor_set_name (oh->group, "Group");
|
||||
g_signal_connect (oh->group, "destroy", G_CALLBACK (on_group_destroy), oh);
|
||||
clutter_actor_add_constraint (oh->group, clutter_align_constraint_new (stage, CLUTTER_ALIGN_X_AXIS, 0.5));
|
||||
clutter_actor_add_constraint (oh->group, clutter_align_constraint_new (stage, CLUTTER_ALIGN_Y_AXIS, 0.5));
|
||||
clutter_actor_add_constraint (oh->group, clutter_bind_constraint_new (stage, CLUTTER_BIND_SIZE, 0.0f));
|
||||
|
||||
oh->hand = g_new (ClutterActor*, n_hands);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user