public final class AnimationManager
- Object
- AnimationManager
Animation manager concentrates all of the animations for a given form into a single place that allows us
to manage all mutations to a Form in a way the prevents collisions between mutations. The one type of
animation that isn’t handled by this class is the form level transition, replace transitions are handled by this class.
Methods
Inherited methods
Method details
isAnimating
public boolean isAnimating()Returns true if an animation is currently in progress
Returns
true if an animation is currently in progress
addUIMutation
public void addUIMutation(Container container, ComponentAnimation an)Adds a UIMutation to the animation manager. If there are any current compatible
UIMutations in the animation queue, then this mutation will be added to that mutation.
Otherwise it will appended to the end of the queue to be run sequentially.
Parameters
containerContainer- The container that is being mutated.
anComponentAnimation- The animation
See also
addAnimation
public void addAnimation(ComponentAnimation an)Adds the animation to the end to the animation queue
Parameters
anComponentAnimation- the animation object
addAnimationAndBlock
public void addAnimationAndBlock(ComponentAnimation an)Adds the animation to the end of the animation queue and blocks the current thread until the animation
completes
Parameters
anComponentAnimation- the animation to perform
addAnimation
public void addAnimation(ComponentAnimation an, Runnable callback)Adds the animation to the end to the animation queue
Parameters
anComponentAnimation- the animation object
callbackRunnable- invoked when the animation completes
addUIMutation
public void addUIMutation(Container container, ComponentAnimation an, Runnable callback)Adds a UIMutation to the animation manager. If there are any current compatible
UIMutations in the animation queue, then this mutation will be added to that mutation.
Otherwise it will appended to the end of the queue to be run sequentially.
Parameters
containerContainer- The container that is being mutated.
anComponentAnimation- The animation
callbackRunnable- A callback to be run on completion.
See also
onTitleScrollAnimation
public void onTitleScrollAnimation(ComponentAnimation... cna)Performs a step animation as the user scrolls down/up the page e.g. slowly converting a title UIID from
a big visual representation to a smaller title for easier navigation then back again when scrolling up
Parameters
cnaComponentAnimation...- the animation to bind to the scroll event
onTitleScrollAnimation
public void onTitleScrollAnimation(Container content, ComponentAnimation... cna)Performs a step animation as the user scrolls down/up the page e.g. slowly converting a title UIID from
a big visual representation to a smaller title for easier navigation then back again when scrolling up
Parameters
contentContainer- the scrollable container representing the body
cnaComponentAnimation...- the animation to bind to the scroll event
flushAnimation
public void flushAnimation(Runnable r)Invokes the runnable when all animations have completed
Parameters
rRunnable- the runnable that will be invoked after the animations