public class AnimationManager extends Object
Constructor and Description |
---|
AnimationManager(VirtualSpaceManager vsm)
Creates a new AnimationManager.
|
Modifier and Type | Method and Description |
---|---|
void |
cancelAnimation(Animation anim)
Cancels an animation.
|
AnimationFactory |
getAnimationFactory()
Get the AnimationFactory associated with this AnimationManager.
|
boolean |
pauseAnimation(Animation anim)
Pauses an animation.
|
boolean |
resumeAnimation(Animation anim)
Resumes an animation.
|
void |
setResolution(int resolution)
Sets the timing events period, in milliseconds.
|
void |
start()
Starts this AnimationManager.
|
void |
startAnimation(Animation anim,
boolean force)
Starts an animation.
|
void |
stop()
Stops this AnimationManager
After calling this method, all animations handled by this AnimationManager will stop.
|
void |
stopAnimation(Animation anim)
Stops an animation.
|
public AnimationManager(VirtualSpaceManager vsm)
vsm
- the VirtualSpaceManager in charge of this UI (a singleton: VirtualSpaceManager.INSTANCE).public void start()
public void stop()
IllegalStateException
- if called more than oncepublic AnimationFactory getAnimationFactory()
public void startAnimation(Animation anim, boolean force)
anim
- animation to start (must have been created by
calling createAnimation on the same AnimationManager).force
- if true, any previously started and conflicting
animations will be cancelled. Queued conflicting animations
that did not yet start are cancelled. Two animations conflict if
they target the same subject and animate the same dimension.
Note that the end() action of a cancelled animation will not
be executed.public void stopAnimation(Animation anim)
anim
- animation to stop (must have been created by
calling createAnimation on the same AnimationManager).public void cancelAnimation(Animation anim)
anim
- animation to cancel (must have been created by
calling createAnimation on the same AnimationManager).
Note that the end() action of a cancelled animation will not
be executed.public boolean pauseAnimation(Animation anim)
anim
- animation to pausepublic boolean resumeAnimation(Animation anim)
anim
- animation to resumepublic void setResolution(int resolution)
resolution
- minimal tick interval, in milliseconds.
All animations handled by this AnimationManager share the same
resolution.Copyright © 2000-2002 Xerox Corporation. All Rights Reserved
Copyright © 2003 World Wide Web Consortium. All Rights Reserved
Copyright © 2004-2015 INRIA. All Rights Reserved
Licensed under the GNU LGPL. For full terms see the file COPYING.