From 2fb102fd7b115a9002d7e960ac043249f130b06d Mon Sep 17 00:00:00 2001 From: Dave Hoover Date: Thu, 18 Feb 2010 06:42:58 +0000 Subject: [PATCH] Convenience wrappers. I've been doing a whole bunch of AnimationSequences and 99% of the time it's been one of those two stupid simple cases, so make them stupid simple to do & stop cluttering up my code with extra args to linewrap. git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@888 ed5b42cb-e716-0410-a449-f6a68f950b19 --- .../media/animation/AnimationSequencer.java | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/java/com/threerings/media/animation/AnimationSequencer.java b/src/java/com/threerings/media/animation/AnimationSequencer.java index 127a4138..c214277b 100644 --- a/src/java/com/threerings/media/animation/AnimationSequencer.java +++ b/src/java/com/threerings/media/animation/AnimationSequencer.java @@ -96,6 +96,22 @@ public class AnimationSequencer extends Animation _queued.add(arec); } + /** + * Convenience wrapper to add an animation to run at the same time as the previous one. + */ + public void addAnimation (Animation anim) + { + addAnimation(anim, 0, null); + } + + /** + * Convenience wrapper to add an animation to run after the previous one. + */ + public void appendAnimation (Animation anim) + { + addAnimation(anim, -1, null); + } + /** * Clears out the animations being managed by this sequencer. */