[clutter/master-next: 31/51] actor: Remove automatic transition init from add_transition()
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [clutter/master-next: 31/51] actor: Remove automatic transition init from add_transition()
- Date: Wed, 25 Apr 2012 16:40:17 +0000 (UTC)
commit 63daa9b0ab0790fc86eff0ca153fb59f6e933bfc
Author: Emmanuele Bassi <ebassi linux intel com>
Date: Thu Apr 19 16:35:39 2012 +0100
actor: Remove automatic transition init from add_transition()
Adding an explicit transition overrides any consideration of the easing
state of an actor.
clutter/clutter-actor.c | 11 -----------
tests/interactive/test-keyframe-transition.c | 7 +------
2 files changed, 1 insertions(+), 17 deletions(-)
---
diff --git a/clutter/clutter-actor.c b/clutter/clutter-actor.c
index 35e8167..2acde19 100644
--- a/clutter/clutter-actor.c
+++ b/clutter/clutter-actor.c
@@ -17236,10 +17236,6 @@ out:
* The @name string is a per-actor unique identifier of the @transition: only
* one #ClutterTransition can be associated to the specified @name.
*
- * The @transition will be given the easing duration, mode, and delay
- * associated to the actor's current easing state; it is possible to modify
- * these values after calling clutter_actor_add_transition().
- *
* The @transition will be started once added.
*
* This function will take a reference on the @transition.
@@ -17282,13 +17278,6 @@ clutter_actor_add_transition (ClutterActor *self,
timeline = CLUTTER_TIMELINE (transition);
- if (info->cur_state != NULL)
- {
- clutter_timeline_set_delay (timeline, info->cur_state->easing_delay);
- clutter_timeline_set_duration (timeline, info->cur_state->easing_duration);
- clutter_timeline_set_progress_mode (timeline, info->cur_state->easing_mode);
- }
-
clos = g_slice_new (TransitionClosure);
clos->actor = self;
clos->transition = g_object_ref (transition);
diff --git a/tests/interactive/test-keyframe-transition.c b/tests/interactive/test-keyframe-transition.c
index 07b628d..801af44 100644
--- a/tests/interactive/test-keyframe-transition.c
+++ b/tests/interactive/test-keyframe-transition.c
@@ -50,11 +50,8 @@ test_keyframe_transition_main (int argc, char *argv[])
clutter_actor_set_position (rect, PADDING, cur_y);
clutter_actor_add_child (stage, rect);
- clutter_actor_save_easing_state (rect);
- clutter_actor_set_easing_duration (rect, 2000);
- clutter_actor_set_easing_mode (rect, CLUTTER_LINEAR);
-
group = clutter_transition_group_new ();
+ clutter_timeline_set_duration (CLUTTER_TIMELINE (group), 2000);
clutter_timeline_set_repeat_count (CLUTTER_TIMELINE (group), 1);
clutter_timeline_set_auto_reverse (CLUTTER_TIMELINE (group), TRUE);
@@ -80,8 +77,6 @@ test_keyframe_transition_main (int argc, char *argv[])
clutter_actor_add_transition (rect, "rectAnimation", group);
g_object_unref (group);
-
- clutter_actor_restore_easing_state (rect);
}
clutter_actor_show (stage);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]