Transferred from the Adobe Open Source Subversion Repository

Revision: 3985
Author:   smgilson@adobe.com
Date:     2008-10-31T20:45:23.566944Z

Log Message:
-----------
add pointers to event classes

QE Notes: None
Doc Notes: None
Bugs: -

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxTextInput.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/FxTextBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/TextView.as</path>

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

--- frameworks/projects/spark/src/spark/components/RichEditableText.as
+++ frameworks/projects/spark/src/spark/components/RichEditableText.as
@@ -65,6 +65,8 @@
  *  Dispached after the selectionAnchorPosition and/or
  *  selectionActivePosition properties have changed.
  *  due to a user interaction.
+ *
+ *  @eventType mx.events.FlexEvent.SELECTION_CHANGE
  */
 [Event(name="selectionChange", type="mx.events.FlexEvent")]

@@ -72,16 +74,22 @@
  *  Dispatched before a user editing operation occurs.
  *  You can alter the operation, or cancel the event
  *  to prevent the operation from being processed.
+ *
+ *  @eventType mx.events.FlexEvent.CHANGING
  */
 [Event(name="changing", type="mx.events.TextOperationEvent")]

 /**
  *  Dispatched after a user editing operation is complete.
+ *
+ *  @eventType mx.events.FlexEvent.CHANGE
  */
 [Event(name="change", type="mx.events.TextOperationEvent")]

 /**
  *  Dispatched when the user pressed the Enter key.
+ *
+ *  @eventType mx.events.FlexEvent.ENTER
  */
 [Event(name="enter", type="mx.events.FlexEvent")]

@@ -982,11 +990,11 @@
     {
         // The whiteSpaceCollapse format determines how whitespace
         // is processed when markup is imported.
-		staticCharacterFormat.whiteSpaceCollapse =
+        staticCharacterFormat.whiteSpaceCollapse =
             getStyle("whiteSpaceCollapse");
-		staticConfiguration.textFlowInitialCharacterFormat =
+        staticConfiguration.textFlowInitialCharacterFormat =
             staticCharacterFormat;
-		staticImportExportConfiguration.textFlowConfiguration =
+        staticImportExportConfiguration.textFlowConfiguration =
             staticConfiguration;

         if (markup is String)
@@ -1038,7 +1046,7 @@
             {
                 textFlow = createTextFlowFromChildren([ _content ]);
             }
-	        else if (_content is String || _content is XML)
+            else if (_content is String || _content is XML)
             {
                 textFlow = createTextFlowFromMarkup(_content);
             }


Transferred from the Adobe Open Source Subversion Repository

Revision: 5545
Author:   jimurphy@adobe.com
Date:     2009-03-25T19:00:52.330680Z

Log Message:
-----------
1st pass of rename according to the spec http://opensource.adobe.com/wiki/display/flexsdk/Dropping+the+Fx+Prefix

Flex now requires CSS Style declarations to declare @namespace rules and disambiguate between halo and spark components using CSS 3 namespace prefixes on type selectors. At compile time, this namespace information will be used to map type names to qualified ActionScript class names. At runtime, type selectors are matched on qualified ActionScript class name (for example mx.controls.Button rather than just Button). Flex 3 applications must be compiled with -compatibility-version=3.0.0 to get unqualified CSS type selector behavior.

QE: Yes, this build may help in updating test cases to use the new namespaces and class names.
Dev: Not yet
Doc: Not yet

Modified Paths:
--------------
748 paths were modified

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

--- frameworks/projects/spark/src/spark/effects/interpolation/RGBInterpolator.as
+++ frameworks/projects/spark/src/spark/effects/interpolation/RGBInterpolator.as
@@ -8,7 +8,7 @@
 //  in accordance with the terms of the license agreement accompanying it.
 //
 ////////////////////////////////////////////////////////////////////////////////
-package mx.effects.interpolation
+package spark.effects.interpolation
 {
 /**
  * The RGBInterpolator class provides RGB-space interpolation between


Transferred from the Adobe Open Source Subversion Repository

Revision: 4111
Author:   chaase@adobe.com
Date:     2008-11-14T16:39:46.711628Z

Log Message:
-----------
Makes auto-reversal of transitions work more completely and correctly, fixing some API issues and other related animation/effect issues along the way. Seeking behavior in effects is improved (although still far from perfect, especially for non-playing effects), and dynamic behavior of effects (picking up values dynamically from the environment) is improved.

QE Notes: better seek() behavior, can just call it on non-playing effects and it will automatically play/pause the effect if necessary
Doc Notes: None
Bugs: sdk-17294, sdk-16595, sdk-18104, sdk-18105, sdk-18106, sdk-18107
Reviewer: Jason
tests: checkintests, Mustella: tests/Effects, tests/gumbo/effects tests/ListDataEffects

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/states/Transition.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/CompositeEffect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/RemoveAction.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/framework/src/mx/events/EffectEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxResizeInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxMoveInstance.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/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/Parallel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/CallAction.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxAnimateInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/FxAnimate.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/framework/src/mx/effects/effectClasses/SequenceInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/Sequence.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/AddAction.as</path>

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

--- frameworks/projects/spark/src/spark/effects/supportClasses/ResizeInstance.as
+++ frameworks/projects/spark/src/spark/effects/supportClasses/ResizeInstance.as
@@ -284,8 +284,6 @@
         {
             if (!isNaN(widthTo) && !isNaN(widthBy))
                 widthFrom = widthTo - widthBy;
-            else if (propertyChanges && propertyChanges.start["width"] !== undefined)
-                widthFrom = propertyChanges.start["width"];
         }
         if (isNaN(widthTo))
         {
@@ -316,8 +314,6 @@
         {
             if (!isNaN(heightTo) && !isNaN(heightBy))
                 heightFrom = heightTo - heightBy;
-            else if (propertyChanges && propertyChanges.start["height"] != undefined)
-                heightFrom = propertyChanges.start["height"];
         }
         if (isNaN(heightTo))
         {


Transferred from the Adobe Open Source Subversion Repository

Revision: 20208
Author:   smgilson@adobe.com
Date:     2011-02-08T21:40:02.122057Z

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

QE notes:
Doc notes:
Bugs: FLEXDOCS-1342, FLEXDOCS-1330, FLEXDOCS-1323
Reviewer:
Tests run:
Is noteworthy for integration:

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/core/EmbeddedFont.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/asdoc/en_US/spark/components/examples/ScrollerExample.mxml</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/primitives/BitmapImage.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/primitives/RectangularDropShadow.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/airspark/src/spark/skins/spark/windowChrome/MacTitleBarSkin.mxml</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/states/AddItems.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/airframework/src/mx/core/FlexHTMLLoader.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/flash-integration/src/mx/flash/UIMovieClip.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/managers/IFocusManagerComponent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/utils/ObjectUtil.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GroupBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/core/DeferredInstanceFromClass.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/core/DeferredInstanceFromFunction.as</path>

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

--- frameworks/projects/framework/src/mx/managers/IFocusManagerComponent.as
+++ frameworks/projects/framework/src/mx/managers/IFocusManagerComponent.as
@@ -80,7 +80,7 @@
     /**
      *  @copy mx.core.UIComponent#hasFocusableChildren
      *
-     *  @langversion 4.0
+     *  @langversion 3.0
      *  @playerversion Flash 10
      *  @playerversion AIR 1.5
      *  @productversion Flex 4


Transferred from the Adobe Open Source Subversion Repository

Revision: 18046
Author:   jasonsj@adobe.com
Date:     2010-10-06T23:00:53.128377Z

Log Message:
-----------
Style changes for ActionBar including: new 67px height, title shadow up, light-look and chromeColor support in ActionBar buttons.
Added inheriting MobileTextFieldTextStyles to ActionBar.
Added inheriting container styles to ActionBar: accentColor, contentBackgroundAlpha, contentBackgroundColor, focusColor.
Added skin states to ActionBar

QE notes:
Doc notes:
Bugs:
SDK-27684 Several ActionBar style metadata tags are missing
SDK-28006 ActionBar TitleContent is not replacing Title when set in AS
SDK-27948 unable to style components inside actionContent and navigationContent via individual component's css rule
SDK-27684 Several ActionBar style metadata tags are missing
Reviewer: rfrishbe
Tests run: checkintests
Is noteworthy for integration: yes

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/assets/NavigationButton_up.fxg</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/assets/ActionButton_down.fxg</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/assets/ActionBarBackground.fxg</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/assets/NavigationButton_down.fxg</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/defaults.css</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ActionBarSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/MobileThemeClasses.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/ActionBar.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ActionBarButtonSkinBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ActionButtonSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ButtonSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/NavigationButtonSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/assets/ActionButton_up.fxg</path>

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

--- frameworks/projects/mobiletheme/src/spark/skins/mobile/ActionBarSkin.as
+++ frameworks/projects/mobiletheme/src/spark/skins/mobile/ActionBarSkin.as
@@ -17,10 +17,10 @@
 import flash.text.TextFormatAlign;
 import flash.text.TextLineMetrics;

-import mx.core.ILayoutElement;
 import mx.core.UIComponent;
 import mx.core.UITextField;
 import mx.core.mx_internal;
+import mx.events.ResizeEvent;
 import mx.utils.ColorUtil;

 import spark.components.ActionBar;
@@ -65,13 +65,25 @@
     //
     //--------------------------------------------------------------------------

+    private static var BORDER_HEIGHT:uint = 1;
+
+    private static var SHADOW_HEIGHT:uint = 3;
+
+    private static var CONTENT_GROUP_HEIGHT:uint = 65;
+
     public var hostComponent:ActionBar;

     public var navigationGroup:Group;

+    private var _navigationVisible:Boolean = false;
+
     public var titleGroup:Group;

+    private var _titleContentVisible:Boolean = false;
+
     public var actionGroup:Group;
+
+    private var _actionVisible:Boolean = false;

     public var titleDisplay:TitleDisplayComponent;

@@ -106,7 +118,7 @@
         hLayout.horizontalAlign = HorizontalAlign.LEFT;
         hLayout.verticalAlign = VerticalAlign.MIDDLE;
         hLayout.gap = 0;
-        hLayout.paddingLeft = hLayout.paddingRight = 25;
+        hLayout.paddingLeft = hLayout.paddingRight = 20;
         hLayout.paddingTop = hLayout.paddingBottom = 0;
         titleGroup.layout = hLayout;

@@ -120,7 +132,6 @@
         actionGroup.layout = hLayout;

         titleDisplay = new TitleDisplayComponent();
-        titleDisplay.percentWidth = 100;

         initializeStyles();

@@ -144,12 +155,12 @@
         var titleWidth:Number = 0;
         var titleHeight:Number = 0;

-        if (titleGroup && hostComponent.titleContent)
+        if (_titleContentVisible)
         {
             titleWidth = titleGroup.getPreferredBoundsWidth();
             titleHeight = titleGroup.getPreferredBoundsHeight();
         }
-        else if (titleDisplay)
+        else
         {
             // use titleLayout for paddingLeft and paddingRight
             var layoutObject:Object = hostComponent.titleLayout;
@@ -165,12 +176,26 @@
             + actionGroup.getPreferredBoundsWidth()
             + titleWidth;

-        // min height is 82 (80px content height, 1px borders on top and bottom)
+        // min height is 67 (65px content height, 1px borders on top and bottom)
         // Math.max.apply optimization used instead of "..." rest parameter
         measuredMinHeight = measuredHeight =
-            Math.max.apply(null, [80, navigationGroup.getPreferredBoundsHeight(),
+            Math.max(CONTENT_GROUP_HEIGHT,
+                navigationGroup.getPreferredBoundsHeight(),
                 actionGroup.getPreferredBoundsHeight(),
-                titleHeight]) + 2;
+                titleHeight)
+            + (BORDER_HEIGHT * 2);
+    }
+
+    override protected function commitCurrentState():void
+    {
+        super.commitCurrentState();
+
+        _titleContentVisible = currentState.indexOf("titleContent") >= 0;
+        _navigationVisible = currentState.indexOf("Navigation") >= 0;
+        _actionVisible = currentState.indexOf("Action") >= 0;
+
+        invalidateSize();
+        invalidateDisplayList();
     }

     override protected function updateDisplayList(unscaledWidth:Number,
@@ -191,31 +216,30 @@
         var actionGroupWidth:Number = 0;

         // remove top and bottom borders from content group height
-        var contentGroupsHeight:Number = unscaledHeight - 2;
+        var contentGroupsHeight:Number = unscaledHeight - (BORDER_HEIGHT * 2);

         // FXG uses scale-9, 3 px drop shadow is drawn outside the bounds
-        resizePart(border, unscaledWidth, unscaledHeight + 3);
+        resizePart(border, unscaledWidth, unscaledHeight + SHADOW_HEIGHT);

         // position groups, overlap of navigation and action groups is allowed
         // when overlap occurs, titleDisplay/titleGroup is not visible
-        if (navigationGroup.numElements > 0
-            && navigationGroup.includeInLayout)
+        if (_navigationVisible)
         {
             navigationGroupWidth = navigationGroup.getPreferredBoundsWidth();
             titleCompX += navigationGroupWidth;

             navigationGroup.setLayoutBoundsSize(navigationGroupWidth, contentGroupsHeight);
-            navigationGroup.setLayoutBoundsPosition(0, 1); // top border
-        }
-
-        if (actionGroup.numElements > 0 && actionGroup.includeInLayout)
+            navigationGroup.setLayoutBoundsPosition(0, BORDER_HEIGHT);
+        }
+
+        if (_actionVisible)
         {
             // actionGroup x position can be negative
             actionGroupWidth = actionGroup.getPreferredBoundsWidth();
             actionGroupX = unscaledWidth - actionGroupWidth;

             actionGroup.setLayoutBoundsSize(actionGroupWidth, contentGroupsHeight);
-            actionGroup.setLayoutBoundsPosition(actionGroupX, 1); // top border
+            actionGroup.setLayoutBoundsPosition(actionGroupX, BORDER_HEIGHT);
         }

         titleCompWidth = unscaledWidth - navigationGroupWidth - actionGroupWidth;
@@ -224,14 +248,14 @@
             titleDisplay.visible = false;
             titleGroup.visible = false;
         }
-        else if (hostComponent.titleContent != null && titleGroup.includeInLayout)
+        else if (_titleContentVisible)
         {
             titleDisplay.visible = false;
             titleGroup.visible = true;

             // use titleGroup for titleContent
             titleGroup.setLayoutBoundsSize(titleCompWidth, contentGroupsHeight);
-            titleGroup.setLayoutBoundsPosition(titleCompX, 1); // top border
+            titleGroup.setLayoutBoundsPosition(titleCompX, BORDER_HEIGHT);
         }
         else
         {
@@ -243,38 +267,74 @@
             var titlePaddingLeft:Number = (layoutObject.paddingLeft) ? Number(layoutObject.paddingLeft) : 0;
             var titlePaddingRight:Number = (layoutObject.paddingRight) ? Number(layoutObject.paddingRight) : 0;

-            // implement padding by adjusting width and position
-            titleCompX += titlePaddingLeft;
-            titleCompWidth = titleCompWidth - (titlePaddingLeft + titlePaddingRight);
+            // vertical align center by subtracting the descent and top gutter
+            titleHeight = titleDisplay.getExplicitOrMeasuredHeight();
+            titleCompY = Math.round((contentGroupsHeight - titleHeight - UITextField.TEXT_HEIGHT_PADDING + titleDisplay.descent) / 2);

             // align titleDisplay to the absolute center
             var titleAlign:String = getStyle("titleAlign");
-            if (titleAlign == "center")
+
+            // check for available width after padding
+            if ((titleCompWidth - titlePaddingLeft - titlePaddingRight) <= 0)
+            {
+                titleCompX = 0;
+                titleCompWidth = 0;
+            }
+            else if (titleAlign == "center")
             {
                 // use LEFT instead of CENTER
                 titleDisplay.setStyle("textAlign", TextFormatAlign.LEFT);
                 titleCompWidth = titleDisplay.getExplicitOrMeasuredWidth();

                 // use x position of titleDisplay to implement CENTER
-                titleCompX = Math.floor((unscaledWidth - titleCompWidth)/ 2);
+                titleCompX = Math.round((unscaledWidth - titleCompWidth) / 2);
+
+                var navigationOverlap:Number = navigationGroupWidth + titlePaddingLeft - titleCompX;
+                var actionOverlap:Number = (titleCompX + titleCompWidth + titlePaddingRight) - actionGroupX;
+
+                // shrink and/or move titleDisplay width if there is any
+                // overlap after centering
+                if ((navigationOverlap > 0) && (actionOverlap > 0))
+                {
+                    // remaining width
+                    titleCompX = navigationGroupWidth + titlePaddingLeft;
+                    titleCompWidth = unscaledWidth - navigationGroupWidth - actionGroupWidth - titlePaddingLeft - titlePaddingRight;
+                }
+                else if ((navigationOverlap > 0) || (actionOverlap > 0))
+                {
+                    if (navigationOverlap > 0)
+                    {
+                        // nudge to the right
+                        titleCompX += navigationOverlap;
+                    }
+                    else if (actionOverlap > 0)
+                    {
+                        // nudge to the left
+                        titleCompX -= actionOverlap;
+
+                        // force left padding
+                        if (titleCompX < (navigationGroupWidth + titlePaddingLeft))
+                            titleCompX = navigationGroupWidth + titlePaddingLeft;
+                    }
+
+                    // recompute action overlap and force right padding
+                    actionOverlap = (titleCompX + titleCompWidth + titlePaddingRight) - actionGroupX;
+
+                    if (actionOverlap > 0)
+                        titleCompWidth -= actionOverlap;
+                }
             }
             else
             {
                 titleDisplay.setStyle("textAlign", titleAlign);
+
+                // implement padding by adjusting width and position
+                titleCompX += titlePaddingLeft;
+                titleCompWidth -= titlePaddingLeft + titlePaddingRight;
             }
-
-            // shrink and/or move titleDisplay width if there is any overlap after padding
-            if ((titleCompX < navigationGroupWidth)
-                || ((titleCompX + titleCompWidth) > (actionGroupX - titlePaddingRight)))
-            {
-                titleCompX = navigationGroupWidth + titlePaddingLeft;
-                titleCompWidth = actionGroupX - titleCompX - titlePaddingRight;
-            }
-
-            // vertical align center by subtracting the descent and top gutter
-            titleHeight = titleDisplay.getExplicitOrMeasuredHeight();
-            titleCompY = Math.floor((contentGroupsHeight - titleHeight + titleDisplay.descent) / 2);
-            titleCompY -= (UITextField.TEXT_HEIGHT_PADDING / 2);
+
+            // check for negative width
+            titleCompWidth = (titleCompWidth < 0) ? 0 : titleCompWidth;

             titleDisplay.setLayoutBoundsSize(titleCompWidth, titleHeight);
             titleDisplay.setLayoutBoundsPosition(titleCompX, titleCompY);
@@ -284,9 +344,12 @@

         // Draw the gradient background
         var chromeColor:uint = getStyle("chromeColor");
-        var alpha:Number = getStyle("backgroundAlpha");
-        var alphas:Array = [alpha, alpha, alpha];
+        var backgroundAlphaValue:Number = getStyle("backgroundAlpha");
         var colors:Array = [];
+
+        // apply alpha to border and chromeColor
+        border.alpha = backgroundAlphaValue;
+        var backgroundAlphas:Array = [backgroundAlphaValue, backgroundAlphaValue, backgroundAlphaValue];

         // exclude top and bottom 1px borders
         matrix.createGradientBox(unscaledWidth, contentGroupsHeight, Math.PI / 2, 0, 0);
@@ -295,8 +358,8 @@
         colors[1] = chromeColor;
         colors[2] = ColorUtil.adjustBrightness2(chromeColor, -20);

-        graphics.beginGradientFill(GradientType.LINEAR, colors, alphas, ratios, matrix);
-        graphics.drawRect(0, 1, unscaledWidth, contentGroupsHeight);
+        graphics.beginGradientFill(GradientType.LINEAR, colors, backgroundAlphas, ratios, matrix);
+        graphics.drawRect(0, BORDER_HEIGHT, unscaledWidth, contentGroupsHeight);
         graphics.endFill();
     }
 }
@@ -356,6 +419,7 @@
         titleDisplayShadow.selectable = false;
         titleDisplayShadow.multiline = false;
         titleDisplayShadow.wordWrap = false;
+        titleDisplayShadow.alpha = .45;

         addChild(titleDisplayShadow);
         addChild(titleDisplay);
@@ -396,7 +460,6 @@
         }

         textHeight = lineMetrics.height + UITextField.TEXT_HEIGHT_PADDING;
-
         descent = lineMetrics.descent;

         measuredWidth = textWidth;
@@ -417,7 +480,7 @@
         titleDisplay.truncateToFit();

         titleDisplayShadow.commitStyles();
-        titleDisplayShadow.y = titleDisplay.y + 1; // 90 degree drop shadow
+        titleDisplayShadow.y = titleDisplay.y - 1; // -90 degree shadow
         titleDisplayShadow.width = unscaledWidth;
         titleDisplayShadow.height = unscaledHeight;


Transferred from the Adobe Open Source Subversion Repository

Revision: 7376
Author:   hmuller@adobe.com
Date:     2009-05-28T18:25:57.415529Z

Log Message:
-----------
Bug fixes for DropDownList, virtualized TileLayout.  Refactoring of the "cooperative layout"
code in TrackBase.

QE Notes:
Doc Notes:
Bugs: sdk-21459, sdk-21250, sdk-20864
Reviewer: Ryan

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/layouts/TileLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/VideoPlayerScrubBar.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/components/supportClasses/TrackBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/layouts/supportClasses/LayoutBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/layouts/supportClasses/LinearLayoutVector.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/SkinnableDataContainer.as</path>

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

--- frameworks/projects/spark/src/spark/components/mediaClasses/ScrubBar.as
+++ frameworks/projects/spark/src/spark/components/mediaClasses/ScrubBar.as
@@ -84,14 +84,6 @@
      *  @productversion Flex 4
      */
     public var bufferedArea:IVisualElement;
-
-    //--------------------------------------------------------------------------
-    //
-    //  Variables
-    //
-    //--------------------------------------------------------------------------
-
-    private var tempTrackSize:Number = NaN;

     //--------------------------------------------------------------------------
     //
@@ -162,41 +154,16 @@

             invalidateDisplayList();
         }
-        else if (instance == track)
-        {
-            tempTrackSize = NaN;
-        }
-    }
-
-    /**
-     *  @private
-     */
-    override protected function updateDisplayList(unscaledWidth:Number,
-                                                  unscaledHeight:Number):void
-    {
-        super.updateDisplayList(unscaledWidth, unscaledHeight);
-
+    }
+
+    /**
+     *  @private
+     */
+    override protected function completeTrackLayout():void
+    {
+        super.completeTrackLayout();
         sizeBufferedArea(valueToPosition(bufferedValue) + thumbSize);
         sizePlayedArea(valueToPosition(value) + thumbSize);
-    }
-
-    /**
-     *  @private
-     *  Force the component to set itself up correctly now that the
-     *  track is completely loaded.
-     */
-    override protected function track_updateCompleteHandler(event:Event):void
-    {
-        super.track_updateCompleteHandler(event);
-
-        //TODO: Consider the case where the track moves (like the move
-        //effect). Perhaps this handler should run every time...
-        if (trackSize != tempTrackSize)
-        {
-            sizeBufferedArea(valueToPosition(bufferedValue) + thumbSize);
-            sizePlayedArea(valueToPosition(value) + thumbSize);
-            tempTrackSize = trackSize;
-        }
     }

     /**
@@ -212,7 +179,7 @@
     protected function sizeBufferedArea(bufferedAreaSize:Number):void
     {
         if (bufferedArea)
-            DisplayObject(bufferedArea).width = Math.round(bufferedAreaSize);
+            bufferedArea.setLayoutBoundsSize(Math.round(bufferedAreaSize), NaN);
     }

     /**
@@ -228,7 +195,7 @@
     protected function sizePlayedArea(playedAreaSize:Number):void
     {
         if (playedArea)
-            DisplayObject(playedArea).width = Math.round(playedAreaSize);
+            playedArea.setLayoutBoundsSize(Math.round(playedAreaSize), NaN);
     }

     /**


- fixed dropshadow bug fo' shizzle!

- fixed dropshadow bug fo' shizzle!

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

--- src/reprise/css/propertyparsers/Filters.as
+++ src/reprise/css/propertyparsers/Filters.as
@@ -85,21 +85,21 @@
 					name + 'ShadowColor');
 				part = parts[counter++];
 			}
-			if (parts.length == 4)
-			{
-				res.addPropertyForKey(strToIntProperty(part + important, file),
-					name + 'ShadowXOffset');
-				part = parts[counter++];
-				res.addPropertyForKey(strToIntProperty(part + important, file),
-						name + 'ShadowYOffset');
-			}
-			else if (parts.length < 4)
+			if (parts.length == 3)
 			{
 				res.addPropertyForKey(strToIntProperty(part + important, file),
 					name + 'ShadowXOffset');
 				part = parts[counter++];
 				res.addPropertyForKey(strToIntProperty(part + important, file),
+						name + 'ShadowYOffset');
+			}
+			else if (parts.length < 3)
+			{
+				res.addPropertyForKey(strToIntProperty(part + important, file),
+					name + 'ShadowXOffset');
+				res.addPropertyForKey(strToIntProperty(part + important, file),
 					name + 'ShadowYOffset');
+				return res;
 			}
 			part = parts[counter++];
 			res.addPropertyForKey(strToIntProperty(part + important, file),


Transferred from the Adobe Open Source Subversion Repository

Revision: 18569
Author:   egeorgie@adobe.com
Date:     2010-11-13T00:36:07.390544Z

Log Message:
-----------
Animations to ViewMenu, default skin for SkinnablePopUpContainer

- Add SkinnablePopUpContainerSkin
- Add state transitions for ViewMenuSkin

QE notes:
Doc notes:
Bugs:
Reviewer: Jason
Tests run: manual, checkintests
Is noteworthy for integration: Yes

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/SparkClasses.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/MobileApplicationBase.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/skins/spark/SkinnablePopUpContainerSkin.mxml</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/defaults.css</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ViewMenuSkin.mxml</path>

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

--- frameworks/projects/spark/src/SparkClasses.as
+++ frameworks/projects/spark/src/SparkClasses.as
@@ -82,6 +82,7 @@
 import spark.skins.spark.ScrollerSkin; ScrollerSkin;
 import spark.skins.spark.SkinnableContainerSkin; SkinnableContainerSkin;
 import spark.skins.spark.SkinnableDataContainerSkin; SkinnableDataContainerSkin;
+import spark.skins.spark.SkinnablePopUpContainerSkin; SkinnablePopUpContainerSkin;
 import spark.skins.spark.SpinnerDecrementButtonSkin; SpinnerDecrementButtonSkin;
 import spark.skins.spark.SpinnerIncrementButtonSkin; SpinnerIncrementButtonSkin;
 import spark.skins.spark.SpinnerSkin; SpinnerSkin;


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

 package mx.effects.effectClasses
 {


Use native trim() method in JS

Use native trim() method in JS

--- frameworks/projects/Core/src/main/flex/org/apache/flex/utils/StringTrimmer.as
+++ frameworks/projects/Core/src/main/flex/org/apache/flex/utils/StringTrimmer.as
@@ -52,6 +52,7 @@
 		 *  @playerversion AIR 2.6
 		 *  @productversion FlexJS 0.0
          */
+		COMPILE::SWF
         public static function trim(str:String):String
         {
             if (str == null) return '';
@@ -69,6 +70,13 @@
             else
                 return "";
         }
+
+		COMPILE::JS
+		public static function trim(str:String):String
+		{
+			if (str == null) return '';
+			return str.trim();
+		}

         /**
          *  Removes all whitespace characters from the beginning and end


Transferred from the Adobe Open Source Subversion Repository

Revision: 18126
Author:   gruehle@adobe.com
Date:     2010-10-11T18:03:16.346900Z

Log Message:
-----------
Change name MobileTextField to StyleableTextField.

QE notes: Tests using MobileTextField by name will need updating.
Doc notes: Docs mentioning MobileTextField will need updating.
Bugs: SDK-27849
Reviewer: Ryan
Tests run: checkintests, QE cyclone
Is noteworthy for integration: Yes

Modified Paths:
--------------
<path kind="file" copyfrom-path="/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/MobileTextField.as" copyfrom-rev="18115" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/StyleableTextField.as</path>
<path kind="file" action="D">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/styles/metadata/MobileTextFieldTextStyles.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/TextAreaSkin.as</path>
<path kind="file" action="D">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/MobileTextField.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/ButtonSkinBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/MobileItemRenderer.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ActionBarSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/TextInputOperation.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/TextInputSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/ActionBar.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/styles/metadata/StyleableTextFieldTextStyles.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/MobileComponentsClasses.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/MobileIconItemRenderer.as</path>

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

--- frameworks/projects/mobilecomponents/src/spark/components/IconItemRenderer.as
+++ frameworks/projects/mobilecomponents/src/spark/components/IconItemRenderer.as
@@ -25,7 +25,7 @@
 import mx.graphics.BitmapScaleMode;
 import mx.styles.CSSStyleDeclaration;

-import spark.components.supportClasses.MobileTextField;
+import spark.components.supportClasses.StyleableTextField;
 import spark.core.ContentCache;
 import spark.core.DisplayObjectSharingMode;
 import spark.core.IContentLoader;
@@ -823,7 +823,7 @@
      *  @playerversion AIR 2.5
      *  @productversion Flex 4.5
      */
-    protected var messageDisplay:MobileTextField;
+    protected var messageDisplay:StyleableTextField;

     /**
      *  @private
@@ -1190,7 +1190,7 @@
                 // get styles for this text component

                 // need to create it
-                messageDisplay = MobileTextField(createInFontContext(MobileTextField));
+                messageDisplay = StyleableTextField(createInFontContext(StyleableTextField));
                 messageDisplay.getStyleFunction = messageGetStyleFunction;
                 messageDisplay.editable = false;
                 messageDisplay.selectable = false;
@@ -1379,7 +1379,7 @@
     private function createLabelDisplay():void
     {
         // need to create it
-        labelDisplay = MobileTextField(createInFontContext(MobileTextField));
+        labelDisplay = StyleableTextField(createInFontContext(StyleableTextField));
         labelDisplay.styleProvider = this;
         labelDisplay.editable = false;
         labelDisplay.selectable = false;
@@ -1789,7 +1789,7 @@
     /**
      *  @private
      *  Function we pass in to message for it to grab the styles and push
-     *  them in to the TextFormat object used by that MobileTextField.
+     *  them in to the TextFormat object used by that StyleableTextField.
      */
     private function messageGetStyleFunction(styleProp:String):*
     {


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

 package spark.components.supportClasses
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 3553
Author:   chaase@adobe.com
Date:     2008-10-09T23:14:18.257660Z

Log Message:
-----------
Fixed sdk-17113, sdk-17139, sdk-16526, sdk-16884, sdk-17154, sdk-16999, sdk-16631, sdk-17214. Most of these fixes are related to making effects work when contraints are enabled on the target. For that, two new attributes were added to FxAnimate: disableLayout (default false) and adjustConstraints (default false). Fixes were also made for various other effects issues, such as running all animations and startDelays off of the same global timer.
The change also includes renames of some effects classes and the easing API (now in mx.effects.interpolation).

Reviewed by: Jason (effects code) and Hans (renames)
tests: checkintests

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxRotateInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxResizeInstance.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/fxEasing/IEaser.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/IEaser.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/fxEasing/Linear.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/Linear.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/mxml-2009-manifest.xml</path>
<path kind="dir" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/fxEasing</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/Animate3DInstance.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxAnimate3DInstance.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/Animate3D.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/FxAnimate3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxMoveInstance.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/Animate3DInstance.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/Animate3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/gumbo-manifest.xml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/Timeline.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/manifest.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxAnimateInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/FxAnimate.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/Animation.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/fxEasing/Constant.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/Constant.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/Rotate3DInstance.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxRotate3DInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/FxAnimateFilter.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/Rotate3D.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/FxRotate3D.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/fxEasing/EaseInOut.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/EaseInOut.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/fxEasing/Power.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/Power.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/Rotate3DInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/GroupBase.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/fxEasing/Sine.as" copyfrom-rev="3548" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/Sine.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/Rotate3D.as</path>

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

--- frameworks/projects/spark/src/spark/effects/supportClasses/AnimateInstance.as
+++ frameworks/projects/spark/src/spark/effects/supportClasses/AnimateInstance.as
@@ -12,18 +12,24 @@
 package mx.effects.effectClasses
 {
 import flash.events.TimerEvent;
+import flash.geom.Point;
 import flash.utils.Timer;

+import mx.components.baseClasses.GroupBase;
 import mx.components.Group;
 import mx.effects.Animation;
 import mx.effects.PropertyValuesHolder;
-import mx.effects.fxEasing.IEaser;
+import mx.effects.interpolation.IEaser;
 import mx.effects.interpolation.IInterpolator;
 import mx.events.AnimationEvent;
-
+import mx.layout.ILayoutItem;
+import mx.layout.LayoutItemFactory;
+
+import mx.core.Container;
 import mx.core.UIComponent;
 import mx.effects.EffectInstance;
 import mx.effects.EffectManager;
+import mx.managers.LayoutManager;
 import mx.styles.IStyleClient;

 /**
@@ -111,6 +117,9 @@
      */
     protected var autoRemoveTarget:Boolean = false;

+    public var adjustConstraints:Boolean;
+
+    public var disableLayout:Boolean;

     private var _easer:IEaser;
     public function set easer(value:IEaser):void
@@ -283,8 +292,11 @@

         isStyleMap = new Array(propertyValuesList.length);

-        if (affectsConstraints)
-            disableConstraints();
+        if (affectsConstraints || adjustConstraints)
+            cacheConstraints(affectsConstraints);
+
+        if (disableLayout)
+            setupParentLayout(false);

         // These two temporary arrays will hold the values passed into the
         // Animation to be interpolated between during the animation. The order
@@ -453,11 +465,13 @@
     protected function endHandler(event:AnimationEvent):void
     {
         dispatchEvent(event);
-        finishEffect();
-        if (affectsConstraints)
+        if (affectsConstraints || adjustConstraints)
             reenableConstraints();
         if (autoRemoveTarget)
             removeDisappearingTarget();
+        if (disableLayout)
+            setupParentLayout(true);
+        finishEffect();
     }

     /**
@@ -541,12 +555,16 @@

     private var constraintsHolder:Object;

+    // TODO (chaase): Use IConstraintClient for this
     private function reenableConstraint(name:String):void
     {
         var value:* = constraintsHolder[name];
         if (value !== undefined)
         {
-            target.setStyle(name, value);
+            if (name in target)
+                target[name] = value;
+            else
+                target.setStyle(name, value);
             delete constraintsHolder[name];
         }
     }
@@ -557,6 +575,52 @@
         // there must have been no constraints to worry about
         if (constraintsHolder)
         {
+            if (adjustConstraints)
+            {
+                var layoutItem:ILayoutItem = LayoutItemFactory.getLayoutItemFor(target);
+                var location:Point = layoutItem.actualPosition;
+                var size:Point = layoutItem.actualSize;
+                if (constraintsHolder["left"] !== undefined)
+                    constraintsHolder["left"] = Math.round(location.x);
+                if (constraintsHolder["top"] !== undefined)
+                    constraintsHolder["top"] = Math.round(location.y);
+                if (constraintsHolder["right"] !== undefined)
+                {
+                    var parentW:int = 0;
+                    if ("parent" in target && target.parent)
+                    {
+                        parentW = target.parent.width;
+                    }
+                    else if ("elementHost" in target && target.elementHost)
+                    {
+                        parentW = target.elementHost.width;
+                    }
+                    if (parentW > 0)
+                    {
+                        // Only bother adjusting 'right' if our target is
+                        // parented to an object with a positive width
+                        constraintsHolder["right"] = parentW - location.x - size.x;
+                    }
+                }
+                if (constraintsHolder["bottom"] !== undefined)
+                {
+                    var parentH:int = 0;
+                    if ("parent" in target && target.parent)
+                    {
+                        parentH = target.parent.height;
+                    }
+                    else if ("elementHost" in target && target.elementHost)
+                    {
+                        parentH = target.elementHost.height;
+                    }
+                    if (parentH > 0)
+                    {
+                        // Only bother adjusting 'bottom' if our target is
+                        // parented to an object with a positive height
+                        constraintsHolder["bottom"] = parentH - location.y - size.y;
+                    }
+                }
+            }
             reenableConstraint("left");
             reenableConstraint("right");
             reenableConstraint("top");
@@ -568,30 +632,41 @@
         }
     }

-    private function disableConstraint(name:String):void
-    {
-        var value:* = target.getStyle(name);
-        if (value !== undefined)
+    // TODO (chaase): Use IConstraintClient for this
+    private function cacheConstraint(name:String, disable:Boolean):void
+    {
+        var isProperty:Boolean = (name in target);
+        var value:*;
+        if (isProperty)
+            value = target[name];
+        else
+            value = target.getStyle(name);
+        if (!isNaN(value))
         {
             if (!constraintsHolder)
                 constraintsHolder = new Object();
             constraintsHolder[name] = value;
-            target.setStyle(name, undefined);
+            if (disable)
+            {
+                if (isProperty)
+                    target[name] = NaN;
+                else if (target is IStyleClient)
+                    target.setStyle(name, undefined);
+            }
         }
     }
-    private function disableConstraints():void
-    {
-        if (target is IStyleClient)
-        {
-            disableConstraint("left");
-            disableConstraint("right");
-            disableConstraint("top");
-            disableConstraint("bottom");
-            disableConstraint("verticalCenter");
-            disableConstraint("horizontalCenter");
-            disableConstraint("baseline");
-        }
-    }
+
+    private function cacheConstraints(disable:Boolean):void
+    {
+        cacheConstraint("left", disable);
+        cacheConstraint("right", disable);
+        cacheConstraint("top", disable);
+        cacheConstraint("bottom", disable);
+        cacheConstraint("verticalCenter", disable);
+        cacheConstraint("horizontalCenter", disable);
+        cacheConstraint("baseline", disable);
+    }
+
     /**
      * Utility function to handle situation where values may be queried or
      * set on the target prior to completely setting up the effect's
@@ -657,5 +732,30 @@
         else
             return target.getStyle(property);
     }
+
+    /**
+     * Enables or disables autoLayout in the target's container.
+     * This is used to disable layout during the course of an animation,
+     * and to re-enable it when the animation finishes.
+     */
+    private function setupParentLayout(enable:Boolean):void
+    {
+        var parent:* = null;
+        if ("parent" in target && target.parent)
+        {
+            parent = target.parent;
+        }
+        else if ("elementHost" in target && target.elementHost)
+        {
+            parent = target.elementHost;
+        }
+        if (parent)
+        {
+            if (parent is Container)
+                Container(parent).autoLayout = enable;
+            else if (parent is GroupBase)
+                GroupBase(parent).autoLayout = enable;
+        }
+    }
 }
 }


Play, pause, mute and unmute working

Play, pause, mute and unmute working

--- src/Player.as
+++ src/Player.as
@@ -7,6 +7,7 @@
   import flash.events.Event;
   import flash.events.NetStatusEvent;
   import flash.external.ExternalInterface;
+  import flash.media.SoundTransform;
   import flash.media.Video;
   import flash.net.NetConnection;
   import flash.net.NetStream;
@@ -14,11 +15,14 @@
   import flash.system.Security;
   import flash.text.TextField;

-  // TODO: Add external interface for play, pause, mute and unmute
   public class Player extends Sprite {

     private var posterUrl: String;
     private var videoUrl: String;
+    private var muted: Boolean;
+    private var autoPlay: Boolean;
+
+    private var videoPlaying: Boolean;

     private var poster: Loader;
     private var video: Video;
@@ -34,17 +38,46 @@
       Security.allowDomain("*");
       Security.allowInsecureDomain("*");

-      var field: TextField = new TextField();
-      field.text = ExternalInterface.available ? "Available" : "Unavailable";
-      addChild(field);
+      registerExternalMethods();

-      //posterUrl = loaderInfo.parameters['poster'];
+      posterUrl = loaderInfo.parameters.poster;
       videoUrl = loaderInfo.parameters.video;
+      muted = loaderInfo.parameters.muted == "true";
+      autoPlay = loaderInfo.parameters.autoPlay == "true";

-      //setBackgroundColor();
-      registerExternalMethods();
-      //if (posterUrl) loadPoster();
-      //loadVideo();
+      setBackgroundColor();
+
+      if (posterUrl) {
+        loadPoster();
+      }
+
+      loadVideo();
+    }
+
+    private function play(): void {
+      videoPlaying = true;
+      stream.resume();
+    }
+
+    private function pause(): void {
+      videoPlaying = false;
+      stream.pause();
+    }
+
+    private function isPaused(): Boolean {
+      return !videoPlaying;
+    }
+
+    private function mute(): void {
+      stream.soundTransform = new SoundTransform(0);
+    }
+
+    private function unmute(): void {
+      stream.soundTransform = new SoundTransform(1);
+    }
+
+    private function isMuted(): Boolean {
+      return stream.soundTransform.volume == 0;
     }

     private function setBackgroundColor(): void {
@@ -54,13 +87,12 @@
     }

     private function registerExternalMethods(): void {
-      ExternalInterface.addCallback("foo", function(): void {
-        var field: TextField = new TextField();
-        field.text = "BAR!";
-        field.y = 15;
-        addChild(field);
-      });
-
+      ExternalInterface.addCallback("play", play);
+      ExternalInterface.addCallback("pause", pause);
+      ExternalInterface.addCallback("paused", isPaused);
+      ExternalInterface.addCallback("mute", mute);
+      ExternalInterface.addCallback("unmute", unmute);
+      ExternalInterface.addCallback("muted", isMuted);
       ExternalInterface.call("DivineVideoPlayer.ready");
     }

@@ -69,6 +101,8 @@
       addChild(posterContainer);

       poster = new Loader();
+      poster.width = stage.stageWidth;
+      poster.height = stage.stageHeight;
       poster.contentLoaderInfo.addEventListener(Event.COMPLETE, function(): void {
         posterContainer.addChild(poster);
       });
@@ -96,10 +130,12 @@
       //posterContainer.visible = false;

       stream = new NetStream(connection);
+      stream.soundTransform = new SoundTransform(muted ? 0 : 1);
       stream.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
       video.attachNetStream(stream);

       stream.play(videoUrl);
+      if (!autoPlay) pause();
     }

   }


fixed bar chart missing color bug

fixed bar chart missing color bug

--- WeaveUISpark/src/weave/visualization/plotters/CompoundBarChartPlotter.as
+++ WeaveUISpark/src/weave/visualization/plotters/CompoundBarChartPlotter.as
@@ -457,7 +457,8 @@
 								if (_heightColumns.length == 1)
 									color = colorColumn.getValueFromKey(recordKey, Number) as Number;

-								graphics.beginFill(color, 1);
+								if (isFinite(color))
+									graphics.beginFill(color, 1);
 								lineStyle.beginLineStyle(recordKey, graphics);
 								if (tempBounds.getHeight() == 0)
 									graphics.lineStyle(0,0,0);


Sum change

Sum change


Transferred from the Adobe Open Source Subversion Repository

Revision: 19328
Author:   mhorn@adobe.com
Date:     2010-12-13T20:45:00.405533Z

Log Message:
-----------
ASDoc updates

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/ButtonSkinBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/MobileSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ActionBarSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/TextInputSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/NavigationAngledButtonSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ActionButtonSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/VScrollBarSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/VScrollBarThumbSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/TextSkinBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ButtonSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/TabbedViewNavigatorApplicationSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/HSliderDataTip.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/TextAreaSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/HSliderTrackSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/ActionBarButtonSkinBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/SelectableButtonSkinBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/CheckBoxSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/TabbedViewNavigatorSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/HSliderSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/HSliderThumbSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/RadioButtonSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/HScrollBarSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/HScrollBarThumbSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/NavigationButtonSkin.as</path>

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

--- frameworks/projects/mobiletheme/src/spark/skins/mobile/HScrollBarSkin.as
+++ frameworks/projects/mobiletheme/src/spark/skins/mobile/HScrollBarSkin.as
@@ -21,18 +21,18 @@

 public class HScrollBarSkin extends MobileSkin
 {
-	//--------------------------------------------------------------------------
-	//
-	//  Variables
-	//
-	//--------------------------------------------------------------------------
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
     public function HScrollBarSkin()
     {
         super();

         useChromeColor = true;

-		// Depending on density set our measured width and height
+        // Depending on density set our measured width and height
         switch (authorDensity)
         {
             case DeviceDensity.PPI_240:
@@ -58,81 +58,81 @@
     //  Variables
     //
     //--------------------------------------------------------------------------
-	/**
-	 *  @copy spark.skins.spark.ApplicationSkin#hostComponent
-	 */
+    /**
+     *  @copy spark.skins.spark.ApplicationSkin#hostComponent
+     */
     public var hostComponent:HScrollBar;

-
+
     //--------------------------------------------------------------------------
     //
     //  Skin parts
     //
     //--------------------------------------------------------------------------
-	/**
-	 *  HScrollbar track skin part
-	 *
-	 *  @langversion 3.0
-	 *  @playerversion Flash 10
-	 *  @playerversion AIR 2.5
-	 *  @productversion Flex 4.5
-	 */
+    /**
+     *  HScrollbar track skin part.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10
+     *  @playerversion AIR 2.5
+     *  @productversion Flex 4.5
+     */
     public var track:Button;

-	/**
-	 *  HScrollbar thumb skin part
-	 *
-	 *  @langversion 3.0
-	 *  @playerversion Flash 10
-	 *  @playerversion AIR 2.5
-	 *  @productversion Flex 4.5
-	 */
+    /**
+     *  HScrollbar thumb skin part.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10
+     *  @playerversion AIR 2.5
+     *  @productversion Flex 4.5
+     */
     public var thumb:Button;

-
+
     //--------------------------------------------------------------------------
     //
     //  Overridden methods
     //
     //--------------------------------------------------------------------------
-	/**
-	 *  @private
-	 */
+    /**
+     *  @private
+     */
     override protected function createChildren():void
     {
         // Create our skin parts if necessary: track and thumb.
-		if (!track)
-		{
-			// We don't want a visible track so we set the skin to MobileSkin
-	        track = new Button();
-	        track.setStyle("skinClass", spark.skins.mobile.supportClasses.MobileSkin);
-	        track.width = layoutMeasuredWidth;
-	        track.height = layoutMeasuredHeight;
-	        addChild(track);
-		}
+        if (!track)
+        {
+            // We don't want a visible track so we set the skin to MobileSkin
+            track = new Button();
+            track.setStyle("skinClass", spark.skins.mobile.supportClasses.MobileSkin);
+            track.width = layoutMeasuredWidth;
+            track.height = layoutMeasuredHeight;
+            addChild(track);
+        }

-		if (!thumb)
-		{
-	        thumb = new Button();
-	        thumb.setStyle("skinClass", spark.skins.mobile.HScrollBarThumbSkin);
-	        thumb.width = layoutMeasuredHeight;
-	        thumb.height = layoutMeasuredHeight;
-	        addChild(thumb);
-		}
+        if (!thumb)
+        {
+            thumb = new Button();
+            thumb.setStyle("skinClass", spark.skins.mobile.HScrollBarThumbSkin);
+            thumb.width = layoutMeasuredHeight;
+            thumb.height = layoutMeasuredHeight;
+            addChild(thumb);
+        }
     }

-	/**
-	 *  @private
-	 */
+    /**
+     *  @private
+     */
     override protected function measure():void
     {
         measuredWidth = layoutMeasuredWidth;
         measuredHeight = layoutMeasuredHeight;
     }

-	/**
-	 *  @private
-	 */
+    /**
+     *  @private
+     */
     override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void
     {
         setElementSize(track, unscaledWidth, unscaledHeight);


Transferred from the Adobe Open Source Subversion Repository

Revision: 17701
Author:   hmuller@adobe.com
Date:     2010-09-14T19:42:02.652272Z

Log Message:
-----------
Changed right padding from 10 to 5 in DefaultGridItemRenderer and UITextFieldGridItemRenderer.   Added the latter to spark-manifest.xml.

Fixed a horizontal scrolling performance problem introduced by SVN 17668.  Moved itemRenderer (IFactory) wrapping and caching from GridColumn to GridLayout/itemToRenderer().

QE notes: checkin tests pass, Mustella tests that fail due to the layout change have been excluded
Doc notes:
Bugs:
Reviewer: Kevin
Tests run: checkin, mustella cyclone
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/skins/spark/TextFieldGridItemRendererInclude.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/spark-manifest.xml</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GridColumn.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GridLayout.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/DataGrid.as</path>

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

--- frameworks/projects/spark/src/spark/components/gridClasses/GridColumn.as
+++ frameworks/projects/spark/src/spark/components/gridClasses/GridColumn.as
@@ -307,20 +307,19 @@
     //----------------------------------

     private var _itemRenderer:IFactory = null;
-    private var rendererClassFactory:GridItemRendererClassFactory = null;

     [Bindable("itemRendererChanged")]

     /**
      *  A factory for IGridItemRenderers used to render invidual grid cells.  If not specified,
-     *  the grid's defaultItemRenderer is return.
+     *  the grid's itemRenderer is returned.
      *
      *
The default item renderer just displays the value of its label property,
      *  which is based on the dataProvider item for the cell's row, and on the column's dataField
      *  property.  Custom item renderers that derive more values from the data item and include
      *  more complex visuals are easily created by subclassing GridItemRenderer.

      *
-     *  @default The value of the grid's defaultItemRenderer, or null.
+     *  @default The value of the grid's itemRenderer, or null.
      *
      *  @see #dataField
      *  @see GridItemRenderer
@@ -794,35 +793,6 @@
     }

     /**
-     *  @private
-     *  The static embeddedFonts property is initialized lazily.
-     */
-    private static var  _embeddedFontRegistryExists:Boolean = false;
-    private static var embeddedFontRegistryExistsInitialized:Boolean = false;
-
-    /**
-     *  @private
-     *  True if an embedded font registry singleton exists.
-     */
-    private static function get embeddedFontRegistryExists():Boolean
-    {
-        if (!embeddedFontRegistryExistsInitialized)
-        {
-            embeddedFontRegistryExistsInitialized = true;
-            try
-            {
-                _embeddedFontRegistryExists = Singleton.getInstance("mx.core::IEmbeddedFontRegistry") != null;
-            }
-            catch (e:Error)
-            {
-                _embeddedFontRegistryExists = false;
-            }
-        }
-
-        return _embeddedFontRegistryExists;
-    }
-
-    /**
      *  Convert the specified dataProvider item to a column-specific item renderer factory.
      *  By default this method calls the itemRendererFunction if it's
      *  non-null, otherwise it just returns the value of the column's itemRenderer
@@ -835,21 +805,7 @@
     public function itemToRenderer(item:Object):IFactory
     {
         const itemRendererFunction:Function = itemRendererFunction;
-        var factory:IFactory = (itemRendererFunction != null) ? itemRendererFunction(item, this) : itemRenderer;
-
-        // If this app might have embedded fonts then item renderers must be created with the Grid's
-        // module factory.  To enable that we wrap the real item renderer factory with
-        // a GridItemRendererClassFactory.
-
-        if (embeddedFontRegistryExists && (factory is ClassFactory))
-        {
-            if (!rendererClassFactory || (rendererClassFactory.factory != factory))
-                rendererClassFactory = new GridItemRendererClassFactory(grid, ClassFactory(factory));
-        }
-        else
-            rendererClassFactory = null;
-
-        return (rendererClassFactory) ? rendererClassFactory : factory;
+        return (itemRendererFunction != null) ? itemRendererFunction(item, this) : itemRenderer;
     }

     /**
@@ -875,50 +831,3 @@
 }
 }

-import flash.utils.getQualifiedClassName;
-
-import mx.core.ClassFactory;
-import mx.core.IFactory;
-import mx.core.IFlexModuleFactory;
-
-import spark.components.Grid;
-
-
-/**
- *  @private
- *  A wrapper class for item renderers that creates the renderer instance with the grid's
- *  module factory.
- *
- *  This is necessary for applications that use embedded fonts.   The module factory creates
- *  the renderer instance in the correct "font context" in the same way as ContextualClassFactory
- *  does.   More about this in the  ContextualClassFactory  ASDoc.
- */
-class GridItemRendererClassFactory extends ClassFactory
-{
-    public var grid:Grid;
-    public var factory:ClassFactory;
-
-    public function GridItemRendererClassFactory(grid:Grid, factory:ClassFactory)
-    {
-        super(factory.generator);
-        this.grid = grid;
-        this.factory = factory;
-    }
-
-    override public function newInstance():*
-    {
-        const factoryGenerator:Class = factory.generator;
-        const moduleFactory:IFlexModuleFactory = grid.moduleFactory;
-        const instance:Object =
-            (moduleFactory) ? moduleFactory.create(getQualifiedClassName(factoryGenerator)) : new factoryGenerator();
-
-        const factoryProperties:Object = factory.properties;
-        if (factoryProperties)
-        {
-            for (var p:String in factoryProperties)
-                instance[p] = factoryProperties[p];
-        }
-
-        return instance;
-    }
-}


Transferred from the Adobe Open Source Subversion Repository

Revision: 17070
Author:   cframpto@adobe.com
Date:     2010-07-27T15:16:53.362377Z

Log Message:
-----------
selectIndices(startRowIndex, endRowIndex) -> selectIndices(rowIndex, rowCount)
ensureIndexIsVisible -> ensureCellIsVisible

clean up layout.dataProviderCollectionReset to eliminate RTE on sort

dispatch the changing/change events for ctrl-a that I recently added

many small bug fixes and a few ASdoc corrections which are evident from the diffs

QE notes: API changes again
Doc notes:
Bugs: SDK-27116, SDK-27117, SDK-27111, SDK-27112, SDK-26926, SDK-26951
Reviewer: Hans
Tests run: none
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/Grid.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GridSelection.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GridLayout.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/DataGrid.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/GridContainerBase.as</path>

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

--- frameworks/projects/spark/src/spark/components/gridClasses/GridLayout.as
+++ frameworks/projects/spark/src/spark/components/gridClasses/GridLayout.as
@@ -922,6 +922,7 @@
     {
         for each (var renderer:IVisualElement in renderers)
             freeItemRenderer(renderer);
+        renderers.length = 0;
     }

     //--------------------------------------------------------------------------
@@ -1574,14 +1575,29 @@
      */
     private function dataProviderCollectionReset(event:CollectionEvent):Boolean
     {
-        visibleRowIndices.length = 0;
-        visibleColumnIndices.length = 0;
-        visibleItemRenderersBounds.setEmpty();
-        visibleGridBounds.setEmpty();
         freeGridElements(visibleRowBackgrounds);
         freeGridElements(visibleRowSeparators);
+        visibleRowIndices.length = 0;
+
+        freeGridElements(visibleColumnBackgrounds);
+        freeGridElements(visibleColumnSeparators);
+        visibleColumnIndices.length = 0;
+
         freeItemRenderers(visibleItemRenderers);
-
+
+        freeGridElements(visibleSelectionIndicators);
+        visibleRowSelectionIndices.length = 0;
+        visibleColumnSelectionIndices.length = 0;
+
+        freeGridElement(hoverIndicator)
+        hoverIndicator = null;
+
+        freeGridElement(caretIndicator);
+        caretIndicator = null;
+
+        visibleItemRenderersBounds.setEmpty();
+        visibleGridBounds.setEmpty();
+
         return true;
     }

@@ -1696,6 +1712,7 @@
     {
         for each (var elt:IVisualElement in elements)
             freeGridElement(elt);
+        elements.length = 0;
     }

     private function removeGridElement(element:IVisualElement):void


 - fixed wrong return type in FLVResource::bytesLoaded/bytesTotal

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

--- src/reprise/external/FLVResource.as
+++ src/reprise/external/FLVResource.as
@@ -23,12 +23,12 @@
 			initStream();
 		}

-		public override function bytesTotal():Number
+		public override function bytesTotal() : int
 		{
 			return m_stream.bytesTotal;
 		}

-		public override function bytesLoaded():Number
+		public override function bytesLoaded() : int
 		{
 			return m_stream.bytesLoaded;
 		}


- bugfix: FLVResource returned switched value for bytesLoaded and bytesTotal

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

--- src/reprise/external/FLVResource.as
+++ src/reprise/external/FLVResource.as
@@ -25,12 +25,12 @@

 		public override function bytesTotal():Number
 		{
-			return m_stream.bytesLoaded;
+			return m_stream.bytesTotal;
 		}

 		public override function bytesLoaded():Number
 		{
-			return m_stream.bytesTotal;
+			return m_stream.bytesLoaded;
 		}

 		public override function content():*


 - fixed wrong override statement in Mp3Resource (changed number to int)

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

--- src/reprise/external/MP3Resource.as
+++ src/reprise/external/MP3Resource.as
@@ -21,12 +21,12 @@
 			m_sound.addEventListener(Event.COMPLETE, sound_complete);
 		}

-		public override function bytesTotal():Number
+		public override function bytesTotal():int
 		{
 			return m_sound.bytesLoaded;
 		}

-		public override function bytesLoaded():Number
+		public override function bytesLoaded():int
 		{
 			return m_sound.bytesTotal;
 		}
@@ -35,8 +35,6 @@
 		{
 			return m_sound;
 		}
-
-

 		protected override function doLoad():void
 		{


Simpler reclaiming of RTMFPSocket buffer space.

--- RTMFPSocket.as
+++ RTMFPSocket.as
@@ -192,8 +192,7 @@
             buffer.readBytes(output, offset, length);
             if (buffer.bytesAvailable == 0) {
                 /* Reclaim memory space. */
-                buffer.position = 0;
-                buffer.length = 0;
+                buffer.clear();
             }
         }


added connectTheDots test code

added connectTheDots test code

Change-Id: Ie919cd2fe6b847e650b479feecb90742d42c27ed

--- WeaveUISpark/src/weave/visualization/plotters/ScatterPlotPlotter.as
+++ WeaveUISpark/src/weave/visualization/plotters/ScatterPlotPlotter.as
@@ -33,6 +33,7 @@
 	import weave.api.registerLinkableChild;
 	import weave.api.reportError;
 	import weave.api.setSessionState;
+	import weave.api.ui.IPlotTask;
 	import weave.api.ui.IPlotter;
 	import weave.compiler.StandardLib;
 	import weave.core.DynamicState;
@@ -128,12 +129,30 @@

 		public const fill:SolidFillStyle = newLinkableChild(this, SolidFillStyle);

+		override public function drawPlotAsyncIteration(task:IPlotTask):Number
+		{
+			// this template will draw one record per iteration
+			if (task.iteration == 0)
+			{
+				if (!task.asyncState)
+					task.asyncState = {};
+				if (!task.asyncState.prevPoint)
+					task.asyncState.prevPoint = new Point();
+				var p:Point = task.asyncState.prevPoint as Point;
+				p.x = p.y = NaN;
+			}
+			prevPoint = task.asyncState.prevPoint as Point;
+			return super.drawPlotAsyncIteration(task);
+		}
+
+		private var prevPoint:Point;
+		public var connectTheDots:Boolean = false;
+
 		/**
 		 * This function may be defined by a class that extends AbstractPlotter to use the basic template code in AbstractPlotter.drawPlot().
 		 */
 		override protected function addRecordGraphicsToTempShape(recordKey:IQualifiedKey, dataBounds:IBounds2D, screenBounds:IBounds2D, tempShape:Shape):void
 		{
-//			var hasPrevPoint:Boolean = (isFinite(tempPoint.x) && isFinite(tempPoint.y));
 			var graphics:Graphics = tempShape.graphics;
 			graphics.clear();

@@ -170,8 +189,12 @@
 				radius = defaultScreenRadius.value;
 			}

-//			if (hasPrevPoint)
-//				graphics.lineTo(tempPoint.x, tempPoint.y);
+			var hasPrevPoint:Boolean = connectTheDots && isFinite(prevPoint.x) && isFinite(prevPoint.y);
+			if (hasPrevPoint)
+			{
+				graphics.moveTo(prevPoint.x, prevPoint.y);
+				graphics.lineTo(tempPoint.x, tempPoint.y);
+			}
 			if (!isFinite(radius))
 			{
 				// handle undefined radius
@@ -204,9 +227,10 @@
 				}
 			}
 			graphics.endFill();
-//			graphics.moveTo(tempPoint.x, tempPoint.y);
-		}
-		private static const tempPoint:Point = new Point(); // reusable object
+
+			prevPoint.x = tempPoint.x;
+			prevPoint.y = tempPoint.y;
+		}
 	}
 }


Updated structure

Updated structure

Updated Player class to conform with Axis coding guidelines.

--- src/Player.as
+++ src/Player.as
@@ -1,5 +1,4 @@
 package {
-
   import com.axis.ClientEvent;
   import com.axis.IClient;
   import com.axis.audioclient.AxisTransmit;
@@ -19,12 +18,12 @@
   import flash.events.Event;
   import flash.events.MouseEvent;
   import flash.external.ExternalInterface;
+  import flash.media.Microphone;
   import flash.media.SoundMixer;
   import flash.media.SoundTransform;
   import flash.media.Video;
   import flash.net.NetStream;
   import flash.system.Security;
-  import flash.media.Microphone;

   [SWF(frameRate="60")]
   [SWF(backgroundColor="#efefef")]
@@ -43,6 +42,7 @@
     private var savedSpeakerVolume:Number;
     private var savedMicrophoneVolume:Number;
     private var fullscreenAllowed:Boolean = true;
+
     public function Player() {
       var self:Player = this;

@@ -72,17 +72,22 @@
       ExternalInterface.addCallback("startAudioTransmit", audioTransmitStartInterface);
       ExternalInterface.addCallback("stopAudioTransmit", audioTransmitStopInterface);

+      /* Set default speaker volume */
       this.speakerVolume(0.5);

+      /* Set default microphone volume */
       this.microphoneVolume(50);

+      /* Stage setup */
       this.stage.align = StageAlign.TOP_LEFT;
       this.stage.scaleMode = StageScaleMode.NO_SCALE;
       addEventListener(Event.ADDED_TO_STAGE, onStageAdded);

+      /* Video object setup */
       video = new Video(stage.stageWidth, stage.stageHeight);
       addChild(video);

+      /* Fullscreen support setup */
       this.stage.doubleClickEnabled = true;
       this.stage.addEventListener(MouseEvent.DOUBLE_CLICK, fullscreen);
       this.stage.addEventListener(Event.FULLSCREEN, function(event:Event):void {
@@ -90,15 +95,13 @@
       });
     }

-    public function fullscreen(event:MouseEvent):void
-    {
+    public function fullscreen(event:MouseEvent):void {
       if (this.fullscreenAllowed)
         this.stage.displayState = (StageDisplayState.NORMAL === stage.displayState) ?
         StageDisplayState.FULL_SCREEN : StageDisplayState.NORMAL;
     }

-    public function videoResize():void
-    {
+    public function videoResize():void {
       var stagewidth:uint = (StageDisplayState.NORMAL === stage.displayState) ?
         stage.stageWidth : stage.fullScreenWidth;
       var stageheight:uint = (StageDisplayState.NORMAL === stage.displayState) ?
@@ -119,8 +122,7 @@
       video.y = (stageheight - video.height) / 2;
     }

-    public function play(iurl:String = null):void
-    {
+    public function play(iurl:String = null):void {
       if (client) {
         urlParsed = url.parse(iurl);
         /* Stop the client, and 'onStopped' will start the new stream. */
@@ -132,8 +134,7 @@
       start();
     }

-    private function start():void
-    {
+    private function start():void {
       switch (urlParsed.protocol) {
       case 'rtsph':
         /* RTSP over HTTP */
@@ -166,20 +167,17 @@
       client.start();
     }

-    public function pause():void
-    {
+    public function pause():void {
       client.pause();
       this.callAPI('streamPaused');
     }

-    public function resume():void
-    {
+    public function resume():void {
       client.resume();
       this.callAPI('streamResumed');
     }

-    public function stop():void
-    {
+    public function stop():void {
       urlParsed = null;
       ns = null;
       client.stop();
@@ -253,21 +251,18 @@
       trace('stage added');
     }

-    public function onMetaData(item:Object):void
-    {
+    public function onMetaData(item:Object):void {
       this.meta = item;
       this.videoResize();
     }

-    public function onNetStreamCreated(ev:ClientEvent):void
-    {
+    public function onNetStreamCreated(ev:ClientEvent):void {
       this.ns = ev.data.ns;
       ev.data.ns.bufferTime = config.buffer;
       ev.data.ns.client = this;
     }

-    private function onStopped(ev:ClientEvent):void
-    {
+    private function onStopped(ev:ClientEvent):void {
       video.clear();
       client = null;
       if (urlParsed) {
@@ -275,8 +270,7 @@
       }
     }

-    private function callAPI(eventName:String, data:Object = null):void
-    {
+    private function callAPI(eventName:String, data:Object = null):void {
       if (!ExternalInterface.available) {
         trace("ExternalInterface is not available!");
         return;


Added streamPaused event

Added streamPaused event

--- src/Player.as
+++ src/Player.as
@@ -30,6 +30,7 @@

   public class Player extends Sprite {
     private static const EVENT_STREAM_STARTED:String  = "streamStarted";
+    private static const EVENT_STREAM_PAUSED:String  = "streamPaused";
     private static const EVENT_FULLSCREEN_ENTERED:String  = "fullscreenEntered";
     private static const EVENT_FULLSCREEN_EXITED:String  = "fullscreenExited";

@@ -212,7 +213,7 @@

     public function pause():void {
       client.pause();
-      this.callAPI('streamPaused');
+      this.callAPI(EVENT_STREAM_PAUSED);
       this.currentState = "paused";
     }


Transferred from the Adobe Open Source Subversion Repository

Revision: 3933
Author:   shodgson@adobe.com
Date:     2008-10-28T20:57:03.525449Z

Log Message:
-----------
Bug: LCDS-427 - Using streaming AMF channel with reliable destination both Producer and Consumer getting channel fault during transient disconnect.
QA: Yes
Doc: No
Checkintests: Pass

Details:
* Add handling for Client.Data.Underflow NetStatus events to AMFChannel (log warning rather than triggering channel disconnect)
* Fix in helper class for streaming channels to correctly reset internal state machine upon disconnect

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/channels/AMFChannel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/channels/StreamingConnectionHandler.as</path>

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

--- frameworks/projects/rpc/src/mx/messaging/channels/StreamingConnectionHandler.as
+++ frameworks/projects/rpc/src/mx/messaging/channels/StreamingConnectionHandler.as
@@ -220,6 +220,12 @@
      *  The server-assigned id for the streaming connection.
      */
     protected var streamId:String;
+
+    /**
+     *  @private
+     *  Optional token to append to request URLs; generally contains a session token.
+     */
+    private var _appendToURL:String;

     /**
      *  Storage for the hex-format chunk size value from the byte stream.
@@ -258,6 +264,8 @@
      */
     public function openStreamingConnection(appendToURL:String=null):void
     {
+        _appendToURL = appendToURL;
+
     	// Construct the streaming connection if needed.
         if (streamingConnection == null)
         {
@@ -275,8 +283,8 @@
         {
             var request:URLRequest = new URLRequest();
             var url:String = channel.endpoint;
-            if (appendToURL != null)
-                url += appendToURL;
+            if (_appendToURL != null)
+                url += _appendToURL;
             request.url = url + "?" + COMMAND_PARAM_NAME + "=" + OPEN_COMMAND + "&" + VERSION_PARAM_NAME + "=" + VERSION_1;
             request.method = URLRequestMethod.POST;
             var postParams:URLVariables = new URLVariables();
@@ -292,6 +300,8 @@
      */
     public function closeStreamingConnection():void
     {
+        resetParserState();
+
     	// First, close the existing connection.
         if (streamingConnection != null)
         {
@@ -344,7 +354,10 @@
     		if (!streamingConnectionCloser.connected)
     		{
     			var request:URLRequest = new URLRequest();
-    			request.url = channel.endpoint + "?" + COMMAND_PARAM_NAME + "=" + CLOSE_COMMAND + "&"
+    			var url:String = channel.endpoint;
+                if (_appendToURL != null)
+                    url += _appendToURL;
+    			request.url = url + "?" + COMMAND_PARAM_NAME + "=" + CLOSE_COMMAND + "&"
     			              + STREAM_ID_PARAM_NAME + "=" + streamId + "&" + VERSION_PARAM_NAME + "=" + VERSION_1;
     			request.method = URLRequestMethod.POST;
     			var postParams:URLVariables = new URLVariables();
@@ -401,6 +414,18 @@
             result += digit * powerOfSixteen;
         }
         return result;
+    }
+
+    /**
+     *  Helper method to reset parser to initial state.
+     */
+    private function resetParserState():void
+    {
+        state = INIT_STATE;
+        chunkBuffer = null;
+        hexChunkSize = null;
+        dataBytesToRead = -1;
+        dataOffset = 0;
     }

     /**


ShaderPart.min() and ShaderPart.max() are now variadic

--- src/aerys/minko/render/shader/part/ShaderPart.as
+++ src/aerys/minko/render/shader/part/ShaderPart.as
@@ -683,14 +683,26 @@
 			return new SFloat(new Instruction(Instruction.SAT, getNode(value)));
 		}

-		protected final function min(a : Object, b : Object) : SFloat
-		{
-			return new SFloat(new Instruction(Instruction.MIN, getNode(a), getNode(b)));
-		}
-
-		protected final function max(a : Object, b : Object) : SFloat
-		{
-			return new SFloat(new Instruction(Instruction.MAX, getNode(a), getNode(b)));
+		protected final function min(a : Object, b : Object, ...arguments) : SFloat
+		{
+			var min : Instruction = new Instruction(Instruction.MIN, getNode(a), getNode(b));
+			var numArguments : uint = arguments.length;
+
+			for (var i : uint = 0; i < numArguments; ++i)
+				min = new Instruction(Instruction.MIN, min, getNode(arguments[i]));
+
+			return new SFloat(min);
+		}
+
+		protected final function max(a : Object, b : Object, ...arguments) : SFloat
+		{
+			var max : Instruction = new Instruction(Instruction.MAX, getNode(a), getNode(b));
+			var numArguments : uint = arguments.length;
+
+			for (var i : uint = 0; i < numArguments; ++i)
+				max = new Instruction(Instruction.MAX, max, getNode(arguments[i]));
+
+			return new SFloat(max);
 		}

 		protected final function greaterEqual(a : Object, b : Object) : SFloat


Transferred from the Adobe Open Source Subversion Repository

Revision: 20845
Author:   mhorn@adobe.com
Date:     2011-03-14T15:29:23.391952Z

Log Message:
-----------
merge 20756,20790,20712,20805

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/charts/src/mx/charts/series/PlotSeries.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/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/styles/CSSStyleDeclaration.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/geom/Transform.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/utils/StringUtil.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/events/FlexEvent.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="dir" action="M">/private/flex/sdk/trunk</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@1284863 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/formatters/DateTimeFormatter.as
+++ frameworks/projects/spark/src/spark/formatters/DateTimeFormatter.as
@@ -988,7 +988,8 @@
     }

     /**
-     *  Lists all of the locale ID names supported by this class.
+     *  Lists all of the locale ID names supported by this class. This is a list of locales supported by
+     *  the operating system, not a list of locales that the ResourceManager has resources for.
      *
      *  @return A vector of strings containing all of the locale ID names
      *         supported by this class and operating system.


Gah, my bad: we've got to return the value from the friend function.
Of course, the flash documentation says that function.apply() returns
void, but luckily this is not the case. DO NOT TRUST THEIR DOCS, they are
riddled with errors.

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

--- src/as/com/threerings/ezgame/EZGameControl.as
+++ src/as/com/threerings/ezgame/EZGameControl.as
@@ -605,7 +605,7 @@
     {
         // var args
         args.unshift(name);
-        callEZCode.apply(this, args);
+        return callEZCode.apply(this, args);
     }

     /**


This is probably not such a good idea after all

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

--- src/as/com/threerings/flash/DisplayUtil.as
+++ src/as/com/threerings/flash/DisplayUtil.as
@@ -43,29 +43,21 @@
         container :DisplayObjectContainer, comp :Function = null) :void
     {
         var numChildren :int = container.numChildren;
-
-        // since it's likely this function will be called frequently on the same
-        // DisplayObjectContainer, keep the Array around so that we're not
-        // re-allocating memory more often than we need to
-        if (_sortDisplayChildrenArray.length != numChildren) {
-            _sortDisplayChildrenArray = new Array(numChildren);
-        }
-
+        // put all children in an array
+        var children :Array = new Array(numChildren);
         var ii :int;
         for (ii = 0; ii < numChildren; ii++) {
-            _sortDisplayChildrenArray[ii] = container.getChildAt(ii);
+            children[ii] = container.getChildAt(ii);
         }

         // stable sort the array
-        ArrayUtil.stableSort(_sortDisplayChildrenArray, comp);
+        ArrayUtil.stableSort(children, comp);

         // set their new indexes
         for (ii = 0; ii < numChildren; ii++) {
-            container.setChildIndex(DisplayObject(_sortDisplayChildrenArray[ii]), ii);
-        }
-    }
-
-    private static var _sortDisplayChildrenArray :Array = [];
+            container.setChildIndex(DisplayObject(children[ii]), ii);
+        }
+    }

     /**
      * Call the specified function for the display object and all descendants.