1
0
Fork 0

animator: fix crash when setting keys on running animator

When inserting or modifying keys of a running animator the internal
iterators per property could go out of sync. Reinitializing the
iterators if the timeline is running avoids this.
This commit is contained in:
Øyvind Kolås 2010-05-05 13:34:06 +01:00
parent 0ff02d18d2
commit d45395d78b

View file

@ -1259,6 +1259,10 @@ clutter_animator_set_key_internal (ClutterAnimator *animator,
priv->score = g_list_insert_sorted (priv->score, key,
sort_actor_prop_progress_func);
/* if the animator is already running reinitialize internal iterators */
if (clutter_timeline_is_playing (priv->timeline))
animation_animator_started (priv->timeline, animator);
}
/**