AQScale

Kind of class:class
Inherits from:none
Author:Arthur Clemens
Classpath:org.asapframework.util.actionqueue.AQScale
File last modified:Thursday, 12 October 2006, 11:19:40
ActionQueue method to control the scaling of a movieclip.
See also AQPulse to scale a movieclip in a pulsating manner.

Summary


Class properties
  • START_VALUE : Number
    • Start animation value to be returned to the perform function.
  • END_VALUE : Number
    • End animation value to be returned to the perform function.
Class methods
  • scale (inMC:MovieClip, inDuration:Number, inStartScaleX:Number, inStartScaleY:Number, inEndScaleX:Number, inEndScaleY:Number, inEffect:Function) : ActionQueuePerformData

Class properties

END_VALUE

static private END_VALUE:Number = 0
(read)

End animation value to be returned to the perform function.

START_VALUE

static private START_VALUE:Number = 1
(read)

Start animation value to be returned to the perform function.

Class methods

scale

static function scale (
inMC:MovieClip, inDuration:Number, inStartScaleX:Number, inStartScaleY:Number, inEndScaleX:Number, inEndScaleY:Number, inEffect:Function) : ActionQueuePerformData

Parameters:
inMC :
movieclip to scale
inDuration :
length of animation in seconds; 0 is used for perpetual animations - use -1 for instant change
inStartScaleX:
x value to start scaling from; if null then inMC's current _xscale value is used
inStartScaleY:
y value to start scaling from; if null then inMC's current _yscale value is used
inEndScaleX :
x value to end scaling to; if null then inMC's current (dynamic) _xscale value is used
inEndScaleY :
y value to end scaling to; if null then inMC's current (dynamic) _yscale value is used
inEffect :
(optional) An effect function, for instance one of the mx.transitions.easing methods. Arguments to pass the effect function may be appended as a comma-separated list.
Returns:
  • A new ActionQueuePerformData object.
Example:
  • This example scales a movieclip from scale 100 to scale 200 in 2 seconds:
    queue.addAction( AQScale.scale, my_mc, 2, 100, 100, 200, 200, Elastic.easeOut );
    To scale back to normal scale from an arbitrary bigger or smaller scale:
    queue.addAction( AQScale.scale, my_mc, 2, null, null, 100, 100, Elastic.easeOut );