Let the world know what's playing.

git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@323 ed5b42cb-e716-0410-a449-f6a68f950b19
This commit is contained in:
Par Winzell
2007-10-31 22:23:15 +00:00
parent b0a9cb847e
commit 9d8d509fc7
3 changed files with 13 additions and 1 deletions
-1
View File
@@ -63,6 +63,5 @@ public class AlphaFade extends AnimationImpl
protected var _to :Number;
protected var _duration :Number;
protected var _done :Function;
}
}
@@ -33,6 +33,11 @@ public class AnimationImpl implements Animation
AnimationManager.stop(this);
}
public function isPlaying () :Boolean
{
return AnimationManager.isPlaying(this);
}
public function updateAnimation (elapsed :Number) :void
{
// please implement!
@@ -82,6 +82,14 @@ public class AnimationManager
}
}
/**
* Test to see if the specified animation has been started and not stopped.
*/
public static function isPlaying (anim :Animation) :Boolean
{
return _anims.indexOf(anim) >= 0;
}
/**
* Track a DisplayObject that is also an Animation- it will
* automatically be started when added to the stage and