Transferred from the Adobe Open Source Subversion Repository

Revision: 3930
Author:   egreenfi@adobe.com
Date:     2008-10-28T16:30:24.729265Z

Log Message:
-----------
Step 1 of memory improvements
GraphicElement now optimizes away its AdvancedLayoutFeatures as long is has a trivial (translation only) transform matrix.
Added a new OnDemandEventDispatcher class that only allocates memory for event dispatcher functionality when it gets its first listener.
GraphicElement, OverrideBase, and LayoutBase extend OnDemandEventDispatcher.

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/states/OverrideBase.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/OnDemandEventDispatcher.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/LinearGradientStroke.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/RadialGradientStroke.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/FrameworkClasses.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/LinearGradient.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/graphics/graphicsClasses/GraphicElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/layout/LayoutBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/RadialGradient.as</path>

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

--- frameworks/projects/spark/src/spark/primitives/supportClasses/GraphicElement.as
+++ frameworks/projects/spark/src/spark/primitives/supportClasses/GraphicElement.as
@@ -25,26 +25,27 @@
 import flash.geom.Point;
 import flash.geom.Transform;

-import mx.geom.Transform;
-import mx.graphics.IGraphicElement;
-import mx.graphics.MaskType;
-import mx.utils.MatrixUtil;
-import mx.layout.ILayoutItem;
 import mx.components.baseClasses.GroupBase;
 import mx.core.AdvancedLayoutFeatures;
 import mx.core.IInvalidating;
-import mx.geom.TransformOffsets;
+import mx.core.IVisualItem;
+import mx.core.UIComponent;
 import mx.core.UIComponentGlobals;
-import mx.core.UIComponent;
 import mx.core.mx_internal;
 import mx.events.FlexEvent;
 import mx.events.PropertyChangeEvent;
 import mx.events.PropertyChangeEventKind;
 import mx.filters.BaseFilter;
 import mx.filters.IBitmapFilter;
+import mx.geom.Transform;
+import mx.geom.TransformOffsets;
+import mx.graphics.IGraphicElement;
 import mx.graphics.IStroke;
+import mx.graphics.MaskType;
+import mx.layout.ILayoutItem;
 import mx.managers.ILayoutManagerClient;
-import mx.core.IVisualItem;
+import mx.utils.MatrixUtil;
+import mx.utils.OnDemandEventDispatcher;

 use namespace mx_internal;

@@ -63,7 +64,7 @@
  *  object in the object's parent coordinate space. The UBounds are the boundaries
  *  of an object in its own coordinate space.</p>
  */
-public class GraphicElement extends EventDispatcher
+public class GraphicElement extends OnDemandEventDispatcher
     implements IGraphicElement, IInvalidating, ILayoutItem, IVisualItem
 {
     include "../../core/Version.as";
@@ -114,7 +115,6 @@
     public function GraphicElement()
     {
         super();
-        layoutFeatures = new AdvancedLayoutFeatures();
     }

     //--------------------------------------------------------------------------
@@ -132,11 +132,6 @@
      *  @private
      */
     private var _colorTransform:ColorTransform;
-
-    /**
-     *  @private
-     */
-    private var _layer:Number = 0;

 	/**
      *  @private The Sprite to draw into.
@@ -172,6 +167,19 @@
      *  property.
      */
     protected var layoutFeatures:AdvancedLayoutFeatures;
+
+
+    /**
+     *  @private
+     *  storage for the x property. This property is used when a GraphicElement has a simple transform.
+     */
+     private var _x:Number = 0;
+
+    /**
+     *  @private
+     *  storage for the y property. This property is used when a GraphicElement has a simple transform.
+     */
+     private var _y:Number = 0;

     //--------------------------------------------------------------------------
     //
@@ -189,6 +197,9 @@
      */
     public function set offsets(value:TransformOffsets):void
     {
+        if(value != null)
+            allocateLayoutFeatures();
+
         var oldValue:TransformOffsets = layoutFeatures.offsets;

         if(layoutFeatures.offsets != null)
@@ -204,7 +215,16 @@
      */
     public function get offsets():TransformOffsets
     {
-        return layoutFeatures.offsets;
+        return (layoutFeatures == null)? null:layoutFeatures.offsets;
+    }
+
+    protected function allocateLayoutFeatures():void
+    {
+        if(layoutFeatures != null)
+            return;
+        layoutFeatures = new AdvancedLayoutFeatures();
+        layoutFeatures.layoutX = _x;
+        layoutFeatures.layoutY = _y;
     }

     protected function invalidateTransform(changeInvalidatesLayering:Boolean = true,triggerLayout:Boolean = true):void
@@ -216,7 +236,8 @@
             invalidateParentSizeAndDisplayList();
             invalidateProperties();
         }
-        layoutFeatures.updatePending = true;
+        if(layoutFeatures != null)
+	        layoutFeatures.updatePending = true;
     }

     /**
@@ -1219,7 +1240,7 @@
 	 */
     public function get rotationX():Number
     {
-        return layoutFeatures.layoutRotationX;
+        return (layoutFeatures == null)? 0:layoutFeatures.layoutRotationX;
     }

     /**
@@ -1227,10 +1248,13 @@
      */
     public function set rotationX(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutRotationX;
+
+        var oldValue:Number = rotationX;
         if (oldValue == value)
             return;

+        allocateLayoutFeatures();
+
         layoutFeatures.layoutRotationX = value;
         dispatchPropertyChangeEvent("rotationX", oldValue, value);
         invalidateTransform();
@@ -1249,18 +1273,18 @@
 	 */
     public function get rotationY():Number
     {
-        return layoutFeatures.layoutRotationY;
-    }
-
+        return (layoutFeatures == null)? 0:layoutFeatures.layoutRotationY;
+    }
     /**
      *  @private
      */
     public function set rotationY(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutRotationY;
+        var oldValue:Number = rotationY;
         if (oldValue == value)
             return;
-
+
+        allocateLayoutFeatures();
         layoutFeatures.layoutRotationY = value;
         dispatchPropertyChangeEvent("rotationY", oldValue, value);
         invalidateTransform();
@@ -1275,7 +1299,7 @@
      */
     public function get rotationZ():Number
     {
-        return layoutFeatures.layoutRotationZ;
+        return (layoutFeatures == null)? 0:layoutFeatures.layoutRotationZ;
     }

     /**
@@ -1283,10 +1307,12 @@
      */
     public function set rotationZ(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutRotationZ;
+        var oldValue:Number = rotationZ;
         if (oldValue == value)
             return;

+        allocateLayoutFeatures();
+
         layoutFeatures.layoutRotationZ = value;
         dispatchPropertyChangeEvent("rotationZ", oldValue, value);
         dispatchPropertyChangeEvent("rotation", oldValue, value);
@@ -1302,7 +1328,7 @@
      */
     public function get rotation():Number
     {
-        return layoutFeatures.layoutRotationZ;
+        return (layoutFeatures == null)? 0:layoutFeatures.layoutRotationZ;
     }

     /**
@@ -1326,7 +1352,7 @@
      */
     public function get scaleX():Number
     {
-        return layoutFeatures.layoutScaleX;
+        return (layoutFeatures == null)? 1:layoutFeatures.layoutScaleX;
     }

     /**
@@ -1334,9 +1360,11 @@
      */
     public function set scaleX(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutScaleX;
+        var oldValue:Number = scaleX;
         if (oldValue == value)
             return;
+
+        allocateLayoutFeatures();

         layoutFeatures.layoutScaleX = value;
         dispatchPropertyChangeEvent("scaleX", oldValue, value);
@@ -1356,7 +1384,7 @@
      */
     public function get scaleY():Number
     {
-        return layoutFeatures.layoutScaleY;
+        return (layoutFeatures == null)? 1:layoutFeatures.layoutScaleY;
     }

     /**
@@ -1364,9 +1392,11 @@
      */
     public function set scaleY(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutScaleY;
+        var oldValue:Number = scaleY;
         if (oldValue == value)
             return;
+
+        allocateLayoutFeatures();

         layoutFeatures.layoutScaleY = value;
         dispatchPropertyChangeEvent("scaleY", oldValue, value);
@@ -1386,7 +1416,7 @@
      */
     public function get scaleZ():Number
     {
-        return layoutFeatures.layoutScaleZ;
+        return (layoutFeatures == null)? 1:layoutFeatures.layoutScaleZ;
     }

     /**
@@ -1394,9 +1424,11 @@
      */
     public function set scaleZ(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutScaleZ;
+        var oldValue:Number = scaleZ;
         if (oldValue == value)
             return;
+
+        allocateLayoutFeatures();

         layoutFeatures.layoutScaleZ = value;
         dispatchPropertyChangeEvent("scaleZ", oldValue, value);
@@ -1465,6 +1497,8 @@

         if (_transform)
         {
+            allocateLayoutFeatures();
+
             if(_transform.matrix != null)
             {
                 layoutFeatures.layoutMatrix = _transform.matrix.clone();
@@ -1510,7 +1544,11 @@
      */
     public function get layoutMatrix():Matrix
     {
-        return layoutFeatures.layoutMatrix;
+        if(layoutFeatures != null)
+            return layoutFeatures.layoutMatrix;
+        var m:Matrix = new Matrix();
+        m.translate(_x,_y);
+        return m;
     }

     /**
@@ -1518,6 +1556,7 @@
      */
     public function set layoutMatrix(value:Matrix):void
     {
+        allocateLayoutFeatures();
         layoutFeatures.layoutMatrix = value;
         invalidateTransform();
     }
@@ -1534,6 +1573,7 @@
      */
     public function set layoutMatrix3D(value:Matrix3D):void
     {
+        allocateLayoutFeatures();
         layoutFeatures.layoutMatrix3D = value;
         invalidateTransform();
     }
@@ -1543,7 +1583,11 @@
      */
     public function get layoutMatrix3D():Matrix3D
     {
-        return layoutFeatures.layoutMatrix3D;
+        if(layoutFeatures != null)
+            return layoutFeatures.layoutMatrix3D;
+        var m:Matrix3D = new Matrix3D();
+        m.appendTranslation(_x,_y,0);
+        return m;
     }

 	/**
@@ -1556,6 +1600,7 @@
 	 */
     public function transformAround(rx:Number,ry:Number,rz:Number,sx:Number,sy:Number,sz:Number,tx:Number,ty:Number,tz:Number):void
     {
+        allocateLayoutFeatures();
         layoutFeatures.transformAround(rx,ry,rz,sx,sy,sz,tx,ty,tz,true);
         invalidateTransform();
     }
@@ -1572,7 +1617,7 @@
      */
     public function get transformX():Number
     {
-        return layoutFeatures.transformX;
+        return (layoutFeatures == null)? 0:layoutFeatures.transformX;
     }

     /**
@@ -1580,9 +1625,11 @@
      */
     public function set transformX(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.transformX;
+        var oldValue:Number = transformX;
         if ( oldValue == value)
             return;
+
+        allocateLayoutFeatures();

         layoutFeatures.transformX = value;
         dispatchPropertyChangeEvent("transformX", oldValue, value);
@@ -1602,7 +1649,7 @@
      */
     public function get transformY():Number
     {
-        return layoutFeatures.transformY;
+        return (layoutFeatures == null)? 0:layoutFeatures.transformY;
     }

     /**
@@ -1610,9 +1657,12 @@
      */
     public function set transformY(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.transformY;
+        var oldValue:Number = transformY;
         if (oldValue == value)
             return;
+
+        allocateLayoutFeatures();
+
         layoutFeatures.transformY = value;
         dispatchPropertyChangeEvent("transformY", oldValue, value);
         invalidateTransform(false);
@@ -1631,7 +1681,7 @@
      */
     public function get transformZ():Number
     {
-        return layoutFeatures.transformZ;
+        return (layoutFeatures == null)? 0:layoutFeatures.transformZ;
     }

     /**
@@ -1639,9 +1689,12 @@
      */
     public function set transformZ(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.transformZ;
+        var oldValue:Number = transformZ;
         if (oldValue == value)
             return;
+
+        allocateLayoutFeatures();
+
         layoutFeatures.transformZ = value;
         dispatchPropertyChangeEvent("transformZ", oldValue, value);
         invalidateTransform();
@@ -1737,7 +1790,7 @@
 	 */
     public function get layer():Number
     {
-        return layoutFeatures.layer;
+        return (layoutFeatures == null)? 0:layoutFeatures.layer;
     }

     /**
@@ -1747,6 +1800,9 @@
     {
         if(value == layer)
             return;
+
+        allocateLayoutFeatures();
+
          layoutFeatures.layer = value;
         if(_host != null && _host is UIComponent)
             (_host as UIComponent).invalidateLayering();
@@ -1763,7 +1819,7 @@
      */
     public function get x():Number
     {
-        return layoutFeatures.layoutX;
+        return (layoutFeatures == null)? _x:layoutFeatures.layoutX;
     }

     /**
@@ -1771,11 +1827,15 @@
      */
     public function set x(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutX;
+        var oldValue:Number = x;
         if (oldValue == value)
             return;

-        layoutFeatures.layoutX = value;
+        if(layoutFeatures != null)
+            layoutFeatures.layoutX = value;
+        else
+            _x = value;
+
         dispatchPropertyChangeEvent("x", oldValue, value);
         invalidateTransform(false);
     }
@@ -1792,7 +1852,7 @@
      */
     public function get y():Number
     {
-        return layoutFeatures.layoutY;
+        return (layoutFeatures == null)? _y:layoutFeatures.layoutY;
     }

     /**
@@ -1800,11 +1860,14 @@
      */
     public function set y(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutY;
+        var oldValue:Number = y;
         if (oldValue == value)
             return;

-        layoutFeatures.layoutY = value;
+        if(layoutFeatures != null)
+            layoutFeatures.layoutY = value;
+        else
+            _y = value;
         dispatchPropertyChangeEvent("y", oldValue, value);
         invalidateTransform(false);
     }
@@ -1821,7 +1884,7 @@
      */
     public function get z():Number
     {
-        return layoutFeatures.layoutZ;
+        return (layoutFeatures == null)? 0:layoutFeatures.layoutZ;
     }

     /**
@@ -1829,10 +1892,12 @@
      */
     public function set z(value:Number):void
     {
-        var oldValue:Number = layoutFeatures.layoutZ;
+        var oldValue:Number = z;
         if (oldValue == value)
             return;

+        allocateLayoutFeatures();
+
         layoutFeatures.layoutZ = value;
         dispatchPropertyChangeEvent("z", oldValue, value);
         invalidateTransform();
@@ -1966,8 +2031,8 @@
         }
         else
         {
-            topLeft.x += layoutFeatures.layoutX;
-            topLeft.y += layoutFeatures.layoutY;
+            topLeft.x += x;
+            topLeft.y += y;
         }

         // Take stroke into account:
@@ -2005,8 +2070,8 @@
         // TODO!!! We need to apply all of the transforms of our ancestors
         if(displayObject != null)
             return 0;
-        var result:Number = layoutFeatures.layoutX;
-        if(layoutFeatures.offsets != null)
+        var result:Number = x;
+        if(layoutFeatures != null && layoutFeatures.offsets != null)
             result +=  layoutFeatures.offsets.x;
         return sharedDisplayObject && sharedDisplayObject != elementHost ? result - sharedDisplayObject.x : result;
     }
@@ -2024,8 +2089,8 @@
         // TODO!!! We need to apply all of the transforms of our ancestors
         if(displayObject != null)
             return 0;
-        var result:Number = layoutFeatures.layoutY;
-        if(layoutFeatures.offsets != null)
+        var result:Number = y;
+        if(layoutFeatures != null && layoutFeatures.offsets != null)
             result +=  layoutFeatures.offsets.y;
         return sharedDisplayObject && sharedDisplayObject != elementHost ? result - sharedDisplayObject.y : result;
     }
@@ -2155,14 +2220,13 @@
         var result:Boolean;
         result = ((_filters && _filters.length > 0) ||
             _blendMode != BlendMode.NORMAL || _mask ||
-            layoutFeatures.layoutScaleX != 1 || layoutFeatures.layoutScaleY != 1 || layoutFeatures.layoutScaleZ != 1 ||
+            (layoutFeatures != null && (layoutFeatures.layoutScaleX != 1 || layoutFeatures.layoutScaleY != 1 || layoutFeatures.layoutScaleZ != 1 ||
             layoutFeatures.layoutRotationX != 0 || layoutFeatures.layoutRotationY != 0 || layoutFeatures.layoutRotationZ != 0 ||
-            layoutFeatures.layoutZ  != 0 ||
+            layoutFeatures.layoutZ  != 0)) ||
             _colorTransform != null ||
-            _alpha != 1 ||
-            _layer != 0);
-
-        if(layoutFeatures.offsets != null)
+            _alpha != 1);
+
+        if(layoutFeatures != null && layoutFeatures.offsets != null)
         {
             var o:TransformOffsets = layoutFeatures.offsets;
             result = result || (o.scaleX != 1 || o.scaleY != 1 || o.scaleZ != 1 ||
@@ -2533,7 +2597,7 @@
                 invalidateDisplayList();
             }
         }
-        if (layoutFeatures.updatePending ||
+        if ((layoutFeatures == null || layoutFeatures.updatePending) ||
             updateTransform)
         {
             applyComputedTransform();
@@ -2669,7 +2733,7 @@
         // we commit our transform in two places. First, during commit properties, because our size depends on it,
         // and our parent will most likely take it into account during layout. Secondly, here, because our parent will likely
         // change our xform as a result of layout, and we need to commit it before we end up on screen.
-        if (layoutFeatures.updatePending)
+        if (layoutFeatures == null || layoutFeatures.updatePending)
         {
             applyComputedTransform();
         }
@@ -2745,6 +2809,9 @@
         if (!displayObject)
             return null;

+        if(layoutFeatures == null)
+            return null;
+
         var m:Matrix = layoutFeatures.layoutMatrix;
         return MatrixUtil.isDeltaIdentity(m) ? null : m;
     }
@@ -2826,6 +2893,9 @@
     public function setActualPosition(x:Number, y:Number):void
     {

+        var currentX:Number = this.x;
+        var currentY:Number = this.y;
+
         // Take stroke into account:
         // TODO EGeorgie: We assume that the stroke extents are even on both sides.
         // and that's not necessarily true.
@@ -2842,8 +2912,8 @@

             // now adjust our tx/ty values based on the difference between our current transformed position and
             // where we want to end up.
-            x = x - topLeft.x + layoutFeatures.layoutX;
-            y = y - topLeft.y + layoutFeatures.layoutY;
+            x = x - topLeft.x + currentX;
+            y = y - topLeft.y + currentY;
         }
         else
         {
@@ -2852,14 +2922,23 @@
         }

-        if(x != layoutFeatures.layoutX || y != layoutFeatures.layoutY)
-        {
-            layoutFeatures.layoutX = x;
-            layoutFeatures.layoutY = y;
-            // note that we don't want to call invalidateTransform, because
-            // this is in the middle of an update pass. Instead, we just note that the
-            // transform has an update pending, so we can apply it later.
-            layoutFeatures.updatePending = true;
+        if(x != currentX || y != currentY)
+        {
+            if(layoutFeatures != null)
+            {
+                layoutFeatures.layoutX = x;
+                layoutFeatures.layoutY = y;
+
+                // note that we don't want to call invalidateTransform, because
+                // this is in the middle of an update pass. Instead, we just note that the
+                // transform has an update pending, so we can apply it later.
+                layoutFeatures.updatePending = true;
+            }
+            else
+            {
+                _x = x;
+                _y = y;
+            }
             invalidateDisplayList();
         }
     }
@@ -2956,19 +3035,28 @@
      */
     protected function applyComputedTransform():void
     {
-        layoutFeatures.updatePending = false;
+        if(layoutFeatures != null)
+	        layoutFeatures.updatePending = false;

         if(displayObject == null)
             return;

-        if(layoutFeatures.is3D)
-        {
-            displayObject.transform.matrix3D = layoutFeatures.computedMatrix3D;
+        if(layoutFeatures != null)
+        {
+	        if(layoutFeatures.is3D)
+	        {
+	            displayObject.transform.matrix3D = layoutFeatures.computedMatrix3D;
+	        }
+	        else
+	        {
+	            displayObject.transform.matrix = layoutFeatures.computedMatrix;
+	        }
         }
         else
         {
-            displayObject.transform.matrix = layoutFeatures.computedMatrix;
+            displayObject.x = _x;
+            displayObject.y = _y;
         }

         if (_colorTransform)
@@ -3006,24 +3094,27 @@
         if (!scaleMode || scaleMode == LineScaleMode.NONE)
             return new Point(weight, weight);

+        var sX:Number = scaleX;
+        var sY:Number = scaleY;
+
         // TODO EGeorgie: stroke thickness depends on all matrix components,
         // not only on scale.
         if (scaleMode == LineScaleMode.NORMAL)
         {
-            if (layoutFeatures.layoutScaleX == layoutFeatures.layoutScaleY)
-                weight *= layoutFeatures.layoutScaleX;
+            if (sX  == sY)
+                weight *= sX;
             else
-                weight *= Math.sqrt(0.5 * (layoutFeatures.layoutScaleX * layoutFeatures.layoutScaleX + layoutFeatures.layoutScaleY * layoutFeatures.layoutScaleY));
+                weight *= Math.sqrt(0.5 * (sX * sX + sY * sY));

             return new Point(weight, weight);
         }
         else if (scaleMode == LineScaleMode.HORIZONTAL)
         {
-            return new Point(weight * layoutFeatures.layoutScaleX, weight);
+            return new Point(weight * sX, weight);
         }
         else if (scaleMode == LineScaleMode.VERTICAL)
         {
-            return new Point(weight, weight * layoutFeatures.layoutScaleY);
+            return new Point(weight, weight * sY);
         }

         return null;
@@ -3060,6 +3151,8 @@
                 // Apply matrix
                 if (_transform)
                 {
+                    allocateLayoutFeatures();
+
                     layoutFeatures.layoutMatrix = _transform.matrix.clone();
                     invalidateTransform();
                 }


Transferred from the Adobe Open Source Subversion Repository

Revision: 3615
Author:   jimurphy@adobe.com
Date:     2008-10-14T02:23:18.365152Z

Log Message:
-----------
Merged 3.0.x revisions 3562,3592,3612 -> trunk
integrate:
AIK: 20081013
coretech:1.360354
flex-messaging-common.jar: 4.0.0.3605

Modified Paths:
--------------
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/lib/flex-messaging-common.jar</path>
<path kind="file" action="M">/flex/sdk/trunk/in/air/win/AIR Integration Kit.zip</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/in/air/mac/AIR Integration Kit.tbz2</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Menu.as</path>
<path kind="file" action="M">/flex/sdk/trunk/lib/rideau.jar</path>

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

--- frameworks/projects/mx/src/mx/controls/Menu.as
+++ frameworks/projects/mx/src/mx/controls/Menu.as
@@ -1434,7 +1434,7 @@
             // do x
             var screen:Rectangle;
             var pt:Point = new Point(x, y);
-            pt = DisplayObject(this.document).localToGlobal(pt);
+            pt = sbRoot.localToGlobal(pt);

             if (sm != sbRoot)
             {


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@1282218 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/supportClasses/GroupBase.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/GroupBase.as
@@ -1,11 +1,19 @@
 ////////////////////////////////////////////////////////////////////////////////
 //
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2009 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.
 //
 ////////////////////////////////////////////////////////////////////////////////


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@1283155 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/supportClasses/TrackBase.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/TrackBase.as
@@ -1,3 +1,13 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2008 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 spark.components.supportClasses
 {


listen() is supposed to be the final call in a chain, so it didn't make much sense for it to return this

--- raw/src/org/yellcorp/lib/events/EventTask.as
+++ raw/src/org/yellcorp/lib/events/EventTask.as
@@ -43,7 +43,7 @@
         return this;
     }

-    public function listen():EventTask
+    public function listen():void
     {
         for each (var listener:ListenerDescriptor in listeners)
         {
@@ -55,7 +55,6 @@
             target.addEventListener(eventType, onTerminate, false, int.MIN_VALUE);
         }
         listened = true;
-        return this;
     }

     public function unlisten():EventTask


Transferred from the Adobe Open Source Subversion Repository

Revision: 6220
Author:   smgilson@adobe.com
Date:     2009-04-23T19:19:23.764222Z

Log Message:
-----------
More ASDoc work on effects

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

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/AnimateColorInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/AnimateInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/RotateInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/FadeInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/AnimateShaderTransitionInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/ResizeInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/AnimateFilterInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/WipeInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/AddActionInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/MoveInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/CallActionInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/SetActionInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/AnimateTransformInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/RemoveActionInstance.as</path>

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

--- frameworks/projects/spark/src/spark/effects/supportClasses/CallActionInstance.as
+++ frameworks/projects/spark/src/spark/effects/supportClasses/CallActionInstance.as
@@ -15,12 +15,12 @@
 import mx.effects.effectClasses.ActionEffectInstance;

 /**
- *  The CallFunctionActionInstance class implements the instance class
- *  for the CallFunctionAction effect.
- *  Flex creates an instance of this class when it plays a CallFunctionAction
+ *  The CallActionInstance class implements the instance class
+ *  for the CallAction effect.
+ *  Flex creates an instance of this class when it plays a CallAction
  *  effect; you do not create one yourself.
  *
- *  @see flex.effects.CallFunctionAction
+ *  @see spark.effects.CallAction
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -63,7 +63,7 @@
     //----------------------------------

     /**
-     * Function that will be called on the target when this effect plays
+     *  @copy spark.effects.CallAction#functionName
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -77,8 +77,7 @@
     //----------------------------------

     /**
-     * Parameters that will be supplied to the function that is called
-     * by this effect
+     *  @copy spark.effects.CallAction#parameters
      *
      *  @langversion 3.0
      *  @playerversion Flash 10


add debug traces to track audio/video timestamp differences

--- src/org/mangui/HLS/streaming/FragmentLoader.as
+++ src/org/mangui/HLS/streaming/FragmentLoader.as
@@ -287,7 +287,7 @@
       }

 		/** Kill any active load **/
-		private function _clearLoader():void {
+		public function clearLoader():void {
 			if(_fragstreamloader && _fragstreamloader.connected) {
 				_fragstreamloader.close();
 			}
@@ -352,7 +352,6 @@

         public function loadfirstfragment(position:Number,callback:Function):Number {
             Log.debug("loadfirstfragment(" + position + ")");
-            _clearLoader();
             // reset IO Error when loading first fragment
             _bIOError = false;
             _need_reload = false;
@@ -694,6 +693,10 @@
        // Tags used for PTS analysis
        var min_pts:Number = Number.POSITIVE_INFINITY;
        var max_pts:Number = Number.NEGATIVE_INFINITY;
+       var min_audio_pts:Number = Number.POSITIVE_INFINITY;
+       var max_audio_pts:Number = Number.NEGATIVE_INFINITY;
+       var min_video_pts:Number = Number.POSITIVE_INFINITY;
+       var max_video_pts:Number = Number.NEGATIVE_INFINITY;
        var ptsTags:Vector.<Tag>;

       // reset IO error, as if we reach this point, it means fragment has been successfully retrieved and demuxed
@@ -704,17 +707,32 @@
          Log.error(error_txt);
          _hls.dispatchEvent(new HLSEvent(HLSEvent.ERROR, error_txt));
       }
-
-       if (audioTags.length > 0) {
-        ptsTags = audioTags;
-      } else {
-      // no audio, video only stream
-        ptsTags = videoTags;
-      }
-
-      for(var k:Number=0; k < ptsTags.length; k++) {
-         min_pts = Math.min(min_pts,ptsTags[k].pts);
-         max_pts = Math.max(max_pts,ptsTags[k].pts);
+      var k:Number;
+      if (audioTags.length > 0) {
+         for(k=0; k < audioTags.length; k++) {
+            min_audio_pts = Math.min(min_audio_pts,audioTags[k].pts);
+            max_audio_pts = Math.max(max_audio_pts,audioTags[k].pts);
+         }
+         ptsTags = audioTags;
+         min_pts = min_audio_pts;
+         max_pts = max_audio_pts;
+         Log.debug("m/M audio PTS:" + min_pts +"/" + max_pts);
+      }
+
+      if (videoTags.length > 0) {
+         for(k=0; k < videoTags.length; k++) {
+            min_video_pts = Math.min(min_video_pts,videoTags[k].pts);
+            max_video_pts = Math.max(max_video_pts,videoTags[k].pts);
+         }
+         Log.debug("m/M video PTS:" + min_video_pts +"/" + max_video_pts);
+         if (audioTags.length == 0) {
+         // no audio, video only stream
+            ptsTags = videoTags;
+            min_pts = min_video_pts;
+            max_pts = max_video_pts;
+         } else {
+            Log.debug("Delta audio/video m/M PTS:" + (min_video_pts-min_audio_pts) +"/" + (max_video_pts-max_audio_pts));
+         }
       }

       /* in case we are probing PTS, retrieve PTS info and synchronize playlist PTS / sequence number */


Update WindowMediator.as

Update WindowMediator.as

when window is maximized, it should be stored the last window position, size instead of full screen size, otherwise, when the window relaunch and user click "restore" button on the top right corner, the window is still stayed as full screen size.

--- src-standard/org/puremvc/as3/utilities/air/desktopcitizen/view/WindowMediator.as
+++ src-standard/org/puremvc/as3/utilities/air/desktopcitizen/view/WindowMediator.as
@@ -39,6 +39,8 @@
 		// Constant for Minimum stage height
 		public static const MIN_HEIGHT:Number = 570;

+		private var lastRect:Rectangle;
+
 		/**
 		 * Constructor.
 		 */
@@ -142,10 +144,10 @@
 		 * @param event the resize event
 		 */
 		protected function onResize( event:NativeWindowBoundsEvent ):void
-		{
+		{
 			// The StageMediator passed in a Rectangle representing the size and location
 			var rect:Rectangle = event.afterBounds;
-
+			lastRect = windowMetricsProxy.bounds;
 			// Only save the changes to size and location if not minimized or maximized
 			if ( windowMetricsProxy.displayState == NativeWindowDisplayState.NORMAL ) windowMetricsProxy.bounds = rect;

@@ -154,7 +156,7 @@
 			if (firstPass) {
 				firstPass = false;
 				sendNotification( WINDOW_SHOW );
-			}
+			}
 		}

 		/**
@@ -164,9 +166,12 @@
 		 */
 		protected function onFullScreen( event:NativeWindowDisplayStateEvent ):void
 		{
+
 			// Update the WindoMetrics display_state property
 			windowMetricsProxy.displayState = String( event.afterDisplayState );
-
+			if ( windowMetricsProxy.displayState == NativeWindowDisplayState.MAXIMIZED ) {
+				windowMetricsProxy.bounds = lastRect;
+			}
 		}

 		/**
@@ -199,4 +204,4 @@
 		private var firstPass:Boolean 	= true;
 		private var needConfirm:Boolean = false ;
 	}
-}+}


Transferred from the Adobe Open Source Subversion Repository

Revision: 11884
Author:   jon.avila@ssbbartgroup.com
Date:     2009-11-17T03:02:19.724741Z

Log Message:
-----------
Updated Label.as to include mixin/metadata and functions for accessibility (if accessibility is linked-in)
QE notes: none
Doc notes: none
Bugs: n/a
Reviewer: Gordon
Tests run: checkintests
Is noteworthy for integration: no

Modified Paths:
--------------
/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Label.as

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


Transferred from the Adobe Open Source Subversion Repository

Revision: 6261
Author:   rfrishbe@adobe.com
Date:     2009-04-24T22:19:48.376838Z

Log Message:
-----------
Moving a fix for SDK-18864 from trunk in to 3.x.

QE Notes: -
Doc Notes: -
Bugs: SDK-18864
Reviewer: -
tests: checkintests

Modified Paths:
--------------
/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Container.as

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

--- frameworks/projects/mx/src/mx/core/Container.as
+++ frameworks/projects/mx/src/mx/core/Container.as
@@ -2340,29 +2340,6 @@
             }
         }
     }
-
-    /**
-     *  @private
-     *  We're doing special behavior on addEventListener to make sure that
-     *  we successfully capture mouse events, even when there's no background.
-     *  However, this means adding an event listener changes the behavior
-     *  a little, and this can be troublesome for overlapping components
-     *  that now don't get any mouse events.  This is acceptable normally;
-     *  however, automation adds certain events to the Container, and
-     *  it'd be better if automation support didn't modify the behavior of
-     *  the component.  For this reason, especially, we have an mx_internal
-     *  $addEventListener to add event listeners without affecting the behavior
-     *  of the component.
-     */
-    mx_internal function $addEventListener(
-                            type:String, listener:Function,
-                            useCapture:Boolean = false,
-                            priority:int = 0,
-                            useWeakReference:Boolean = false):void
-    {
-        super.addEventListener(type, listener, useCapture,
-                               priority, useWeakReference);
-    }

     /**
      *  @private
@@ -2392,26 +2369,6 @@
                 setStyle("mouseShieldChildren", false);
             }
         }
-    }
-
-    /**
-     *  @private
-     *  We're doing special behavior on removeEventListener to make sure that
-     *  we successfully capture mouse events, even when there's no background.
-     *  However, this means removing an event listener changes the behavior
-     *  a little, and this can be troublesome for overlapping components
-     *  that now don't get any mouse events.  This is acceptable normally;
-     *  however, automation adds certain events to the Container, and
-     *  it'd be better if automation support didn't modify the behavior of
-     *  the component.  For this reason, especially, we have an mx_internal
-     *  $removeEventListener to remove event listeners without affecting the behavior
-     *  of the component.
-     */
-    mx_internal function $removeEventListener(
-                              type:String, listener:Function,
-                              useCapture:Boolean = false):void
-    {
-        super.removeEventListener(type, listener, useCapture);
     }

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


Transferred from the Adobe Open Source Subversion Repository

Revision: 8091
Author:   smgilson@adobe.com
Date:     2009-06-23T15:36:08.467475Z

Log Message:
-----------
ASDoc bug fixes

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

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/Channel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flash-integration/src/mx/flash/UIMovieClip.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/binding/utils/BindingUtils.as</path>

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

--- frameworks/projects/mx/src/mx/controls/DateField.as
+++ frameworks/projects/mx/src/mx/controls/DateField.as
@@ -653,21 +653,21 @@

             if (mask == "M")
             {
-            	if ( outputFormat.charAt(i+1) == "/" && value.getMonth() < 9 ) {
-	            	output += month.substring(1) + "/";
-	            } else {
-	            	output += month;
-	            }
-	            i++;
+                if ( outputFormat.charAt(i+1) == "/" && value.getMonth() < 9 ) {
+                    output += month.substring(1) + "/";
+                } else {
+                    output += month;
+                }
+                i++;
             }
             else if (mask == "D")
             {
-            	if ( outputFormat.charAt(i+1) == "/" && value.getDate() < 10 ) {
-	            	output += date.substring(1) + "/";
-	            } else {
-	            	output += date;
-	            }
-	            i++;
+                if ( outputFormat.charAt(i+1) == "/" && value.getDate() < 10 ) {
+                    output += date.substring(1) + "/";
+                } else {
+                    output += date;
+                }
+                i++;
             }
             else if (mask == "Y")
             {
@@ -1847,7 +1847,7 @@
      *  Accepts a Date object as a parameter. If the incoming Date
      *  object has any time values, they are zeroed out.
      *
-     *
Selecting the currently selected date in the control deselects it,
+     *
Holding down the Control key when selecting the currently selected date deselects it,
      *  sets the selectedDate property to null,
      *  and then dispatches the change event.

      *
@@ -2063,7 +2063,7 @@
         textInput.addEventListener(TextEvent.TEXT_INPUT, textInput_textInputHandler);
         // hide the border, we use the text input's border
         if (border)
-        	border.visible = false;
+            border.visible = false;

     }


Transferred from the Adobe Open Source Subversion Repository

Revision: 11247
Author:   klin@adobe.com
Date:     2009-10-28T21:59:11.963883Z

Log Message:
-----------
Fix for https://bugs.adobe.com/jira/browse/SDK-23184.

Updated a bunch of Style metadata ASDocs to describe different defaults between the Halo and Spark themes. Also, fixed a few typos along the way.

defaults.css - rearranged a few styles to be in alphabetical order
Button.as - removed extra emphasizedSkin style metadata
Panel.as - added spark theme to borderAlpha metadata

QE notes: None
Doc notes: None
Bugs: SDK-23184
Reviewer: Glenn
Tests run: checkintests
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/TileListItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ProgressBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/ButtonBarButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ButtonBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateChooser.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Menu.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/halo/defaults.css</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/fl/video/NCManagerNative.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Container.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/metadata/SkinStyles.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Button.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ColorPicker.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/metadata/BorderStyles.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/FlexModuleFactory.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/treeClasses/TreeItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/metadata/TextStyles.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Application.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/LinkButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/menuClasses/MenuItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/PopUpButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Tree.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Panel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Accordion.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/colorPickerClasses/SwatchPanel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Application.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/framework/src/mx/controls/ComboBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/halo/PopUpMenuIcon.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/metadata/PaddingStyles.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManagerProxy.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/List.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/metadata/GapStyles.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/defaults.css</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DataGrid.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Label.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/fl/video/NCManagerDynamicStream.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/LinkBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/GroupBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/metadata/FocusStyles.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/supportClasses/AnimateTransformInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/BitmapImage.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/supportClasses/StrokedElement.as</path>

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

--- frameworks/projects/mx/src/mx/controls/DateField.as
+++ frameworks/projects/mx/src/mx/controls/DateField.as
@@ -141,7 +141,7 @@
  *  NumericStepper, ProgressBar, RadioButton, ScrollBar, Slider, and any
  *  components that support the borderStyle style.
  *  The default value depends on the component class;
- *  if not overriden for the class, the default value is 0xB7BABC.
+ *  if not overridden for the class, the default value is 0xB7BABC
  *
  *  @langversion 3.0
  *  @playerversion Flash 9
@@ -182,7 +182,9 @@
 /**
  *  Color of the highlight area of the date when the user holds the
  *  mouse pointer over a date in the DateChooser control.
- *  @default 0xE3FFD6
+ *
+ *  The default value for the Halo theme is 0xB2E1FF.
+ *  The default value for the Spark theme is 0xCEDBEF.
  *
  *  @langversion 3.0
  *  @playerversion Flash 9
@@ -194,7 +196,9 @@
 /**
  *  Color of the highlight area of the currently selected date
  *  in the DateChooser control.
- *  @default 0xCDFFC1
+ *
+ *  The default value for the Halo theme is 0x7FCEFF.
+ *  The default value for the Spark theme is 0xA8C6EE.
  *
  *  @langversion 3.0
  *  @playerversion Flash 9


Transferred from the Adobe Open Source Subversion Repository

Revision: 4279
Author:   shodgson@adobe.com
Date:     2008-12-10T18:25:13.673622Z

Log Message:
-----------
Bug: BLZ-289 - In Channel.as failover method need to do lookup of AdvancedChannelSet in try/catch block.
QA: Yes
Doc: No

Modified Paths:
--------------
/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/Channel.as

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

--- frameworks/projects/rpc/src/mx/messaging/Channel.as
+++ frameworks/projects/rpc/src/mx/messaging/Channel.as
@@ -1317,7 +1317,12 @@
         {
             _previouslyConnected = false;

-            var acs:Class = getDefinitionByName("mx.messaging.AdvancedChannelSet") as Class;
+            var acs:Class = null;
+            try
+            {
+                acs = getDefinitionByName("mx.messaging.AdvancedChannelSet") as Class;
+            }
+            catch (ignore:Error) {}
             var duration:int = -1;
             if (acs != null)
             {


name refactoring

name refactoring

--- RNLib/src/rnlib/net/amf/RemoteAmfService.as
+++ RNLib/src/rnlib/net/amf/RemoteAmfService.as
@@ -1458,29 +1458,52 @@
 		/**
 		 * @private
 		 * If plugin cancel operation is forced call fault handler
-		 * @param e
-		 */
-		protected function onPluginCancel(e:NetPluginEvent):void
-		{
-			var plugin:INetPlugin = e.target as INetPlugin;
+		 * @param event
+		 */
+		protected function onPluginCancel(event:NetPluginEvent):void
+		{
+			var plugin:INetPlugin = event.target as INetPlugin;
 			var vo:MethodVO = _plugins[plugin];
 			disposePlugin(plugin);
-
-			var rm:ResultMediatorVO = prepareResultMediator(vo);
+			callFinalFault(vo, event.data);
+		}
+
+		/**
+		 * @private
+		 * We will proceed only on ready/complete event
+		 * @param event
+		 */
+		protected function onPluginComplete(event:NetPluginEvent):void
+		{
+			var plugin:INetPlugin = event.target as INetPlugin;
+			var vo:MethodVO = _plugins[plugin];
+
+			try
+			{
+				vo.args = plugin.args;
+			}
+			catch (e:Error)
+			{
+				disposePlugin(plugin);
+				callFinalFault(vo, e);
+				return;
+			}
+
+			disposePlugin(plugin);
+			callRemoteMethod(vo);
 			vo.dispose();
-
-			onFault(e.data, rm.name, rm.id, rm.uid);
-		}
-
-		/**
-		 * @private
-		 * We will proceed only on ready/complete event
-		 * @param e
-		 */
-		protected function onPluginComplete(e:NetPluginEvent):void
-		{
-			var plugin:INetPlugin = e.target as INetPlugin;
+		}
+
+		/**
+		 * @private
+		 * MultipartPlugin is ready to share arguments for remote method
+		 * @param event
+		 */
+		protected function onMultipartPluginReady(event:NetPluginEvent):void
+		{
+			var plugin:INetMultipartPlugin = event.target as INetMultipartPlugin;
 			var vo:MethodVO = _plugins[plugin];
+			vo = vo.clone();

 			try
 			{
@@ -1494,34 +1517,6 @@
 				return;
 			}

-			disposePlugin(plugin);
-			callRemoteMethod(vo);
-			vo.dispose();
-		}
-
-		/**
-		 * @private
-		 * MultipartPlugin is ready to share arguments for remote method
-		 * @param e
-		 */
-		protected function onMultipartPluginReady(e:NetPluginEvent):void
-		{
-			var plugin:INetMultipartPlugin = e.target as INetMultipartPlugin;
-			var vo:MethodVO = _plugins[plugin];
-			vo = vo.clone();
-
-			try
-			{
-				vo.args = plugin.args;
-			}
-			catch (e:Error)
-			{
-				disposePlugin(plugin);
-				callFinalFault(vo, e);
-				vo.dispose();
-				return;
-			}
-
 			callRemoteMethod(vo, plugin);
 			vo.dispose();
 		}
@@ -1529,18 +1524,18 @@
 		/**
 		 * @private
 		 * MultipartPlugin finish successfully his work
-		 * @param e
-		 */
-		protected function onMultipartPluginComplete(e:NetPluginEvent):void
-		{
-			var plugin:INetMultipartPlugin = e.target as INetMultipartPlugin;
+		 * @param event
+		 */
+		protected function onMultipartPluginComplete(event:NetPluginEvent):void
+		{
+			var plugin:INetMultipartPlugin = event.target as INetMultipartPlugin;
 			var vo:MethodVO = _plugins[plugin];
 			disposePlugin(plugin);

 			var rm:ResultMediatorVO = prepareResultMediator(vo);
 			vo.dispose();

-			onResult(e.data, rm.name, rm.id, rm.uid);
+			onResult(event.data, rm.name, rm.id, rm.uid);
 		}

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


Tweaked sysdelayclock wording

Tweaked sysdelayclock wording

--- src/Modules/SysDelayClock.as
+++ src/Modules/SysDelayClock.as
@@ -40,7 +40,7 @@

 		override public function getDescription():String {
 			var edgeLength:int = configuration.value;
-			return "Outputs "+EDGE+" for "+edgeLength+" ticks every "+(U.state ? U.state.time.clockPeriod : '-')+" ticks, and "+NO_EDGE+" the rest of the time."
+			return "Outputs "+EDGE+" for the last "+edgeLength+" ticks out of every "+(U.state ? U.state.time.clockPeriod : '-')+"; outputs "+NO_EDGE+" the rest of the time."
 		}

 		protected function get delayLength():int {


Revert "Added StandardLib.join, a faster alternative to Array.join()."

This reverts commit 296a180b5d3b53f567d31382c899a6704c75ecb8.

--- WeaveCore/src/weave/compiler/StandardLib.as
+++ WeaveCore/src/weave/compiler/StandardLib.as
@@ -19,7 +19,6 @@

 package weave.compiler
 {
-	import flash.utils.ByteArray;
 	import flash.utils.getQualifiedClassName;

 	import mx.formatters.DateFormatter;
@@ -39,29 +38,6 @@
 	 */
 	public class StandardLib
 	{
-		/**
-		 * Same functionality as Array.join, only twice as fast.
-		 * @param array The Array (or Vector)
-		 * @param separator The separator
-		 * @return Each item in the array concatenated into a String using the given separator.
-		 */
-		public static function join(array:*, separator:String = ','):String
-		{
-			var first:Boolean = true;
-			var out:ByteArray = new ByteArray();
-			for each (var item:String in array)
-			{
-				if (first)
-					first = false;
-				else
-					out.writeUTFBytes(separator);
-
-				out.writeUTFBytes(item);
-			}
-			out.position = 0;
-			return out.readUTFBytes(out.length);
-		}
-
 		/**
 		 * This function will cast a value of any type to a Number,
 		 * interpreting the empty string ("") and null as NaN.


Attempt to improve performance/reliability of JavaScriptCanvas

--- WeaveUI/src/weave/ui/JavaScriptCanvas.as
+++ WeaveUI/src/weave/ui/JavaScriptCanvas.as
@@ -11,14 +11,17 @@
 	import flash.events.Event;
 	import flash.utils.Timer;
 	import flash.utils.getTimer;
+	import flash.utils.Dictionary;
 	import flash.events.TimerEvent;

 	public class JavaScriptCanvas extends Canvas implements ILinkableObject
 	{
 		private var buffers:Vector.<Image> = new Vector.<Image>(2, true);
 		private var buffer_index:int = 0;
-		private var lastUpdate:int = 0;
-		private var forceReadTimer:Timer;
+		private var last_update:int = 0;
+		private var buffer_dirty:Dictionary = new Dictionary();
+
+		private static const MIN_FRAME_INTERVAL:int = 1000/30;

 		public const elementId:LinkableString = newLinkableChild(this, LinkableString);

@@ -30,51 +33,76 @@

 		override protected function createChildren():void
 		{
-			lastUpdate = getTimer();
-			forceReadTimer = new Timer(250);
 			buffers[0] = new Image();
 			buffers[1] = new Image();

+			buffer_dirty[buffers[0]] = false;
+			buffer_dirty[buffers[1]] = false;
+
 			buffers[0].addEventListener(Event.COMPLETE, readFromCanvas);
 			buffers[1].addEventListener(Event.COMPLETE, readFromCanvas);
-			forceReadTimer.addEventListener(TimerEvent.TIMER, readFromCanvas);
+			addEventListener(Event.ENTER_FRAME, readFromCanvas);

 			addChild(buffers[0]);
 			addChild(buffers[1]);

 			super.createChildren();

-			forceReadTimer.start();
+			last_update = getTimer();
 		}

-		public function readFromCanvas(evt:Event):void
+		public function readFromCanvas(evt:Event = null):void
 		{
-			/* Only execute on the timer tick if we haven't loaded recently */
-			if (evt.type == TimerEvent.TIMER && (getTimer() < (lastUpdate + 200)) ) return;
+			var target:Image = evt.target as Image;
+
+			if (target)
+				buffer_dirty[target] = false;
+
+			var interval:int = getTimer() - last_update;
+
+			if (!elementId.value ||interval < MIN_FRAME_INTERVAL || buffer_dirty[buffers[buffer_index]])
+			{
+				return;
+			}

 			var content:String;

-			/* TODO convert to raw ExternalInterface */
-			if (elementId.value) content = JavaScript.exec(
+			last_update = getTimer();
+
+			buffer_index = (buffer_index + 1) % 2;
+
+			buffer_dirty[buffers[buffer_index]] = true;
+
+			WeaveAPI.StageUtils.callLater(this, updateImage);
+		}
+
+		public function updateImage():void
+		{
+			var content:String;
+			var current_buffer:Image = buffers[buffer_index];
+
+			if (!elementId.value)
+			{
+				buffer_dirty[current_buffer] = false;
+				return;
+			}
+
+			content = JavaScript.exec(
 				{elementId: elementId.value},
 				"var canvas = document.getElementById(elementId);",
 				"return canvas && canvas.toDataURL && canvas.toDataURL().split(',').pop();");

-			if (elementId.value && content)
+			if (!content)
 			{
-				setImage(content);
+				buffer_dirty[current_buffer] = false;
+				return;
 			}
-		}

-		public function setImage(base64:String):void
-		{
-			lastUpdate = getTimer();
+			setChildIndex(current_buffer, 1);

-			setChildIndex(buffers[buffer_index], 0);
+			current_buffer.source = StandardLib.atob(content);

-			buffer_index = (buffer_index + 1) % 2;
-
-			buffers[buffer_index].source = StandardLib.atob(base64);
+
 		}
 	}
 }


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@1261379 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/logging/errors/InvalidCategoryError.as
+++ frameworks/projects/framework/src/mx/logging/errors/InvalidCategoryError.as
@@ -1,3 +1,13 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2005-2006 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.logging.errors
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 1098
Author:   jimurphy@adobe.com
Date:     2008-04-03T21:50:39.896200Z

Log Message:
-----------
Merge 3.0.x -- 362:394, 427:429, 603:608, 644:645, 651:663, 672:676, 755:756, 763:766, 785:790, 812:814, 854:861, 862:866, 866:933,971:1009, 1050:1056 --> trunk

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/TileListItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/treeClasses/DefaultDataDescriptor.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/VRule.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/AsyncRequest.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/IList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/LayoutManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/channels/StreamingConnectionHandler.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/IRepeaterClient.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/videoClasses/VideoError.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/ObjectProxy.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/messages/HTTPRequestMessage.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/resources/Locale.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/ParallelInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/Responder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/errors/MessageSerializationError.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/messages/SOAPMessage.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/IBrowserManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ComponentDescriptor.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/events/FaultEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridColumn.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/IViewCursor.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/soap/AbstractWebService.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/Tween.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Panel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/DragManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/TextInput.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/menuClasses/IMenuItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/MessageResponder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/preloaders/Preloader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/ILayoutManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Spacer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Label.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/Fault.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/XMLListCollection.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/EffectTargetFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/SliderEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/AsyncToken.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/Window.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/resources/ResourceManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/ScrollEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/http/mxml/HTTPService.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/videoClasses/CuePointManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/CrossDomainRSLItem.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/NumericStepperEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/BrowserManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/events/ChannelFaultEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/TextArea.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/CursorBookmark.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/http/HTTPService.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/framework/src/mx/controls/ComboBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/soap/LoadEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/ListCollectionView.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/FlexClient.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/SubscriptionInfo.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/DescribeTypeCache.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/logging/LogLogger.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/FocusManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/MessageAgent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/build_framework.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/WindowedSystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/events/HeaderEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridDragProxy.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/preloaders/DownloadProgressBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/treeClasses/ITreeDataDescriptor.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/framework/src/mx/controls/listClasses/TileBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListItemDragProxy.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/ChannelSet.as</path>

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

--- frameworks/projects/mx/src/mx/controls/treeClasses/DefaultDataDescriptor.as
+++ frameworks/projects/mx/src/mx/controls/treeClasses/DefaultDataDescriptor.as
@@ -45,7 +45,7 @@
     include "../../core/Version.as";

     /**
-     *  Constructor
+     *  Constructor.
      */
     public function DefaultDataDescriptor()
     {
@@ -162,11 +162,12 @@
     }

     /**
-     *  Returns true if the node actually has children.
+     *  Determines if the node actually has children.
      *
      *  @param node The node object currently being evaluated.
      *  @param model The collection that contains the node; ignored by this class.
-     *  @return boolean indicating if this node currently has children
+     *
+     *  @return true if this node currently has children.
      */
     public function hasChildren(node:Object, model:Object = null):Boolean
     {
@@ -199,7 +200,8 @@
      *
      *  @param node The node object currently being evaluated.
      *  @param model The collection that contains the node; ignored by this class.
-     *  @return boolean indicating if this node is non-terminating
+     *
+     *  @return true if this node is non-terminating.
      */
     public function isBranch(node:Object, model:Object = null):Boolean
     {
@@ -284,11 +286,12 @@
      *

      *

      *
-     *  @param parent The node object that will parent the child
-     *  @param newChild The node object that will be parented by the node
-     *  @param index The 0-based index of where to put the child node relative to the parent
-     *  @param model The entire collection that this node is a part of
-     *  @return true if successful
+     *  @param parent The node object that will parent the child.
+     *  @param newChild The node object that will be parented by the node.
+     *  @param index The 0-based index of where to put the child node relative to the parent.
+     *  @param model The entire collection that this node is a part of.
+     *
+     *  @return true if successful.
      */
     public function addChildAt(parent:Object, newChild:Object, index:int, model:Object = null):Boolean
     {
@@ -358,11 +361,12 @@
      *  access the child; otherwise, it uses the parent parameter
      *  and ignores the model parameter.
     *
-     *  @param parent The node object that currently parents the child node
-     *  @param child The node that is being removed
-     *  @param index The 0-based index of  the child node to remove relative to the parent
-     *  @param model The entire collection that this node is a part of
-     *  @return true if successful
+     *  @param parent The node object that currently parents the child node.
+     *  @param child The node that is being removed.
+     *  @param index The 0-based index of  the child node to remove relative to the parent.
+     *  @param model The entire collection that this node is a part of.
+     *
+     *  @return true if successful.
      */
     public function removeChildAt(parent:Object, child:Object, index:int, model:Object = null):Boolean
     {
@@ -420,7 +424,8 @@
      *  a check box, or normal item.
      *
      *  @param node The node object for which to get the type.
-     *  @return  the value of the type attribute or field,
+     *
+     *  @return  The value of the type attribute or field,
      *  or the empty string if there is no such field.
      */
     public function getType(node:Object):String
@@ -447,9 +452,10 @@
      *  This method is used by menu-based controls.
      *
      *  @param node The node for which to get the status.
-     *  @return the value of the node's enabled
+     *
+     *  @return The value of the node's enabled
      *  attribute or field, or true if there is no such
-     *  entry or the value is not false.
+     *  entry or the value is not false.
      */
     public function isEnabled(node:Object):Boolean
     {
@@ -506,6 +512,7 @@
      *  This method is used by menu-based controls.
      *
      *  @param node The node for which to get the status.
+     *
      *  @return The value of the node's toggled
      *  attribute or field, or false if there is no such
      *  entry.


Transferred from the Adobe Open Source Subversion Repository

Revision: 9118
Author:   jszeto@adobe.com
Date:     2009-08-05T21:16:58.466037Z

Log Message:
-----------
DropDropList bug fix

http://bugs.adobe.com/jira/browse/SDK-22535 - Rolling over a programmatically opened Spark DropDownList causes the DropDownList to close itself

In ButtonBase, when the keepDown property was set to true while the mouse was not over the button, a subsequent rollover caused the ButtonDown event to be dispatched. The fix is to change keepDown from a property to a function and introduce a second parameter that stops the Button from dispatching the ButtonDown in this situation.

DropDownController needs to call keepDown in two different ways depending upon whether the component was opened via mouse interaction on the button or via keyboard interaction / programmatically. I didn’t want to add a new parameter to the public API, so I refactored the function and change the way it is called internally.

QE notes: Add test case
Doc notes: None
Bugs: SDK-22535
Reviewer: Ryan
Tests run: DropDownList, Button
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/DropDownController.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/ButtonBase.as</path>

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

--- frameworks/projects/spark/src/spark/components/supportClasses/ButtonBase.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/ButtonBase.as
@@ -593,25 +593,24 @@
     /**
      *  @private
      *  If true, forces the button to be in the down state
-     */
-    mx_internal function set keepDown(value:Boolean):void
-    {
-        if (_keepDown == value)
+     *  Set fireEvent to false if you want to supress the ButtonDown event.
+     *  This is useful if you have programmatically set keepDown but the
+     *  mouse is not over the button.
+     */
+    mx_internal function keepDown(down:Boolean, fireEvent:Boolean = true):void
+    {
+        if (_keepDown == down)
             return;

-        _keepDown = value;
+        _keepDown = down;
+
+        if (!fireEvent) // Don't let the ButtonDown event get fired
+            _downEventFired = true;
+
         if (_keepDown)
             invalidateSkinState();
         else
             invalidateButtonState();
-    }
-
-    /**
-     *  @private
-     */
-    mx_internal function get keepDown():Boolean
-    {
-        return _keepDown;
     }

@@ -694,7 +693,7 @@
         if (!enabled)
             return false;

-        if (keepDown)
+        if (_keepDown)
             return true;

         if (keyboardPressed)


Transferred from the Adobe Open Source Subversion Repository

Revision: 3057
Author:   jimurphy@adobe.com
Date:     2008-09-02T15:18:38.819662Z

Log Message:
-----------
Merged 3.0.x revisions [2966,2969,2995,3004,3018-3019,3023,3029-3030,3046,3049,3052] -> trunk

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/TileListItemRenderer.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/ModalWindowRequest.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Menu.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/dragClasses/DragProxy.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/PopUpManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Button.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ColorPicker.as</path>
<path kind="file" copyfrom-path="/flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/InterDragManagerEvent.as" copyfrom-rev="3052" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/InterDragManagerEvent.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/PopUpRequest.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManagerGlobals.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/SWFBridgeEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/systemClasses/EventProxy.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/ISystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/tools/dependencychecker/flex/tools/dependencychecker/FrameworkSwcDependencyRules.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/sliderClasses/SliderThumb.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/treeClasses/TreeItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/DividedBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/DragManagerImpl.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/SizeRequest.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridHeader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/SWFLoader.as</path>
<path kind="file" copyfrom-path="/flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/InterManagerRequest.as" copyfrom-rev="3052" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/InterManagerRequest.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/NativeDragManagerImpl.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/FocusRequest.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/wsdl/WSDL.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/PopUpButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/scrollClasses/ScrollBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/dividedBoxClasses/BoxDivider.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Panel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/SandboxRootDragEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/FocusManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/WindowedSystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ComboBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManager.as</path>
<path kind="file" copyfrom-path="/flex/sdk/branches/3.0.x/frameworks/projects/framework/src/mx/events/SandboxMouseEvent.as" copyfrom-rev="3052" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/SandboxMouseEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/List.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManagerProxy.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/SandboxRootRequest.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/EventUtil.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/SandboxRootMouseEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ScrollControlBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DataGrid.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/sliderClasses/Slider.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/CursorManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/SWFBridgeRequest.as</path>

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

--- frameworks/projects/framework/src/mx/managers/ISystemManager.as
+++ frameworks/projects/framework/src/mx/managers/ISystemManager.as
@@ -399,8 +399,9 @@
      *  @param event Event to dispatch
      *  @param skip IEventDispatcher to not dispatch from
      *  @param trackClones Whether to keep a reference to the events as they are dispatched
-	 */
-	function dispatchEventFromSWFBridges(event:Event, skip:IEventDispatcher = null, trackClones:Boolean = false):void
+     *  @param toOtherSystemManagers Whether to dispatch to other top level SystemManagers
+	 */
+	function dispatchEventFromSWFBridges(event:Event, skip:IEventDispatcher = null, trackClones:Boolean = false, toOtherSystemManagers:Boolean = false):void

     /**
      *  Determines if the caller using this system manager


Bug 504567: remove one garbage test that snuck in with previous patch

--- test/acceptance/ecma3/String/split_504567.as
+++ test/acceptance/ecma3/String/split_504567.as
@@ -63,12 +63,6 @@
                                     "'babab'.split(/a*/)",
                                     "b,b,b",
                                     'babab'.split(/a*/).toString() );
-
-    array[item++] = new TestCase(   SECTION,
-                                    "fff",
-                                    "b,b,b",
-                                    'abab'.replace("/a*/", "g").toString() );
-

     return array;


Fixed the ParserOptions.defaultMaterialFunction that always ignored the ParserOptions.material even when explicitly specified.

--- src/aerys/minko/type/loader/parser/ParserOptions.as
+++ src/aerys/minko/type/loader/parser/ParserOptions.as
@@ -223,7 +223,7 @@
 		private function defaultMaterialFunction(materialName	: String,
 												 material		: Material) : Material
 		{
-			return material;
+			return _material ? _material : material; // default material if nothing
 		}
     }
 }


Transferred from the Adobe Open Source Subversion Repository

Revision: 12850
Author:   jimurphy@adobe.com
Date:     2009-12-11T14:57:14.623098Z

Log Message:
-----------
add 6 new DMV projects to the SDK:
automation
automation_air
automation_dmv
automation_flashflexkit
automation_spark
datavisualization

These projects are setup to build in an ant main call.  There are currently several warnings in the datavisualization project that will be cleaned up.  No checkintests exist for these projects as of yet.

I also modified the exisitng projects build files for easier management of the localization targets, bundle and fat-swc. If the projects that I updated:airframework,airspark,framework,playerglobal,rpc,and spark.  All the new projects have been implemented this same way.

QE notes: DMV folks should run through their tests
Doc notes: probably
Bugs: nope
Reviewer:
Tests run: ran the following targets: compile,checkintests,other.locales and doc
Is noteworthy for integration: no

Modified Paths:
--------------
1404 paths were modified

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

--- frameworks/projects/automation/src/mx/automation/codec/KeyModifierPropertyCodec.as
+++ frameworks/projects/automation/src/mx/automation/codec/KeyModifierPropertyCodec.as
@@ -0,0 +1,84 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  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.automation.codec
+{
+
+	import mx.automation.qtp.IQTPPropertyDescriptor;
+	import mx.automation.IAutomationManager;
+	import mx.automation.IAutomationObject;
+
+	/**
+	 * Translates between internal Flex keyModifiers and automation-friendly ones.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public class KeyModifierPropertyCodec extends DefaultPropertyCodec
+	{
+		/**
+		 *  Constructor
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 9
+		 *  @playerversion AIR 1.1
+		 *  @productversion Flex 3
+		 */
+		public function KeyModifierPropertyCodec()
+		{
+			super();
+		}
+
+		/**
+		 *  @private
+		 */
+		override public function encode(automationManager:IAutomationManager,
+										obj:Object,
+										pd:IQTPPropertyDescriptor,
+										relativeParent:IAutomationObject):Object
+		{
+			var val:int = 0;
+
+			if ("ctrlKey" in obj && Boolean(obj["ctrlKey"]))
+				val |= (1 << 0);
+
+			if ("shiftKey" in obj && Boolean(obj["shiftKey"]))
+				val |= (1 << 1);
+
+			if ("altKey" in obj && Boolean(obj["altKey"]))
+				val |= (1 << 2);
+
+			return val;
+		}
+
+		/**
+		 *  @private
+		 */
+		override public function decode(automationManager:IAutomationManager,
+										obj:Object,
+										value:Object,
+										pd:IQTPPropertyDescriptor,
+										relativeParent:IAutomationObject):void
+		{
+			if ("ctrlKey" in obj)
+				obj["ctrlKey"] = (uint(value) & (1 << 0)) != 0;
+
+			if ("shiftKey" in obj)
+				obj["shiftKey"] = (uint(value) & (1 << 1)) != 0;
+
+			if ("altKey" in obj)
+				obj["altKey"] = (uint(value) & (1 << 2)) != 0;
+		}
+	}
+
+}


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@1268893 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/mx/src/mx/controls/listClasses/ListBaseSelectionDataPending.as
+++ frameworks/projects/mx/src/mx/controls/listClasses/ListBaseSelectionDataPending.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2005-2006 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.listClasses
 {


fixed infinite async task loop

fixed infinite async task loop

Change-Id: If4b663b6e89f0252af059f9e39d5ccf641404be4

--- WeaveData/src/weave/data/BinningDefinitions/NaturalJenksBinningDefinition.as
+++ WeaveData/src/weave/data/BinningDefinitions/NaturalJenksBinningDefinition.as
@@ -110,7 +110,7 @@

 			_compoundIterateAll(-1); // reset compound task

-			WeaveAPI.StageUtils.startTask(this, _compoundIterateAll, WeaveAPI.TASK_PRIORITY_PARSING, _handleJenksBreaks);
+			WeaveAPI.StageUtils.startTask(asyncResultCallbacks, _compoundIterateAll, WeaveAPI.TASK_PRIORITY_PARSING, _handleJenksBreaks);
 		}

 		private var _compoundIterateAll:Function = StageUtils.generateCompoundIterativeTask(_getValueFromKeys, _iterateSortedKeys, _iterateJenksBreaks);