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

--- frameworks/projects/framework/src/mx/core/MXMLObjectAdapter.as
+++ frameworks/projects/framework/src/mx/core/MXMLObjectAdapter.as
@@ -1,11 +1,19 @@
 ////////////////////////////////////////////////////////////////////////////////
 //
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2004-2006 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: 6122
Author:   chaase@adobe.com
Date:     2009-04-10T14:30:17.762458Z

Log Message:
-----------
Various refactorings/renamings/changes from effects PARB review.

QE Notes: mx/effects and spark/effects currently broken (and disabled) due to these API changes. Matt is fixing.
Doc Notes: None
Bugs:
Reviewer: Hans
tests: checkintests, mustella tests/ListDataEffects

Modified Paths:
--------------
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/easing/EaseInOut.as" copyfrom-rev="5944" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/easing/EaseInOutBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/CompositeEffectInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransformMove.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/easing/EaseInOut.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/easing/EasingFraction.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/easing/Power.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/EffectEvent.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/framework/src/mx/effects/Effect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/TweenEffectInstance.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/Animate.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/animation/RepeatBehavior.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/spark-manifest.xml</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/interpolation/NumberArrayInterpolator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransformScale.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/IEffect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/Animate3DInstance.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimationProperty.as" copyfrom-rev="5944" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/SimpleMotionPath.as</path>
<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/animation/Animation.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/framework/src/mx/effects/EffectInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/Resize.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/easing/Sine.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/Rotate3DInstance.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/events/AnimationEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/interpolation/ArrayInterpolator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/IEffectInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransform.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/supportClasses/RotateInstance.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/animation/IAnimationTarget.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/MotionPath.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimationProperty.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/framework/src/mx/effects/effectClasses/SequenceInstance.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/AnimateTransformRotate.as</path>

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

--- frameworks/projects/framework/src/mx/effects/EffectInstance.as
+++ frameworks/projects/framework/src/mx/effects/EffectInstance.as
@@ -323,17 +323,12 @@
     //----------------------------------
     //  playheadTime
     //----------------------------------
-
-    // TODO (chaase): This property should be in an interface, to
-    // allow it to be called easily through an interface instead of
-    // having to import Effect just to call it
-    // TODO (chaase): Consider renaming this property; playheadTime
-    // is very video-specific
-    /**
-     *  The current position of the effect, in milliseconds.
-     *  This value is between 0 and the value of the
-     *  duration property.
-     *  Use the seek() method to change the position of the effect.
+
+    /**
+     *  Current time position of the effect.
+     *  This property has a value between 0 and the total duration,
+     *  which includes the Effect's startDelay,
+     *  repeatCount, and repeatDelay.
      *
      *  @langversion 3.0
      *  @playerversion Flash 9
@@ -345,6 +340,15 @@
         return Math.max(playCount - 1, 0) * (duration + repeatDelay) +
                (playReversed ? 0 : startDelay);
     }
+
+    /**
+     * @private
+     */
+    public function set playheadTime(value:Number):void
+    {
+        // Nothing to do for non-animated effects: subclasses should override
+    }
+

     //----------------------------------
     //  playReversed
@@ -597,11 +601,6 @@
     //  Methods
     //
     //--------------------------------------------------------------------------
-
-    public function seek(seekTime:Number):void
-    {
-        // Nothing to do for non-animated effects
-    }

     /**
      *  @copy mx.effects.IEffectInstance#initEffect()


Transferred from the Adobe Open Source Subversion Repository

Revision: 19127
Author:   aharui@adobe.com
Date:     2010-12-08T00:17:29.798813Z

Log Message:
-----------
Reset minorSize only in certain situations to prevent looping bug.

QE notes: none
Doc notes: none
Bugs: SDK-28585
Reviewer: Hans, Evtim
Tests run: checkintests mustella full run
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/layouts/supportClasses/LayoutBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/layouts/supportClasses/LinearLayoutVector.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/layouts/HorizontalLayout.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/layouts/VerticalLayout.as</path>

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

--- frameworks/projects/spark/src/spark/layouts/HorizontalLayout.as
+++ frameworks/projects/spark/src/spark/layouts/HorizontalLayout.as
@@ -143,6 +143,16 @@
      */
     private var flexibleWidth:Number;

+    /**
+     *  @private
+     */
+    private var lastEstimatedHeight:Number;
+
+    /**
+     *  @private
+     */
+    private var inUpdateDisplayListVirtual:Boolean;
+
     //--------------------------------------------------------------------------
     //
     //  Class methods
@@ -1011,13 +1021,41 @@
             return;

         if (_target)
-            _target.removeEventListener(FlexEvent.MEASURED_SIZE_PRELIMINARY, measuredSizePreliminaryHandler);
+        {
+            if (useVirtualLayout)
+                _target.removeEventListener(FlexEvent.MEASURED_SIZE_PRELIMINARY, measuredSizePreliminaryHandler);
+        }
         _target = value;
         super.target = value;
         if (value)
-            value.addEventListener(FlexEvent.MEASURED_SIZE_PRELIMINARY, measuredSizePreliminaryHandler, false, 0, true);
-    }
-
+        {
+            if (useVirtualLayout)
+                value.addEventListener(FlexEvent.MEASURED_SIZE_PRELIMINARY, measuredSizePreliminaryHandler, false, 0, true);
+        }
+    }
+
+    //----------------------------------
+    //  useVirtualLayout
+    //----------------------------------
+
+    /**
+     * @private
+     */
+    override public function set useVirtualLayout(value:Boolean):void
+    {
+        if (_useVirtualLayout == value)
+            return;
+
+        if (_target)
+        {
+            if (value)
+                _target.addEventListener(FlexEvent.MEASURED_SIZE_PRELIMINARY, measuredSizePreliminaryHandler, false, 0, true);
+            else
+                _target.removeEventListener(FlexEvent.MEASURED_SIZE_PRELIMINARY, measuredSizePreliminaryHandler);
+        }
+        super.useVirtualLayout = value;
+    }
+
     //--------------------------------------------------------------------------
     //
     //  Methods
@@ -1092,11 +1130,12 @@
      */
     override public function estimateSizesOfElements():void
     {
-        if (llv)
+        if (llv && target.estimatedHeight != lastEstimatedHeight && llv.minorSizeBasedOnLayoutSize)
         {
             llv.minorSize = 0;
             llv.minMinorSize = 0;
         }
+        lastEstimatedHeight = target.estimatedHeight;

         var size:SizesAndLimit = new SizesAndLimit();
         var spaceToDistribute:Number = !isNaN(target.explicitWidth) ? target.explicitWidth : target.estimatedWidth;
@@ -2158,7 +2197,7 @@
         // simply start from minVisibleX - SDK-22497.
         var startIndex:int = llv.indexOf(Math.max(0, minVisibleX + gap));
         if (startIndex == -1)
-            return;
+            return;

         var fixedColumnWidth:Number = NaN;
         if (!variableColumnWidth)
@@ -2188,8 +2227,6 @@
             // not final
 			if (!notFinalTargets)
 				notFinalTargets = [];
-			else
-	            notFinalTargets.length = 0;
 			// request element, but skip validation (especially of the displaylist)
 			elt = layoutTarget.getVirtualElementAt(index, eltWidth, eltHeight, true);
 			// then validate everything but the displaylist so there are valid
@@ -2217,6 +2254,7 @@
 					notFinalComponents[t] = index;

 				}
+                notFinalTargets.length = 0;
 				if (!notFinalIndexes)
 					notFinalIndexes = [];
                 // remember that this index didn't want to be cached
@@ -2560,11 +2598,20 @@
             if (layoutTarget.numElements == 0)
                 layoutTarget.setContentSize(Math.ceil(paddingLeft + paddingRight),
                                             Math.ceil(paddingTop + paddingBottom));
+            if (notFinalTargets)
+                notFinalTargets.length = 0;
             return;
         }

         if (useVirtualLayout)
-            updateDisplayListVirtual();
+        {
+            inUpdateDisplayListVirtual = true;
+            updateDisplayListVirtual();
+            inUpdateDisplayListVirtual = false;
+
+            if (notFinalTargets)
+                notFinalTargets.length = 0;
+        }
         else
             updateDisplayListReal();
     }
@@ -2603,6 +2650,9 @@
      */
     private function measuredSizePreliminaryHandler(event:FlexEvent):void
     {
+        if (!inUpdateDisplayListVirtual)
+            return;
+
         event.target.addEventListener(FlexEvent.MEASURED_SIZE_FINAL, measuredSizeFinalHandler, false, 0, true);
 		if (!notFinalTargets)
 			notFinalTargets = [];
@@ -2624,8 +2674,7 @@
 		if (notFinalComponents)
         	delete notFinalComponents[event.target];
     }
-
-
+
     //--------------------------------------------------------------------------
     //
     //  Drop methods


Transferred from the Adobe Open Source Subversion Repository

Revision: 3270
Author:   hmuller@adobe.com
Date:     2008-09-19T14:38:31.675747Z

Log Message:
-----------
Added row/column visibility tracking to Vertical,HorizontalLayout.
This is an incremental change aimed at enabling step/page scrolling
and animated scrolling.

Added new bindable read-only properties firstIndexInView and
lastIndexInView to VerticalLayout.  They track the first/last row
that's within the layout target's scrollRect and included in the
layout.  Note that any other row within this range may not actually be
"in view" (or visible) because its item could be null or
includeInLayout=false, or have height=0, etc.

Exposed these properties on VGroup.

Added a VerticalLayout method called inView that reports if a
particular row is "in view" or partially so.

Made comparable changes to HorizontalLayout, HGroup.

QE: No
Doc: No
Checkintests: Pass
Reviewer: Evtim

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/component/VGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/layout/HorizontalLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/layout/VerticalLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/component/HGroup.as</path>

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

--- frameworks/projects/spark/src/spark/layouts/HorizontalLayout.as
+++ frameworks/projects/spark/src/spark/layouts/HorizontalLayout.as
@@ -11,10 +11,13 @@

 package flex.layout
 {
+import flash.display.DisplayObject;
 import flash.geom.Rectangle;
+import flash.events.Event;
 import flash.events.EventDispatcher;

 import flex.core.GroupBase;
+import flex.graphics.IGraphicElement;
 import flex.intf.ILayout;
 import flex.intf.ILayoutItem;

@@ -315,6 +318,140 @@
         }
     }

+    //----------------------------------
+    //  firstIndexInView
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    private var _firstIndexInView:int = -1;
+
+    [Inspectable(category="General")]
+    [Bindable("indexInViewChanged")]
+
+    /**
+     *  The index of the first column that's part of the layout and within
+     *  the layout target's scrollRect, or -1 if nothing has been displayed yet.
+     *
+     *  Note that the column may only be partially in view.
+     *
+     *  @see lastIndexInView
+     *  @see inView
+     */
+    public function get firstIndexInView():int
+    {
+        return _firstIndexInView;
+    }
+
+
+    //----------------------------------
+    //  lastIndexInView
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    private var _lastIndexInView:int = -1;
+
+    [Inspectable(category="General")]
+    [Bindable("indexInViewChanged")]
+
+    /**
+     *  The index of the last column that's part of the layout and within
+     *  the layout target's scrollRect, or -1 if nothing has been displayed yet.
+     *
+     *  Note that the column may only be partially in view.
+     *
+     *  @see firstIndexInView
+     *  @see inView
+     */
+    public function get lastIndexInView():int
+    {
+        return _lastIndexInView;
+    }
+
+    /**
+     *  Sets the firstIndexInView and lastIndexInView
+     *  properties and dispatches a "indexInViewChanged"
+     *  event.
+     *
+     *  This method is intended to be used by subclasses that
+     *  override updateDisplayList() to sync the first and
+     *  last indexInView properties with the current display.
+     *
+     *  @param firstIndex The new value for firstIndexInView.
+     *  @param lastIndex The new value for lastIndexInView.
+     *
+     *  @see firstIndexInView
+     *  @see lastIndexInview
+     */
+    protected function setIndexInView(firstIndex:int, lastIndex:int):void
+    {
+        if ((_firstIndexInView == firstIndex) && (_lastIndexInView == lastIndex))
+            return;
+
+        _firstIndexInView = firstIndex;
+        _lastIndexInView = lastIndex;
+        dispatchEvent(new Event("indexInViewChanged"));
+    }
+
+    /**
+     *  An index is "in view" if the corresponding non-null layout item is
+     *  within the horizontal limits of the layout target's scrollRect
+     *  and included in the layout.
+     *
+     *  Returns 1.0 if the specified index is completely in view, 0.0 if
+     *  it's not, and a value in between if the index is partially
+     *  within the view.
+     *
+     *  If the specified index is partially within the view, the
+     *  returned value is the percentage of the corresponding
+     *  layout item that's visible.
+     *
+     *  Returns 0.0 if the specified index is invalid or if it corresponds to
+     *  null item, or a ILayoutItem for which includeInLayout is false.
+     *
+     *  @return the percentage of the specified item that's in view.
+     *  @see firstIndexInView
+     *  @see lastIndexInView
+     */
+   public function inView(index:int):Number
+    {
+        var vp:GroupBase = GroupBase(target);
+        if (!vp)
+            return 0.0;
+
+        var li:ILayoutItem = vp.getLayoutItemAt(index);
+        if ((li == null) || !li.includeInLayout)
+            return 0.0;
+
+        var c0:int = firstIndexInView;
+        var c1:int = lastIndexInView;
+
+        // outside the visible index range
+        if ((c0 == -1) || (c1 == -1) || (index < c0) || (index > c1))
+            return 0.0;
+
+        // within the visible index range, but not first or last
+        if ((index > c0) && (index < c1))
+            return 1.0;
+
+        // index is first (c0) or last (c1) visible column
+        var x0:Number = vp.horizontalScrollPosition;
+        var x1:Number = x0 + vp.width;
+        var ix0:Number = li.actualPosition.x;
+        var ix1:Number = ix0 + li.actualSize.x;
+        if (ix0 >= ix1)  // item has 0 or negative height
+            return 0.0;
+        if ((ix0 >= x0) && (ix1 <= x1))
+            return 1.0;
+        if (index == c0)
+            return (ix1 - x0) / (ix1 - ix0);
+        else
+            return (x1 - ix0) / (ix1 - ix0);
+    }
+

     public function variableColumnWidthMeasure(layoutTarget:GroupBase):void
     {
@@ -461,32 +598,51 @@
         // TODO EGeorgie: verticalAlign
         var vAlign:Number = 0;

-
         // If columnCount wasn't set, then as the LayoutItems are positioned
         // we'll count how many columns fall within the layoutTarget's scrollRect
         var visibleColumns:uint = 0;
         var minVisibleX:Number = layoutTarget.horizontalScrollPosition;
         var maxVisibleX:Number = minVisibleX + unscaledWidth

-        // Finally, position the objects
+        // Finally, position the LayoutItems and find the first/last
+        // visible indices, the content size, and the number of
+        // visible items.
         var x:Number = 0;
         var maxX:Number = 0;
-        var maxY:Number = 0;
-        for each (var lo:ILayoutItem in layoutItemArray)
-        {
+        var maxY:Number = 0;
+        var firstColInView:int = -1;
+        var lastColInView:int = -1;
+
+        for (var index:int = 0; index < count; index++)
+        {
+            var lo:ILayoutItem = layoutTarget.getLayoutItemAt(index);
+            if (!layoutItem || !layoutItem.includeInLayout)
+                continue;
+
+            // Set the layout item's acutual size and position
             var y:Number = (unscaledHeight - lo.actualSize.y) * vAlign;
             lo.setActualPosition(x, y);
             var dy:Number = lo.actualSize.y;
             if (!variableColumnWidth)
-            	lo.setActualSize(columnWidth, dy);
+                lo.setActualSize(columnWidth, dy);
+
+            // Update maxX,Y, first,lastVisibleIndex, and x
             var dx:Number = lo.actualSize.x;
             maxX = Math.max(maxX, x + dx);
             maxY = Math.max(maxY, y + dy);
             if((x < maxVisibleX) && ((x + dx) > minVisibleX))
-            	visibleColumns += 1;
+            {
+                visibleColumns += 1;
+                if (firstColInView == -1)
+                   firstColInView = lastColInView = index;
+                else
+                   lastColInView = index;
+            }
             x += dx + gap;
         }
+
         setColumnCount(visibleColumns);
+        setIndexInView(firstColInView, lastColInView);
         layoutTarget.setContentSize(maxX, maxY);
     }


fixed small things

fixed small things

--- src/hype/framework/core/ObjectCollection.as
+++ src/hype/framework/core/ObjectCollection.as
@@ -1,4 +1,4 @@
-package hype.framework.collection {
+package hype.framework.core {

 	public class ObjectCollection {


Add empty methods on the fuse script that can be used when we are hovering a fuse in a certain slot.


Add a getter to get the frameId from the viewport

--- src/aerys/minko/render/Viewport.as
+++ src/aerys/minko/render/Viewport.as
@@ -115,6 +115,11 @@
 			}
 		}

+		public function get frameId() : uint
+		{
+			return _renderer.frameId;
+		}
+
 		public function get sceneSize() : uint
 		{
 			return _sceneSize;


- bugfix: Resources didn't set didSucceed

git-svn-id: e38e7cdd6ace00d8230583a2d3b43e9a55f5c011@444 bc4816be-ef27-423a-9c4d-fc420be121a2

--- src/reprise/external/AbstractResource.as
+++ src/reprise/external/AbstractResource.as
@@ -309,6 +309,8 @@
 				trace(errMsg);
 			}

+			m_didSucceed = success;
+
 			dispatchEvent(new ResourceEvent(Event.COMPLETE,
 				success, m_failureReason, m_httpStatus));
 			m_isExecuting = false;


Halt tests after a failure

Halt tests after a failure

--- exporter/src/test/as/flump/test/TestRunner.as
+++ exporter/src/test/as/flump/test/TestRunner.as
@@ -58,6 +58,7 @@
             _failed.push(name)
             if (f.result is Error) log.error("Failed", "test", name, f.result);
             else log.error("Failed", "test", name, "reason", f.result);
+            _exec.shutdownNow();
         }
         if (_exec.isIdle) _exec.shutdown();
     }


Transferred from the Adobe Open Source Subversion Repository

Revision: 5115
Author:   rfrishbe@adobe.com
Date:     2009-02-27T21:27:41.731597Z

Log Message:
-----------
Adding SpriteVisualElement, a light-weight, Sprited-based implementation of IVisualElement.  This will be used for some FXG compiler optimizations.

Added setter for includeInLayout into IVisualElement so that DataGroup's virtualization code can use this, rather than cast it to a UIComponent.  I also removed an unused method in DataGroup: _removeChild.  We needed this before to remove children on a previously parented DataGroup, but now that we do the cleanup pro-actively, this is no longer needed.

Also a few ASDoc cleanups in IVisualElement, ILayoutElement, and FxDataContainer.

QE Notes: -
Doc Notes: -
Bugs: -
Reviewer: Chet, Evtim
tests: checkintests, mustella list, datagroup, fxdatacontainer, buttonbar.  Some mustella were failing, but I think it's just a mac thing.

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/IVisualElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/DataGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/Flex4Classes.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/core/SpriteVisualElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxDataContainer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ILayoutElement.as</path>

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

--- frameworks/projects/spark/src/SparkClasses.as
+++ frameworks/projects/spark/src/SparkClasses.as
@@ -23,6 +23,7 @@
  *  For example, Button does not have a reference to ButtonSkin,
  *  but ButtonSkin needs to be in framework.swc along with Button.
  */
+import mx.core.SpriteVisualElement; SpriteVisualElement;
 import mx.skins.spark.FxApplicationSkin; FxApplicationSkin;
 import mx.skins.spark.FxButtonSkin; FxButtonSkin;
 import mx.skins.spark.FxDefaultButtonSkin; FxDefaultButtonSkin;


added DrawUtils.drawDashedLine()

added DrawUtils.drawDashedLine()

--- WeaveUISpark/src/weave/utils/DrawUtils.as
+++ WeaveUISpark/src/weave/utils/DrawUtils.as
@@ -117,6 +117,53 @@
 				graphics.lineTo(endX, endY);
 			else
 				graphics.curveTo(startX + (endX - startX)/2, startY + (1 - curvature)/2*(endY - startY), endX, endY);
+		}
+
+		/**
+		 * Draws a dashed line using lineTo/moveTo with the current lineStyle of a Graphics object.
+		 * @param graphics The Graphics object on which to draw.
+		 * @param points A list of Point objects defining a polyline.
+		 * @param dashedLengths A list of alternating segment and gap lengths.
+		 */
+		public static function drawDashedLine(graphics:Graphics, points:Array, dashedLengths:Array):void
+		{
+			if (!graphics || !points || !dashedLengths || points.length == 0)
+				return;
+
+			var a:Point = new Point();
+			var b:Point = new Point();
+			var iPoint:int = 1;
+			var iDash:int = 0;
+			var dashLength:Number = dashedLengths[0];
+
+			a.x = points[0].x;
+			a.y = points[0].y;
+			graphics.moveTo(a.x, a.y);
+
+			while (iPoint < points.length && isFinite(dashLength))
+			{
+				b.x = points[iPoint].x;
+				b.y = points[iPoint].y;
+				var segmentLength:Number = Point.distance(a, b);
+
+				if (!isFinite(segmentLength))
+					break;
+
+				var c:Point = Point.interpolate(b, a, Math.min(dashLength / segmentLength, 1));
+				if (iDash % 2)
+					graphics.moveTo(c.x, c.y);
+				else
+					graphics.lineTo(c.x, c.y);
+				a = c;
+
+				if (segmentLength <= dashLength) // segment ended
+					++iPoint;
+
+				if (segmentLength < dashLength) // segment ended before dash
+					dashLength -= segmentLength; // partial dash progression
+				else // dash ended
+					dashLength = dashedLengths[++iDash % dashedLengths.length];
+			}
 		}
 	}
 }


Remove the juggler when removed

Remove the juggler when removed

--- runtime/src/main/as/flump/display/Movie.as
+++ runtime/src/main/as/flump/display/Movie.as
@@ -123,7 +123,7 @@

     protected function addedToStage (..._) :void { Starling.juggler.add(_ticker); }

-    protected function removedFromStage (..._) :void { Starling.juggler.add(_ticker); }
+    protected function removedFromStage (..._) :void { Starling.juggler.remove(_ticker); }

     protected var _goingToFrame :Boolean;
     protected var _pendingFrame :int = NO_FRAME;


Replaced soft tabs with hard tabs in AS file.

--- dev/com/createjs/soundjs/FlashAudioPlugin.as
+++ dev/com/createjs/soundjs/FlashAudioPlugin.as
@@ -91,7 +91,7 @@
 				getDurationBySrc: handleGetDurationBySrc,
 				setLoop: handleSetLoop,

-                setMasterVolume: handleSetMasterVolume,
+				setMasterVolume: handleSetMasterVolume,

 				command: handleCommand
 			};
@@ -106,7 +106,7 @@
 				for (var n:String in map) {
 					ExternalInterface.addCallback(n, map[n]);
 				}
-                // NOTE this is in an ENTER_FRAME to deal with a race issue in IE caused by caching
+				// NOTE this is in an ENTER_FRAME to deal with a race issue in IE caused by caching
 				this.addEventListener(Event.ENTER_FRAME, handleReady, false, 0, true);
 			} catch (e:*) {
 				handleError(e);
@@ -207,7 +207,7 @@

 			lookup[id] = wrapper;
 			wrapper.addEventListener(Event.SOUND_COMPLETE, handleSoundFinished, false, 0, true);
-            wrapper.addEventListener("loop", handleSoundLoop, false, 0, true);
+			wrapper.addEventListener("loop", handleSoundLoop, false, 0, true);
 			wrapper.addEventListener("interrupt", handleSoundInterrupt, false, 0, true);
 			log("Play Sound", id, src, "o:",offset, "l:",loop, "v:",volume, "p:",pan, "sT:",startTime, "d:",duration, "mv:",masterVolume);
 			return id;
@@ -222,14 +222,14 @@
 			log("Complete", wrapper.id, "Remaining:", activeSoundCount);
 		}

-        // An instance loop callback.
-        protected function handleSoundLoop(event:Event):void {
-            var wrapper:SoundWrapper = event.target as SoundWrapper;
-            ExternalInterface.call(SOUND_CALLBACK, wrapper.id, "handleSoundLoop");
-            log("Loop", wrapper.id, "Remaining:", wrapper.loop);
-        }
-
-        protected function handleSoundInterrupt(id:String):void {
+		// An instance loop callback.
+		protected function handleSoundLoop(event:Event):void {
+			var wrapper:SoundWrapper = event.target as SoundWrapper;
+			ExternalInterface.call(SOUND_CALLBACK, wrapper.id, "handleSoundLoop");
+			log("Loop", wrapper.id, "Remaining:", wrapper.loop);
+		}
+
+		protected function handleSoundInterrupt(id:String):void {
 			var wrapper:SoundWrapper = getWrapper(id, true);
 			if (wrapper != null) {
 				log("Interrupted", wrapper.id);
@@ -582,17 +582,17 @@

 	/** Get/Set the playhead position. */
 	public function get position():Number {
-        if (channel != null && !_paused) {
-            return channel.position - this._startTime;
-        }
-        return offset;
-    }
+		if (channel != null && !_paused) {
+			return channel.position - this._startTime;
+		}
+		return offset;
+	}

 	/** @private */
 	public function set position(value:Number):void {
-        if (channel != null) {
-            channel.stop();
-        }
+		if (channel != null) {
+			channel.stop();
+		}
 		startSound(value);
 	}

@@ -652,17 +652,17 @@

 	// Sound playback has completed.
 	protected function handleSoundComplete(event:Event):void {
-        offset = 0;  // have to set this as it can be set by pause during playback
-        if (loop != 0) {
+		offset = 0;  // have to set this as it can be set by pause during playback
+		if (loop != 0) {
 			//only decrement loop if it is not -1
-            if(loop > 0) loop--;  // NOTE this introduces a theoretical limit on loops = float max size x 2 - 1
-
-            startSound(offset);
-
-            dispatchEvent(new Event("loop"));
-        } else {
-            dispatchEvent(event);
-        }
+			if(loop > 0) loop--;  // NOTE this introduces a theoretical limit on loops = float max size x 2 - 1
+
+			startSound(offset);
+
+			dispatchEvent(new Event("loop"));
+		} else {
+			dispatchEvent(event);
+		}
 	}

 	// An error has occurred.


handling reset and destroy in eventLoop

handling reset and destroy in eventLoop

--- src/com/phylake/fsm/impl/Fsm.as
+++ src/com/phylake/fsm/impl/Fsm.as
@@ -3,7 +3,6 @@
     import com.phylake.fsm.core.*;
     import com.phylake.util.tryDestroy;
     import flash.errors.IllegalOperationError;
-    import flash.utils.Dictionary;

     public class Fsm implements IFsm
     {
@@ -20,6 +19,7 @@
         protected var _initialState:IState;
         protected var _currentState:IState;
         protected var _inEventLoop:Boolean;
+        protected var _destroyed:Boolean;
         protected var _that:IFsm;

         /**
@@ -45,12 +45,20 @@
             });

             _currentState = _initialState;
+            _events = new Vector.<IEvent>;
+
+            /*
+                Accept new events because you could be on the same stack frame
+                and end up queueing events
+            */
+            _inEventLoop = false;
         }

         public function destroy():void
         {
             mapSubmachines(tryDestroy);

+            _destroyed = true;
             _eventMap = null;
             _events = null;
             _states = null;
@@ -137,6 +145,7 @@
             var guard:IGuard;
             var trueGuard:IGuard;//the guard allowing a state transition
             var submachine:IFsm;
+            var earlyOut:Boolean;

             while (event = _events.shift())
             {
@@ -188,15 +197,18 @@
                 {
                     // execute exitState action for the current state
                     executeAction(currentState.exitState, event);
+                    if (_destroyed) return;

                     // execute transition action
                     executeAction(foundTransition.action, event);
+                    if (_destroyed) return;

                     // complete transition
                     _currentState = foundTransition.to;
-
+
                     // execute enterState action for the new state
                     executeAction(currentState.enterState, event);
+                    if (_destroyed) return;
                 }
                 else if (noTransitionException)
                 {


Исправление ошибки

Исправление ошибки

--- src/main/org/shypl/common/util/FilePath.as
+++ src/main/org/shypl/common/util/FilePath.as
@@ -1,4 +1,6 @@
 package org.shypl.common.util {
+	import mx.utils.StringUtil;
+
 	import org.shypl.common.lang.IllegalStateException;

 	public class FilePath {
@@ -10,7 +12,7 @@

 		public function FilePath(parts:Vector.<String> = null, base:String = null) {
 			_parts = parts == null ? new Vector.<String>(0) : parts.concat();
-			if (base !== null) {
+			if (!StringUtils.isEmpty(base)) {
 				if (StringUtils.endsWith(base, FilePathUtils.UNIX_SEPARATOR)) {
 					base = StringUtils.trimRight(base, FilePathUtils.UNIX_SEPARATOR);
 				}


You can't use that! It's the square of an imaginary number!
(0 should mean no-value)

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

--- src/as/com/threerings/ezgame/EZGameControl.as
+++ src/as/com/threerings/ezgame/EZGameControl.as
@@ -504,7 +504,7 @@
      * Ends the current round. If nextRoundDelay is greater than zero, the next round will be
      * started in the specified number of seconds.
      */
-    public function endRound (nextRoundDelay :int = -1) :void
+    public function endRound (nextRoundDelay :int = 0) :void
     {
         callEZCode("endRound_v1", nextRoundDelay);
     }


Transferred from the Adobe Open Source Subversion Repository

Revision: 20352
Author:   smgilson@adobe.com
Date:     2011-02-17T19:26:00.432539Z

Log Message:
-----------
Minor ASDoc cleanup

QE notes:
Doc notes:
Bugs:
Reviewer:
Tests run: checkintests
Is noteworthy for integration:

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/TabbedViewNavigator.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/View.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/BusyIndicator.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/LabelItemRenderer.as</path>

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

--- frameworks/projects/mobilecomponents/src/spark/components/View.as
+++ frameworks/projects/mobilecomponents/src/spark/components/View.as
@@ -324,7 +324,15 @@

     [Inspectable(category="General", defaultValue="false")]
     /**
-     *  @copy spark.components.supportClasses.ViewNavigatorBase#overlayControls
+     *  By default, the TabBar and ActionBar controls of a
+     *  mobile application define an area that cannot be used
+     *  by the views of an application.
+     *  That means your content cannot use the full screen size
+     *  of the mobile device.
+     *  If you set this property to true, the content area
+     *  of the application spans the entire width and height of the screen.
+     *  The ActionBar and TabBar controls hover over the content area with
+     *  an alpha value of 0.5 so that they are partially transparent.
      *
      *  @default false
      *
@@ -562,11 +570,15 @@
     private var _viewMenuItems:Vector.<ViewMenuItem>;

     /**
-     *  The Vector of ViewMenuItem objects that are passed to the ViewMenu when
+     *  The Vector of ViewMenuItem objects passed to the ViewMenu when
      *  this View is the active view.
      *
      *  @see ViewMenu
      *  @see ViewMenuItem
+     *
+     *  @langversion 3.0
+     *  @playerversion AIR 2.5
+     *  @productversion Flex 4.5
      */
     public function get viewMenuItems():Vector.<ViewMenuItem>
     {


Transferred from the Adobe Open Source Subversion Repository

Revision: 8
Author:   open-source-svn-admin@adobe.com
Date:     2007-12-15T01:49:31.087529Z

Log Message:
-----------
The beginning of the open-source Flex SDK.

Populated the flex/sdk/trunk directory with an open-source subset of files from //depot/flex/sdk/...@191097 in the Faramir Perforce server. This changelist is a bit past the 3.0rc0 build.

The Ant scripts will not successfully build yet. They need to be adapted to the open-source subset.

Modified Paths:
--------------
2532 paths were modified

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

--- frameworks/projects/mx/src/mx/accessibility/ColorPickerAccImpl.as
+++ frameworks/projects/mx/src/mx/accessibility/ColorPickerAccImpl.as
@@ -0,0 +1,329 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 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.accessibility
+{
+
+import flash.accessibility.Accessibility;
+import flash.events.Event;
+import mx.collections.CursorBookmark;
+import mx.collections.IViewCursor;
+import mx.controls.ColorPicker;
+import mx.controls.colorPickerClasses.SwatchPanel;
+import mx.controls.ComboBase;
+import mx.core.UIComponent;
+import mx.core.mx_internal;
+import mx.events.ColorPickerEvent;
+import mx.events.DropdownEvent;
+import mx.skins.halo.SwatchSkin;
+
+use namespace mx_internal;
+
+public class ColorPickerAccImpl extends ComboBaseAccImpl
+{
+	include "../core/Version.as";
+
+	//--------------------------------------------------------------------------
+	//
+	//  Class initialization
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 *  Static variable triggering the hookAccessibility() method.
+	 *  This is used for initializing DateChooserAccImpl class to hook its
+	 *  createAccessibilityImplementation() method to DateChooser class
+	 *  before it gets called from UIComponent.
+	 */
+	private static var accessibilityHooked:Boolean = hookAccessibility();
+
+	/**
+	 *  @private
+	 *  Static method for swapping the createAccessibilityImplementation()
+	 *  method of Slider withthe SliderAccImpl class.
+	 */
+	private static function hookAccessibility():Boolean
+	{
+		ColorPicker.createAccessibilityImplementation =
+			createAccessibilityImplementation;
+
+		return true;
+	}
+
+	/**
+	 *  @private
+	 */
+	private static const EVENT_OBJECT_VALUECHANGE:uint = 0x800E;
+
+	/**
+	 *  @private
+	 */
+	private static const EVENT_OBJECT_SELECTION:uint = 0x8006;
+
+		/**
+	 *  @private
+	 */
+	private static const STATE_SYSTEM_FOCUSED:uint = 0x00000004;
+
+	/**
+	 *  @private
+	 */
+	private static const STATE_SYSTEM_SELECTABLE:uint = 0x00200000;
+
+	/**
+	 *  @private
+	 */
+	private static const STATE_SYSTEM_SELECTED:uint = 0x00000002;
+
+//--------------------------------------------------------------------------
+	//
+	//  Class methods
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 *  Method for creating the Accessibility class.
+	 *  This method is called from UIComponent.
+	 *  @review
+	 */
+	mx_internal static function createAccessibilityImplementation(
+								component:UIComponent):void
+	{
+		component.accessibilityImplementation =
+			new ColorPickerAccImpl(component);
+	}
+
+	/**
+	 *  Method call for enabling accessibility for a component.
+	 *  This method is required for the compiler to activate
+	 *  the accessibility classes for a component.
+	 */
+	public static function enableAccessibility():void
+	{
+		//SwatchPanelAccImpl.enableAccessibility();
+	}
+
+
+	//--------------------------------------------------------------------------
+	//
+	//  Constructor
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  Constructor.
+	 *
+	 *  @param master The UIComponent instance that this AccImpl instance
+	 *  is making accessible.
+	 */
+
+	public function ColorPickerAccImpl(master:UIComponent)
+	{
+		super(master);
+		master.accessibilityProperties.description = "Color Picker";
+		Accessibility.updateProperties();
+		ColorPicker(master).addEventListener(DropdownEvent.OPEN, openHandler);
+		ColorPicker(master).addEventListener(DropdownEvent.CLOSE, closeHandler);
+		//role = 0x2E;
+	}
+
+	private function openHandler(event:Event):void
+	{
+		ColorPicker(master).dropdown.addEventListener("change",  dropdown_changeHandler);
+	}
+	private function closeHandler(event:Event):void
+	{
+		ColorPicker(master).dropdown.removeEventListener("change",  dropdown_changeHandler);
+	}
+
+	private function dropdown_changeHandler(event:Event):void
+	{
+		master.dispatchEvent(new Event("childChange"));
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Overridden methods: AccImpl
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 *  method for returning the name of the ComboBase
+	 *  For children items (i. e. ColorSwatch colors), it returns the digits if the hex
+	 *  color. We add a space between each digit to force the screen reader to read it
+	 *  as a series of text, not a number (e.g. #009900 is "zero, zero, nine, nine, zero, zero",
+	 *  not "nine thousand, nine hundred".
+	 *
+	 *  ComboBase should return the name specified in the AccessibilityProperties.
+	 *
+	 *  @param childID uint
+	 *
+	 *  @return Name String
+	 *  @review
+	 */
+	override protected function getName(childID:uint):String
+	{
+		if (childID == 0 || childID > 0xFFF)
+			return "";
+
+		var colorPicker:ColorPicker = ColorPicker(master);
+		var iterator:IViewCursor = colorPicker.collectionIterator;
+		iterator.seek(CursorBookmark.FIRST, childID - 1);
+		var item:Object = iterator.current;
+
+
+		if (typeof(item) != "object")
+		{
+			var str:String = item.toString(16);
+			var x:String =  formatColorString(str);
+	//		trace(x);
+			return x;
+		}
+
+		return !item.label ? item.data : item.label;
+	}
+
+
+
+	/**
+	 *  @private
+	 *  IAccessible method for returning the state of the ListItem
+	 *  (basically to remove 'not selected').
+	 *  States are predefined for all the components in MSAA.
+	 *  Values are assigned to each state.
+	 *  Depending upon the listItem being Selected, Selectable,
+	 *  Invisible, Offscreen, a value is returned.
+	 *
+	 *  @param childID uint
+	 *
+	 *  @return State uint
+	 */
+	override public function get_accState(childID:uint):uint
+	{
+		var accState:uint = getState(childID);
+
+		if (childID > 0)
+		{
+			accState |= STATE_SYSTEM_SELECTABLE;
+
+			accState |= STATE_SYSTEM_SELECTED | STATE_SYSTEM_FOCUSED;
+		}
+
+		return accState;
+	}
+
+	/**
+	 *  @private
+	 *  Method to return the current val;ue of the component
+	 *
+	 *  @return string
+	 */
+	override public function get_accValue(childID:uint):String
+	{
+		if (ColorPicker(master).showingDropdown)
+		{
+			return ColorPicker(master).dropdown ?
+				ColorPicker(master).dropdown.textInput.text :
+				null;
+		}
+		else
+			return ColorPicker(master).selectedColor.toString(16);
+	}
+
+	/**
+	 *  @private
+	 *  Method to return an array of childIDs.
+	 *
+	 *  @return Array
+	 */
+	override public function getChildIDArray():Array
+	{
+		var childIDs:Array = [];
+		if (ColorPicker(master).dropdown)
+		{
+			var n:uint= ColorPicker(master).dropdown.length;
+			for (var i:int = 0; i < n; i++)
+			{
+				childIDs[i] = i + 1;
+			}
+		}
+		return childIDs;
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Overridden properties: AccImpl
+	//
+	//--------------------------------------------------------------------------
+
+	//----------------------------------
+	//  eventsToHandle
+	//----------------------------------
+
+	/**
+	 *  @private
+	 *	Array of events that we should listen for from the master component.
+	 */
+	override protected function get eventsToHandle():Array
+	{
+		return super.eventsToHandle.concat([ "childChange"]);
+	}
+	//--------------------------------------------------------------------------
+	//
+	//  Overridden event handlers: AccImpl
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 *  Override the generic event handler.
+	 *  All AccImpl must implement this to listen for events
+	 *  from its master component.
+	 */
+	override protected function eventHandler(event:Event):void
+	{
+		switch (event.type)
+		{
+			case "childChange":
+			{
+				var index:int = ComboBase(master).selectedIndex;
+				Accessibility.sendEvent(master, ColorPicker(master).dropdown.focusedIndex + 1, EVENT_OBJECT_SELECTION);
+				Accessibility.sendEvent(master, 0,
+								EVENT_OBJECT_VALUECHANGE, true)
+			}
+
+			case "valueCommit":
+			{
+				Accessibility.sendEvent(master, 0, EVENT_OBJECT_VALUECHANGE);
+				break;
+			}
+		}
+	}
+
+	/**
+	 *  @private
+	 *  formats string color to add a space between each digit (hexit?).
+	 *  Makes screen readers read color properly.
+	 */
+	private function formatColorString(color:String):String
+	{
+		var str2:String = "";
+		var n:int = color.length;
+		for (var i:uint = 0; i < n; i++)
+			str2 += color.charAt(i) + " ";
+		return str2;
+	}
+}
+
+}


Turned off position-validity-checking for deployed modules.

--- src/Modules/Module.as
+++ src/Modules/Module.as
@@ -27,6 +27,7 @@
 		public var delay:int;

 		public var exists:Boolean = true;
+		public var deployed:Boolean = false;
 		public var FIXED:Boolean = false;
 		public var dirty:Boolean;

@@ -91,6 +92,7 @@

 		public function register():Module {
 			exists = true;
+			deployed = true;

 			var self:Module = this;

@@ -124,6 +126,7 @@
 				portLayout.deregister();
 			}

+			deployed = false;
 			exists = false;

 			return this;
@@ -134,6 +137,8 @@
 		}

 		public function get validPosition():Boolean {
+			if (deployed) return true;
+
 			var OK:Object = { 'x' : true, 'y' : true };
 			var self:Module = this;
 			iterContainedLines(function h(X:int, Y:int):void {


removing unused ContextObject.as

removing unused ContextObject.as

--- src/patternpark/net/ContextObject.as
+++ src/patternpark/net/ContextObject.as
@@ -1,6 +0,0 @@
-package patternpark.net {
-
-    public interface ContextObject {
-        public function close():void;
-    }
-}


Transferred from the Adobe Open Source Subversion Repository

Revision: 20844
Author:   jimurphy@adobe.com
Date:     2011-03-14T15:10:07.899037Z

Log Message:
-----------
block hero_private revs 20698,20699,20702 from being merged into trunk
revert 20839,20841,20842,20843

QE notes: no
Doc notes: no
Bugs: no
Reviewer:no
Tests run: no
Is noteworthy for integration:no

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/spark/src/spark/formatters/NumberFormatter.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/CSSCondition.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/ISortField.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/spark/src/spark/formatters/CurrencyFormatter.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/BitmapFill.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/spark/src/spark/formatters/DateTimeFormatter.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/charts/src/mx/charts/chartClasses/CartesianChart.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/GradientStroke.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/ArrayList.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/GradientBase.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/charts/src/mx/charts/chartClasses/PolarChart.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/shaderClasses/ColorDodgeShader.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/charts/src/mx/charts/chartClasses/PolarDataCanvas.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/OnDemandEventDispatcher.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/charts/src/mx/charts/series/PlotSeries.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/TabBar.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/SolidColorStroke.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/geom/Transform.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/advancedgrids/src/mx/collections/HierarchicalCollectionViewCursor.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/CSSStyleDeclaration.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/FlexEvent.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/charts/src/mx/charts/series/CandlestickSeries.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/StringUtil.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/spark/src/spark/globalization/StringTools.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/geom/CompoundTransform.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/AdvancedStyleClient.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/binding/utils/ChangeWatcher.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/LinearGradientStroke.as</path>

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

--- frameworks/projects/framework/src/mx/styles/CSSStyleDeclaration.as
+++ frameworks/projects/framework/src/mx/styles/CSSStyleDeclaration.as
@@ -487,8 +487,6 @@
      *  Determines whether this style declaration applies to the given component
      *  based on a match of the selector chain.
      *
-     *  @param object The component to match the style declaration against.
-     *
      *  @return true if this style declaration applies to the component,
      *  otherwise false.
      *
@@ -691,7 +689,7 @@
             for (i = 0; i < n; i++)
             {
                 sm = sms[i];
-                cm = sm.getImplementation("mx.managers::ISystemManagerChildManager");
+			    cm = sm.getImplementation("mx.managers::ISystemManagerChildManager");
                 cm.regenerateStyleCache(true);
             }
         }
@@ -699,7 +697,7 @@
         for (i = 0; i < n; i++)
         {
             sm = sms[i];
-            cm = sm.getImplementation("mx.managers::ISystemManagerChildManager");
+		    cm = sm.getImplementation("mx.managers::ISystemManagerChildManager");
             cm.notifyStyleChangeInChildren(styleProp, true);
         }
     }


Transferred from the Adobe Open Source Subversion Repository

Revision: 9202
Author:   cframpto@adobe.com
Date:     2009-08-10T13:33:47.301560Z

Log Message:
-----------
RET was intercepting the enter key for the !multiline case and allowing it to go to TLF for the multiline case but that doesn't work since the TLF EditManager.keyUpHandler() doesn't check event.isDefaultPrevented() and does a event.stopImmediatePropogration() on the enter key.

Now we never let TLF handle the enter key.  That means for the multiline case we needed to duplicate the code from the EditManager which is never a good thing to do but unavoidable.

QE notes: from Gordon: We've had so much trouble with the Enter key that I think we need some (or more?) Mustella tests for it, including testing it after toggling the multiline property, and testing it with both 'text', 'content', and 'textFlow'.
Doc notes:
Bugs: SDK-22527
Reviewer: Gordon
Tests run:
Is noteworthy for integration: no

Modified Paths:
--------------
/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/RichEditableText.as

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

--- frameworks/projects/spark/src/spark/components/RichEditableText.as
+++ frameworks/projects/spark/src/spark/components/RichEditableText.as
@@ -252,8 +252,13 @@
         if (classInitialized)
             return;

+        staticConfiguration = new Configuration();
+        staticConfiguration.manageEnterKey = false; // default is true
+        staticConfiguration.manageTabKey = false;   // default is false
+
         staticPlainTextImporter =
-            TextConverter.getImporter(TextConverter.PLAIN_TEXT_FORMAT);
+            TextConverter.getImporter(TextConverter.PLAIN_TEXT_FORMAT,
+            staticConfiguration);

         // Throw import errors rather than return a null textFlow.
         // Alternatively, the error strings are in the Vector, importer.errors.
@@ -278,7 +283,16 @@
      *  @private
      */
     private static var classInitialized:Boolean = false;
-
+
+    /**
+     *  @private
+     *  Create a single Configuration used by all Text instances.
+     *  It tells the TextContainerManager that we don't want it
+     *  to handle the ENTER key, because we need the ENTER key to behave
+     *  differently based on the 'multiline' property.
+     */
+    private static var staticConfiguration:Configuration;
+
     /**
      *  @private
      *  This TLF object is used to import a 'text' String
@@ -1667,35 +1681,17 @@
         // We are about to set focus on this component.  If it is due to
         // a programmatic focus change we have to programatically do what the
         // mouseOverHandler and the mouseDownHandler do so that the user can
-        // type in this component without using the mouse first.
-        //
-        //   1) TCM addActivationEventListeners() called so that event handlers
-        //      are in place to catch the upcoming FocusEvent.FOCUS_IN which
-        //      will cause our focusInHandler to be called.
-        //   2) Make sure there is a textFlow with an interactionManager
-        //      in place so that selection/editing can occur.  Our focusIn
-        //      handler does this indirectly for the editable case since
-        //      to set a selection, there must be a textFlow in this state.
-        //
-        // We can't call addActivationEventListeners() directly but it is
-        // called by TCM.setTextFlow() which is called by the textFlow getter.
-        // The textFlow getter also makes sure there is an interactionManager
-        // in place.
-        //
-        // Alternatively, we could call convertToTextFlowWithComposer() if it
-        // was made accessible.  This eliminates the need for
-        // addActivationEventListeners(), since the text flow with a composer
-        // is put in place immediately.
-
-        if (editingMode != EditingMode.READ_ONLY)
-        {
-            if (_textContainerManager.handlersState ==
-                TextContainerManager.HANDLERS_NOTADDED ||
-                _textContainerManager.composeState !=
-                TextContainerManager.COMPOSE_COMPOSER)
-            {
-                textFlow;
-            }
+        // type in this component without using the mouse first.  Ideally
+        // we would call convertToTextFlowWithComposer() to put a textFlow
+        // with a composer in place but it is not accessible.  The workaround
+        // is to call scrollToRange which makes sure the textFlow is in place
+        // and then returns immediately from scrollToRange since the scroll
+        // positions are not valid.
+        if (editingMode != EditingMode.READ_ONLY &&
+            _textContainerManager.composeState !=
+            TextContainerManager.COMPOSE_COMPOSER)
+        {
+            _textContainerManager.scrollToRange(-1, -1);
         }

         super.setFocus();
@@ -2355,9 +2351,7 @@
      */
     mx_internal function createTextContainerManager():TextContainerManager
     {
-        // Use the default configuration.
-        // TODO:(cframpto) should set enableEnterKey = false
-        return new RichEditableTextContainerManager(this, null);
+        return new RichEditableTextContainerManager(this, staticConfiguration);
     }

     /**
@@ -3327,13 +3321,26 @@
             return;

         if (event.keyCode == Keyboard.ENTER)
-        {
-            // Do not let TLF handle the ENTER key if only one line.
-            if (!multiline)
+        {
+            // We always handle the 'enter' key since we would have to recreate
+            // the container manager to change the configuration if multiline
+            // changes.
+            if (multiline)
             {
-                event.preventDefault();
+                var editManager:IEditManager =
+                    EditManager(_textContainerManager.beginInteraction());
+
+                if (editManager.hasSelection())
+                    editManager.splitParagraph();
+
+                _textContainerManager.endInteraction();
+            }
+            else
+            {
                 dispatchEvent(new FlexEvent(FlexEvent.ENTER));
             }
+
+            event.preventDefault();
          }
     }


Branch merge

Branch merge

--- as3/xobjas3/src/com/rpath/xobj/XObjUtils.as
+++ as3/xobjas3/src/com/rpath/xobj/XObjUtils.as
@@ -191,7 +191,7 @@
         /**
          * Use our own version of getClassInfo to support various metadata
          * tags we use.  See ObjectUtil.getClassInfo for more info about
-         * the baisc functionality of this method.
+         * the basic functionality of this method.
          */
         public static function getClassInfo(obj:Object,
                                             excludes:Array = null,
@@ -422,6 +422,19 @@
             return result;
         }

+        public static function getSuperclasses(object:*):Array
+        {
+            var result:Array = [];
+            var classInfo:XML = DescribeTypeCache.describeType(object).typeDescription;
+
+            for each (var superClass:XML in classInfo.extendsClass)
+            {
+                result.push(getClassByName(superClass.@type));
+            }
+            return result;
+        }
+
+
         /**
          *  @private
          */


fixed bugs in WeaveJS/ColumnUtils.joinColumns()

--- WeaveJS/src/weavejs/data/ColumnUtils.as
+++ WeaveJS/src/weavejs/data/ColumnUtils.as
@@ -388,14 +388,17 @@
 			{
 				// count the number of appearances of each key in each column
 				var map_key_count:Object = new JS.Map();
-				for each (column in columns)
-					for each (key in column ? column.keys : null)
+				for each (column in columns)
+				{
+					var columnKeys:Array = column ? column.keys : null;
+					for each (key in columnKeys)
 						map_key_count.set(key, (map_key_count.get(key)|0) + 1);
+				}
 				// get a list of keys
 				keys = [];
 				var filter:IKeyFilter = keyFilter as IKeyFilter;
 				var mapKeys:Array = JS.mapKeys(map_key_count);
-				for (var qkey:* in mapKeys)
+				for each (var qkey:* in mapKeys)
 					if (allowMissingData || map_key_count.get(qkey) == columns.length)
 						if (!filter || filter.containsKey(qkey))
 							keys.push(qkey);


* 修复了 ObjectRenderer 渲染 avatarID 为 null 时，没有正确定位的 bug

--- age/src/age/renderers/ObjectRenderer.as
+++ age/src/age/renderers/ObjectRenderer.as
@@ -301,14 +301,12 @@
 				isAvatarIDChange = false;
 			}

-			// 优化：如果 avatarID 为 null，后面的流程就不用跑了
-			if (avatarID == null)
-			{
-				return;
-			}
-			// 更新 action
-			actionName = info.actionName;
-			addAllLayerRenderers(actionInfo);
+			if (avatarID)
+			{
+				// 更新 action
+				actionName = info.actionName;
+				addAllLayerRenderers(actionInfo);
+			}

 			if (isAutoPlay)
 			{


Transferred from the Adobe Open Source Subversion Repository

Revision: 8945
Author:   clucier@adobe.com
Date:     2009-07-30T23:36:09.321240Z

Log Message:
-----------
Fix layout update issue with dynamic change of maxWidth or maxHeight in WindowedApplication.

QE notes: None
Doc notes: None
Bugs: SDK-22200
Reviewer: Darrell
Tests run: Cyclone to QA
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/spark/components/WindowedApplication.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/WindowedApplication.as</path>

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

--- frameworks/projects/airframework/src/mx/core/WindowedApplication.as
+++ frameworks/projects/airframework/src/mx/core/WindowedApplication.as
@@ -2193,6 +2193,7 @@
             var newMaxWidth:Number = maxWidthChanged ? _maxWidth + chromeWidth() : nativeWindow.maxSize.x;
             var newMaxHeight:Number = maxHeightChanged ? _maxHeight + chromeHeight() : nativeWindow.maxSize.y;

+            windowBoundsChanged = true;
             nativeWindow.maxSize = new Point(newMaxWidth, newMaxHeight);

             if (maxWidthChanged)


Transferred from the Adobe Open Source Subversion Repository

Revision: 18433
Author:   aharui@adobe.com
Date:     2010-11-03T20:10:29.475195Z

Log Message:
-----------
FIx problem with tooltips on newly instantiated components.  Wait until the target is initialized before trusting its position

QE notes: none
Doc notes: none
Bugs: SDK-28319
Reviewer: Corey
Tests run: checkintests mustella managers/ToolTipManager
Is noteworthy for integration: no

Modified Paths:
--------------
/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as

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

--- frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as
+++ frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as
@@ -689,6 +689,9 @@
     	//target hitTest will return true.
     	if ((target.stage.mouseX == 0)	 && (target.stage.mouseY == 0))
     		return false;
+
+        if (target is ILayoutManagerClient && !ILayoutManagerClient(target).initialized)
+            return false;

     	return target.hitTestPoint(target.stage.mouseX,
     							   target.stage.mouseY, true);


Transferred from the Adobe Open Source Subversion Repository

Revision: 22987
Author:   jszeto@adobe.com
Date:     2011-10-12T23:52:46.424992Z

Log Message:
-----------
Validator backwards compatibility bug

SDK-31809 Validators do not show red errors around input boxes when compiled with Flex 3 compatibility mode

 We added some code during the development of the Spark Form feature to control whether an error border and tooltip are shown. These are controlled by styles. These styles don't exist in Flex 3 compat mode, thus they resolve as false and therefore don't display the border or tooltip.

The fix is to add compatibility flag checks around this code in UIComponent.

QE notes: none
Doc notes: none
Bugs: SDK-31809
Reviewer: Kevin L
Tests run: checkintests, cyclone
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as</path>

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

--- frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as
+++ frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as
@@ -21,23 +21,25 @@
 import flash.geom.Point;
 import flash.geom.Rectangle;
 import flash.utils.Timer;
+
 import mx.controls.ToolTip;
 import mx.core.FlexGlobals;
+import mx.core.FlexVersion;
 import mx.core.IFlexModule;
 import mx.core.IInvalidating;
+import mx.core.ILayoutDirectionElement;
 import mx.core.IToolTip;
 import mx.core.IUIComponent;
 import mx.core.LayoutDirection;
 import mx.core.mx_internal;
+import mx.effects.EffectManager;
 import mx.effects.IAbstractEffect;
-import mx.effects.EffectManager;
 import mx.events.DynamicEvent;
 import mx.events.EffectEvent;
 import mx.events.ToolTipEvent;
 import mx.managers.IToolTipManagerClient;
 import mx.styles.IStyleClient;
 import mx.validators.IValidatorListener;
-import mx.core.ILayoutDirectionElement;

 use namespace mx_internal;

@@ -777,7 +779,9 @@
                 currentText = IValidatorListener(displayObject).errorString;
                 var showErrorTip:Boolean;
                 if (displayObject is IStyleClient)
-                    showErrorTip = IStyleClient(displayObject).getStyle("showErrorTip");
+                    showErrorTip = FlexVersion.compatibilityVersion < FlexVersion.VERSION_4_0 ||
+                                   IStyleClient(displayObject).getStyle("showErrorTip");
+                                   ;
                 if (currentText != null && currentText != "" && showErrorTip)
                 {
                     currentTarget = displayObject;


BusyIndicator now supports manually setting visibility when there are
no linkable targets.

Change-Id: Id28d5a63bc91ef72eb03376749303334c1df20b9

--- WeaveUISpark/src/weave/ui/BusyIndicator.as
+++ WeaveUISpark/src/weave/ui/BusyIndicator.as
@@ -40,7 +40,8 @@
 		public function BusyIndicator(target:ILinkableObject = null, ...moreTargets)
 		{
 			super();
-			moreTargets.unshift(target);
+			if (target)
+				moreTargets.unshift(target);
 			this.targets = moreTargets;
 			includeInLayout = false;
 			mouseChildren = false;
@@ -113,7 +114,7 @@
 			if (!stage)
 				return;

-			if (targets)
+			if (targets.length)
 				toggleVisible();

 			if (!visible)


Transferred from the Adobe Open Source Subversion Repository

Revision: 22006
Author:   jasonsj@adobe.com
Date:     2011-08-15T23:49:37.068379Z

Log Message:
-----------
SDK-31052 erase the CalloutSkin drop shadow when backgroundAlpha < 1
SDK-31028 New contentBackgroundAppearance style and CalloutContentBackgroundAppearance to remove content background shadow and/or color in Callout.

QE notes: ViewNavigatorCalloutSkin has been removed. Instead, set contentBackgroundAppearance=none on the Callout. It's no longer necessary to set contentBackgroundAlpha=1 on ViewNavigators inside a Callout.
Doc notes:
Bugs:
SDK-31052 Drop shadow appears beneath arrow when Callout has a backgroundAlpha less than 1
SDK-31028 Callout skinning/styling should account for arbitrary use of a ViewNavigator child
Reviewer: betravis
Tests run: checkintests, mustella-mobile
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="D">/private/flex/sdk/branches/4.y/frameworks/projects/mobiletheme/src/spark/skins/mobile/ViewNavigatorCalloutSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/mobilecomponents/src/MobileComponentsClasses.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/mobiletheme/src/spark/skins/mobile320/assets/CalloutContentBackground.fxg</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/mobiletheme/defaults.css</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/mobiletheme/src/spark/skins/mobile240/assets/CalloutContentBackground.fxg</path>
<path kind="file" action="A">/private/flex/sdk/branches/4.y/frameworks/projects/mobilecomponents/src/spark/components/CalloutContentBackgroundAppearance.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/mobiletheme/src/spark/skins/mobile/CalloutSkin.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/4.y/frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/CalloutArrow.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/mobiletheme/src/spark/skins/mobile160/assets/CalloutContentBackground.fxg</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/mobiletheme/src/MobileThemeClasses.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/4.y/frameworks/projects/mobilecomponents/src/spark/components/Callout.as</path>

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

--- frameworks/projects/mobilecomponents/src/spark/components/Callout.as
+++ frameworks/projects/mobilecomponents/src/spark/components/Callout.as
@@ -33,6 +33,28 @@
 import mx.utils.PopUpUtil;

 use namespace mx_internal;
+
+//--------------------------------------
+//  Styles
+//--------------------------------------
+
+/**
+ *  Appearance of the contentGroup. Valid MXML values are inset
+ *  flat and transparent.
+ *
+ *
In ActionScript, you can use the following constants
+ *  to set this property:
+ *  CalloutContentBackgroundAppearance.INSET,
+ *  CalloutContentBackgroundAppearance.FLAT and
+ *  CalloutContentBackgroundAppearance.NONE.

+ *
+ *  @default CalloutContentBackgroundAppearance.INSET
+ *
+ *  @langversion 3.0
+ *  @playerversion AIR 3
+ *  @productversion Flex 4.5.2
+ */
+[Style(name="contentBackgroundAppearance", type="String", enumeration="inset,flat,none", inherit="no")]

 //--------------------------------------
 //  Other metadata
@@ -79,6 +101,12 @@
  *  and transition to the normal skin state.
  *  To define open and close animations, use a custom skin with transitions between
  *  the closed and normal skin states.

+ *
+ *
Callout changes the default inheritance behavior seen in Flex components
+ *  and instead, inherits styles from the top-level application. This prevents
+ *  Callout's contents from unintentionally inheriting styles from an owner
+ *  (i.e. Button or TextInput) where the default appearance was desired and
+ *  expected.

  *
  *
The Callout container has the following default characteristics:

  *


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

--- frameworks/projects/rpc/src/mx/messaging/messages/AbstractMessage.as
+++ frameworks/projects/rpc/src/mx/messaging/messages/AbstractMessage.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2006-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.messaging.messages
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 5573
Author:   jimurphy@adobe.com
Date:     2009-03-26T15:11:59.159776Z

Log Message:
-----------
-more updated package and class names that were missed in the first pass
-remove the mx folder

qa: probably
doc: this updated more asdoc comments so you may want to make sure that this pass made the correct updates
checkintests: pass

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Scroller.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/DataGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/DropDownList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/layout/supportClasses/LayoutBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransformMove.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/core/IViewport.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/VideoDisplay.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Group.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/ButtonBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/interpolation/HSBInterpolator.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/core/IGraphicElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransformScale3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/HGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/NumericStepper.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/easing/IEaser.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/Animate.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/components/examples/DataGroupExample.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateShaderTransition.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransformScale.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/Slider.as</path>
<path kind="dir" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/mx</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/TextArea.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/ScrollBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Spinner.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/VGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/RichEditableText.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/CheckBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/pathSegments/PathSegment.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/animation/Animation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/RadioButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/HScrollBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/components/examples/FxToggleButtonExample.mxml</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/events/AnimationEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/SkinnableDataContainer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransform.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/TextBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/VScrollBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/SkinnableContainer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransformRotate3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/List.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/components/supportClasses/GroupBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransformMove3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/SkinnableComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransformRotate.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/SetAction.as</path>

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

--- frameworks/projects/spark/src/spark/components/SkinnableContainer.as
+++ frameworks/projects/spark/src/spark/components/SkinnableContainer.as
@@ -51,7 +51,7 @@
  *  Dispatched when a visual element is added to the content holder.
  *  event.element is the visual element that was added.
  *
- *  @eventType mx.events.ElementExistenceEvent.ELEMENT_ADD
+ *  @eventType spark.events.ElementExistenceEvent.ELEMENT_ADD
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -64,7 +64,7 @@
  *  Dispatched when a visual element is removed to the content holder.
  *  event.element is the visual element that's being removed.
  *
- *  @eventType mx.events.ElementExistenceEvent.ELEMENT_REMOVE
+ *  @eventType spark.events.ElementExistenceEvent.ELEMENT_REMOVE
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -78,7 +78,7 @@
 include "../styles/metadata/SelectionFormatTextStyles.as"

 /**
- *  @copy mx.components.baseClasses.GroupBase#alternatingItemColors
+ *  @copy spark.components.supportClasses.GroupBase#alternatingItemColors
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -88,7 +88,7 @@
 [Style(name="alternatingItemColors", type="Array", arrayType="uint", format="Color", inherit="yes")]

 /**
- *  @copy mx.components.baseClasses.GroupBase#contentBackgroundColor
+ *  @copy spark.components.supportClasses.GroupBase#contentBackgroundColor
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -98,7 +98,7 @@
 [Style(name="contentBackgroundColor", type="uint", format="Color", inherit="yes")]

 /**
- *  @copy mx.components.baseClasses.GroupBase#focusColor
+ *  @copy spark.components.supportClasses.GroupBase#focusColor
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -108,7 +108,7 @@
 [Style(name="focusColor", type="uint", format="Color", inherit="yes")]

 /**
- * @copy mx.components.baseClasses.GroupBase#rollOverColor
+ * @copy spark.components.supportClasses.GroupBase#rollOverColor
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -118,7 +118,7 @@
 [Style(name="rollOverColor", type="uint", format="Color", inherit="yes")]

 /**
- *  @copy mx.components.baseClasses.GroupBase#symbolColor
+ *  @copy spark.components.supportClasses.GroupBase#symbolColor
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -320,7 +320,7 @@
     [Inspectable(defaultValue="true")]

     /**
-     *  @copy mx.components.baseClasses.GroupBase#autoLayout
+     *  @copy spark.components.supportClasses.GroupBase#autoLayout
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -469,7 +469,7 @@
     //----------------------------------

     /**
-     *  @copy mx.components.baseClasses.GroupBase#layout
+     *  @copy spark.components.supportClasses.GroupBase#layout
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -508,7 +508,7 @@
     [ArrayElementType("mx.core.IVisualElement")]

     /**
-     *  @copy mx.components.Group#mxmlContent
+     *  @copy spark.components.Group#mxmlContent
      *
      *  @langversion 3.0
      *  @playerversion Flash 10


Transferred from the Adobe Open Source Subversion Repository

Revision: 6384
Author:   smgilson@adobe.com
Date:     2009-04-29T17:35:57.804487Z

Log Message:
-----------
First pass on ASDoc for containers

QE Notes: None
Doc Notes: None
Bugs:
Checkintests: passed

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/styles/metadata/SelectionFormatTextStyles.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/DataGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/SkinnableContainer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/core/IViewport.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Panel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/SkinnableDataContainer.as</path>

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

--- frameworks/projects/spark/src/spark/components/SkinnableContainer.as
+++ frameworks/projects/spark/src/spark/components/SkinnableContainer.as
@@ -137,10 +137,41 @@
 [DefaultProperty("mxmlContentFactory")]

 /**
- *  The SkinnableContainer class is the base class for all skinnable components that have
+ *  The SkinnableContainer class is the base class for skinnable containers that have
  *  visual content.
+ *  The SkinnableContainer container take as children any components that implement
+ *  the IVisualElement interface.
+ *  All Spark and Halo components implement the IVisualElement interface, as does
+ *  the GraphicElement class.
+ *  That means the container can use the graphics classes, such as Rect and Ellipse, as children.
+ *
+ *
To improve performance and minimize application size,
+ *  you can use the Group container. The Group container cannot be skinned.

+ *
+ *  @mxml
+ *
+ *
The <SkinnableContainer> tag inherits all of the tag
+ *  attributes of its superclass and adds the following tag attributes:

+ *
+ *

+ *  <SkinnableContainer
+ *    Properties
+ *    autoLayout="true"
+ *    clipAndEnableScrolling="false"
+ *    creationPolicy="auto"
+ *    horizontalScrollPosition"null"
+ *    layout"VerticalLayout"
+ *    verticalScrollPosition="null"
+ *
+ *    Events
+ *    elementAdd="No default"
+ *    elementRemove="No default"
+ *  />
+ *

  *
  *  @see SkinnableDataContainer
+ *  @see Group
+ *  @see spark.skins.default.SkinnableContainerSkin
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -288,6 +319,8 @@

     /**
      *  @inheritDoc
+     *
+     *  @default auto
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -324,6 +357,8 @@

     /**
      *  @copy spark.components.supportClasses.GroupBase#autoLayout
+     *
+     *  @default true
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -363,6 +398,8 @@

     /**
      *  @inheritDoc
+     *
+     *  @default false
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -473,6 +510,8 @@

     /**
      *  @copy spark.components.supportClasses.GroupBase#layout
+     *
+     *  @default VerticalLayout
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -785,7 +824,8 @@
     //--------------------------------------------------------------------------

     /**
-     *  Create our content, if the creationPolicy is != "none".
+     *  Create content children, if the creationPolicy property
+     *  is not equal to none.
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -804,10 +844,7 @@
     }

     /**
-     *  Called when a skin part has been added or assigned.
-     *  This method pushes the content, layout, itemRenderer, and
-     *  itemRendererFunction properties down to the contentGroup
-     *  skin part.
+     *  @inheritDoc
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -910,7 +947,7 @@
     }

     /**
-     *  Called when a skin part is removed.
+     *  @inheritDoc
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -1020,10 +1057,11 @@
     //--------------------------------------------------------------------------

     /**
-     *  Create the content for this component. When creationPolicy is "auto" or
-     *  "all", this function is called automatically by the Flex framework.
-     *  When creationPolicy="none", this method must be called to initialize
-     *  the content property.
+     *  Create the content for this component.
+     *  When the creationPolicy property is auto or
+     *  all, this function is called automatically by the Flex framework.
+     *  When creationPolicy is none, you call this method to initialize
+     *  the content.
      *
      *  @langversion 3.0
      *  @playerversion Flash 10


fixed compiler warnings.

fixed compiler warnings.

--- WeaveUISpark/src/weave/visualization/plotters/SizeBinLegendPlotter.as
+++ WeaveUISpark/src/weave/visualization/plotters/SizeBinLegendPlotter.as
@@ -94,7 +94,7 @@
 		private var yInterval:Number;
 		override public function drawBackground(dataBounds:IBounds2D, screenBounds:IBounds2D, destination:BitmapData):void
 		{
-
+			var i:int;
 			valueMax = radiusColumnStats.getMax();
 			valueMin = radiusColumnStats.getMin();

@@ -103,7 +103,7 @@
 			if (typeRadio.value == simpleRadio)
 			{
 				circleRadiuses = new Array();
-				for (var i:int = 0; i < numberOfCircles.value; i++)
+				for (i = 0; i < numberOfCircles.value; i++)
 					circleRadiuses.push(StandardLib.roundSignificant(valueMin + i * (valueMax - valueMin) / (numberOfCircles.value - 1), 4));

 				yInterval = screenBounds.getYCoverage() / numberOfCircles.value;
@@ -112,7 +112,7 @@
 			{
 				circleRadiuses = customCircleRadiuses.value.split(',');
 				// remove bad values
-				for (var i:int = circleRadiuses.length - 1; i >= 0; i--)
+				for (i = circleRadiuses.length - 1; i >= 0; i--)
 				{
 					var number:Number = StandardLib.asNumber(circleRadiuses[i]);
 					if (!isFinite(number) || circleRadiuses[i] < valueMin || circleRadiuses[i] > valueMax)
@@ -132,12 +132,12 @@
 			if (absoluteValueColorEnabled.value)
 			{
 				var absMax:Number = Math.max(Math.abs(valueMin), Math.abs(valueMax));
-				for (var i:int = 0; i < circleRadiuses.length; i++)
+				for (i = 0; i < circleRadiuses.length; i++)
 					normalizedCircleRadiuses.push(StandardLib.normalize(Math.abs(circleRadiuses[i]), 0, absMax) * maxScreenRadius.value);
 			}
 			else
 			{
-				for (var i:int = 0; i < circleRadiuses.length; i++)
+				for (i = 0; i < circleRadiuses.length; i++)
 					normalizedCircleRadiuses.push(minScreenRadius.value + (StandardLib.normalize(circleRadiuses[i], valueMin, valueMax) * (maxScreenRadius.value - minScreenRadius.value)));
 			}

@@ -149,7 +149,7 @@
 			g.clear();
 			lineStyle.beginLineStyle(null, g);

-			for (var i:int = 0; i < normalizedCircleRadiuses.length; i++)
+			for (i = 0; i < normalizedCircleRadiuses.length; i++)
 			{
 				tempPoint.y = yPosition;


Transferred from the Adobe Open Source Subversion Repository

Revision: 10828
Author:   jszeto@adobe.com
Date:     2009-10-02T17:41:48.523309Z

Log Message:
-----------
FXG stroke and fill translation fix

http://bugs.adobe.com/jira/browse/SDK-23257 - Gradient translation should occur from 0,0, not the upper left bounds

The current API only passes in the shape's bounds. I have added a new targetOrigin parameter to IFill.begin, IStroke.apply and IStroke.createGraphicsStroke of type Point. It is the origin (0,0) of the shape in the target graphic's coordinate space.

Changed the logic in the gradient stroke and fills. The x and y transform properties are now positioned relative to the origin instead of to the top left corner of the bounds. If no x and y are set, then the default behavior remains the same.

Removed the centering logic in LinearGradientStroke when scaleX was set.

This API change has been approved by PARB.

QE notes: Need to add tests that exercise this logic
Doc notes: Need to document additions to the API
Bugs: SDK-23257
Reviewer: Deepa
Tests run: spark/primitives, gumbo/components
Is noteworthy for integration: Yes, modifications to the API

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/supportClasses/FilledElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/IFill.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/IStroke.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/SolidColorStroke.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/Line.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/mx/graphics/BitmapFill.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/GradientStroke.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/Path.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/framework/src/mx/graphics/SolidColor.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/supportClasses/StrokedElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/RadialGradient.as</path>

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

--- frameworks/projects/framework/src/mx/graphics/LinearGradientStroke.as
+++ frameworks/projects/framework/src/mx/graphics/LinearGradientStroke.as
@@ -17,6 +17,7 @@
 import flash.display.GraphicsGradientFill;
 import flash.display.GraphicsStroke;
 import flash.geom.Matrix;
+import flash.geom.Point;
 import flash.geom.Rectangle;

 import mx.core.mx_internal;
@@ -121,6 +122,11 @@
         super(weight, pixelHinting, scaleMode, caps, joints, miterLimit);
     }

+    /**
+     *  @private
+     */
+    private static var commonMatrix:Matrix = new Matrix();
+
 	//--------------------------------------------------------------------------
 	//
 	//  Properties
@@ -182,27 +188,17 @@
     //--------------------------------------------------------------------------

     /**
-     *  @inheritDoc
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
-     */
-    private static var commonMatrix:Matrix = new Matrix();
-
-    /**
      *  @inheritdoc
      */
-    override public function apply(graphics:Graphics, bounds:Rectangle = null):void
+    override public function apply(graphics:Graphics, targetBounds:Rectangle, targetOrigin:Point):void
 	{
 		commonMatrix.identity();

         graphics.lineStyle(weight, 0, 1, pixelHinting, scaleMode,
                     caps, joints, miterLimit);

-        if (bounds)
-        	calculateTransformationMatrix(bounds, commonMatrix);
+        if (targetBounds)
+        	calculateTransformationMatrix(targetBounds, commonMatrix, targetOrigin);

         graphics.lineGradientStyle(GradientType.LINEAR, colors,
                             alphas, ratios,
@@ -213,17 +209,17 @@
     /**
      *  @private
      */
-    override public function createGraphicsStroke(bounds:Rectangle):GraphicsStroke
+    override public function createGraphicsStroke(targetBounds:Rectangle, targetOrigin:Point):GraphicsStroke
     {
         // The parent class sets the gradient stroke properties common to
         // LinearGradientStroke and RadialGradientStroke
-        var graphicsStroke:GraphicsStroke = super.createGraphicsStroke(bounds);
+        var graphicsStroke:GraphicsStroke = super.createGraphicsStroke(targetBounds, targetOrigin);

         if (graphicsStroke)
         {
             // Set other properties specific to this LinearGradientStroke
             GraphicsGradientFill(graphicsStroke.fill).type = GradientType.LINEAR;
-            calculateTransformationMatrix(bounds, commonMatrix);
+            calculateTransformationMatrix(targetBounds, commonMatrix, targetOrigin);
             GraphicsGradientFill(graphicsStroke.fill).matrix = commonMatrix;
         }

@@ -234,27 +230,26 @@
      *  @private
      *  Calculates this LinearGradientStroke's transformation matrix.
      */
-    private function calculateTransformationMatrix(rect:Rectangle, matrix:Matrix):void
+    private function calculateTransformationMatrix(targetBounds:Rectangle, matrix:Matrix, targetOrigin:Point):void
     {
         if (!compoundTransform)
         {
-            var w:Number = !isNaN(scaleX) ? scaleX : rect.width;
-            var bX:Number = !isNaN(x) ? x + rect.left : rect.left + (rect.width - w) / 2;
-            var bY:Number = !isNaN(y) ? y + rect.top : rect.top;
-
-
-            matrix.createGradientBox(w, rect.height,
+            var w:Number = !isNaN(scaleX) ? scaleX : targetBounds.width;
+            var bX:Number = !isNaN(x) ? x + targetOrigin.x : targetBounds.left;
+            var bY:Number = !isNaN(y) ? y + targetOrigin.y : targetBounds.top;
+
+            matrix.createGradientBox(w, targetBounds.height,
                                     !isNaN(_angle) ?
                                         _angle : rotationInRadians,
                                      bX, bY);
         }
         else
-        {
-            matrix.identity();
+        {
+            matrix.identity();
             matrix.translate(GRADIENT_DIMENSION / 2, GRADIENT_DIMENSION / 2);
             matrix.scale(1 / GRADIENT_DIMENSION, 1 / GRADIENT_DIMENSION);
             matrix.concat(compoundTransform.matrix);
-            matrix.translate(rect.left, rect.top);
+            matrix.translate(targetOrigin.x, targetOrigin.y);
         }
     }