public class FlipHorizontalAnimation extends Animation implements Combinable
Modifier and Type | Field and Description |
---|---|
static int |
PIVOT_CENTER |
static int |
PIVOT_LEFT |
static int |
PIVOT_RIGHT |
DIRECTION_DOWN, DIRECTION_LEFT, DIRECTION_RIGHT, DIRECTION_UP, DURATION_DEFAULT, DURATION_LONG, DURATION_SHORT
Constructor and Description |
---|
FlipHorizontalAnimation(View view)
This animation causes the view to flip horizontally by a customizable
number of degrees and at a customizable pivot point.
|
Modifier and Type | Method and Description |
---|---|
void |
animate()
This method animates the properties of the view specific to the Animation
object.
|
AnimatorSet |
getAnimatorSet() |
float |
getDegrees() |
long |
getDuration() |
TimeInterpolator |
getInterpolator() |
AnimationListener |
getListener() |
int |
getPivot()
The available pivot points are
PIVOT_CENTER ,
PIVOT_LEFT and PIVOT_RIGHT . |
FlipHorizontalAnimation |
setDegrees(float degrees)
In order to flip to the left, the number of degrees should be negative
and vice versa.
|
FlipHorizontalAnimation |
setDuration(long duration) |
FlipHorizontalAnimation |
setInterpolator(TimeInterpolator interpolator) |
FlipHorizontalAnimation |
setListener(AnimationListener listener) |
FlipHorizontalAnimation |
setPivot(int pivot)
The available pivot points are
PIVOT_CENTER ,
PIVOT_LEFT and PIVOT_RIGHT . |
public static final int PIVOT_CENTER
public static final int PIVOT_LEFT
public static final int PIVOT_RIGHT
public FlipHorizontalAnimation(View view)
view
- The view to be animated.public void animate()
Animation
animate
in interface Combinable
animate
in class Animation
public AnimatorSet getAnimatorSet()
getAnimatorSet
in interface Combinable
public float getDegrees()
public FlipHorizontalAnimation setDegrees(float degrees)
degrees
- The number of degrees to set to flip by.public int getPivot()
PIVOT_CENTER
,
PIVOT_LEFT
and PIVOT_RIGHT
.public FlipHorizontalAnimation setPivot(int pivot)
PIVOT_CENTER
,
PIVOT_LEFT
and PIVOT_RIGHT
.pivot
- The pivot point to set for flipping.public TimeInterpolator getInterpolator()
public FlipHorizontalAnimation setInterpolator(TimeInterpolator interpolator)
setInterpolator
in interface Combinable
interpolator
- The interpolator of the entire animation to set.public long getDuration()
getDuration
in interface Combinable
public FlipHorizontalAnimation setDuration(long duration)
setDuration
in interface Combinable
duration
- The duration of the entire animation to set.public AnimationListener getListener()
public FlipHorizontalAnimation setListener(AnimationListener listener)
setListener
in interface Combinable
listener
- The listener to set for the end of the animation.