1.02
flm.b4a.animationplus.TransitionDrawable
TransitionDrawable
android.graphics.drawable.TransitionDrawable
activity
Initialize
Initializes the TransitionDrawable.
<B>Layer1</B>: the drawable (or bitmap) to display first.
<B>Layer2</B>: the drawable (or bitmap) displayed after a transition.
void
Layer1
java.lang.Object
Layer2
java.lang.Object
ShowFirstLayer
Shows only the first layer.
void
ReverseTransition_2To1
Reverses the transition, picking up where the transition currently is. If the transition is not currently running, this will start the transition with the specified duration. If the transition is already running, the last known duration will be used.
<B>Duration</B>: the duration to use if no transition is running.
void
Duration
int
IsInitialized
boolean
StartTransition_1To2
Starts the cross-fade sequence to display the second layer on top of the first layer.
<B>Duration</B>: the length of the transition in milliseconds.
void
Duration
int
CrossFadeEnabled
boolean
Enabled
boolean
Gets/sets whether the cross fade is enabled for this transition.
When cross fade is disabled, the first drawable is always drawn opaque. With cross fade enabled, the first drawable is drawn with the opposite alpha of the second drawable. Cross fade is disabled by default.
flm.b4a.animationplus.LayerDrawable
LayerDrawable
android.graphics.drawable.LayerDrawable
activity
Initialize
Initializes the LayerDrawable.
<B>Layers</B>: an array of drawables (or bitmaps) to draw together.
The element with the largest index will be drawn on top.
void
Layers
java.lang.Object[]
SetAlpha
Sets the opacity of the layer at the given index.
You should invalidate the view displaying the layerdrawable after using this function.
Value: Value of the alpha channel between 0 and 255.
void
Index
int
Value
int
ChangeLayer
Changes the layer (drawable or bitmap) at the given index.
Returns True if the layer was replaced or False if the index was not found.
You should invalidate the view displaying the layerdrawable after using this function.
boolean
Index
int
Layer
java.lang.Object
GetDrawable
Returns the drawable at the specified layer index.
android.graphics.drawable.Drawable
Index
int
IsInitialized
boolean
NumberOfLayers
int
Returns the number of layers contained within the LayerDrawable.
flm.b4a.animationplus.ClipDrawable
ClipDrawable
android.graphics.drawable.ClipDrawable
activity
Initialize
Initializes the ClipDrawable.
<B>Drawable</B>: the drawable or bitmap to clip.
<B>Gravity</B>: where to clip within the drawable.
<B>Orientation</B>: one of the two orientation constants (horizontal or vertical).
<B>StartLevel</B>: the initial clipping level.
The drawable is clipped completely and not visible when the level is 0 and fully revealed when the level is 10000.
void
Drawable
java.lang.Object
Gravity
int
Orientation
int
StartLevel
int
IsInitialized
boolean
Level
int
Level
int
Gets or sets the clipping level.
The drawable is clipped completely and not visible when the level is 0 and fully revealed when the level is 10000.
ORIENTATION_HORIZONTAL
int
ORIENTATION_VERTICAL
int
flm.b4a.animationplus.AnimationSet
AnimationSet
android.view.animation.AnimationSet
activity
Initialize
Initializes the AnimationSet.
<B>ShareInterpolator</B>: pass true if all of the animations in this set should use the interpolator associated with this AnimationSet. Pass false if each animation should use its own interpolator.
void
ShareInterpolator
boolean
Start
Plays the added animations together.
void
view
android.view.View
SetInterpolatorWithParam
Sets the acceleration curve for every child animation in the set. Defaults to a linear interpolation.
See <I>http://developer.android.com/reference/android/view/animation/Interpolator.html</I> for further details.
This setting is ignored if you set ShareInterpolator to false when you initialized the set.
<B>Interpolator</B>: one of the INTERPOLATOR constants.
<B>Param</B>: factor or tension.
The Accelerate/Decelerate Interpolator and the Bounce Interpolator have no parameter.
void
Interpolator
int
Param
float
SetInterpolator
Sets the acceleration curve for every child animation in the set. Defaults to a linear interpolation.
See <I>http://developer.android.com/reference/android/view/animation/Interpolator.html</I> for further details.
This setting is ignored if you set ShareInterpolator to false when you initialized the set.
<B>Interpolator</B>: one of the INTERPOLATOR constants.
The Cycle Interpolator cannot be used with this function because the parameter is mandatory.
void
Interpolator
int
Stop
Stops all child animations.
Warning: stopping an animation set does not trigger the AnimationEnd event of the child animations.
void
view
android.view.View
AddAnimation
Adds a child animation to this animation set.
<B>Anim</B>: animation to add.
void
Anim
flm.b4a.animationplus.AnimationPlusWrapper
IsInitialized
boolean
PersistAfter
boolean
persistAfter
boolean
Gets/sets if the transformations that this animation set performed will persist when it is finished.
Duration
long
Duration
long
Gets/sets the duration in milliseconds of every child animation.
StartOffset
long
startOffset
long
Gets/sets when the animation set should begin after the Start function was called (in milliseconds).
INTERPOLATOR_ANTICIPATE_OVERSHOOT
int
INTERPOLATOR_OVERSHOOT
int
INTERPOLATOR_LINEAR
int
INTERPOLATOR_BOUNCE
int
INTERPOLATOR_ACCELERATE
int
INTERPOLATOR_DECELERATE
int
INTERPOLATOR_ACCELERATE_DECELERATE
int
INTERPOLATOR_CYCLE
int
INTERPOLATOR_ANTICIPATE
int
flm.b4a.animationplus.AnimationPlusWrapper
AnimationPlus
android.view.animation.Animation
activity
AnimationEnd
Start
void
MyView
android.view.View
PauseTranslation
Pauses a translation animation.
void
SetInterpolatorWithParam
Sets the acceleration curve for this animation. Defaults to a linear interpolation.
See <I>http://developer.android.com/reference/android/view/animation/Interpolator.html</I> for further details.
<B>Interpolator</B>: one of the INTERPOLATOR constants.
<B>Param</B>: factor or tension.
The Accelerate/Decelerate Interpolator and the Bounce Interpolator have no parameter.
void
Interpolator
int
Param
float
SetInterpolator
Sets the acceleration curve for this animation. Defaults to a linear interpolation.
See <I>http://developer.android.com/reference/android/view/animation/Interpolator.html</I> for further details.
<B>Interpolator</B>: one of the INTERPOLATOR constants.
The Cycle Interpolator cannot be used with this function because the parameter is mandatory.
void
Interpolator
int
InitializeRotateCenter
void
arg0
anywheresoftware.b4a.BA
arg1
java.lang.String
arg2
float
arg3
float
arg4
android.view.View
InitializeScaleCenter
void
arg0
anywheresoftware.b4a.BA
arg1
java.lang.String
arg2
float
arg3
float
arg4
float
arg5
float
arg6
android.view.View
InitializeRotate
void
arg0
anywheresoftware.b4a.BA
arg1
java.lang.String
arg2
float
arg3
float
Stop
void
arg0
android.view.View
InitializeScale
void
arg0
anywheresoftware.b4a.BA
arg1
java.lang.String
arg2
float
arg3
float
arg4
float
arg5
float
ResumeTranslation
Resumes a paused translation animation.
void
InitializeTranslate
void
ba
anywheresoftware.b4a.BA
EventName
java.lang.String
FromDX
float
FromDY
float
ToDX
float
ToDY
float
InitializeAlpha
void
arg0
anywheresoftware.b4a.BA
arg1
java.lang.String
arg2
float
arg3
float
IsInitialized
boolean
RepeatCount
int
arg0
int
PersistAfter
boolean
persistAfter
boolean
Gets/sets if the transformation that this animation performed will persist when it is finished.
RepeatMode
int
arg0
int
Duration
long
arg0
long
StartOffset
long
startOffset
long
Gets/sets when the animation should begin after the Start function was called (in milliseconds).
IsPaused
boolean
Gets whether the translation animation is paused.
INTERPOLATOR_ANTICIPATE_OVERSHOOT
int
INTERPOLATOR_OVERSHOOT
int
INTERPOLATOR_DECELERATE
int
INTERPOLATOR_ACCELERATE_DECELERATE
int
INTERPOLATOR_CYCLE
int
REPEAT_REVERSE
int
REPEAT_RESTART
int
INTERPOLATOR_LINEAR
int
INTERPOLATOR_ACCELERATE
int
INTERPOLATOR_BOUNCE
int
REPEAT_INFINITE
int
INTERPOLATOR_ANTICIPATE
int
flm.b4a.animationplus.AnimationDrawable
AnimationDrawable
android.graphics.drawable.AnimationDrawable
activity
Initialize
Initializes the AnimationDrawable.
void
Start
Starts the animation, looping if necessary. This method has no effect if the animation is running.
void
Stop
Stops the animation. This method has no effect if the animation is not running.
void
AddFrame
Adds a frame to the animation
<B>Frame</B>: the frame to add. It must be a drawable or a bitmap.
<B>Duration</B>: how long in milliseconds the frame should appear.
void
Frame
java.lang.Object
Duration
int
IsRunning
Indicates whether the animation is currently running or not.
boolean
GetCurrent
Returns the drawable currently displayed.
android.graphics.drawable.Drawable
GetDuration
Returns the duration in milliseconds of the frame at the specified index.
int
Index
int
GetFrame
Returns the drawable at the specified frame index.
android.graphics.drawable.Drawable
Index
int
GetNumberOfFrames
Returns the number of frames in the animation
int
IsInitialized
boolean
OneShot
boolean
OneShot
boolean
Gets/sets whether the animation will play once.
2.3
Animation