public class AnimatorPack extends Object
Modifier and Type | Class and Description |
---|---|
static class |
AnimatorPack.Direction |
Constructor and Description |
---|
AnimatorPack() |
Modifier and Type | Method and Description |
---|---|
static android.animation.AnimatorSet |
crossfade(android.view.View out,
android.view.View in)
Switch views with fade and scale in place animation.
|
static android.animation.AnimatorSet |
crossfade(android.view.View out,
android.view.View in,
android.animation.Animator.AnimatorListener outListener,
android.animation.Animator.AnimatorListener inListener)
Switch views with fade and scale in place animation.
|
static android.animation.Animator |
fadeIn(android.view.View toAnimate)
Animation to fade in and scale up a view and make it visible.
|
static android.animation.Animator |
fadeOut(android.view.View toAnimate)
Animation to fade out and scale down a view and make it invisible.
|
static android.animation.AnimatorSet |
scale(android.view.View view,
float from,
float to)
Scales view in place
It's up to you to set view's visibility on animation end
|
static android.animation.Animator |
slideIn(android.view.View toAnimate,
AnimatorPack.Direction from)
Builds a slide in animator
|
static android.animation.Animator |
slideInSequentially(AnimatorPack.Direction from,
long delay,
boolean fadeIn,
boolean scale,
android.view.View... toAnimate)
Slide in animation that delays start of each animated element by an offset.
|
static android.animation.Animator |
slideOut(android.view.View toAnimate,
AnimatorPack.Direction to)
Builds a slide out animator.
|
static android.animation.Animator |
slideOutSequentially(AnimatorPack.Direction to,
long delay,
boolean fadeOut,
boolean scale,
android.view.View... toAnimate)
Slide out animation that delays start of each animated element by an offset.
|
public static android.animation.AnimatorSet scale(android.view.View view, float from, float to)
view
- to be scaledfrom
- starting scaleto
- ending scalepublic static android.animation.AnimatorSet crossfade(android.view.View out, android.view.View in, android.animation.Animator.AnimatorListener outListener, android.animation.Animator.AnimatorListener inListener)
out
- view to hidein
- view to showoutListener
- that listens for fade-out animatorinListener
- that listens for fade-in animatorpublic static android.animation.AnimatorSet crossfade(android.view.View out, android.view.View in)
out
- view to hidein
- view to showpublic static android.animation.Animator slideOut(android.view.View toAnimate, AnimatorPack.Direction to)
toAnimate
- view to animateto
- direction to slide outpublic static android.animation.Animator slideIn(android.view.View toAnimate, AnimatorPack.Direction from)
toAnimate
- view to animatefrom
- direction to slide in frompublic static android.animation.Animator slideOutSequentially(AnimatorPack.Direction to, long delay, boolean fadeOut, boolean scale, android.view.View... toAnimate)
to
- direction to slide out todelay
- durationfadeOut
- true if fading outscale
- true if scalingtoAnimate
- view to animatepublic static android.animation.Animator slideInSequentially(AnimatorPack.Direction from, long delay, boolean fadeIn, boolean scale, android.view.View... toAnimate)
from
- direction to slide in fromdelay
- durationfadeIn
- true if fading inscale
- true if scalingtoAnimate
- view to animatepublic static android.animation.Animator fadeOut(android.view.View toAnimate)
toAnimate
- view to animatepublic static android.animation.Animator fadeIn(android.view.View toAnimate)
toAnimate
- view to animate