Transferred from the Adobe Open Source Subversion Repository

Revision: 19294
Author:   eday@adobe.com
Date:     2010-12-10T22:13:53.316129Z

Log Message:
-----------
Bounce/pull effects for touch scrolling.

1. Extend the throw animation to perform overshoot and settle ("bounce") effects.
2. Allow a scrolled component to be "pulled" past its edges.
3. Match initial throw velocity to final scroll velocity.
4. Calculate throw duration with fixed deceleration factor.

QE notes:
Doc notes:
Bugs:
Reviewer: Ryan
Tests run: checkintests, manual, cyclone run by Joan
Is noteworthy for integration:

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/Scroller.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/VScrollBar.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/HScrollBar.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1280498 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/Scroller.as
+++ frameworks/projects/spark/src/spark/components/Scroller.as
@@ -42,6 +42,7 @@
 import spark.effects.animation.SimpleMotionPath;
 import spark.effects.easing.IEaser;
 import spark.effects.easing.Power;
+import spark.effects.easing.Sine;
 import spark.utils.MouseEventUtil;

 use namespace mx_internal;
@@ -486,15 +487,43 @@

     /**
      *  @private
-     *  Minimum duration of throw effects
-     */
-    private static const THROW_EFFECT_DURATION_MINIMUM:int = 500;
-
-    /**
-     *  @private
-     *  Range (maximum - minimum) of the throw effect duration
-     */
-    private static const THROW_EFFECT_DURATION_RANGE:int = 2500;
+     *  The amount of deceleration to apply to the velocity for each effect period
+     *  For a faster deceleration, you can switch this to 0.990.
+     */
+    private static const THROW_EFFECT_DECEL_FACTOR:Number = 0.998;
+
+    /**
+     *  @private
+     *  The duration of the overshoot effect when a throw "bounces" against the end of the list.
+     */
+    private static const THROW_OVERSHOOT_TIME:int = 200;
+
+    /**
+     *  @private
+     *  The duration of the settle effect when a throw "bounces" against the end of the list.
+     */
+    private static const THROW_SETTLE_TIME:int = 600;
+
+    /**
+     *  @private
+     *  The exponent used in the easer function for the main part of the throw animation.
+     *  NOTE: if you change this, you need to re-differentiate the easer
+     *  function and use the resulting derivative calculation in createThrowMotionPath.
+     */
+    private static const THROW_CURVE_EXPONENT:Number = 3.0;
+
+    /**
+     *  @private
+     *  The exponent used in the easer function for the "overshoot" portion
+     *  of the throw animation.
+     */
+    private static const OVERSHOOT_CURVE_EXPONENT:Number = 2.0;
+
+    /**
+     *  @private
+     *  The ratio that determines how far the list scrolls when pulled past its end.
+     */
+    private static const PULL_TENSION_RATIO:Number = 0.5;

     //--------------------------------------------------------------------------
     //
@@ -1127,20 +1156,23 @@

     /**
      *  @private
-     *  Use the specified scroll distance ratio to determine the duration of the throw effect
-     */
-    private function calculateThrowEffectTime(distanceRatio:Point):int
+     *  Use the specified velocity to determine the duration of the throw effect
+     */
+    private function calculateThrowEffectTime(velocityX:Number, velocityY:Number):int
     {
         if (scrollerLayout)
         {
-            // the throw will last 0.5sec - 3sec, depending on the distance
-            // of the scroll.
-            var throwTimeX:int = THROW_EFFECT_DURATION_MINIMUM + (THROW_EFFECT_DURATION_RANGE * distanceRatio.x);
-            var throwTimeY:int = THROW_EFFECT_DURATION_MINIMUM + (THROW_EFFECT_DURATION_RANGE * distanceRatio.y);
+            // This calculates the effect duration based on a deceleration factor that is applied evenly over time.
+            // We decay the velocity by the deceleration factor until it is less than 0.01/ms, which is rounded to zero pixels.
+            // We want to solve for "time" in this equasion: velocity*(decel^time)-0.01 = 0.
+            // Note that we are only calculating an effect duration here.  The actual curve of our throw velocity is determined by
+            // the exponential easing function we use between animation keyframes.
+            var throwTimeX:int = velocityX == 0 ? 0 : (Math.log(0.01 / (Math.abs(velocityX)))) / Math.log(THROW_EFFECT_DECEL_FACTOR);
+            var throwTimeY:int = velocityY == 0 ? 0 : (Math.log(0.01 / (Math.abs(velocityY)))) / Math.log(THROW_EFFECT_DECEL_FACTOR);

             if (scrollerLayout.canScrollHorizontally && scrollerLayout.canScrollVertically)
             {
-                return Math.max(throwTimeX,throwTimeY);
+                return Math.max(throwTimeX, throwTimeY);
             }
             else if (scrollerLayout.canScrollHorizontally)
             {
@@ -1156,10 +1188,162 @@

     /**
      *  @private
+     *  A utility function to add a new keyframe to the motion path and return the frame time.
+     */
+    private function addKeyframe(motionPath:SimpleMotionPath,time:Number,position:Number,easer:IEaser):Number
+    {
+        var keyframe:Keyframe = new Keyframe(time,position);
+        keyframe.easer = easer;
+        motionPath.keyframes.push(keyframe);
+        return time;
+    }
+
+    /**
+     *  @private
+     *  This function builds a motion path that reflects the starting conditions (position, velocity)
+     *  and exhibits overshoot/settle/snap effects (aka bounce/pull) according to the min/max boundaries.
+     */
+    private function createThrowMotionPath(propertyName:String, velocity:Number, position:Number, minPosition:Number,
+                                            maxPosition:Number, throwEffectTime:Number):SimpleMotionPath
+    {
+        var motionPath:SimpleMotionPath = new SimpleMotionPath(propertyName);
+        motionPath.keyframes = Vector.<Keyframe>([new Keyframe(0, position)]);
+        var keyframe:Keyframe = null;
+        var nowTime:Number = 0;
+
+        // First, we handle the case where the velocity is zero (finger wasn't significantly moving when lifted).
+        // Ordinarily, we do nothing in this case, but if the list is currently scrolled past its end (i.e. "pulled"),
+        // we need to have the animation move it back so none of the empty space is visible.
+        if (velocity == 0)
+        {
+            if (position < minPosition || position > maxPosition)
+            {
+                // Velocity is zero and we're past the end of the list.  We want the
+                // list to "snap" back to its resting position at the end.  We use a
+                // cubic easer curve so the snap has high initial velocity and
+                // gradually decelerates toward the resting point.
+                position = position < minPosition ? minPosition : maxPosition;
+                nowTime = addKeyframe(motionPath, nowTime + THROW_SETTLE_TIME, position, new Power(0, THROW_CURVE_EXPONENT));
+            }
+            else
+            {
+                // Velocity zero without being past the end of the list is a no-op.
+                return null;
+            }
+        }
+
+        // Each iteration of this loop adds one of more keyframes to the motion path and then
+        // updates the velocity and position values.  Once the velocity has decayed to zero,
+        // the motion path is complete.
+        while (velocity != 0.0)
+        {
+            if ((position < minPosition && velocity > 0) || (position > maxPosition && velocity < 0))
+            {
+                // We're past the end of the list and the velocity is directed further beyond
+                // the end.  In this case we want to overshoot the end of the list and then
+                // settle back to it.
+                var settlePosition:Number = position < minPosition ? minPosition : maxPosition;
+
+                // OVERSHOOT_CURVE_EXPONENT is the default initial slope of the easer function we use for the overshoot.
+                // This calculation scales the y axis (distance) of the overshoot so the actual slope matches the velocity.
+                var overshootPosition:Number = Math.round(position -
+                    ((velocity / OVERSHOOT_CURVE_EXPONENT) * THROW_OVERSHOOT_TIME));
+
+                nowTime = addKeyframe(motionPath, nowTime + THROW_OVERSHOOT_TIME,
+                    overshootPosition, new Power(0, OVERSHOOT_CURVE_EXPONENT));
+                nowTime = addKeyframe(motionPath, nowTime + THROW_SETTLE_TIME, settlePosition, new Sine(0.25));
+
+                // Clear the velocity to indicate that the motion path is complete.
+                velocity = 0;
+                position = settlePosition;
+            }
+            else
+            {
+                // Here we're going to do a "normal" throw.
+
+                var effectTime:Number = throwEffectTime;
+
+                var minVelocity:Number;
+                if (position < minPosition || position > maxPosition)
+                {
+                    // The throw is starting beyond the end of the list.  We need to enforce a minimum velocity
+                    // to make sure the throw makes it all the way back to the end (i.e. doesn't leave any blank area
+                    // exposed) and does so within THROW_SETTLE_TIME.  THROW_SETTLE_TIME needs to be consistently
+                    // adhered to in all cases where the tension of being beyond the end acts on the scroll position.
+
+                    // The minimum velocity is that which gets us back to the end position in exactly THROW_SETTLE_TIME milliseconds.
+                    minVelocity = ((position - (position < minPosition ? minPosition : maxPosition)) /
+                        THROW_SETTLE_TIME) * THROW_CURVE_EXPONENT;
+                    if (Math.abs(velocity) < Math.abs(minVelocity))
+                    {
+                        velocity = minVelocity;
+                        effectTime = THROW_SETTLE_TIME;
+                    }
+                }
+
+                // The easer function we use is 1-((1-x)^THROW_CURVE_EXPONENT), which has an initial slope of THROW_CURVE_EXPONENT.
+                // The x axis is scaled according to the throw duration we calculated above, so now we need
+                // to determine the correct y-axis scaling (i.e. throw distance) such that the initial
+                // slope matches the specified throw velocity.
+                var finalPosition:Number = Math.round(position - ((velocity / THROW_CURVE_EXPONENT) * effectTime));
+
+                if (finalPosition < minPosition || finalPosition > maxPosition)
+                {
+                    // The throw is going to hit the end of the list.  In this case we need to clip the
+                    // deceleration curve at the appropriate point.  We want the curve to look exactly as
+                    // it would if we were allowing the throw to go beyond the end of the list.  But the
+                    // keyframe we add here will stop exactly at the end.  The subsequent loop iteration
+                    // will add keyframes that describe the overshoot & settle behavior.
+
+                    var endPosition:Number = finalPosition < minPosition ? minPosition : maxPosition;
+
+                    // since easing function is f(t) = start + (final - start) * e(t)
+                    // e(t) = Math.pow(1 - t/throwEffectTime, 3)
+                    // We want to solve for t when e(t) = finalPosition
+                    // t = throwEffectTime*(1-(Math.pow(1-((endPosition-position)/(finalVSP-position)),1/3)));
+                    var partialTime:Number =
+                            effectTime*(1 - (Math.pow(1 - ((endPosition - position) / (finalPosition - position)), 1 / THROW_CURVE_EXPONENT)));
+
+                    // PartialExponentialCurve creates a portion of the throw easer curve, but scaled up to fill the
+                    // specified duration.
+                    nowTime = addKeyframe(motionPath, nowTime + partialTime, endPosition,
+                            new PartialExponentialCurve(THROW_CURVE_EXPONENT, partialTime / effectTime));
+
+                    // Set the position just past the end of the list for the next loop iteration.
+                    if (finalPosition < minPosition)
+                        position = minPosition - 1;
+                    if (finalPosition > maxPosition)
+                        position = maxPosition + 1;
+
+                    // Set the velocity for the next loop iteration.  Make sure it matches the actual velocity in effect when the
+                    // throw reaches the end of the list.
+                    //
+                    // The easer function we use for the throw is 1-((1-x)^3), the derivative of which is 3*x^2-6*x+3.
+                    // (I used http://www.numberempire.com/derivatives.php to differentiate the easer function).
+                    // Since the slope of a curve function at any point x (i.e. f(x)) is the value of the derivative at x (i.e. f'(x)),
+                    // we can use this to determine the velocity of the throw at the point it reached the beginning of the bounce.
+                    var x:Number = partialTime / effectTime;
+                    var y:Number =  3 * Math.pow(x, 2) - 6 * x + 3; // NOTE: This calculation must be matched to the THROW_CURVE_EXPONENT value.
+                    velocity = -y * (finalPosition - position) / effectTime;
+                }
+                else
+                {
+                    // This is the simplest case.  The throw both begins and ends on the list (i.e. not past the
+                    // end of the list).  We create a single keyframe and clear the velocity to indicate that the
+                    // motion path is complete.
+                    nowTime = addKeyframe(motionPath, nowTime + effectTime, finalPosition, new Power(0, THROW_CURVE_EXPONENT));
+                    velocity = 0;
+                }
+            }
+        }
+        return motionPath;
+    }
+
+    /**
+     *  @private
      *  Set up the effect to be used for the throw animation
-     *  FIXME (rfrishbe): this could use some work
-     */
-    private function setUpThrowEffect(velocityX:Number, velocityY:Number, distanceRatio:Point):void
+     */
+    private function setUpThrowEffect(velocityX:Number, velocityY:Number):Boolean
     {
         // create throwEffect if we haven't already
         if (!throwEffect)
@@ -1170,105 +1354,70 @@

             // effect and easer stuff should be combined some or maybe we just need one
             // touch specific class rather than two
-            var throwEaser:IEaser = new Power(0, 4);
+            var throwEaser:IEaser = new Power(0,THROW_CURVE_EXPONENT);
             throwEffect.easer = throwEaser;
         }

         // Calculate the effect duration
-        var throwEffectTime:int = calculateThrowEffectTime(distanceRatio);
+        var throwEffectTime:int = calculateThrowEffectTime(velocityX,velocityY);
         throwEffect.duration = throwEffectTime;

-        // calculate the finalVSP/finalHSP
-        var finalHSP:Number = viewport.horizontalScrollPosition;
-        var finalVSP:Number = viewport.verticalScrollPosition;
-
-        // figure out where we're scrolling to
+        var throwEffectMotionPaths:Vector.<MotionPath> = new Vector.<MotionPath>();
+
+        scrollingHorizontally = false;
+        var horizontalTime:Number = 0;
+        var finalKeyframe:int;
         if (scrollerLayout && scrollerLayout.canScrollHorizontally)
         {
             var hsp:Number = viewport.horizontalScrollPosition;
             var viewportWidth:Number = isNaN(viewport.width) ? 0 : viewport.width;
             var cWidth:Number = viewport.contentWidth;
-            var maxWidth:Number = Math.max(0, (cWidth == 0) ? viewport.horizontalScrollPosition : cWidth - viewportWidth);
-
-            // we want the throw to go half the distance it would if its velocity remained constant
-            finalHSP = viewport.horizontalScrollPosition - (velocityX * throwEffectTime * 0.5);
-
-            // Make sure the animation ends on a nice round number so extra scroll position
-            // property changes don't occur after the touchInteractionEnd event is dispatched.
-            finalHSP = Math.round(finalHSP);
-        }
-
+            var maxWidth:Number =
+                    Math.max(0, (cWidth == 0) ? viewport.horizontalScrollPosition : cWidth - viewportWidth);
+
+            var horizontalMP:SimpleMotionPath =
+                    createThrowMotionPath("horizontalScrollPosition",velocityX,hsp,0,maxWidth,throwEffectTime);
+            if (horizontalMP)
+            {
+                throwEffectMotionPaths.push(horizontalMP);
+                horizontalTime = horizontalMP.keyframes[horizontalMP.keyframes.length-1].time;
+                scrollingHorizontally = true;
+            }
+        }
+
+        scrollingVertically = false;
+        var verticalTime:Number = 0;
         if (scrollerLayout && scrollerLayout.canScrollVertically)
         {
             var vsp:Number = viewport.verticalScrollPosition;
             var viewportHeight:Number = isNaN(viewport.height) ? 0 : viewport.height;
             var cHeight:Number = viewport.contentHeight;
-            var maxHeight:Number = Math.max(0, (cHeight == 0) ? viewport.verticalScrollPosition : cHeight - viewportHeight);
-
-            // we want the throw to go half the distance it would if its velocity remained constant
-            finalVSP = viewport.verticalScrollPosition - (velocityY * throwEffectTime * 0.5);
-
-            // Make sure the animation ends on a nice round number so extra scroll position
-            // property changes don't occur after the touchInteractionEnd event is dispatched.
-            finalVSP = Math.round(finalVSP);
-        }
-
-        // maybe use motion paths with more keyframes for the bounce effect??
-
-        var throwEffectMotionPaths:Vector.<MotionPath> = new Vector.<MotionPath>();
-
-        // set up a simple motion path for the animation from our current hsp/vsp to
-        // the final hsp/vsp.
-        var timeToReachHSP:Number = 0;
-        var timeToReachVSP:Number = 0;
-
-        if (scrollerLayout && scrollerLayout.canScrollHorizontally)
-        {
-            var horizontalMP:MotionPath = new SimpleMotionPath("horizontalScrollPosition", hsp, finalHSP);
-            var hspToUse:Number = Math.min(Math.max(finalHSP,0), maxWidth);
-
-            // see formula in VSP section.
-            if (finalHSP == hspToUse)
-                timeToReachHSP = throwEffectTime;
-            else
-                timeToReachHSP = throwEffectTime*(1-(Math.pow(1-((hspToUse-hsp)/(finalHSP-hsp)),.25)));
-
-            horizontalMP.keyframes = Vector.<Keyframe>([new Keyframe(0, null), new Keyframe(timeToReachHSP, hspToUse)]);
-            throwEffectMotionPaths.push(horizontalMP);
-            scrollingHorizontally = true;
+            var maxHeight:Number =
+                    Math.max(0, (cHeight == 0) ? viewport.verticalScrollPosition : cHeight - viewportHeight);
+
+            var verticalMP:SimpleMotionPath =
+                    createThrowMotionPath("verticalScrollPosition",velocityY,vsp,0,maxHeight,throwEffectTime);
+            if (verticalMP)
+            {
+                throwEffectMotionPaths.push(verticalMP);
+                verticalTime = verticalMP.keyframes[verticalMP.keyframes.length-1].time;
+                scrollingVertically = true;
+            }
+        }
+
+        if (throwEffectMotionPaths.length == 0)
+        {
+            touchScrollHelper.endTouchScroll();
+            return false;
         }
         else
         {
-            scrollingHorizontally = false;
-        }
-
-        if (scrollerLayout && scrollerLayout.canScrollVertically)
-        {
-            var verticalMP:SimpleMotionPath = new SimpleMotionPath("verticalScrollPosition");
-            var vspToUse:Number = Math.min(Math.max(finalVSP,0), maxHeight);
-
-            // since easing function is f(t) = start + (final - start) * e(t)
-            // e(t) = Math.pow(1 - t/throwEffectTime, 4)
-            // We want to solve for t when e(t) = vspToUse
-            // t = throwEffectTime*(1-(Math.pow(1-((vspToUse-vsp)/(finalVSP-vsp)),.25)));
-            if (finalVSP == vspToUse)
-                timeToReachVSP = throwEffectTime;
-            else
-                timeToReachVSP = throwEffectTime*(1-(Math.pow(1-((vspToUse-vsp)/(finalVSP-vsp)),.25)));
-
-            verticalMP.keyframes = Vector.<Keyframe>([new Keyframe(0, null), new Keyframe(timeToReachVSP, vspToUse)]);
-            throwEffectMotionPaths.push(verticalMP);
-            scrollingVertically = true;
-        }
-        else
-        {
-            scrollingVertically = false;
-        }
-
-        throwEffect.duration = Math.max(timeToReachVSP, timeToReachHSP);
-
-        throwEffect.motionPaths = throwEffectMotionPaths;
-    }
+            throwEffect.duration = Math.max(horizontalTime, verticalTime);
+            throwEffect.motionPaths = throwEffectMotionPaths;
+            return true;
+        }
+    }
+

     /**
      *  @private
@@ -1664,6 +1813,31 @@

     /**
      *  @private
+     *  Stop the effect if it's currently playing and prepare for a possible scroll
+     */
+    private function stopThrowEffectOnMouseDown():void
+    {
+        if (throwEffect && throwEffect.isPlaying)
+        {
+            // stop the effect.  we don't want to move it to its final value...we want to stop it in place
+            stoppedPreemptively = true;
+            throwEffect.stop();
+
+            // Snap the scroll position to the content in case the empty space beyond the edge was visible
+            // due to bounce/pull.
+            var maxHsp:Number = viewport.contentWidth > viewport.width ? viewport.contentWidth-viewport.width : 0;
+            viewport.horizontalScrollPosition = Math.min(Math.max(0,viewport.horizontalScrollPosition),maxHsp);
+            var maxVsp:Number = viewport.contentHeight > viewport.height ? viewport.contentHeight-viewport.height : 0;
+            viewport.verticalScrollPosition = Math.min(Math.max(0,viewport.verticalScrollPosition),maxVsp);
+
+            // get new values in case we start scrolling again
+            hspBeforeTouchScroll = viewport.horizontalScrollPosition;
+            vspBeforeTouchScroll = viewport.verticalScrollPosition;
+        }
+    }
+
+    /**
+     *  @private
      *  Event listeners added while a scroll/throw animation is in effect
      */
     private function touchScrolling_captureMouseHandler(event:MouseEvent):void
@@ -1674,17 +1848,7 @@
                 if (!captureNextMouseDown)
                     return;

-                if (throwEffect && throwEffect.isPlaying)
-                {
-                    // stop the effect.  we don't want to move it to its final value...we want to stop it in place
-                    // FIXME (rfrishbe): however if it's below 0 or above maxVSP, we should snap it to these values
-                    stoppedPreemptively = true;
-                    throwEffect.stop();
-
-                    // get new values in case we start scrolling again
-                    hspBeforeTouchScroll = viewport.horizontalScrollPosition;
-                    vspBeforeTouchScroll = viewport.verticalScrollPosition;
-                }
+                stopThrowEffectOnMouseDown();

                 touchScrollHelper.startScrollWatch(event);
                 event.stopImmediatePropagation();
@@ -1704,8 +1868,7 @@
      */
     private function mouseDownHandler(event:MouseEvent):void
     {
-        // TODO (rfrishbe): if currently scrolling and we have spring/pull effects,
-        // we should stop scrolling and move the VSP/HSP in to range (0, maxVSP).
+        stopThrowEffectOnMouseDown();

         captureNextClick = false;

@@ -1729,21 +1892,32 @@
         var newHSP:Number = hspBeforeTouchScroll - xMove;
         var newVSP:Number = vspBeforeTouchScroll - yMove;

-        // use min and max to clamp hsp/vsp values for now.  At some point we may allow them to
-        // "pull" it in to the negatives, but now not
         var hsp:Number = viewport.horizontalScrollPosition;
         var viewportWidth:Number = isNaN(viewport.width) ? 0 : viewport.width;
         var cWidth:Number = viewport.contentWidth;
         var maxWidth:Number = Math.max(0, (cWidth == 0) ? viewport.horizontalScrollPosition : cWidth - viewportWidth);

+        // If we're pulling the list past its end, we want it to move
+        // only a portion of the finger distance to simulate tension.
+        if (newHSP < 0)
+            newHSP = Math.round(newHSP * PULL_TENSION_RATIO);
+        if (newHSP > maxWidth)
+            newHSP = Math.round(maxWidth + ((newHSP-maxWidth) * PULL_TENSION_RATIO));
+
         var vsp:Number = viewport.verticalScrollPosition;
         var viewportHeight:Number = isNaN(viewport.height) ? 0 : viewport.height;
         var cHeight:Number = viewport.contentHeight;
         var maxHeight:Number = Math.max(0, (cHeight == 0) ? viewport.verticalScrollPosition : cHeight - viewportHeight);

+        if (newVSP < 0)
+            newVSP = Math.round(newVSP * PULL_TENSION_RATIO);
+
+        if (newVSP > maxHeight)
+            newVSP = Math.round(maxHeight + ((newVSP-maxHeight) * PULL_TENSION_RATIO));
+
         // clamp the values here
-        newHSP = Math.min(Math.max(newHSP,0), maxWidth);
-        newVSP = Math.min(Math.max(newVSP,0), maxHeight);
+        newHSP = Math.min(Math.max(newHSP, -viewportWidth), maxWidth+viewportWidth);
+        newVSP = Math.min(Math.max(newVSP, -viewportHeight), maxHeight+viewportHeight);

         viewport.horizontalScrollPosition = newHSP;
         viewport.verticalScrollPosition = newVSP;
@@ -1759,17 +1933,18 @@
         if (stoppedPreemptively)
             return;

-        touchScrollHelper.touchScrollThrowAnimationEnd();
+        touchScrollHelper.endTouchScroll();
     }

     /**
      *  @private
      */
-    mx_internal function performThrow(velocityX:Number, velocityY:Number, distanceRatio:Point):void
+    mx_internal function performThrow(velocityX:Number, velocityY:Number):void
     {
         stoppedPreemptively = false;
-        setUpThrowEffect(velocityX, velocityY, distanceRatio);
-        throwEffect.play();
+
+        if (setUpThrowEffect(velocityX, velocityY))
+            throwEffect.play();
     }

     /**
@@ -2293,30 +2468,14 @@
         }
         averageDt /= len-1;

-        // use the amount they've used as well as the velocity to denote how far to throw the list.
-        // to do this, we multiply by the ratio of how far they moved with respect to the screen size
-        // available size of the scroller.
-
-        // allow 0% faster if they used everything
-        const RATIO_TO_USE:Number = 1.0;
-
 		// if off screen for some reason, let's end scrolling:
 		if (!scroller.stage)
 		{
-			// don't do anything
-			scrollEndEvent = new TouchInteractionEvent(TouchInteractionEvent.TOUCH_INTERACTION_END, true);
-			scrollEndEvent.relatedObject = scroller;
-			scrollEndEvent.reason = TouchInteractionReason.SCROLL;
-			dispatchBubblingEventOnMouseDownedDisplayObject(scrollEndEvent);
+            endTouchScroll();
 			return;
 		}

-        // for the max size, we couldn't decide between using screen width/height or
-        // scroller width/height, so we're using a weighted average for it
-        var widthToUseForRatio:Number = (2*scroller.width + scroller.stage.stageWidth)/3;
-        var heightToUseForRatio:Number = (2*scroller.height + scroller.stage.stageHeight)/3;
         var lastMouseEventPoint:Point = mouseEventCoordinatesHistory[endIndex];
-        var movedRatio:Point = new Point(Math.abs(RATIO_TO_USE*lastMouseEventPoint.x/widthToUseForRatio), Math.abs(RATIO_TO_USE*lastMouseEventPoint.y/heightToUseForRatio));

         // calculate the last velocity and make sure there was no pause that occurred
         var indexBeforeLast:int = ((mouseEventLength - 2) % EVENT_HISTORY_LENGTH);
@@ -2325,46 +2484,32 @@
         lastVelocity.x /= lastDt;
         lastVelocity.y /= lastDt;

-
         var minVelocityPixels:Number = MIN_START_VELOCITY_IPS * flash.system.Capabilities.screenDPI / 1000;

         var scrollEndEvent:TouchInteractionEvent;

+        // calculate the velocity using a weighted average
+        var throwVelocity:Point = calculateThrowVelocity();
+        if (throwVelocity.length <= minVelocityPixels)
+        {
+            throwVelocity.x = 0;
+            throwVelocity.y = 0;
+        }
+
         // FIXME (rfrishbe): should be minXVelocity, minYVelocity, minDiagonalVelocity
         // FIXME (rfrishbe): this should be parameterized better and the heuristic should
         // be documented better
         if ( (lastDt >= 3*averageDt) &&
             (lastVelocity.length <= minVelocityPixels))
         {
-            isScrolling = false;
-
-            // don't do anything
-            scrollEndEvent = new TouchInteractionEvent(TouchInteractionEvent.TOUCH_INTERACTION_END, true);
-            scrollEndEvent.relatedObject = scroller;
-            scrollEndEvent.reason = TouchInteractionReason.SCROLL;
-			dispatchBubblingEventOnMouseDownedDisplayObject(scrollEndEvent);
-            return;
-        }
-
-        // calculate the velocity using a weighted average
-        var throwVelocity:Point = calculateThrowVelocity();
-
-        // if the velocity is greater than the minimum velocity, start throwing
-        if (throwVelocity.length > minVelocityPixels)
-        {
-            scroller.performThrow(throwVelocity.x, throwVelocity.y, movedRatio);
-        }
-        else
-        {
-            // otherwise, end the scroll operation
-            isScrolling = false;
-
-            // don't do anything
-            scrollEndEvent = new TouchInteractionEvent(TouchInteractionEvent.TOUCH_INTERACTION_END, true);
-            scrollEndEvent.relatedObject = scroller;
-            scrollEndEvent.reason = TouchInteractionReason.SCROLL;
-			dispatchBubblingEventOnMouseDownedDisplayObject(scrollEndEvent);
-        }
+            throwVelocity.x = 0;
+            throwVelocity.y = 0;
+        }
+
+        // Note that we always call performThrow - even when the velocity is zero.
+        // This is needed because we may be past the end of the list and need an
+        // animation to get us back.
+        scroller.performThrow(throwVelocity.x, throwVelocity.y);
     }

     /**
@@ -2403,14 +2548,20 @@
             var dx:Number = mouseEventCoordinatesHistory[nextIndex].x - mouseEventCoordinatesHistory[currentIndex].x;
             var dy:Number = mouseEventCoordinatesHistory[nextIndex].y - mouseEventCoordinatesHistory[currentIndex].y;

-            // calculate a weighted sum for velocities
-            weightedSumX += (dx/dt) * VELOCITY_WEIGHTS[i];
-            weightedSumY += (dy/dt) * VELOCITY_WEIGHTS[i];
-            totalWeight += VELOCITY_WEIGHTS[i];
+            if (dt != 0)
+            {
+                // calculate a weighted sum for velocities
+                weightedSumX += (dx/dt) * VELOCITY_WEIGHTS[i];
+                weightedSumY += (dy/dt) * VELOCITY_WEIGHTS[i];
+                totalWeight += VELOCITY_WEIGHTS[i];
+            }

             currentIndex = nextIndex;
             i++;
         }
+
+        if (totalWeight == 0)
+            return new Point(0,0);

         // Limit the velocity to an absolute maximum
         var maxPixelsPerMS:Number = MAX_THROW_VELOCITY_IPS * flash.system.Capabilities.screenDPI / 1000;
@@ -2457,7 +2608,7 @@
      *  @private
      *  When the touchScrollThrow is over, we should dispatch a touchInteractionEnd.
      */
-    public function touchScrollThrowAnimationEnd():void
+    public function endTouchScroll():void
     {
         isScrolling = false;

@@ -2467,5 +2618,31 @@
 		dispatchBubblingEventOnMouseDownedDisplayObject(scrollEndEvent);
     }

-
 }
+
+import spark.effects.easing.EaseInOutBase;
+
+/**
+ *  @private
+ *  A custom ease-out-only easer class which animates along a specified
+ *  portion of an exponential curve.
+ */
+class PartialExponentialCurve extends EaseInOutBase
+{
+    public function PartialExponentialCurve(exponent:Number,xscale:Number)
+    {
+        super(0);
+        _exponent = exponent;
+        _xscale = xscale;
+        _ymult = 1 / (1 - Math.pow(1 - _xscale,_exponent));
+    }
+
+    override protected function easeOut(fraction:Number):Number
+    {
+        return _ymult * (1 - Math.pow(1 - fraction*_xscale, _exponent));
+    }
+    private var _xscale:Number;
+    private var _ymult:Number;
+    private var _exponent:Number;
+}
+


Transferred from the Adobe Open Source Subversion Repository

Revision: 8385
Author:   smgilson@adobe.com
Date:     2009-07-06T19:38:43.090419Z

Log Message:
-----------
ASDoc updates for Spark layouts and core

QE Notes: None
Doc Notes: None
Bugs: -
checkintests: passed

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/BasicLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/supportClasses/LayoutElementHelper.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/RowAlign.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/ISharedDisplayObject.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/VerticalAlign.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/MaskType.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/NavigationUnit.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/HorizontalLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/TileLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/SpriteVisualElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/supportClasses/LayoutBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/HorizontalAlign.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/DisplayObjectSharingMode.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/VerticalLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/ColumnAlign.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/TileOrientation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ILayoutElement.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1285004 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/layouts/ColumnAlign.as
+++ frameworks/projects/spark/src/spark/layouts/ColumnAlign.as
@@ -13,8 +13,8 @@
 {

 /**
- *  Enumerated type for the TileLayout's columnAlign
- *  property.
+ *  The ColumnAlign class defines the possible values for the
+ *  columnAlign property of the TileLayout class.
  *
  *  @see TileLayout#columnAlign
  *
@@ -26,7 +26,7 @@
 public final class ColumnAlign
 {
     /**
-     *  Does not justify the rows.
+     *  Do not justify the rows.
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -36,7 +36,7 @@
     public static const LEFT:String = "left";

     /**
-     *  Justifies the rows by increasing the vertical gap.
+     *  Justify the rows by increasing the vertical gap.
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -46,7 +46,7 @@
     public static const JUSTIFY_USING_GAP:String = "justifyUsingGap";

     /**
-     *  Justifies the rows by increasing the row height.
+     *  Justify the rows by increasing the row height.
      *
      *  @langversion 3.0
      *  @playerversion Flash 10


Switch Cloner class to cloning of objects by using ByteArray.

--- dolly-framework/src/main/actionscript/dolly/Cloner.as
+++ dolly-framework/src/main/actionscript/dolly/Cloner.as
@@ -3,7 +3,10 @@
 import dolly.core.dolly_internal;
 import dolly.core.errors.CloningError;
 import dolly.core.metadata.MetadataName;
+import dolly.utils.ClassUtil;
 import dolly.utils.PropertyUtil;
+
+import flash.utils.ByteArray;

 import flash.utils.Dictionary;

@@ -16,8 +19,14 @@

 public class Cloner {

+	private static var _isClassPreparedForCloningMap:Dictionary = new Dictionary();
+
 	private static function isTypeCloneable(type:Type):Boolean {
 		return type.hasMetadata(MetadataName.CLONEABLE);
+	}
+
+	private static function isTypePreparedForCloning(type:Type):Boolean {
+		return _isClassPreparedForCloningMap[type.clazz];
 	}

 	private static function failIfTypeIsNotCloneable(type:Type):void {
@@ -29,8 +38,18 @@
 		}
 	}

+	private static function prepareTypeForCloning(type:Type):void {
+		ClassUtil.registerAliasFor(type.clazz);
+
+		_isClassPreparedForCloningMap[type.clazz] = true;
+	}
+
 	dolly_internal static function findAllWritableFieldsForType(type:Type):Vector.<Field> {
 		failIfTypeIsNotCloneable(type);
+
+		if (!isTypePreparedForCloning(type)) {
+			prepareTypeForCloning(type);
+		}

 		const result:Vector.<Field> = new Vector.<Field>();

@@ -52,12 +71,25 @@
 			type = Type.forInstance(source);
 		}

+		if(!isTypePreparedForCloning(type)) {
+			prepareTypeForCloning(type);
+		}
+
 		const fieldsToClone:Vector.<Field> = findAllWritableFieldsForType(type);
-		const clonedInstance:* = new (type.clazz)();

 		for each(var field:Field in fieldsToClone) {
-			PropertyUtil.cloneProperty(source, clonedInstance, field.name);
+//			PropertyUtil.cloneProperty(source, clonedInstance, field.name);
+			var fieldType:Type = field.type;
+			if(isTypeCloneable(fieldType) && !isTypePreparedForCloning(fieldType)) {
+				prepareTypeForCloning(fieldType);
+			}
 		}
+
+		const byteArray:ByteArray = new ByteArray();
+		byteArray.writeObject(source);
+		byteArray.position = 0;
+
+		const clonedInstance:* = byteArray.readObject();

 		return clonedInstance;
 	}


Transferred from the Adobe Open Source Subversion Repository

Revision: 23246
Author:   cframpto@adobe.com
Date:     2011-12-20T17:40:08.069454Z

Log Message:
-----------
Rollback 23243.  If comment followed header it was stripped as well.

Modified Paths:
--------------
2361 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1252807 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/charts/src/mx/charts/AxisLabel.as
+++ frameworks/projects/charts/src/mx/charts/AxisLabel.as
@@ -1,3 +1,13 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2009 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////

 package mx.charts
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 3605
Author:   shodgson@adobe.com
Date:     2008-10-13T22:51:11.374492Z

Log Message:
-----------
Removed [ExcludeClass] metadata from several classes per doc request.

Bug: LCDS-386 - Remove [ExcludeClass] from several classes
QA: No
Doc: Yes
Checkintests Pass: Yes

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/soap/ISOAPDecoder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/events/XMLLoadEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/xml/IXMLEncoder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/soap/ISOAPEncoder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/events/WSDLLoadEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/xml/IXMLDecoder.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1274530 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/rpc/src/mx/rpc/xml/IXMLDecoder.as
+++ frameworks/projects/rpc/src/mx/rpc/xml/IXMLDecoder.as
@@ -11,8 +11,6 @@

 package mx.rpc.xml
 {
-
-[ExcludeClass]

 /**
  * Decodes an XML document to an ActionScript object graph based on XML


Transferred from the Adobe Open Source Subversion Repository

Revision: 23243
Author:   cframpto@adobe.com
Date:     2011-12-20T00:59:57.384047Z

Log Message:
-----------
In frameworks, remove Adobe headers from all files except xml/mxml file types.  There are also a few .txt files that are license files that I didn't touch yet.

Modified Paths:
--------------
2361 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1274700 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/rpc/src/mx/utils/RPCStringUtil.as
+++ frameworks/projects/rpc/src/mx/utils/RPCStringUtil.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2005-2007 Adobe Systems Incorporated
-//  All Rights Reserved.
-//
-//  NOTICE: Adobe permits you to use, modify, and distribute this file
-//  in accordance with the terms of the license agreement accompanying it.
-//
-////////////////////////////////////////////////////////////////////////////////

 package mx.utils
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 23243
Author:   cframpto@adobe.com
Date:     2011-12-20T00:59:57.384047Z

Log Message:
-----------
In frameworks, remove Adobe headers from all files except xml/mxml file types.  There are also a few .txt files that are license files that I didn't touch yet.

Modified Paths:
--------------
2361 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1268337 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/mx/src/mx/controls/NavBar.as
+++ frameworks/projects/mx/src/mx/controls/NavBar.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2003-2007 Adobe Systems Incorporated
-//  All Rights Reserved.
-//
-//  NOTICE: Adobe permits you to use, modify, and distribute this file
-//  in accordance with the terms of the license agreement accompanying it.
-//
-////////////////////////////////////////////////////////////////////////////////

 package mx.controls
 {


XIFF-104: RFC 6122 linking

XIFF-104: RFC 6122 linking

--- src/org/igniterealtime/xiff/core/AbstractJID.as
+++ src/org/igniterealtime/xiff/core/AbstractJID.as
@@ -216,54 +216,62 @@
 		/**
 		 * The resource portion of the JID.
 		 *
-		 * Ensure that the resourcepart of an XMPP address is at
-least one byte in length and at most 1023 bytes in length.
-		 *
-		 * The resourcepart of a JID is an optional identifier placed after the
-domainpart and separated from the latter by the ’/’ character. A
-resourcepart can modify either a <localpart@domainpart> address or a
-mere <domainpart> address. Typically a resourcepart uniquely
-identifies a specific connection (e.g., a device or location) or
-object (e.g., an occupant in a multi-user chat room) belonging to the
-entity associated with an XMPP localpart at a domain (i.e.,
-<localpart@domainpart/resourcepart>).
-A resourcepart MUST be formatted such that the Resourceprep profile
-of [STRINGPREP] can be applied without failing (see Appendix B).
-Before comparing two resourceparts, an application MUST first ensure
-that the Resourceprep profile has been applied to each identifier
-(the profile need not be applied each time a comparison is made, as
-long as it has been applied before comparison).
-A resourcepart MUST NOT be zero bytes in length and MUST NOT be more
-than 1023 bytes in length. This rule is to be enforced after any
-mapping or normalization resulting from application of the
-Resourceprep profile of stringprep (e.g., in Resourceprep some
-characters can be mapped to nothing, which might result in a string
-of zero length).
-Informational Note: For historical reasons, the term "resource
-identifier" is often used in XMPP to refer to the optional portion
-of an XMPP address that follows the domainpart and the "/"
-separator character; to help prevent confusion between an XMPP
-"resource identifier" and the meanings of "resource" and
-"identifier" provided in Section 1.1 of [URI], this specification
-uses the term "resourcepart" instead of "resource identifier" (as
-in RFC 3920).
-
-XMPP entities SHOULD consider resourceparts to be opaque strings and
-SHOULD NOT impute meaning to any given resourcepart. In particular:
-o Use of the ’/’ character as a separator between the domainpart and
-the resourcepart does not imply that XMPP addresses are
-hierarchical in the way that, say, HTTP addresses are
-hierarchical; thus for example an XMPP address of the form
-<localpart@domainpart/foo/bar> does not identify a resource "bar"
-that exists below a resource "foo" in a hierarchy of resources
-associated with the entity "localpart@domain".
-o The ’@’ character is allowed in the resourcepart and is often used
-in the "nick" shown in XMPP chatrooms. For example, the JID
-<room@chat.example.com/user@host> describes an entity who is an
-occupant of the room <room@chat.example.com> with an (asserted)
-nick of <user@host>. However, chatroom services do not
-necessarily check such an asserted nick against the occupant’s
-real JID.
+		 *
Ensure that the resourcepart of an XMPP address is at
+		 * least one byte in length and at most 1023 bytes in length.

+		 *
+		 *
The resourcepart of a JID is an optional identifier placed after the
+		 * domainpart and separated from the latter by the ’/’ character. A
+		 * resourcepart can modify either a <localpart@domainpart> address or a
+		 * mere <domainpart> address. Typically a resourcepart uniquely
+		 * identifies a specific connection (e.g., a device or location) or
+		 * object (e.g., an occupant in a multi-user chat room) belonging to the
+		 * entity associated with an XMPP localpart at a domain (i.e.,
+		 * <localpart@domainpart/resourcepart>).

+		 *
+		 *
A resourcepart MUST be formatted such that the Resourceprep profile
+		 * of [STRINGPREP] can be applied without failing (see Appendix B).
+		 * Before comparing two resourceparts, an application MUST first ensure
+		 * that the Resourceprep profile has been applied to each identifier
+		 * (the profile need not be applied each time a comparison is made, as
+		 * long as it has been applied before comparison).

+		 *
+		 *
A resourcepart MUST NOT be zero bytes in length and MUST NOT be more
+		 * than 1023 bytes in length. This rule is to be enforced after any
+		 * mapping or normalization resulting from application of the
+		 * Resourceprep profile of stringprep (e.g., in Resourceprep some
+		 * characters can be mapped to nothing, which might result in a string
+		 * of zero length).

+		 *
+		 *
Informational Note: For historical reasons, the term "resource
+		 * identifier" is often used in XMPP to refer to the optional portion
+		 * of an XMPP address that follows the domainpart and the "/"
+		 * separator character; to help prevent confusion between an XMPP
+		 * "resource identifier" and the meanings of "resource" and
+		 * "identifier" provided in Section 1.1 of [URI], this specification
+		 * uses the term "resourcepart" instead of "resource identifier" (as
+		 * in RFC 3920).

+		 *
+		 *
XMPP entities SHOULD consider resourceparts to be opaque strings and
+		 * SHOULD NOT impute meaning to any given resourcepart. In particular:

+		 *
+		 *

+		 *
Use of the ’/’ character as a separator between the domainpart and
+		 * the resourcepart does not imply that XMPP addresses are
+		 * hierarchical in the way that, say, HTTP addresses are
+		 * hierarchical; thus for example an XMPP address of the form
+		 * <localpart@domainpart/foo/bar> does not identify a resource "bar"
+		 * that exists below a resource "foo" in a hierarchy of resources
+		 * associated with the entity "localpart@domain".

+		 *
The ’@’ character is allowed in the resourcepart and is often used
+		 * in the "nick" shown in XMPP chatrooms. For example, the JID
+		 * <room@chat.example.com/user@host> describes an entity who is an
+		 * occupant of the room <room@chat.example.com> with an (asserted)
+		 * nick of <user@host>. However, chatroom services do not
+		 * necessarily check such an asserted nick against the occupant’s
+		 * real JID.

+		 *

+		 *
+		 * @see http://tools.ietf.org/html/rfc6122#section-2.4
 		 */
 		public function get resource():String
 		{
@@ -285,31 +293,32 @@
 		/**
 		 * The localpart (used to be called 'node') portion of the JID.
 		 *
-		 * Ensure that the localpart of an XMPP address is at
-least one byte in length and at most 1023 bytes in length
-		 *
-		 * The localpart of a JID is an optional identifier placed before the
-domainpart and separated from the latter by the ’@’ character.
-Typically a localpart uniquely identifies the entity requesting and
-using network access provided by a server (i.e., a local account),
-although it can also represent other kinds of entities (e.g., a chat
-room associated with a multi-user chat service). The entity
-represented by an XMPP localpart is addressed within the context of a
-specific domain (i.e., <localpart@domainpart>).
-A localpart MUST be formatted such that the Nodeprep profile of
-[STRINGPREP] can be applied without failing (see Appendix A). Before
-comparing two localparts, an application MUST first ensure that the
-Nodeprep profile has been applied to each identifier (the profile
-need not be applied each time a comparison is made, as long as it has
-been applied before comparison).
-A localpart MUST NOT be zero bytes in length and MUST NOT be more
-than 1023 bytes in length. This rule is to be enforced after any
-mapping or normalization resulting from application of the Nodeprep
-profile of stringprep (e.g., in Nodeprep some characters can be
-mapped to nothing, which might result in a string of zero length).
-
-
-
+		 *
Ensure that the localpart of an XMPP address is at
+		 * least one byte in length and at most 1023 bytes in length.

+		 *
+		 *
The localpart of a JID is an optional identifier placed before the
+		 * domainpart and separated from the latter by the ’@’ character.
+		 * Typically a localpart uniquely identifies the entity requesting and
+		 * using network access provided by a server (i.e., a local account),
+		 * although it can also represent other kinds of entities (e.g., a chat
+		 * room associated with a multi-user chat service). The entity
+		 * represented by an XMPP localpart is addressed within the context of a
+		 * specific domain (i.e., <localpart@domainpart>).

+		 *
+		 *
A localpart MUST be formatted such that the Nodeprep profile of
+		 * [STRINGPREP] can be applied without failing (see Appendix A). Before
+		 * comparing two localparts, an application MUST first ensure that the
+		 * Nodeprep profile has been applied to each identifier (the profile
+		 * need not be applied each time a comparison is made, as long as it has
+		 * been applied before comparison).

+		 *
+		 *
A localpart MUST NOT be zero bytes in length and MUST NOT be more
+		 * than 1023 bytes in length. This rule is to be enforced after any
+		 * mapping or normalization resulting from application of the Nodeprep
+		 * profile of stringprep (e.g., in Nodeprep some characters can be
+		 * mapped to nothing, which might result in a string of zero length).

+		 *
+		 * @see http://tools.ietf.org/html/rfc6122#section-2.3
 		 */
 		public function get localpart():String
 		{
@@ -331,75 +340,83 @@
 		/**
 		 * The domain portion of the JID.
 		 *
-		 * Ensure that the domainpart of an XMPP address is at
-least one byte in length and at most 1023 bytes in length, and
-conforms to the underlying length limits of the DNS.
-		 *
-		 * The domainpart of a JID is that portion after the ’@’ character (if
-any) and before the ’/’ character (if any); it is the primary
-identifier and is the only REQUIRED element of a JID (a mere
-domainpart is a valid JID). Typically a domainpart identifies the
-"home" server to which clients connect for XML routing and data
-management functionality. However, it is not necessary for an XMPP
-domainpart to identify an entity that provides core XMPP server
-functionality (e.g., a domainpart can identify an entity such as a
-multi-user chat service, a publish-subscribe service, or a user
-directory).
-The domainpart for every XMPP service MUST be a fully qualified
-domain name (FQDN; see [DNS]), IPv4 address, IPv6 address, or
-unqualified hostname (i.e., a text label that is resolvable on a
-local network).
-Interoperability Note: Domainparts that are IP addresses might not
-be accepted by other services for the sake of server-to-server
-communication, and domainparts that are unqualified hostnames
-cannot be used on public networks because they are resolvable only
-on a local network.
-If the domainpart includes a final character considered to be a label
-separator (dot) by [IDNA2003] or [DNS], this character MUST be
-stripped from the domainpart before the JID of which it is a part is
-used for the purpose of routing an XML stanza, comparing against
-another JID, or constructing an [XMPP-URI]. In particular, the
-character MUST be stripped before any other canonicalization steps
-are taken, such as application of the [NAMEPREP] profile of
-[STRINGPREP] or completion of the ToASCII operation as described in
-[IDNA2003].
-A domainpart consisting of a fully qualified domain name MUST be an
-"internationalized domain name" as defined in [IDNA2003]; that is, it
-MUST be "a domain name in which every label is an internationalized
-label" and MUST follow the rules for construction of
-internationalized domain names specified in [IDNA2003]. When
-preparing a text label (consisting of a sequence of UTF-8 encoded
-Unicode code points) for representation as an internationalized label
-in the process of constructing an XMPP domainpart or comparing two
-XMPP domainparts, an application MUST ensure that for each text label
-it is possible to apply without failing the ToASCII operation
-specified in [IDNA2003] with the UseSTD3ASCIIRules flag set (thus
-forbidding ASCII code points other than letters, digits, and
-hyphens). If the ToASCII operation can be applied without failing,
-then the label is an internationalized label. (Note: The ToASCII
-operation includes application of the [NAMEPREP] profile of
-[STRINGPREP] and encoding using the algorithm specified in
-[PUNYCODE]; for details, see [IDNA2003].) Although XMPP applications
-do not communicate the output of the ToASCII operation (called an
-"ACE label") over the wire, it MUST be possible to apply that
-operation without failing to each internationalized label. If an
-XMPP application receives as input an ACE label, it SHOULD convert
-that ACE label to an internationalized label using the ToUnicode
-operation (see [IDNA2003]) before including the label in an XMPP
-domainpart that will be communicated over the wire on an XMPP network
-(however, instead of converting the label, there are legitimate
-reasons why an application might instead refuse the input altogether
-and return an error to the entity that provided the offending data).
-A domainpart MUST NOT be zero bytes in length and MUST NOT be more
-than 1023 bytes in length. This rule is to be enforced after any
-mapping or normalization resulting from application of the Nameprep
-profile of stringprep (e.g., in Nameprep some characters can be
-mapped to nothing, which might result in a string of zero length).
-Naturally, the length limits of [DNS] apply, and nothing in this
-document is to be interpreted as overriding those more fundamental
-limits.
-In the terms of IDNA2008 [IDNA-DEFS], the domainpart of a JID is a
-"domain name slot".
+		 *
Ensure that the domainpart of an XMPP address is at
+		 * least one byte in length and at most 1023 bytes in length, and
+		 * conforms to the underlying length limits of the DNS.

+		 *
+		 *
The domainpart of a JID is that portion after the ’@’ character (if
+		 * any) and before the ’/’ character (if any); it is the primary
+		 * identifier and is the only REQUIRED element of a JID (a mere
+		 * domainpart is a valid JID). Typically a domainpart identifies the
+		 * "home" server to which clients connect for XML routing and data
+		 * management functionality. However, it is not necessary for an XMPP
+		 * domainpart to identify an entity that provides core XMPP server
+		 * functionality (e.g., a domainpart can identify an entity such as a
+		 * multi-user chat service, a publish-subscribe service, or a user
+		 * directory).

+		 *
+		 *
The domainpart for every XMPP service MUST be a fully qualified
+		 * domain name (FQDN; see [DNS]), IPv4 address, IPv6 address, or
+		 * unqualified hostname (i.e., a text label that is resolvable on a
+		 * local network).

+		 *
+		 *
Interoperability Note: Domainparts that are IP addresses might not
+		 * be accepted by other services for the sake of server-to-server
+		 * communication, and domainparts that are unqualified hostnames
+		 * cannot be used on public networks because they are resolvable only
+		 * on a local network.

+		 *
+		 *
If the domainpart includes a final character considered to be a label
+		 * separator (dot) by [IDNA2003] or [DNS], this character MUST be
+		 * stripped from the domainpart before the JID of which it is a part is
+		 * used for the purpose of routing an XML stanza, comparing against
+		 * another JID, or constructing an [XMPP-URI]. In particular, the
+		 * character MUST be stripped before any other canonicalization steps
+		 * are taken, such as application of the [NAMEPREP] profile of
+		 * [STRINGPREP] or completion of the ToASCII operation as described in
+		 * [IDNA2003].

+		 *
+		 *
A domainpart consisting of a fully qualified domain name MUST be an
+		 * "internationalized domain name" as defined in [IDNA2003]; that is, it
+		 * MUST be "a domain name in which every label is an internationalized
+		 * label" and MUST follow the rules for construction of
+		 * internationalized domain names specified in [IDNA2003]. When
+		 * preparing a text label (consisting of a sequence of UTF-8 encoded
+		 * Unicode code points) for representation as an internationalized label
+		 * in the process of constructing an XMPP domainpart or comparing two
+		 * XMPP domainparts, an application MUST ensure that for each text label
+		 * it is possible to apply without failing the ToASCII operation
+		 * specified in [IDNA2003] with the UseSTD3ASCIIRules flag set (thus
+		 * forbidding ASCII code points other than letters, digits, and
+		 * hyphens). If the ToASCII operation can be applied without failing,
+		 * then the label is an internationalized label. (Note: The ToASCII
+		 * operation includes application of the [NAMEPREP] profile of
+		 * [STRINGPREP] and encoding using the algorithm specified in
+		 * [PUNYCODE]; for details, see [IDNA2003].) Although XMPP applications
+		 * do not communicate the output of the ToASCII operation (called an
+		 * "ACE label") over the wire, it MUST be possible to apply that
+		 * operation without failing to each internationalized label. If an
+		 * XMPP application receives as input an ACE label, it SHOULD convert
+		 * that ACE label to an internationalized label using the ToUnicode
+		 * operation (see [IDNA2003]) before including the label in an XMPP
+		 * domainpart that will be communicated over the wire on an XMPP network
+		 * (however, instead of converting the label, there are legitimate
+		 * reasons why an application might instead refuse the input altogether
+		 * and return an error to the entity that provided the offending data).

+		 *
+		 *
A domainpart MUST NOT be zero bytes in length and MUST NOT be more
+		 * than 1023 bytes in length. This rule is to be enforced after any
+		 * mapping or normalization resulting from application of the Nameprep
+		 * profile of stringprep (e.g., in Nameprep some characters can be
+		 * mapped to nothing, which might result in a string of zero length).
+		 * Naturally, the length limits of [DNS] apply, and nothing in this
+		 * document is to be interpreted as overriding those more fundamental
+		 * limits.

+		 *
+		 *
In the terms of IDNA2008 [IDNA-DEFS], the domainpart of a JID is a
+		 * "domain name slot".

+		 *
+		 * @see http://tools.ietf.org/html/rfc6122#section-2.2
 		 */
 		public function get domain():String
 		{


And another bug, something that wasn't wired up.

git-svn-id: a3e1eb16dde062992de22c830ed8045c8013209a@215 c613c5cb-e716-0410-b11b-feb51c14d237

--- src/as/com/threerings/ezgame/client/GameControlBackend.as
+++ src/as/com/threerings/ezgame/client/GameControlBackend.as
@@ -195,6 +195,7 @@
         o["getTurnHolder_v1"] = getTurnHolder_v1;
         o["getOccupantName_v1"] = getOccupantName_v1;
         o["getPlayers_v1"] = getPlayers_v1;
+        o["getPlayerPosition_v1"] = getPlayerPosition_v1;
     }

     /**


WMLoader is now ASTestLoader, seriously.

--- flash/org/windmill/astest/ASTest.as
+++ flash/org/windmill/astest/ASTest.as
@@ -112,7 +112,7 @@
       ASTest.testClassList = [];
       ASTest.testList = [];
       // Load the shit
-      WMLoader.load(files);
+      ASTestLoader.load(files);
     }

     public static function start():void {
@@ -228,7 +228,7 @@
         };
       }
       var testList:Array = [];
-      // No args -- this is being re-invoked from WMLoader
+      // No args -- this is being re-invoked from ASTestLoader
       // now that we have our tests loaded
       for each (var item:Object in ASTest.testClassList) {
         var currTestList:Array = [];


fixes double play event on initial load in flash mode

--- src/flash/htmlelements/VideoElement.as
+++ src/flash/htmlelements/VideoElement.as
@@ -269,9 +269,11 @@
 				}
 				_timer.start();
 				_isPaused = false;
-				sendEvent(HtmlMediaEvent.PLAY);
-				sendEvent(HtmlMediaEvent.PLAYING);
 				_hasStartedPlaying = true;
+
+				// don't toss play/playing events here, because we haven't sent a
+				// canplay / loadeddata event yet. that'll be handled in the net
+				// event listener
 			}

 		}


Ensure all line breaks are LF before splitting into lines

--- src/org/mangui/hls/utils/StringUtil.as
+++ src/org/mangui/hls/utils/StringUtil.as
@@ -66,7 +66,7 @@
 		 */
 		public static function toLines(str:String):Vector.<String>
 		{
-			var lines:Array = (str || "").split("\n");
+			var lines:Array = toLF(str).split("\n");
 			var i:uint;
 			var length:uint = lines.length;


Transferred from the Adobe Open Source Subversion Repository

Revision: 5101
Author:   gauravj@adobe.com
Date:     2009-02-27T05:22:45.887116Z

Log Message:
-----------
Update action script files with asdoc version tags.

QE Notes: None.
Doc Notes: Please review and update as necessary.
tests: checkintests

Modified Paths:
--------------
663 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1260263 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/effects/MaskEffect.as
+++ frameworks/projects/framework/src/mx/effects/MaskEffect.as
@@ -28,6 +28,11 @@
  *  before the tweenStart event.

  *
  *  @eventType mx.events.TweenEvent.TWEEN_START
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 [Event(name="tweenStart", type="mx.events.TweenEvent")]

@@ -38,6 +43,11 @@
  *  and onScaleTweenUpdate() methods.
  *
  *  @eventType mx.events.TweenEvent.TWEEN_UPDATE
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 [Event(name="tweenUpdate", type="mx.events.TweenEvent")]

@@ -52,6 +62,11 @@
  *  after the effect plays for the final time.

  *
  *  @eventType mx.events.TweenEvent.TWEEN_END
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 [Event(name="tweenEnd", type="mx.events.TweenEvent")]

@@ -121,6 +136,11 @@
  *
  *  @see mx.effects.effectClasses.MaskEffectInstance
  *  @see mx.effects.TweenEffect
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 public class MaskEffect extends Effect
 {
@@ -147,6 +167,11 @@
      *  Constructor.
      *
      *  @param target The Object to animate with this effect.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public function MaskEffect(target:Object = null)
     {
@@ -194,6 +219,11 @@
      *
      *
The function returns a single Shape object
      *  that defines the mask.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var createMaskFunction:Function;

@@ -204,6 +234,11 @@
     /**
      *  Easing function to use for moving the mask.
      *  @default null
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var moveEasingFunction:Function;

@@ -229,6 +264,11 @@
     /**
      *  Easing function to use for scaling the mask.
      *  @default null
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var scaleEasingFunction:Function;

@@ -245,6 +285,11 @@
      *  you must specify all four of these properties:
      *  scaleXFrom, scaleYFrom,
      *  scaleXTo, and scaleX.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var scaleXFrom:Number;

@@ -261,6 +306,11 @@
      *  you must specify all four of these properties:
      *  scaleXFrom, scaleYFrom,
      *  scaleXTo, and scaleX.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var scaleXTo:Number;

@@ -277,6 +327,11 @@
      *  you must specify all four of these properties:
      *  scaleXFrom, scaleYFrom,
      *  scaleXTo, and scaleX.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var scaleYFrom:Number;

@@ -293,6 +348,11 @@
      *  you must specify all four of these properties:
      *  scaleXFrom, scaleYFrom,
      *  scaleXTo, and scaleX.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var scaleYTo:Number;

@@ -328,6 +388,11 @@
      *  event listener for the startEffect event.
      *
      *  @default true
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public function get showTarget():Boolean
     {
@@ -356,6 +421,11 @@
      *  you must specify all four of these properties:
      *  xFrom, yFrom, xTo,
      *  and yTo.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var xFrom:Number;

@@ -372,6 +442,11 @@
      *  you must specify all four of these properties:
      *  xFrom, yFrom, xTo,
      *  and yTo.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var xTo:Number;

@@ -388,6 +463,11 @@
      *  you must specify all four of these properties:
      *  xFrom, yFrom, xTo,
      *  and yTo.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var yFrom:Number;

@@ -404,6 +484,11 @@
      *  you must specify all four of these properties:
      *  xFrom, yFrom, xTo,
      *  and yTo.

+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public var yTo:Number;

@@ -453,6 +538,11 @@
      *  properties modified by this effect.
      *
      *  @see mx.effects.Effect#getAffectedProperties()
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     override public function getAffectedProperties():Array /* of String */
     {
@@ -499,6 +589,11 @@
      *  If you override this method, ensure that you call the super method.
      *
      *  @param event An event object of type TweenEvent.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     protected function tweenEventHandler(event:TweenEvent):void
     {


Transferred from the Adobe Open Source Subversion Repository

Revision: 20007
Author:   cframpto@adobe.com
Date:     2011-01-28T20:19:13.564049Z

Log Message:
-----------
Add [Inspectable] metadata to all spark text components

QE notes:
Doc notes:
Bugs: part of SDK-28942
Reviewer: Corey
Tests run: cyclone, FlashBuilder w/ DesignView
Is noteworthy for integration:

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/RichEditableText.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/TextInput.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/TextBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/RichText.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/TextArea.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/SkinnableTextBase.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1280397 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/RichText.as
+++ frameworks/projects/spark/src/spark/components/RichText.as
@@ -399,7 +399,6 @@
     //----------------------------------
     //  text
     //----------------------------------
-    [Inspectable(category="General")]

     // Compiler will strip leading and trailing whitespace from text string.
     [CollapseWhiteSpace]
@@ -519,6 +518,8 @@
      */
     private var contentChanged:Boolean = false;

+    [Inspectable(environment="none")]
+
     /**
      *  @private
      *  This metadata tells the MXML compiler to disable some of its default
@@ -670,6 +671,8 @@
      */
     private var maskTypeChanged:Boolean;

+    [Inspectable(defaultValue="clip", enumeration="clip,alpha,luminosity")]
+
     /**
      *
The maskType defines how the mask is applied to the component.

      *
@@ -774,6 +777,8 @@
      */
     private var luminositySettingsChanged:Boolean;

+    [Inspectable(defaultValue="false")]
+
     /**
      *  A property that controls the calculation of the RGB
      *  color value of a graphic element being masked by
@@ -818,6 +823,8 @@
      */
     private var _luminosityClip:Boolean = false;

+    [Inspectable(defaultValue="false")]
+
     /**
      *  A property that controls whether the luminosity
      *  mask clips the masked content. This property can


Transferred from the Adobe Open Source Subversion Repository

Revision: 23247
Author:   cframpto@adobe.com
Date:     2011-12-20T19:21:13.134833Z

Log Message:
-----------
Remove ADOBE SYSTEMS license and replace with Apache license in headers - frameworks.  A 2nd pass will be needed to get the files not handled up by the scripts.

Modified Paths:
--------------
4959 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1280556 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/Scroller.as
+++ frameworks/projects/spark/src/spark/components/Scroller.as
@@ -1,11 +1,19 @@
 ////////////////////////////////////////////////////////////////////////////////
 //
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2008 Adobe Systems Incorporated
-//  All Rights Reserved.
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
 //
-//  NOTICE: Adobe permits you to use, modify, and distribute this file
-//  in accordance with the terms of the license agreement accompanying it.
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
 //
 ////////////////////////////////////////////////////////////////////////////////


Added getUserRoles method

Added getUserRoles method

--- src/src/com/backendless/service/_UserService.as
+++ src/src/com/backendless/service/_UserService.as
@@ -302,14 +302,13 @@

 			var token:AsyncToken = BackendlessClient.instance.invoke(SERVICE_SOURCE, "update",
 				[Backendless.appId, Backendless.version, user.properties]);
-
-			token.addResponder(
-				new Responder(
-					function (event:ResultEvent):void
-					{
-						if (responder) responder.result(
-							ResultEvent.createEvent(ObjectsBuilder.updateUser(user, event.result), token)
-						);
+
+          if( responder != null )
+			token.addResponder(
+				new Responder(
+					function (event:ResultEvent):void
+					{
+                      responder.result( ResultEvent.createEvent(ObjectsBuilder.updateUser(user, event.result), token) );
 					},
 					function (event:FaultEvent):void
 					{
@@ -325,5 +324,15 @@
 		{
 			return _currentUser;
 		}
+
+      public function getUserRoles( responder:IResponder = null ):AsyncToken
+      {
+        var token:AsyncToken = BackendlessClient.instance.invoke(SERVICE_SOURCE, "getUserRoles", [Backendless.appId, Backendless.version ]);
+
+        if( responder != null )
+          token.addResponder( responder );
+
+        return token;
+      }
 	}
 }


added check for string before for-in loop

--- WeaveData/src/weave/data/hierarchy/WeaveTreeDescriptorNode.as
+++ WeaveData/src/weave/data/hierarchy/WeaveTreeDescriptorNode.as
@@ -36,15 +36,19 @@
 		 * @param params An values for the properties of this WeaveTreeDescriptorNode.
 		 */
 		public function WeaveTreeDescriptorNode(params:Object)
-		{
+		{
+			super();
 			childItemClass = WeaveTreeDescriptorNode;
-
-			for (var key:String in params)
-			{
-				if (this[key] is Function && this.hasOwnProperty('_' + key))
-					this['_' + key] = params[key];
-				else
-					this[key] = params[key];
+
+			if (typeof params === 'object')
+			{
+				for (var key:String in params)
+				{
+					if (this[key] is Function && this.hasOwnProperty('_' + key))
+						this['_' + key] = params[key];
+					else
+						this[key] = params[key];
+				}
 			}
 		}


Added disposeLocalData on TextureResource

--- src/aerys/minko/render/resource/texture/TextureResource.as
+++ src/aerys/minko/render/resource/texture/TextureResource.as
@@ -290,6 +290,20 @@
 			}
 		}

+		public function disposeLocalData() : void
+		{
+			if (_atf)
+			{
+				_atf.clear();
+				_atf = null;
+			}
+			if (_bitmapData)
+			{
+				_bitmapData.dispose();
+				_bitmapData = null;
+			}
+		}
+
 		public function dispose() : void
 		{
 			_disposed = true;


Make sure our seatedness variable accurately reflects the departure of our table.

git-svn-id: a3e1eb16dde062992de22c830ed8045c8013209a@441 c613c5cb-e716-0410-b11b-feb51c14d237

--- src/as/com/threerings/parlor/client/TableDirector.as
+++ src/as/com/threerings/parlor/client/TableDirector.as
@@ -104,6 +104,7 @@
         if (_tlobj != null) {
             (_tlobj as DObject).removeListener(this);
             _tlobj = null;
+            _ourTable = null;
         }
     }


Fix bug in indexing the color classes map.

git-svn-id: b675b909355d5cf946977f44a8ec5a6ceb3782e4@993 ed5b42cb-e716-0410-a449-f6a68f950b19

--- src/as/com/threerings/media/image/ColorPository.as
+++ src/as/com/threerings/media/image/ColorPository.as
@@ -201,7 +201,7 @@
     {
         var pos :ColorPository = new ColorPository();
         for each (var classXml :XML in xml.elements("class")) {
-            pos._classes.put(classXml.@classId, ClassRecord.fromXml(classXml));
+            pos._classes.put(int(classXml.@classId), ClassRecord.fromXml(classXml));
         }

         return pos;


Be sure to call super() in our clickHandler so that selected state toggles
when toggle mode is true.

git-svn-id: a1a4b28b82a3276cc491891159dd9963a0a72fae@4278 542714f4-19e9-0310-aa3c-eee0fc999fb1

--- src/as/com/threerings/mx/controls/CommandButton.as
+++ src/as/com/threerings/mx/controls/CommandButton.as
@@ -31,8 +31,14 @@

     override protected function clickHandler (event :MouseEvent) :void
     {
-        dispatchEvent(new ControllerEvent(_cmd, _arg));
-        event.stopImmediatePropagation();
+        super.clickHandler(event);
+
+        if (enabled) {
+            // stop the click event
+            event.stopImmediatePropagation();
+            // dispatch the command event
+            dispatchEvent(new ControllerEvent(_cmd, _arg));
+        }
     }

     /** The command to submit when clicked. */


RuleLexer bugfix

RuleLexer bugfix

--- raw/src/org/yellcorp/lib/lex/rule/RuleLexer.as
+++ raw/src/org/yellcorp/lib/lex/rule/RuleLexer.as
@@ -131,7 +131,7 @@
         {
             var text:String = _text.substring(start, end);

-            if (_returnWhitespace || StringUtil.hasContent(token.text))
+            if (_returnWhitespace || StringUtil.hasContent(text))
             {
                 var token:Token = new Token();
                 token.text = text;


Transferred from the Adobe Open Source Subversion Repository

Revision: 4804
Author:   jvroom@adobe.com
Date:     2009-02-03T01:56:22.023978Z

Log Message:
-----------
Bugs: LCDS-548: add code to deal with contentType="application/xml" with one parameter (avoid
name/value encoding in that case)
      LCDS-405: baseURL on HTTPMultiService should accept URLs which start with "/"

      Added convertParametersHandler and convertResultsHandler function hooks to RemoteObject
      to support framework code which wants to modify the service behavior.

      Moved "properties" from rpc/http/AbstractOperation to rpc/AbstractOperation so we can use
      it for customizing the handling of remote object results

      Couple of minor ASDoc fixes and one tab -> spaces change

Doc: minor asdoc edits
QE: LCDS QE will verify the bugs in this one
Reviewers: Mete, Pete, Seth, Ed reviewed different parts of this checkin

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/AbstractInvoker.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/http/AbstractOperation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/AbstractOperation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/remoting/Operation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/remoting/RemoteObject.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/http/HTTPMultiService.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/http/Operation.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1274215 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/rpc/src/mx/rpc/http/Operation.as
+++ frameworks/projects/rpc/src/mx/rpc/http/Operation.as
@@ -18,6 +18,7 @@
 import mx.rpc.AbstractService;
 import mx.rpc.AsyncRequest;
 import mx.rpc.AsyncToken;
+import mx.utils.URLUtil;

 use namespace mx_internal;

@@ -119,18 +120,28 @@
     }

     /**
-     * If the rootURL property is not set on the operation, it is inherited from
-     * the service level.
+     * The rootURL is used to compute the URL for an HTTP service operation when the
+     * a relative URL is specified for the operation.  The directory name of the
+     * rootURL is prepended to any relative URLs for the operation.  It is typically
+     * more convenient to set the baseURL since baseURL specifies the directory name
+     * directly whereas rootURL specifies the name of a file whose directory name is
+     * prepended.  If neither rootURL nor baseURL are set explicitly, the directory name
+     * of the .swf file is prepended to relative paths.
      */
     override public function get rootURL():String
     {
         if (_rootURL == null)
         {
-            if (_multiService.baseURL != null)
+            var useRootURL:String = _multiService.baseURL;
+            if (useRootURL != null && useRootURL.length > 0)
             {
-                if (_multiService.baseURL.charAt(_multiService.baseURL.length - 1) != '/')
-                    return _multiService.baseURL + "/";
-                return _multiService.baseURL;
+                if (useRootURL.charAt(useRootURL.length - 1) != '/')
+                    useRootURL = useRootURL + "/";
+
+                // If this is relative to the
+                if (useRootURL.charAt(0) == "/")
+                    useRootURL = URLUtil.getFullURL(super.rootURL, useRootURL);
+                return useRootURL;
             }
             else
                 return super.rootURL; // defaults to SWF's URL
@@ -198,8 +209,19 @@
                     throw new ArgumentError("HTTPMultiService operation called with " + argumentNames.length + " argumentNames and " + args.length + " number of parameters.  When argumentNames is specified, it must match the number of arguments passed to the invocation");
                 else
                 {
-                    for (var i:int = 0; i < argumentNames.length; i++)
-                        params[argumentNames[i]] = args[i];
+                    // Special case for XML content type when only one parameter is provided.
+                    // This gets rid of the need for a serializationFilter for this simple case.
+                    // If there is more than one parameter though, we do not have a reliable way
+                    // to turn the arguments into a body.
+                    if (argumentNames.length == 1 && contentType == CONTENT_TYPE_XML)
+                    {
+                        params = args[0];
+                    }
+                    else
+                    {
+                        for (var i:int = 0; i < argumentNames.length; i++)
+                            params[argumentNames[i]] = args[i];
+                    }
                 }
             }
         }


Removed the use of ArrayCollection in RosterGroup.

git-svn-id: c197267f952b24206666de142881703007ca05d5@11181 b35dd754-fafc-0310-a699-88a17e54d16e

--- src/org/igniterealtime/xiff/data/im/RosterGroup.as
+++ src/org/igniterealtime/xiff/data/im/RosterGroup.as
@@ -3,63 +3,72 @@
  */
 package org.igniterealtime.xiff.data.im
 {
-	/*
-	 * Copyright (C) 2008
-	 * Jive Software
-
+	/**
+	 * Represents the groups in users roster.
 	 */
-
-	import mx.collections.ArrayCollection;
-	import mx.collections.Sort;
-	import mx.collections.SortField;
-
-	public class RosterGroup extends ArrayCollection
+	public class RosterGroup
 	{
 		public var label:String;
 		public var shared:Boolean = false;

-		public function RosterGroup(l:String)
+		private var _items:Array = [];
+
+		/**
+		 * Create a new group with the given name
+		 * @param	name
+		 */
+		public function RosterGroup(name:String)
 		{
-			var s:Sort = new Sort();
-		    s.fields = [new SortField("displayName", true)];
-		    sort = s;
-		    refresh();
-			label = l;
+			label = name;
 		}

-		public override function addItem(item:Object):void
+		/**
+		 * Insert a new roster item if it does not already exists in this group
+		 * @param	item
+		 */
+		public function addItem(item:RosterItemVO):void
 		{
-			if(!item is RosterItemVO)
-				throw new Error("Assertion Failure: attempted to add something other than a RosterItemVO to a RosterGroup");
-			if(source.indexOf(item) == -1)
-				super.addItem(item);
-		}
-
-		public function removeItem(item:RosterItemVO):void
-		{
-			var itemIndex:int = getItemIndex(item);
-			if(itemIndex >= 0)
-				removeItemAt(itemIndex);
-			else
+			if (_items.indexOf(item) == -1)
 			{
-				itemIndex =	source.indexOf(item);
-				if(itemIndex >= 0)
-					source.splice(itemIndex, 1);
+				_items.push(item);
 			}
 		}

-		public override function set filterFunction(f:Function):void
+		/**
+		 * Remove the given roster item from this group.
+		 * @param	item
+		 */
+		public function removeItem(item:RosterItemVO):void
 		{
-			throw new Error("Setting the filterFunction on RosterGroup is not allowed; Wrap it in a ListCollectionView and filter that.");
+			var index:int = _items.indexOf(item);
+			if (index != -1)
+			{
+				_items.splice(index, 1);
+			}
 		}
-
-		private function sortContacts(item1:RosterItemVO, item2:RosterItemVO, fields:Array = null):int
+
+		/**
+		 * Does the given item exists in this group?
+		 * @param	item
+		 * @return
+		 */
+		public function contains(item:RosterItemVO):Boolean
 		{
-			if(item1.displayName.toLowerCase() < item2.displayName.toLowerCase())
-				return -1;
-			else if(item1.displayName.toLowerCase() > item2.displayName.toLowerCase())
-				return 1;
-			return 0;
+			var value:Boolean = false;
+			var index:int = _items.indexOf(item);
+			if (index != -1)
+			{
+				value = true;
+			}
+			return value;
+		}
+
+		/**
+		 * Roster items in this group.
+		 */
+		public function get items():Array
+		{
+			return _items;
 		}
 	}
 }


Улучшения

Улучшения

--- src/main/org/shypl/common/loader/AbstractLoader.as
+++ src/main/org/shypl/common/loader/AbstractLoader.as
@@ -86,10 +86,11 @@
 		protected final function handleLoadingCompleteEvent(event:Event):void {
 			_loading = false;
 			FileLoader.LOGGER.trace("Loaded {}", _url);
-
-			produceResult();
-			freeLoading();
-			complete();
+			if (!_canceled) {
+				produceResult();
+				freeLoading();
+				complete();
+			}
 		}

 		protected final function handleLoadingErrorEvent(event:ErrorEvent):void {


Transferred from the Adobe Open Source Subversion Repository

Revision: 23246
Author:   cframpto@adobe.com
Date:     2011-12-20T17:40:08.069454Z

Log Message:
-----------
Rollback 23243.  If comment followed header it was stripped as well.

Modified Paths:
--------------
2361 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1263095 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/validators/IValidator.as
+++ frameworks/projects/framework/src/mx/validators/IValidator.as
@@ -1,3 +1,13 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2010 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////

 package mx.validators
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 2482
Author:   rfrishbe@adobe.com
Date:     2008-07-15T01:16:25.668131Z

Log Message:
-----------
Fix up focus issues with the new Application.  Added tabChildren=true for group.  Had to override Group's focusPane getter/setter b/c the UIComponent version uses addChild/removeChild which throws an RTE for Group.  This should be revisited when focusPane is revisited (and maybe moved into the Skin...?)

Based on some comments from Glenn, removed backgroundColorNumber and just use backgroundColor typed as an Object.

QE: Yes - Will need to start writing tests for Application and focusing inside Groups
Doc: No
Reviewer: Glenn

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/core/Group.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/skin/ApplicationSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/core/Application.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1278171 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/Application.as
+++ frameworks/projects/spark/src/spark/components/Application.as
@@ -104,7 +104,7 @@
  *  attributes of its superclass and adds the following tag attributes:

  *
  *

- *  <mx:Application
+ *  <Application
  *    Properties
  *    application="No default"
  *    frameRate="24"
@@ -197,6 +197,11 @@
         // documentDescriptor property for the application object.
         // We get the id and the creationPolicy, which we want to
         // set very early, from that descriptor.
+
+        // because we don't have namespace-specific styles yet
+        // just set the default here
+        // TODO (rfrishbe): remove this...
+        setStyle("backgroundColor", "white");
     }

     //--------------------------------------------------------------------------
@@ -244,47 +249,25 @@
     //----------------------------------
 	//  backgroundColor
 	//----------------------------------
-
-	private var _backgroundColor:String = "0xFFFFFF";

 	[Bindable("backgroundColorUpdated")]

 	/**
 	 *  @copy mx.core.Container#backgroundColor
 	 */
-	public function get backgroundColor():String
+	public function get backgroundColor():Object /* Color (int or String) */
 	{
-		return _backgroundColor;
+		return getStyle("backgroundColor");
 	}

-	public function set backgroundColor(value:String):void
+	public function set backgroundColor(value:Object /* Color (int or String) */):void
 	{
-		if (value == _backgroundColor)
+		if (value == getStyle("backgroundColor"))
 			return;

-		_backgroundColor = value;
+		setStyle("backgroundColor", value);

 		dispatchEvent(new Event("backgroundColorUpdated"));
-	}
-
-	//----------------------------------
-	//  backgroundColorNumber
-	//----------------------------------
-
-	[Bindable("backgroundColorUpdated")]
-
-	/**
-	 *  Background color of a component.
-	 *  Because backgroundColor is a String, backgroundColorNumber
-	 *  is just a Number so it can be used by flex graphics.
-	 */
-	public function get backgroundColorNumber():uint
-	{
-        var colorNumber:uint = StyleManager.getColorName(backgroundColor);
-		if (colorNumber == StyleManager.NOT_A_COLOR)
-			colorNumber = parseInt(backgroundColor);
-
-        return colorNumber;
 	}

     //--------------------------------------------------------------------------


add "skipOffsetRemaining" parameter to sequenceVo

--- kdp3Lib/src/com/kaltura/kdpfl/model/vo/SequenceVO.as
+++ kdp3Lib/src/com/kaltura/kdpfl/model/vo/SequenceVO.as
@@ -91,5 +91,9 @@
 		 * In case we want to ignore prerolls, for example, when starting the media from the middle with "mediaProxy.mediaPlayFrom"
 		 */
 		public var skipPrerolls:Boolean = false;
+		/**
+		 * hodls the time remaining until skip ad will be available
+		 */
+		public var skipOffsetRemaining:int;
 	}
 }


Clarify comment.

Clarify comment.

--- HLSPlugin/src/com/kaltura/hls/m2ts/M2TSFileHandler.as
+++ HLSPlugin/src/com/kaltura/hls/m2ts/M2TSFileHandler.as
@@ -421,7 +421,7 @@

 			if ( key ) key.usePadding = true;

-			// Note the start as a debug event.
+			// Note the end as a debug event.
 			_parser.sendDebugEvent( {type:"segmentEnd", uri:segmentUri});

 			var rv:ByteArray = basicProcessFileSegment(input, true);


Fix "Is enabled" checkbox getting moved on gizmo / cursor key node editing. Closes #1401.

--- bin/Data/Scripts/Editor/EditorInspectorWindow.as
+++ bin/Data/Scripts/Editor/EditorInspectorWindow.as
@@ -392,6 +392,8 @@
 {
     bool fullUpdate = false;
     UpdateAttributes(ToSerializableArray(editNodes), GetNodeContainer().GetChild("AttributeList"), fullUpdate);
+    if (fullUpdate)
+        HandleWindowLayoutUpdated();
 }

 /// Update the icons enabled color based on the internal state of the objects.


Cleanup unused node var names from the scene. Closes #1068.

--- bin/Data/Scripts/Editor/EditorInspectorWindow.as
+++ bin/Data/Scripts/Editor/EditorInspectorWindow.as
@@ -738,8 +738,6 @@
     if (delName.empty)
         return;

-    // Note: intentionally do not unregister the variable name here as the same variable name may still be used by other attribute list
-
     bool erased = false;
     for (uint i = 0; i < editNodes.length; ++i)
     {
@@ -747,7 +745,27 @@
         erased = editNodes[i].vars.Erase(delName) || erased;
     }
     if (erased)
+    {
         attributesDirty = true;
+        // If the attribute is not defined in any other node, unregister from the scene
+        // to prevent it from being unnecessarily saved; the global var list will still hold it
+        // to keep the hash-name mapping known in case it's in use in other scenes
+        Array<Node@>@ allChildren = editorScene.GetChildren(true);
+        StringHash delNameHash(delName);
+        bool inUse = false;
+
+        for (uint i = 0; i < allChildren.length; ++i)
+        {
+            if (allChildren[i].vars.Contains(delNameHash))
+            {
+                inUse = true;
+                break;
+            }
+        }
+
+        if (!inUse)
+            editorScene.UnregisterVar(delName);
+    }
 }

 /// Handle create new user-defined variable event for ui-element target.


switched from callback to trigger counter comparison

--- WeaveData/src/weave/data/BinClassifiers/NumberClassifier.as
+++ WeaveData/src/weave/data/BinClassifiers/NumberClassifier.as
@@ -19,15 +19,16 @@

 package weave.data.BinClassifiers
 {
+	import weave.api.core.ICallbackCollection;
 	import weave.api.data.IBinClassifier;
 	import weave.api.data.IPrimitiveColumn;
+	import weave.api.getCallbackCollection;
 	import weave.api.newLinkableChild;
 	import weave.core.LinkableBoolean;
 	import weave.core.LinkableNumber;
 	import weave.data.AttributeColumns.StringColumn;

 	/**
-	 * NumberClassifier
 	 * A classifier that uses min,max values for containment tests.
 	 *
 	 * @author adufilie
@@ -36,7 +37,8 @@
 	{
 		public function NumberClassifier(min:* = NaN, max:* = NaN, minInclusive:Boolean = true, maxInclusive:Boolean = true)
 		{
-			super();
+			super();
+			_callbacks = getCallbackCollection(this);
 			this.min.value = min;
 			this.max.value = max;
 			this.minInclusive.value = minInclusive;
@@ -44,40 +46,23 @@
 		}

 		/**
-		 * min, max
 		 * These values define the bounds of the continuous range contained in this classifier.
 		 */
-		public const min:LinkableNumber = newLinkableChild(this, LinkableNumber, invalidate);
-		public const max:LinkableNumber = newLinkableChild(this, LinkableNumber, invalidate);
+		public const min:LinkableNumber = newLinkableChild(this, LinkableNumber);
+		public const max:LinkableNumber = newLinkableChild(this, LinkableNumber);

 		/**
-		 * minInclusive
 		 * This value is the result of contains(value) when value == min.
 		 */
-		public const minInclusive:LinkableBoolean = newLinkableChild(this, LinkableBoolean, invalidate);
+		public const minInclusive:LinkableBoolean = newLinkableChild(this, LinkableBoolean);
 		/**
-		 * maxInclusive
 		 * This value is the result of contains(value) when value == max.
 		 */
-		public const maxInclusive:LinkableBoolean = newLinkableChild(this, LinkableBoolean, invalidate);
+		public const maxInclusive:LinkableBoolean = newLinkableChild(this, LinkableBoolean);

-		// called when session state changes
-		private function invalidate():void
-		{
-			_dirty = true;
-		}
-		// true when private variables need to be validated
-		private var _dirty:Boolean = true;
-		// validates private variables
-		private function validate():void
-		{
-			_min = min.value;
-			_max = max.value;
-			_minInclusive = minInclusive.value;
-			_maxInclusive = maxInclusive.value;
-			_dirty = false;
-		}
 		// private variables for holding session state, used for speed
+		private var _callbacks:ICallbackCollection;
+		private var _triggerCount:uint = 0;
 		private var _min:Number, _max:Number;
 		private var _minInclusive:Boolean, _maxInclusive:Boolean;

@@ -89,8 +74,14 @@
 		public function contains(value:*):Boolean
 		{
 			// validate private variables before trying to use them
-			if (_dirty)
-				validate();
+			if (_triggerCount != _callbacks.triggerCounter)
+			{
+				_min = min.value;
+				_max = max.value;
+				_minInclusive = minInclusive.value;
+				_maxInclusive = maxInclusive.value;
+				_triggerCount = _callbacks.triggerCounter;
+			}
 			// use private variables for speed
 			return (_minInclusive ? value >= _min : value > _min)
 				&& (_maxInclusive ? value <= _max : value < _max);


Improve sendFLVTag logging.

Improve sendFLVTag logging.

--- HLSPlugin/src/com/kaltura/hls/m2ts/FLVTranscoder.as
+++ HLSPlugin/src/com/kaltura/hls/m2ts/FLVTranscoder.as
@@ -68,7 +68,7 @@

             CONFIG::LOGGING
             {
-                logger.debug("FLV @ " + flvts + " dur=" + duration + " len=" + tag.length + " type=" + type + " payloadLen=" + msgLength);
+                logger.debug("FLV @ " + flvts + " dur=" + duration + " len=" + tag.length + " type=" + type + " payloadLen=" + msgLength + " buffer=" + buffer);
             }

             tag[cursor++] = type;


Missed one 2009 in copyright header

Missed one 2009 in copyright header

--- src/org/igniterealtime/xiff/auth/XFacebookPlatform.as
+++ src/org/igniterealtime/xiff/auth/XFacebookPlatform.as
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2003-2009 Igniterealtime Community Contributors
+ * Copyright (C) 2003-2012 Igniterealtime Community Contributors
  *
  *     Daniel Henninger
  *     Derrick Grigg <dgrigg@rogers.com>