动画引用

Animation

Animation is an abstract base class used as a starting point for all the other animations. provides the basic mechanics for the animation (playing, pausing, stopping, timing, etc.) and leaves the actual animation to be done in the abstract methods getAnimatedValue and setValue.

标签: Animation
类: AjaxControlToolkit.Animation.Animation
基类: Sys.Component
构造函数: new AjaxControlToolkit.Animation.Animation(target, duration, fps);
Play: AjaxControlToolkit.Animation.Animation.play(target, duration, fps);
属性:
Number duration;
Length of time to play the animation (in seconds). The default value is 1.
Number fps;
Number of frames per second shown when animating. The default values is 25.
Boolean isActive; // Read Only
true if animation is active, false if not.
Boolean isInitialized; // Read Only
Inherited from Sys.Component
Boolean isPlaying; // Read Only
true if animation is playing, false if not.
Boolean isUpdating; // Read Only
Inherited from Sys.Component
Number percentComplete; // Read Only
Percentage of the animation already played.
Object target;
Target element that the animation should operate on. (Note: Do not set this property in a generic xml animation description. It will be set automatically using either the TargetControlID or the AnimationTarget properties.)
方法:
dispose();
Dispose the animation
getAnimatedValue();
Determine the state of the animation after the given percentage of its duration has elapsed
getDescriptor();
Inherited from Sys.Component
interpolate(start, end, percentage);
Given two Numbers start and end, the interpolate function will produce another Number the specified percentage between the two values.
onEnd();
Perform any cleanup after playing the animation.
onStart();
Perform any initialization before playing the animation.
onStep(percentage);
Progress the animation through each frame
pause();
Pause the animation
play();
Play the animation
setOwner(owner);
Inherited from Sys.Component
setValue(value);
Set the current state of the animation
stop();
Stop playing the animation

Parent Animation

The ParentAnimation serves as a base class for all animations that contain children (such as ParallelAnimation, SequenceAnimation, etc.). It does not actually play the animations, so any classes that inherit from it must do so.

标签: Parent
类: AjaxControlToolkit.Animation.ParentAnimation
基类: AjaxControlToolkit.Animation.Animation
构造函数: new AjaxControlToolkit.Animation.ParentAnimation(target, duration, fps, animations);
Play: AjaxControlToolkit.Animation.ParentAnimation.play(target, duration, fps, animations);
属性:
Array animations; // Read Only
Array of child animations to be played. To manipulate this array, use the functions add, clear, remove, and removeAt.
Number duration;
Inherited from AjaxControlToolkit.Animation.Animation
Number fps;
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isActive; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isInitialized; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isPlaying; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isUpdating; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Number percentComplete; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Object target;
Inherited from AjaxControlToolkit.Animation.Animation
方法:
add(animation);
Add an animation as a child of this animation.
clear();
Clear the list of child animations.
dispose();
Inherited from AjaxControlToolkit.Animation.Animation
getAnimatedValue();
Inherited from AjaxControlToolkit.Animation.Animation
getDescriptor();
Inherited from AjaxControlToolkit.Animation.Animation
initialize();
Initialize any of the child animations that have not been initialized yet.
interpolate(start, end, percentage);
Inherited from AjaxControlToolkit.Animation.Animation
onEnd();
Inherited from AjaxControlToolkit.Animation.Animation
onStart();
Inherited from AjaxControlToolkit.Animation.Animation
onStep(percentage);
Inherited from AjaxControlToolkit.Animation.Animation
pause();
Inherited from AjaxControlToolkit.Animation.Animation
play();
Inherited from AjaxControlToolkit.Animation.Animation
remove(animation);
Remove the animation from the array of child animations.
removeAt(index);
Remove the animation at a given index from the array of child animations.
setOwner(owner);
Inherited from AjaxControlToolkit.Animation.Animation
setValue(value);
Inherited from AjaxControlToolkit.Animation.Animation
stop();
Inherited from AjaxControlToolkit.Animation.Animation

Parallel Animation

The ParallelAnimation plays several animations simultaneously. It inherits from ParentAnimation, but makes itself the owner of all its child animations as this allows it to use a single timer and synchronization mechanisms of the parent animation (in other words, the duration properties of any child animations are ignored in favor of the parent's duration). It is very useful in creating sophisticated effects through combinations of simpler animations.
Note: The ParallelAnimation cannot have any child animations that derive from SequenceAnimation.

标签: Parallel
类: AjaxControlToolkit.Animation.ParallelAnimation
基类: AjaxControlToolkit.Animation.ParentAnimation
构造函数: new AjaxControlToolkit.Animation.ParallelAnimation(target, duration, fps, animations);
Play: AjaxControlToolkit.Animation.ParallelAnimation.play(target, duration, fps, animations);
属性:
Array animations; // Read Only
Inherited from AjaxControlToolkit.Animation.ParentAnimation
Number duration;
Inherited from AjaxControlToolkit.Animation.Animation
Number fps;
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isActive; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isInitialized; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isPlaying; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isUpdating; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Number percentComplete; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Object target;
Inherited from AjaxControlToolkit.Animation.Animation
方法:
add(animation);
Add an animation as a child of this animation and make ourselves its owner.
clear();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
dispose();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
getAnimatedValue(percentage);
Empty implementation of an abstract function from Sys.UI.Animation.
getDescriptor();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
initialize();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
interpolate(start, end, percentage);
Inherited from AjaxControlToolkit.Animation.Animation
onEnd();
Invoke the onEnd function of the child animations.
onStart();
Invoke the onStart function of the child animations.
onStep(percentage);
Invoke the onStep function of the child animations.
pause();
Inherited from AjaxControlToolkit.Animation.Animation
play();
Inherited from AjaxControlToolkit.Animation.Animation
remove(animation);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
removeAt(index);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
setOwner(owner);
Inherited from AjaxControlToolkit.Animation.Animation
setValue(value);
Inherited from AjaxControlToolkit.Animation.Animation
stop();
Inherited from AjaxControlToolkit.Animation.Animation

Sequence Animation

The SequenceAnimation runs several child animations one after the other. It can also repeat the sequence of animations for a specified number of iterations (which defaults to a single iteration, but will repeat forever if you specify zero or less iterations). It is important to note that the SequenceAnimation ignores its duration and fps properties, and will let each of its child animations use any values they please.
Note: The SequenceAnimation cannot be a child animation of
ParallelAnimation, SelectionAnimation, or any animation deriving from these two.

标签: Sequence
类: AjaxControlToolkit.Animation.SequenceAnimation
基类: AjaxControlToolkit.Animation.ParentAnimation
构造函数: new AjaxControlToolkit.Animation.SequenceAnimation(target, duration, fps, animations, iterations);
Play: AjaxControlToolkit.Animation.SequenceAnimation.play(target, duration, fps, animations, iterations);
属性:
Array animations; // Read Only
Inherited from AjaxControlToolkit.Animation.ParentAnimation
Number duration;
Inherited from AjaxControlToolkit.Animation.Animation, but this property is ignored
Number fps;
Inherited from AjaxControlToolkit.Animation.Animation, but this property is ignored
Boolean isActive; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isInitialized; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isPlaying; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isUpdating; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Number iterations;
Number of iterations to repeat the sequence of child animations when playing. If this value is less than or equal to 0, the sequence of child animations will repeat forever. The default value is 1.
Number percentComplete; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Object target;
Inherited from AjaxControlToolkit.Animation.Animation
方法:
add(animation);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
clear();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
dispose();
Inherited from AjaxControlToolkit.Animation.Animation
getAnimatedValue();
Implementation of an abstract function from Sys.UI.Animation that throws an exception (because it should never be called).
getDescriptor();
Inherited from AjaxControlToolkit.Animation.Animation
initialize();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
interpolate(start, end, percentage);
Inherited from AjaxControlToolkit.Animation.Animation
onEnd();
Clean up after playing an iteration of the sequence of child animations, and if necessary restart the sequence until all iterations have been played.
onStart();
Initialization before playing the animation.
onStep(percentage);
Inherited from AjaxControlToolkit.Animation.Animation
pause();
Pause the currently playing sequence of child animations. Calling play will resume where you left off.
play();
Play the sequence of child animations one after another.
remove(animation);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
removeAt(index);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
setOwner(owner);
Inherited from AjaxControlToolkit.Animation.Animation
setValue(value);
Implementation of an abstract function from Sys.UI.Animation that throws an exception (because it should never be called).
stop();
Stop the currently playing sequence of child animations.

Selection Animation

The SelectionAnimation will run a single animation chosen from of its child animations. This is a base class with no functional implementation, so consider using ConditionAnimation or CaseAnimation.
Note: The SelectionAnimation cannot have any child animations that derive from SequenceAnimation.

标签: Selection
类: AjaxControlToolkit.Animation.SelectionAnimation
基类: AjaxControlToolkit.Animation.ParentAnimation
构造函数: new AjaxControlToolkit.Animation.SelectionAnimation(target, duration, fps, animations);
Play: AjaxControlToolkit.Animation.SelectionAnimation.play(target, duration, fps, animations);
属性:
Array animations; // Read Only
Inherited from AjaxControlToolkit.Animation.ParentAnimation
Number duration;
Inherited from AjaxControlToolkit.Animation.Animation
Number fps;
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isActive; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isInitialized; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isPlaying; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isUpdating; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Number percentComplete; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Object target;
Inherited from AjaxControlToolkit.Animation.Animation
方法:
add(animation);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
clear();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
dispose();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
getAnimatedValue(percentage);
Empty implementation of an abstract function from Sys.UI.Animation.
getDescriptor();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
initialize();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
interpolate(start, end, percentage);
Inherited from AjaxControlToolkit.Animation.Animation
onEnd();
Perform any cleanup after playing the selected animation.
onStart();
Prepare the selected animation to be played.
onStep(percentage);
Play the next step of the selected animation.
pause();
Inherited from AjaxControlToolkit.Animation.Animation
play();
Inherited from AjaxControlToolkit.Animation.Animation
remove(animation);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
removeAt(index);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
setOwner(owner);
Inherited from AjaxControlToolkit.Animation.Animation
setValue(value);
Inherited from AjaxControlToolkit.Animation.Animation
stop();
Inherited from AjaxControlToolkit.Animation.Animation

Condition Animation

The ConditionAnimation is used as a control structure to play a specific child animation depending on the result of executing the conditionScript. If the conditionScript evaluated to true, the first child animation is played. If it evaluates to false, the second child animation is played (although nothing is played if the second animation is not present).
Note: The ConditionAnimation cannot have any child animations that derive from
SequenceAnimation.

标签: Condition
类: AjaxControlToolkit.Animation.ConditionAnimation
基类: AjaxControlToolkit.Animation.SelectionAnimation
构造函数: new AjaxControlToolkit.Animation.ConditionAnimation(target, duration, fps, animations, conditionScript);
Play: AjaxControlToolkit.Animation.ConditionAnimation.play(target, duration, fps, animations, conditionScript);
属性:
Array animations; // Read Only
Inherited from AjaxControlToolkit.Animation.ParentAnimation
String conditionScript;
JavaScript code to be executed and whose value will determine which of the child animations to play.
Number duration;
Inherited from AjaxControlToolkit.Animation.Animation
Number fps;
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isActive; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isInitialized; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isPlaying; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isUpdating; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Number percentComplete; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Object target;
Inherited from AjaxControlToolkit.Animation.Animation
方法:
add(animation);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
clear();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
dispose();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
getAnimatedValue(percentage);
Inherited from AjaxControlToolkit.Animation.SelectionAnimation
getDescriptor();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
initialize();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
interpolate(start, end, percentage);
Inherited from AjaxControlToolkit.Animation.Animation
onEnd();
Inherited from AjaxControlToolkit.Animation.SelectionAnimation
onStart();
Inherited from AjaxControlToolkit.Animation.SelectionAnimation
onStep(percentage);
Inherited from AjaxControlToolkit.Animation.SelectionAnimation
pause();
Inherited from AjaxControlToolkit.Animation.Animation
play();
Inherited from AjaxControlToolkit.Animation.Animation
remove(animation);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
removeAt(index);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
setOwner(owner);
Inherited from AjaxControlToolkit.Animation.Animation
setValue(value);
Inherited from AjaxControlToolkit.Animation.Animation
stop();
Inherited from AjaxControlToolkit.Animation.Animation

Case Animation

The CaseAnimation is used as a control structure to play a specific child animation depending on the result of executing the selectScript, which should evaluate to the index of the child animation to play (this is similar to the switch statement in C#, etc.). If the provided index is outside the bounds of the child animations (or if nothing was returned) then we will not play anything.
Note: The CaseAnimation cannot have any child animations that derive from
SequenceAnimation.

标签: Case
类: AjaxControlToolkit.Animation.CaseAnimation
基类: AjaxControlToolkit.Animation.SelectionAnimation
构造函数: new AjaxControlToolkit.Animation.CaseAnimation(target, duration, fps, animations, selectScript);
Play: AjaxControlToolkit.Animation.CaseAnimation.play(target, duration, fps, animations, selectScript);
属性:
Array animations; // Read Only
Inherited from AjaxControlToolkit.Animation.ParentAnimation
Number duration;
Inherited from AjaxControlToolkit.Animation.Animation
Number fps;
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isActive; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isInitialized; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isPlaying; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Boolean isUpdating; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
Number percentComplete; // Read Only
Inherited from AjaxControlToolkit.Animation.Animation
String selectScript;
JavaScript code to be executed and whose value will determine which of the child animations to play.
Object target;
Inherited from AjaxControlToolkit.Animation.Animation
方法:
add(animation);
Inherited from AjaxControlToolkit.Animation.ParentAnimation
clear();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
dispose();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
getAnimatedValue(percentage);
Inherited from AjaxControlToolkit.Animation.SelectionAnimation
getDescriptor();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
initialize();
Inherited from AjaxControlToolkit.Animation.ParentAnimation
interpolate(start, end, percentage);
Inherited from AjaxControlToolkit.Animation.Animation
onEnd();
Inherited from AjaxControlToolkit.Animation.SelectionAnimation
onStart();
Inherited from AjaxControlToolkit.Animation.SelectionAnimation
onStep(percentage);
Inherited from AjaxControlToolkit.Animation.SelectionAnimation
pause();
Inherited from AjaxControlToolkit.Animation.Animation