      *  The length of time, in milliseconds, of the animation,
      *  not counting any repetitions defined by 
      *  the <code>repeatCount</code> property.
-     *  
-     *  @langversion 3.0
-     *  @playerversion Flash 10
-     *  @playerversion AIR 1.5
-     *  @productversion Flex 4
-     */
-    public var duration:Number;
+     * 
+     * @default 500
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 10
+     *  @playerversion AIR 1.5
+     *  @productversion Flex 4
+     */
+    public var duration:Number = 500;
 
     //----------------------------------
     //  repeatBehavior

import flash.utils.Timer;
import flash.utils.getTimer;

import mx.events.EffectEvent;
import mx.resources.IResourceManager;
import mx.resources.ResourceManager;

import spark.effects.SimpleMotionPath;
import spark.effects.easing.IEaser;
import spark.effects.easing.Linear;

    {
        // stop an already-playing animation first
        stop();
        
        // Make sure the time values in our motion paths are reasonable
        // SimpleMotionPath objects may be set up with no time values, so
        // we have to fill in those values from the duration when necessary
        var i:int;
        var j:int;
        for (i = 0; i < motionPaths.length; ++i)
        {
            var keyframes:Array = motionPaths[i].keyframes;
            if (isNaN(keyframes[0].time))
                keyframes[0].time = 0;
            // Create an initial (time==0) value if necessary 
            else if (keyframes[0].time > 0)
            {
                keyframes.splice(0, 0, new KeyFrame(0, null));
                keyframes[0].timeFraction = 0;
            }
            for (j = 1; j < keyframes.length; ++j)
            {
                if (isNaN(keyframes[j].time))
                    keyframes[j].time = duration;
            }
        }
        for (i = 0; i < motionPaths.length; ++i)
            motionPaths[i].scaleKeyframes(duration);
        
        if (startDelay > 0)
            addToDelayedAnimations(startDelay);
