Package totalcross.ui.anim
Class FadeAnimation
- java.lang.Object
-
- totalcross.ui.anim.ControlAnimation
-
- totalcross.ui.anim.FadeAnimation
-
- All Implemented Interfaces:
TimerListener
public class FadeAnimation extends ControlAnimation implements TimerListener
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class totalcross.ui.anim.ControlAnimation
ControlAnimation.AnimationFinished
-
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULT_MAX_FADEstatic intmaxFadeChange this will affect all fade animations until you reset it to DEFAULT_MAX_FADE.-
Fields inherited from class totalcross.ui.anim.ControlAnimation
c, delayAfterFinish, frameRate, releaseScreenShot, totalTime, useOffscreen
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidanimate()static FadeAnimationcreate(Control c, boolean fadeIn, ControlAnimation.AnimationFinished animFinish, int totalTime)Creates a path animation, moving the control in a direction.voidstart()-
Methods inherited from class totalcross.ui.anim.ControlAnimation
computeSpeed, stop, then, timerTriggered, with
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface totalcross.ui.event.TimerListener
timerTriggered
-
-
-
-
Field Detail
-
DEFAULT_MAX_FADE
public static int DEFAULT_MAX_FADE
-
maxFade
public static int maxFade
Change this will affect all fade animations until you reset it to DEFAULT_MAX_FADE.- See Also:
Toast
-
-
Method Detail
-
start
public void start()
- Overrides:
startin classControlAnimation
-
animate
protected void animate()
- Specified by:
animatein classControlAnimation
-
create
public static FadeAnimation create(Control c, boolean fadeIn, ControlAnimation.AnimationFinished animFinish, int totalTime)
Creates a path animation, moving the control in a direction.- Parameters:
c- The control to be movedfadeIn- True will make the control appear, false will make it disappear.animFinish- An interface method to be called when the animation finished, or null if none.totalTime- The total time in millis that the animation will take, or -1 to use the default value (800ms).
-
-