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

--- frameworks/projects/spark/src/spark/components/supportClasses/TrackBase.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/TrackBase.as
@@ -19,6 +19,8 @@
 import flash.geom.Point;

 import mx.events.SandboxMouseEvent;
+import mx.events.FlexEvent;
+import mx.events.ResizeEvent;

 import spark.components.Button;
 import spark.events.TrackBaseEvent;
@@ -203,7 +205,6 @@
     //
     //--------------------------------------------------------------------------

-    private var tempTrackSize:Number = NaN;
 	private var mouseDownTarget:DisplayObject;

     //--------------------------------------------------------------------------
@@ -411,22 +412,6 @@
     }

     /**
-     *  @private
-     */
-    override protected function updateDisplayList(unscaledWidth:Number,
-                                                  unscaledHeight:Number):void
-    {
-        super.updateDisplayList(unscaledWidth, unscaledHeight);
-
-        if (thumb)
-        {
-            thumbSize = calculateThumbSize();
-            sizeThumb(thumbSize);
-            positionThumb(valueToPosition(value));
-        }
-    }
-
-    /**
      *  @private
      */
     override protected function getCurrentSkinState():String
@@ -436,22 +421,26 @@

     /**
      *  @private
+     *  Warning: the goal of the listeners added here (and removed below) is to
+     *  give the TrackBase a change to fixup the thumb's size and position
+     *  after the skin's BasicLayout has run.   This particular implementation
+     *  is a hack and it begs a solution to the general problem of what we've
+     *  called "cooperative layout".   More about that here:
+     *  http://opensource.adobe.com/wiki/display/flexsdk/Cooperative+Subtree+Layout
      */
     override protected function partAdded(partName:String, instance:Object):void
     {
         if (instance == thumb)
         {
-            thumb.addEventListener(MouseEvent.MOUSE_DOWN,
-                                   thumb_mouseDownHandler);
+            thumb.addEventListener(MouseEvent.MOUSE_DOWN, thumb_mouseDownHandler);
+            thumb.addEventListener(ResizeEvent.RESIZE, thumb_resizeHandler);
+            thumb.addEventListener(FlexEvent.UPDATE_COMPLETE, thumb_updateCompleteHandler);
             thumb.stickyHighlighting = true;
         }
         else if (instance == track)
         {
-            track.addEventListener(MouseEvent.MOUSE_DOWN,
-                                   track_mouseDownHandler);
-            track.addEventListener("updateComplete",
-                                   track_updateCompleteHandler);
-
+            track.addEventListener(MouseEvent.MOUSE_DOWN, track_mouseDownHandler);
+            track.addEventListener(ResizeEvent.RESIZE, track_resizeHandler);
         }
     }

@@ -462,16 +451,14 @@
     {
         if (instance == thumb)
         {
-            thumb.removeEventListener(MouseEvent.MOUSE_DOWN,
-                                      thumb_mouseDownHandler);
+            thumb.removeEventListener(MouseEvent.MOUSE_DOWN, thumb_mouseDownHandler);
+            thumb.removeEventListener(ResizeEvent.RESIZE, thumb_resizeHandler);
+            thumb.removeEventListener(FlexEvent.UPDATE_COMPLETE, thumb_updateCompleteHandler);
         }
         else if (instance == track)
         {
-            track.removeEventListener(MouseEvent.MOUSE_DOWN,
-                                      track_mouseDownHandler);
-            track.removeEventListener("updateComplete",
-                                      track_updateCompleteHandler);
-            tempTrackSize = NaN;
+            track.removeEventListener(MouseEvent.MOUSE_DOWN, track_mouseDownHandler);
+            track.removeEventListener(ResizeEvent.RESIZE, track_resizeHandler);
         }
     }

@@ -662,24 +649,70 @@
     {
     	removeSystemHandlers(MouseEvent.MOUSE_WHEEL, system_mouseWheelHandler, stage_mouseWheelHandler);
     }
+
+    /**
+     *  @private
+     */
+    override protected function updateDisplayList(w:Number, h:Number):void
+    {
+        super.updateDisplayList(w, h);
+        completeTrackLayout();
+    }

     //--------------------------------------------------------------------------
     //
     // Event Handlers
     //
     //--------------------------------------------------------------------------
-
-    /**
-     *  @private
-     *  Force the component to set itself up correctly now that the
-     *  track is completely loaded.
-     */
-    protected function track_updateCompleteHandler(event:Event):void
+
+    /**
+     *  Set thumbSize to the value of calculateThumbSize()
+     *  and then size and position the thumb with sizeThumb() and
+     *  positionThumb.
+     *
+     *  We're assuming that the track's skin will layout the thumb at its default size
+     *  and position.
+     *
+     *  We complete the layout here, when either the track or thumb
+     *  has changed size, or when the track's display list is updated,
+     *  by recomputing the thumb's size and position.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10
+     *  @playerversion AIR 1.5
+     *  @productversion Flex 4
+     *
+     */
+    protected function completeTrackLayout():void
     {
         thumbSize = calculateThumbSize();
         sizeThumb(thumbSize);
         positionThumb(valueToPosition(value));
-        tempTrackSize = trackSize;
+    }
+
+    /**
+     *  @private
+     */
+    private function track_resizeHandler(event:Event):void
+    {
+        completeTrackLayout();
+    }
+
+    /**
+     *  @private
+     */
+    private function thumb_resizeHandler(event:Event):void
+    {
+        completeTrackLayout();
+    }
+
+    /**
+     *  @private
+     */
+    private function thumb_updateCompleteHandler(event:Event):void
+    {
+        completeTrackLayout();
+        thumb.removeEventListener(FlexEvent.UPDATE_COMPLETE, thumb_updateCompleteHandler);
     }

     /**


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

 package mx.managers
 {


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

--- frameworks/projects/spark/src/spark/accessibility/SliderBaseAccImpl.as
+++ frameworks/projects/spark/src/spark/accessibility/SliderBaseAccImpl.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.accessibility
 {


added option for invisible polygon border thickness

--- WeaveCore/src/weave/core/UIUtils.as
+++ WeaveCore/src/weave/core/UIUtils.as
@@ -116,13 +116,14 @@
 		 * @param sprite The component.
 		 * @param coords [x0,y0, x1,y1, ...]
 		 * @param normalizedCoords true for normalized coordinates (x and y values will be multiplied by sprite.width and sprite.height)
+		 * @param borderThickness The thickness of the polygon border in pixels.
 		 */
-		public static function drawInvisiblePolygon(sprite:Sprite, coords:Array, normalizedCoords:Boolean):void
+		public static function drawInvisiblePolygon(sprite:Sprite, coords:Array, normalizedCoords:Boolean, borderThickness:Number = 0):void
 		{
 			var g:Graphics = sprite.graphics;
 			g.moveTo(coords[0], coords[1]);
 			g.beginFill(0xFF0000, debug ? 0.5 : 0);
-			g.lineStyle(0,0,0);
+			g.lineStyle(borderThickness, 0xFF0000, debug ? 0.5 : 0);
 			while (coords.length)
 			{
 				if (normalizedCoords)


Transferred from the Adobe Open Source Subversion Repository

Revision: 4724
Author:   rfrishbe@adobe.com
Date:     2009-01-29T02:13:02.210369Z

Log Message:
-----------
Bunch of small changes:

build scripts..just minor fixes and making it player 10

FxComponent - required parts must be present--not just defined

FxContainer - removing some dead code around IUIComponent since everything should be an IVisualElement now

Group - move around logic for removing a previously parented object.  This helps deal with graphic elements with shared display objects

GraphicElement - need to handle display object getting changed as well

ArrayList/ListCollectionView - add addAll() and addAllAt()

AdvancedLayoutFeatures - remove Vector import (now that build scripts are fixed, it works fine)

QE Notes: Write tests for addAll() and allAllAt(), check that required parts are required in the first state
Doc Notes: None
Bugs: SDK-18536, SDK-18745, SDK-18709, SDK-18189, SDK-18537
Reviewer: Evtim
tests: checkintests, mustella DataGroup, List, Group, FxContainer, FxDataContainer

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/utilities/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/ListCollectionView.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flash-integration/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/FxComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/Group.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/ArrayList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxContainer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/graphics/graphicsClasses/GraphicElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/AdvancedLayoutFeatures.as</path>

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

--- frameworks/projects/spark/src/spark/components/supportClasses/SkinnableComponent.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/SkinnableComponent.as
@@ -405,7 +405,7 @@

                 if (part.required)
                 {
-                    if (!(part.id in skin))
+                    if (!(part.id in skin) || skin[part.id] == null)
                         throw(new Error("Required skin part \"" + part.id + "\" cannot be found."));
                 }


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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


393 Slight change to drawing dashed lines. Sundry documentation in GraphicsShapes

--- raw/src/org/yellcorp/lib/display/GraphicsShapes.as
+++ raw/src/org/yellcorp/lib/display/GraphicsShapes.as
@@ -3,8 +3,25 @@
 import flash.display.Graphics;

+/**
+ * Functions for drawing common shapes on to flash.display.Graphics
+ * instances.
+ */
 public class GraphicsShapes
 {
+    /**
+     * Draws a dashed straight line.
+     *
+     * @param target The Graphics instance to draw into.
+     * @param fromX  The x coordinate of the start of the line.
+     * @param fromY  The y coordinate of the start of the line.
+     * @param toX    The x coordinate of the end of the line.
+     * @param toY    The y coordinate of the end of the line.
+     * @param dashIntervals
+     * An array of segment lengths.  The first number is the length of the
+     * first dash.  Each number after that alternates between gap and dash,
+     * then wraps around.
+     */
     public static function
     drawDashLine(target:Graphics, fromX:Number, fromY:Number,
                  toX:Number, toY:Number, dashIntervals:Array):void
@@ -17,6 +34,7 @@
         var sumDistance:Number = 0;

         var dashIndex:int = 0;
+        var isLineSegment:Boolean = true;

         if (!dashIntervals || dashIntervals.length < 2)
         {
@@ -45,7 +63,7 @@
                 currentX = toX;
                 currentY = toY;
             }
-            if (dashIndex & 1)
+            if (isLineSegment)
             {
                 target.moveTo(currentX, currentY);
             }
@@ -54,6 +72,7 @@
                 target.lineTo(currentX, currentY);
             }
             dashIndex++;
+            isLineSegment = !isLineSegment;
             if (dashIndex >= dashIntervals.length)
             {
                 dashIndex = 0;
@@ -61,8 +80,21 @@
         }
     }

-    public static function
-    drawPlus(target:Graphics, centreX:Number, centreY:Number,
+    /**
+     * Draws a plus symbol.
+     *
+     * @param target   The Graphics instance to draw into.
+     * @param centerX  The x coordinate of the center of the plus.
+     * @param centerY  The y coordinate of the center of the plus.
+     * @param halfWidth   The half-width of the plus.  The plus will have
+     *                    a width double this value.
+     * @param halfHeight  The half-height of the plus.  The plus will have
+     *                    a width double this value.  If omitted or
+     *                    NaN, will use the same value as
+     *                    halfWidth.
+     */
+    public static function
+    drawPlus(target:Graphics, centerX:Number, centerY:Number,
              halfWidth:Number, halfHeight:Number = Number.NaN):void
     {
         if (isNaN(halfHeight))
@@ -70,12 +102,25 @@
             halfHeight = halfWidth;
         }

-        target.moveTo(centreX - halfWidth, centreY);
-        target.lineTo(centreX + halfWidth, centreY);
-        target.moveTo(centreX, centreY - halfHeight);
-        target.lineTo(centreX, centreY + halfHeight);
-    }
-
+        target.moveTo(centerX - halfWidth, centerY);
+        target.lineTo(centerX + halfWidth, centerY);
+        target.moveTo(centerX, centerY - halfHeight);
+        target.lineTo(centerX, centerY + halfHeight);
+    }
+
+    /**
+     * Draws an X symbol.
+     *
+     * @param target   The Graphics instance to draw into.
+     * @param centerX  The x coordinate of the center of the cross.
+     * @param centerY  The y coordinate of the center of the cross.
+     * @param halfWidth   The half-width of the cross.  The cross will have
+     *                    a width double this value.
+     * @param halfHeight  The half-height of the cross.  The cross will have
+     *                    a width double this value.  If omitted or
+     *                    NaN, will use the same value as
+     *                    halfWidth.
+     */
     public static function
     drawCross(target:Graphics, centreX:Number, centreY:Number,
               halfWidth:Number, halfHeight:Number = Number.NaN):void
@@ -91,6 +136,20 @@
         target.lineTo(centreX - halfWidth, centreY + halfHeight);
     }

+    /**
+     * Draws an arc of a circle.
+     *
+     * @param target   The Graphics instance to draw into.
+     * @param centerX  The x coordinate of the center of the circle.
+     * @param centerY  The y coordinate of the center of the circle.
+     * @param radius   The radius of the circle.
+     * @param startAngle  The angle at the start of the arc.
+     * @param endAngle    The angle at the end of the arc.
+     * @param drawRadius  If true, connects the ends of the
+     *                    arc to the center of the circle, creating a wedge
+     *                    shape.
+     * @param steps  The number of quadratic curves to use when drawing.
+     */
     public static function
     drawArc(target:Graphics, centreX:Number, centreY:Number,
             radius:Number, startAngle:Number, endAngle:Number,
@@ -138,6 +197,16 @@
         }
     }

+    /**
+     * Draws a regular polygon.
+     *
+     * @param target   The Graphics instance to draw into.
+     * @param centerX  The x coordinate of the center of the polygon.
+     * @param centerY  The y coordinate of the center of the polygon.
+     * @param radius   The distance from the center to each vertex.
+     * @param sides    The number of sides.
+     * @param rotate   A rotation offset to apply to all vertices.
+     */
     public static function
     drawPolygon(target:Graphics,
                 centreX:Number, centreY:Number,
@@ -160,6 +229,21 @@
         }
     }

+    /**
+     * Draws a star by connecting the points of two concentric regular
+     * polygons.
+     *
+     * @param target   The Graphics instance to draw into.
+     * @param centerX  The x coordinate of the center of the star.
+     * @param centerY  The y coordinate of the center of the star.
+     * @param radius1  The radius of the first guide polygon.
+     * @param radius2  The radius of the second guide polygon.
+     * @param points   The number of outer points of the star.
+     * @param rotate1  The rotational offset of the first guide polygon.
+     * @param rotate2  The rotational offset of the second guide polygon. If
+     *                 omitted or NaN, uses half the angle
+     *                 between two outer points.
+     */
     public static function
     drawPolyStar(target:Graphics,
                  centreX:Number, centreY:Number,
@@ -192,6 +276,23 @@
         }
     }

+    /**
+     * Draws an arrow.
+     *
+     * @param target The Graphics instance to draw into.
+     * @param fromX  The x coordinate of the origin of the arrow.
+     * @param fromY  The y coordinate of the origin of the arrow.
+     * @param toX    The x coordinate of the tip of the arrowhead.
+     * @param toY    The y coordinate of the tip of the arrowhead.
+     * @param headLengthFactor
+     *     The length of the arrowhead, expressed as a factor of the
+     *     arrow's length.
+     * @param headHalfWidthFactor
+     *     The perpendicular distance from the line to a trailing point of
+     *     the arrowhead, expressed as a factor of the arrow's length.
+     * @param closeHead  If true, draws a line between the
+     *               trailing points of the arrowhead.
+     */
     public static function
     drawArrow(target:Graphics,
               fromX:Number, fromY:Number,


Change properties' values.

Change properties' values.

--- dolly-framework/src/test/resources/dolly/data/PropertyLevelCopyableCloneableClass.as
+++ dolly-framework/src/test/resources/dolly/data/PropertyLevelCopyableCloneableClass.as
@@ -4,18 +4,14 @@

 	[Copyable]
 	[Cloneable]
-	public static var staticProperty1:String;
+	public static var staticProperty1:String = "Value of first-level static property.";

 	[Copyable]
 	[Cloneable]
-	private var _writableField1:String;
-
-	[Copyable]
-	[Cloneable]
-	private var _readOnlyField1:String = "read-only field value";
+	private var _writableField1:String = "Value of first-level writable field.";

 	[Cloneable]
-	public var property1:String;
+	public var property1:String = "Value of first-level public property.";

 	public function PropertyLevelCopyableCloneableClass() {
 	}
@@ -33,7 +29,7 @@
 	[Copyable]
 	[Cloneable]
 	public function get readOnlyField1():String {
-		return _readOnlyField1;
+		return "Value of first-level read-only field.";
 	}
 }
 }


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

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

 package mx.collections.errors
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 6129
Author:   aharui@adobe.com
Date:     2009-04-10T15:29:30.622891Z

Log Message:
-----------
TLFDataGridItemRenderer and defaultDataGridItemRenderer style

QE Notes: None
Doc Notes: Yes
Bugs:
Reviewer: gordon
tests: checkintests

Modified Paths:
--------------
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework_textLayout/src/mx/controls/dataGridClasses/TLFDataGridItemRenderer.as</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/framework_textLayout/src/mx/controls/dataGridClasses</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DataGrid.as</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/framework_textLayout/src/mx/controls</path>

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

--- frameworks/projects/spark/src/mx/controls/dataGridClasses/FTEDataGridItemRenderer.as
+++ frameworks/projects/spark/src/mx/controls/dataGridClasses/FTEDataGridItemRenderer.as
@@ -0,0 +1,761 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2005-2007 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.controls.dataGridClasses
+{
+
+import flash.display.DisplayObject;
+import flash.geom.Point;
+import flash.geom.Rectangle;
+import flash.utils.getQualifiedSuperclassName;
+import flash.utils.getDefinitionByName;
+import flash.utils.getQualifiedClassName;
+import mx.controls.DataGrid;
+import mx.controls.listClasses.BaseListData;
+import mx.controls.listClasses.IDropInListItemRenderer;
+import mx.controls.listClasses.IListItemRenderer;
+import mx.core.IDataRenderer;
+import mx.core.IFlexDisplayObject;
+import mx.core.IToolTip;
+import mx.core.UIComponent;
+import mx.core.UIComponentGlobals;
+import mx.core.UITLFTextField;
+import mx.core.mx_internal;
+import mx.events.FlexEvent;
+import mx.events.InterManagerRequest;
+import mx.events.ToolTipEvent;
+import mx.managers.ILayoutManagerClient;
+import mx.managers.ISystemManager;
+import mx.styles.CSSStyleDeclaration;
+import mx.styles.IStyleClient;
+import mx.styles.StyleManager;
+import mx.styles.StyleProtoChain;
+
+use namespace mx_internal;
+
+/**
+ *  Dispatched when the data property changes.
+ *
+ *
When you use a component as an item renderer,
+ *  the data property contains the data to display.
+ *  You can listen for this event and update the component
+ *  when the data property changes.

+ *
+ *  @eventType mx.events.FlexEvent.DATA_CHANGE
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Event(name="dataChange", type="mx.events.FlexEvent")]
+
+/**
+ *  The DataGridItemRenderer class defines the default item renderer for a DataGrid control.
+ *  By default, the item renderer
+ *  draws the text associated with each item in the grid.
+ *
+ *
You can override the default item renderer by creating a custom item renderer.

+ *
+ *  @see mx.controls.DataGrid
+ *  @see mx.core.IDataRenderer
+ *  @see mx.controls.listClasses.IDropInListItemRenderer
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class TLFDataGridItemRenderer extends UITLFTextField
+                                  implements IDataRenderer,
+                                  IDropInListItemRenderer, ILayoutManagerClient,
+                                  IListItemRenderer, IStyleClient
+{
+    include "../../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function TLFDataGridItemRenderer()
+    {
+        super();
+
+        tabEnabled = false;
+        mouseWheelEnabled = false;
+
+        ignorePadding = false;
+
+        addEventListener(ToolTipEvent.TOOL_TIP_SHOW, toolTipShowHandler);
+
+        inheritingStyles = nonInheritingStyles =
+            StyleProtoChain.STYLE_UNINITIALIZED;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    private var invalidatePropertiesFlag:Boolean = false;
+
+    /**
+     *  @private
+     */
+    private var invalidateSizeFlag:Boolean = false;
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden properties: UIComponent
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  nestLevel
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    override public function set nestLevel(value:int):void
+    {
+        super.nestLevel = value;
+
+        UIComponentGlobals.layoutManager.invalidateProperties(this);
+        invalidatePropertiesFlag = true;
+
+        UIComponentGlobals.layoutManager.invalidateSize(this);
+        invalidateSizeFlag = true;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  data
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    private var _data:Object;
+
+    [Bindable("dataChange")]
+
+    /**
+     *  The implementation of the data property as
+     *  defined by the IDataRenderer interface.
+     *
+     *  The value is ignored.  Only the listData property is used.
+     *  @see mx.core.IDataRenderer
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get data():Object
+    {
+        return _data;
+    }
+
+    /**
+     *  @private
+     */
+    public function set data(value:Object):void
+    {
+        _data = value;
+
+        dispatchEvent(new FlexEvent(FlexEvent.DATA_CHANGE));
+    }
+
+    //----------------------------------
+    //  listData
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    private var _listData:DataGridListData;
+
+    [Bindable("dataChange")]
+
+    /**
+     *  The implementation of the listData property as
+     *  defined by the IDropInListItemRenderer interface.
+     *  The text of the renderer is set to the label
+     *  property of the listData.
+     *
+     *  @see mx.controls.listClasses.IDropInListItemRenderer
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get listData():BaseListData
+    {
+        return _listData;
+    }
+
+    /**
+     *  @private
+     */
+    public function set listData(value:BaseListData):void
+    {
+        _listData = DataGridListData(value);
+        if (nestLevel && !invalidatePropertiesFlag)
+        {
+            UIComponentGlobals.layoutManager.invalidateProperties(this);
+            invalidatePropertiesFlag = true;
+            UIComponentGlobals.layoutManager.invalidateSize(this);
+            invalidateSizeFlag = true;
+        }
+    }
+
+    //----------------------------------
+    //  styleDeclaration
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the styleDeclaration property.
+     */
+    private var _styleDeclaration:CSSStyleDeclaration;
+
+    /**
+     *  Storage for the inline inheriting styles on this object.
+     *  This CSSStyleDeclaration is created the first time that setStyle()
+     *  is called on this component to set an inheriting style.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get styleDeclaration():CSSStyleDeclaration
+    {
+        return _styleDeclaration;
+    }
+
+    /**
+     *  @private
+     */
+    public function set styleDeclaration(value:CSSStyleDeclaration):void
+    {
+        _styleDeclaration = value;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UITextField
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    override public function initialize():void
+    {
+        regenerateStyleCache(false)
+    }
+
+    /**
+     *  @private
+     */
+    override public function validateNow():void
+    {
+        if (data && parent)
+        {
+            var newColor:Number;
+
+            if (DataGridBase(_listData.owner).isItemHighlighted(_listData.uid))
+            {
+                newColor = getStyle("textRollOverColor");
+            }
+            else if (DataGridBase(_listData.owner).isItemSelected(_listData.uid))
+            {
+                newColor = getStyle("textSelectedColor");
+            }
+            else
+            {
+                newColor = getStyle("color");
+            }
+
+            if (newColor != explicitColor)
+            {
+                styleChangedFlag = true;
+                explicitColor = newColor;
+                invalidateDisplayList();
+            }
+        }
+
+        super.validateNow();
+    }
+
+    /**
+     *  @copy mx.core.UIComponent#getStyle()
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function getStyle(styleProp:String):*
+    {
+        return (StyleManager.inheritingStyles[styleProp]) ?
+            inheritingStyles[styleProp] : nonInheritingStyles[styleProp];
+    }
+
+    /**
+     *  @copy mx.core.UIComponent#setStyle()
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function setStyle(styleProp:String, newValue:*):void
+    {
+        if (styleProp == "styleName")
+        {
+            // Let the setter handle this one, see UIComponent.
+            styleName = newValue;
+
+            // Short circuit, because styleName isn't really a style.
+            return;
+        }
+
+        /*
+        if (styleProp == "themeColor")
+        {
+            // setThemeColor handles the side effects.
+            setThemeColor(newValue);
+
+            // Do not short circuit, because themeColor is a style.
+            // It just has side effects, too.
+        }
+        */
+
+        // If this UIComponent didn't previously have any inline styles,
+        // then regenerate the UIComponent's proto chain (and the proto chains
+        // of this UIComponent's descendants).
+        var isInheritingStyle:Boolean =
+            StyleManager.isInheritingStyle(styleProp);
+        var isProtoChainInitialized:Boolean =
+            inheritingStyles != StyleProtoChain.STYLE_UNINITIALIZED;
+        if (isInheritingStyle)
+        {
+            if (getStyle(styleProp) == newValue && isProtoChainInitialized)
+                return;
+
+            if (!styleDeclaration)
+            {
+                styleDeclaration = new CSSStyleDeclaration();
+                styleDeclaration.mx_internal::setStyle(styleProp, newValue);
+
+                // If inheritingStyles is undefined, then this object is being
+                // initialized and we haven't yet generated the proto chain.  To
+                // avoid redundant work, don't bother to create the proto chain here.
+                if (isProtoChainInitialized)
+                    regenerateStyleCache(true);
+            }
+            else
+            {
+                styleDeclaration.mx_internal::setStyle(styleProp, newValue);
+            }
+        }
+        else
+        {
+            if (getStyle(styleProp) == newValue && isProtoChainInitialized)
+                return;
+
+            if (!styleDeclaration)
+            {
+                styleDeclaration = new CSSStyleDeclaration();
+                styleDeclaration.mx_internal::setStyle(styleProp, newValue);
+
+                // If nonInheritingStyles is undefined, then this object is being
+                // initialized and we haven't yet generated the proto chain.  To
+                // avoid redundant work, don't bother to create the proto chain here.
+                if (isProtoChainInitialized)
+                    regenerateStyleCache(false);
+            }
+            else
+            {
+                styleDeclaration.mx_internal::setStyle(styleProp, newValue);
+            }
+        }
+
+        if (isProtoChainInitialized)
+        {
+            styleChanged(styleProp);
+            notifyStyleChangeInChildren(styleProp, isInheritingStyle);
+        }
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Methods
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  If Flex calls the LayoutManager.invalidateProperties()
+     *  method on this ILayoutManagerClient, then
+     *  this function is called when it's time to commit property values.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function validateProperties():void
+    {
+        invalidatePropertiesFlag = false;
+        if (_listData)
+        {
+            var dg:DataGrid = DataGrid(_listData.owner);
+
+            var column:DataGridColumn =
+                dg.columns[_listData.columnIndex];
+
+            text = _listData.label;
+
+            if (_data is DataGridColumn)
+                wordWrap = dg.columnHeaderWordWrap(column);
+            else
+                wordWrap = dg.columnWordWrap(column);
+
+            if (DataGrid(_listData.owner).variableRowHeight)
+                multiline = true;
+
+            var dataTips:Boolean = dg.showDataTips;
+            if (column.showDataTips == true)
+                dataTips = true;
+            if (column.showDataTips == false)
+                dataTips = false;
+            if (dataTips)
+            {
+                if (!(_data is DataGridColumn) && (textWidth > width
+                    || column.dataTipFunction || column.dataTipField
+                    || dg.dataTipFunction || dg.dataTipField))
+                {
+                    toolTip = column.itemToDataTip(_data);
+                }
+                else
+                {
+                    toolTip = null;
+                }
+            }
+            else
+            {
+                toolTip = null;
+            }
+        }
+        else
+        {
+            text = " ";
+            toolTip = null;
+        }
+    }
+
+    /**
+     *  If Flex calls the LayoutManager.invalidateSize()
+     *  method on this ILayoutManagerClient, then
+     *  this function is called when it's time to do measurements.
+     *
+     *  @param recursive If true, call this method
+     *  on the object's children.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function validateSize(recursive:Boolean = false):void
+    {
+        invalidateSizeFlag = false;
+        validateNow();
+    }
+
+    /**
+     *  If Flex calls LayoutManager.invalidateDisplayList()
+     *  method on this ILayoutManagerClient, then
+     *  this function is called when it's time to update the display list.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function validateDisplayList():void
+    {
+        validateNow();
+    }
+
+    /**
+     *  @copy mx.core.UIComponent#clearStyle()
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function clearStyle(styleProp:String):void
+    {
+        setStyle(styleProp, undefined);
+    }
+
+    /**
+     *  @inheritDoc
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function notifyStyleChangeInChildren(
+                        styleProp:String, recursive:Boolean):void
+    {
+    }
+
+    /**
+     *  Sets up the inheritingStyles
+     *  and nonInheritingStyles objects
+     *  and their proto chains so that the getStyle() method can work.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function initProtoChain():void
+    {
+        styleChangedFlag = true;
+
+        var classSelectors:Array = [];
+
+        if (styleName)
+        {
+            if (styleName is CSSStyleDeclaration)
+            {
+                // Get the style sheet referenced by the styleName property
+                classSelectors.push(CSSStyleDeclaration(styleName));
+            }
+            else if (styleName is IFlexDisplayObject)
+            {
+                // If the styleName property is a UIComponent, then there's a
+                // special search path for that case.
+                StyleProtoChain.initProtoChainForUIComponentStyleName(this);
+                return;
+            }
+            else if (styleName is String)
+            {
+                // Get the style sheet referenced by the styleName property
+                var styleNames:Array = styleName.split(/\s+/);
+                for (var c:int=0; c < styleNames.length; c++)
+                {
+                    if (styleNames[c].length) {
+                        classSelectors.push(StyleManager.getStyleDeclaration("." +
+                            styleNames[c]));
+                    }
+                }
+            }
+        }
+
+        // To build the proto chain, we start at the end and work forward.
+        // Referring to the list at the top of this function, we'll start by
+        // getting the tail of the proto chain, which is:
+        //  - for non-inheriting styles, the global style sheet
+        //  - for inheriting styles, my parent's style object
+        var nonInheritChain:Object = StyleManager.stylesRoot;
+
+        var p:IStyleClient = parent as IStyleClient;
+        if (p)
+        {
+            var inheritChain:Object = p.inheritingStyles;
+            if (inheritChain == StyleProtoChain.STYLE_UNINITIALIZED)
+                inheritChain = nonInheritChain;
+        }
+        else
+        {
+            inheritChain = StyleManager.stylesRoot;
+        }
+
+        // Working backwards up the list, the next element in the
+        // search path is the type selector
+        var typeSelectors:Array = getClassStyleDeclarations();
+        var n:int = typeSelectors.length;
+        for (var i:int = 0; i < n; i++)
+        {
+            var typeSelector:CSSStyleDeclaration = typeSelectors[i];
+            inheritChain = typeSelector.addStyleToProtoChain(inheritChain, this);
+            nonInheritChain = typeSelector.addStyleToProtoChain(nonInheritChain, this);
+        }
+
+        // Next are the class selectors
+        for (i = 0; i < classSelectors.length; i++)
+        {
+            var classSelector:CSSStyleDeclaration = classSelectors[i];
+            if (classSelector)
+            {
+                inheritChain = classSelector.addStyleToProtoChain(inheritChain, this);
+                nonInheritChain = classSelector.addStyleToProtoChain(nonInheritChain, this);
+            }
+        }
+
+
+        // Finally, we'll add the in-line styles
+        // to the head of the proto chain.
+        inheritingStyles = styleDeclaration ?
+                           styleDeclaration.addStyleToProtoChain(inheritChain, this) :
+                           inheritChain;
+
+        nonInheritingStyles = styleDeclaration ?
+                              styleDeclaration.addStyleToProtoChain(nonInheritChain, this) :
+                              nonInheritChain;
+    }
+
+    /**
+     *  @inheritDoc
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function regenerateStyleCache(recursive:Boolean):void
+    {
+        initProtoChain();
+    }
+
+    /**
+     *  @inheritDoc
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function registerEffects(effects:Array /* of String */):void
+    {
+    }
+
+    /**
+     *  @inheritDoc
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function getClassStyleDeclarations():Array
+    {
+        var className:String = getQualifiedClassName(this)
+        className = className.replace("::", ".");
+
+        var decls:Array = [];
+
+        while (className != null &&
+               className != "mx.core.UIComponent" &&
+               className != "mx.core.UITLFTextField")
+        {
+            var s:CSSStyleDeclaration =
+                StyleManager.getStyleDeclaration(className);
+
+            if (s)
+            {
+                decls.unshift(s);
+            }
+
+            try
+            {
+                className = getQualifiedSuperclassName(getDefinitionByName(className));
+                className = className.replace("::", ".");
+            }
+            catch(e:ReferenceError)
+            {
+                className = null;
+            }
+        }
+
+        return decls;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Event handlers
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  The event handler to position the tooltip.
+     *
+     *  @param event The event object.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    protected function toolTipShowHandler(event:ToolTipEvent):void
+    {
+        var toolTip:IToolTip = event.toolTip;
+
+        // Calculate global position of label.
+        var sm:ISystemManager = systemManager.topLevelSystemManager;
+        var sbRoot:DisplayObject = sm.getSandboxRoot();
+        var screen:Rectangle;
+        var pt:Point = new Point(0, 0);
+        pt = localToGlobal(pt);
+        pt = sbRoot.globalToLocal(pt);
+
+        toolTip.move(pt.x, pt.y + (height - toolTip.height) / 2);
+
+        if (sm != sbRoot)
+        {
+            var request:InterManagerRequest = new InterManagerRequest(InterManagerRequest.SYSTEM_MANAGER_REQUEST,
+                                    false, false,
+                                    "getVisibleApplicationRect");
+            sbRoot.dispatchEvent(request);
+            screen = Rectangle(request.value);
+        }
+        else
+            screen = sm.getVisibleApplicationRect();
+
+        var screenRight:Number = screen.x + screen.width;
+        pt.x = toolTip.x;
+        pt.y = toolTip.y;
+        pt = sbRoot.localToGlobal(pt);
+        if (pt.x + toolTip.width > screenRight)
+            toolTip.move(toolTip.x - (pt.x + toolTip.width - screenRight), toolTip.y);
+    }
+}
+
+}


make backtrace function actually work

make backtrace function actually work

--- vivified/core/vivi_initialize.as
+++ vivified/core/vivi_initialize.as
@@ -101,11 +101,12 @@
 Commands.where = function () {
   var frame = Player.frame;
   if (frame == undefined) {
-    print ("---");
+    Commands.print ("---");
     return;
   }
+  var i = 0;
   while (frame) {
-    print (frame);
+    Commands.print (i++ + ": " + frame);
     frame = frame.next;
   }
 };


updated documentation

updated documentation

--- WeaveUISpark/src/weave/utils/LegendUtils.as
+++ WeaveUISpark/src/weave/utils/LegendUtils.as
@@ -72,20 +72,20 @@
 		 * @param destination The bitmap on which to render the text.
 		 * @param text The text to draw on the bitmap.
 		 * @param itemScreenBounds The screen bounds of the item.
-		 * @param iconGap The gap between the icon and the text.
+		 * @param xOffset The label X offset value.
 		 * @param clipRectangle A rectangle used for clipping, if desired. This is typically the bounds of the
 		 * screen during a drawPlot or drawBackground call.
 		 */
-		public static function renderLegendItemText(destination:BitmapData, text:String, itemScreenBounds:IBounds2D, iconGap:int, clipRectangle:Rectangle = null):void
+		public static function renderLegendItemText(destination:BitmapData, text:String, itemScreenBounds:IBounds2D, xOffset:int, clipRectangle:Rectangle = null):void
 		{
 			LinkableTextFormat.defaultTextFormat.copyTo(bitmapText.textFormat);

 			bitmapText.verticalAlign = BitmapText.VERTICAL_ALIGN_MIDDLE;

 			bitmapText.text = text;
-			bitmapText.x = itemScreenBounds.getXNumericMin() + iconGap;
+			bitmapText.x = itemScreenBounds.getXNumericMin() + xOffset;
 			bitmapText.y = itemScreenBounds.getYCenter();
-			bitmapText.maxWidth = itemScreenBounds.getXCoverage() - iconGap;
+			bitmapText.maxWidth = itemScreenBounds.getXCoverage() - xOffset;
 			bitmapText.maxHeight = itemScreenBounds.getYCoverage();
 			bitmapText.draw(destination, null, null, null, clipRectangle );
 		}


Transferred from the Adobe Open Source Subversion Repository

Revision: 11664
Author:   smgilson@adobe.com
Date:     2009-11-11T19:42:00.734447Z

Log Message:
-----------
Update ASDoc comments on new MXItemRenderer classes, and fix a broken HTML tag in Range.as

QE notes: -
Doc notes: -
Bugs: -
Reviewer: -
Tests run: - Checkintests
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/mx/controls/dataGridClasses/MXDataGridItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/mx/controls/treeClasses/MXTreeItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/mx/controls/listClasses/MXItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/Range.as</path>

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

--- frameworks/projects/spark/src/mx/controls/treeClasses/MXTreeItemRenderer.as
+++ frameworks/projects/spark/src/mx/controls/treeClasses/MXTreeItemRenderer.as
@@ -28,12 +28,14 @@
 [Exclude(name="listData", kind="property")]

 /**
- *  The MXItemRenderer class is the base class for Spark item renderers in
- *  Halo (mx) classes
+ *  The MXTreeItemRenderer class defines the Spark item renderer class
+ *  for use with the MX Tree control.
+ *  This class lets you use the Spark item renderer architecture with the
+ *  MX Tree control.
  *
  *  @mxml
  *
- *
The <s:MXItemRenderer> tag inherits all of the tag
+ *
The <s:MXTreeItemRenderer > tag inherits all of the tag
  *  attributes of its superclass and adds the following tag attributes:

  *
  *

@@ -41,6 +43,8 @@
  *    Properties
  *  />
  *

+ *
+ *  @see mx.controls.Tree
  *
  *  @langversion 3.0
  *  @playerversion Flash 10
@@ -78,7 +82,7 @@
     private var _disclosureGroup:Group;

     /**
-     *  ID of the component that will receive focus as the editor
+     *  The ID of the component that receives focus as the item editor.
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -124,6 +128,8 @@
     /**
      *  The implementation of the listData property
      *  as defined by the IDropInListItemRenderer interface.
+     *  Use this property to access information about the
+     *  data item displayed by the item renderer.
      *
      *  @see mx.controls.listClasses.IDropInListItemRenderer
      *


messageToString ???????????

messageToString ???????????

--- as3/com/netease/protobuf/messageToString.as
+++ as3/com/netease/protobuf/messageToString.as
@@ -13,12 +13,15 @@
 		var s:String = getQualifiedClassName(message) + "(\n"
 		const descriptor:XML = describeType(message)
 		for each (var getter:String in descriptor.accessor.(@access != "writeonly").@name) {
-			if (getter.search(/^has(.)(.*)$/) != -1) {
+			if (getter.search(/^has[A-Z]/) != -1) {
 				continue
 			}
 			s += fieldToString(message, descriptor, getter)
 		}
 		for each (var field:String in descriptor.variable.@name) {
+			if (field.search(/^_/) != -1) {
+				continue
+			}
 			s += fieldToString(message, descriptor, field)
 		}
 		for (var k:* in message) {


Update menuColourIdiomes.as

Update menuColourIdiomes.as

--- com/segonquart/menuColourIdiomes.as
+++ com/segonquart/menuColourIdiomes.as
@@ -2,7 +2,7 @@
 import mx.transitions.easing.*;
 import com.mosesSupposes.fuse.*;

-class com.segonquart.menuColouridiomes extends MoviieClip
+class menuColouridiomes extends MoviieClip

 	{
 		public var cat, es, en ,fr:MovieClip;


No need to route these events through pointless methods.

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

--- src/as/com/threerings/util/EmbeddedSwfLoader.as
+++ src/as/com/threerings/util/EmbeddedSwfLoader.as
@@ -29,8 +29,8 @@
     public function EmbeddedSwfLoader ()
     {
         _loader = new Loader();
-        _loader.contentLoaderInfo.addEventListener(Event.COMPLETE, completeHandler);
-        _loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, ioErrorHandler);
+        _loader.contentLoaderInfo.addEventListener(Event.COMPLETE, dispatchEvent);
+        _loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, dispatchEvent);
     }

     /**
@@ -107,16 +107,6 @@
         return !(loaderInfo.bytesTotal == 0 || loaderInfo.bytesLoaded != loaderInfo.bytesTotal);
     }

-    protected function completeHandler (e :Event) :void
-    {
-        dispatchEvent(e);
-    }
-
-    protected function ioErrorHandler (e :Event) :void
-    {
-        dispatchEvent(e);
-    }
-
     protected var _loader :Loader;
 }
 }


change uploaded filename to be more unique

--- src/com/ryanberdeen/echonest/api/v3/TrackApi.as
+++ src/com/ryanberdeen/echonest/api/v3/TrackApi.as
@@ -63,7 +63,7 @@
         api_key: _apiKey,
         wait: 'N'
       });
-      encoder.addFile('file', 'file', fileData);
+      encoder.addFile('file', 'file' + new Date().time + '.mp3', fileData);

       var request:URLRequest = new URLRequest();
       request.url = _baseUrl + 'upload';


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

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

 package mx.effects.effectClasses
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 4736
Author:   chaase@adobe.com
Date:     2009-01-29T19:31:04.898445Z

Log Message:
-----------
API improvements in some of the effects classes, such as:

- PropertyValuesHolder renamed to AnimationProperty
	- Also, values[] array changed to valueFrom and valueTo Objects
	- Also, 'delta' property changed to valueBy Object property
- FxAnimate.propertyValuesList renamed to FxAnimate.animationProperties
- Constant interpolator renamed Linear (old Linear interpolator went away)
- ColorInterpolator renamed RGBInterpolator
- HSBInterpolator now exists (not used by default: FxAnimateColor uses RGBInterpolator)
- HSBColor: new data structure in mx.utils for holding HSB colors and converting from/to RGB
- various changes to *Instance classes in effects (but these are not generally used externally)

QE Notes: Mustella tests will break due to class and property renames. QE is fixing these issues and a follow-up putback to Mustella is expected
Doc Notes: None
Bugs: -
Reviewer: Gordon
tests: checkintests, Mustella: tests/Effects tests/ListDataEffects

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/FxFadeInstance.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/interpolation/Constant.as" copyfrom-rev="4610" action="R">/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="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxMoveInstance.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/ColorInterpolator.as" copyfrom-rev="4610" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/RGBInterpolator.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/HSBInterpolator.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/HSBColor.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/ColorInterpolator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/ArrayInterpolator.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/FxAnimateColorInstance.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/flex4/src/mx/effects/effectClasses/FxAnimateShaderTransitionInstance.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/Constant.as</path>
<path kind="file" action="M">/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" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/IInterpolator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/NumberInterpolator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/interpolation/EaseInOut.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/FrameworkClasses.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/AnimationProperty.as</path>

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

--- frameworks/projects/spark/src/spark/effects/supportClasses/ResizeInstance.as
+++ frameworks/projects/spark/src/spark/effects/supportClasses/ResizeInstance.as
@@ -13,7 +13,7 @@
 import flash.events.Event;

 import mx.effects.Animation;
-import mx.effects.PropertyValuesHolder;
+import mx.effects.AnimationProperty;
 import mx.events.AnimationEvent;

 import mx.components.FxApplication;
@@ -241,9 +241,9 @@
         // effects manually on the children themselves
         var childrenHiding:Boolean = false; // hidePanelChildren();

-        propertyValuesList =
-            [new PropertyValuesHolder("width", [widthFrom, widthTo], widthBy),
-             new PropertyValuesHolder("height", [heightFrom, heightTo], heightBy)];
+        animationProperties =
+            [new AnimationProperty("width", widthFrom, widthTo, widthBy),
+             new AnimationProperty("height", heightFrom, heightTo, heightBy)];

         super.play();

@@ -254,7 +254,7 @@

     /**
      * Handles the end event from the tween. The value here is an Array of
-     * values, one for each 'property' in our propertyValuesList.
+     * values, one for each 'property' in our animationProperties.
      */
     override protected function endHandler(event:AnimationEvent):void
     {


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

 package mx.managers
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 6595
Author:   dsubrama@adobe.com
Date:     2009-05-04T20:00:36.061973Z

Log Message:
-----------
Support for caret state in ItemRenderers and List. Focus management puts renderers in the caret state and selectUponNavigation is partly implemented. This is the first step towards getting DropDownList selection/list keyboard navigation work working. Jason will do the integration/refactoring on the List end with a subsequent check-in.

QA: Hold off till Jason's refactoring work comes in
Checkintests: PASS
Mustella tests: List, ButtonBar - PASS

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/default/DefaultItemRenderer.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/List.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/ButtonBarButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/IItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/ItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/ButtonBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/IndexChangedEvent.as</path>

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

--- frameworks/projects/spark/src/spark/components/supportClasses/ListBase.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/ListBase.as
@@ -51,6 +51,18 @@
  *  @productversion Flex 4
  */
 [Event(name="selectionChanged", type="mx.events.IndexChangedEvent")]
+
+/**
+ *  Dispatched after the focus has changed.
+ *
+ *  @eventType mx.events.IndexChangedEvent.ITEM_FOCUS_CHANGED
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
+ */
+[Event(name="itemFocusChanged", type="mx.events.IndexChangedEvent")]

 /**
  *  The ListBase class is the base class for all components that support
@@ -609,10 +621,12 @@
      */
     override public function updateRenderer(renderer:IVisualElement):void
     {
-        //First clean up any old, stale properties like selected
+        //First clean up any old, stale properties like selected and caret
         if (renderer is IItemRenderer && IItemRenderer(renderer).selected)
+        {
             IItemRenderer(renderer).selected = false;
-
+            IItemRenderer(renderer).caret = false;
+        }
         //Now run through and initialize the renderer correctly
         super.updateRenderer(renderer);

@@ -667,6 +681,25 @@
     protected function itemSelected(index:int, selected:Boolean):void
     {
         // Subclasses must override this method to display the selection.
+    }
+
+    /**
+     *  Called when an item is in its caret state or not.
+     *  Subclasses must override this method to display the caret.
+     *
+     *  @param index The item index that was put into caret state.
+     *
+     *  @param inFocus true if the item is in the caret state,
+     *  and false if it is not.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10
+     *  @playerversion AIR 1.5
+     *  @productversion Flex 4
+     */
+    protected function itemInCaret(index:int, caret:Boolean):void
+    {
+        // Subclasses must override this method to display the caret.
     }

     /**


Player: Stop and clear video properly.

Player: Stop and clear video properly.

--- src/Player.as
+++ src/Player.as
@@ -102,8 +102,7 @@
       var urlParsed:Object = url.parse(iurl);

       if (client) {
-        client.stop();
-        video.clear();
+        stop();
       }

       switch (urlParsed.protocol) {
@@ -149,6 +148,7 @@
     public function stop():void
     {
       client.stop();
+      video.clear();
     }

     public function audioTransmitStopInterface():void {


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

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

--- frameworks/projects/framework/src/mx/logging/Log.as
+++ frameworks/projects/framework/src/mx/logging/Log.as
@@ -0,0 +1,431 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2005-2007 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.logging
+{
+
+import mx.logging.errors.InvalidCategoryError;
+import mx.managers.ISystemManager;
+import mx.managers.SystemManager;
+import mx.resources.IResourceManager;
+import mx.resources.ResourceManager;
+
+[ResourceBundle("logging")]
+
+/**
+ *  Provides pseudo-hierarchical logging capabilities with multiple format and
+ *  output options.
+ *  The log system consists of two major components, the logger and a target.
+ *  You can use the logger to send information to a target.
+ *  The target is responsible for formatting and general output of the log data.
+ *

+ *  Loggers are singleton instances created for a particular category of
+ *  information.
+ *  Typically, the category is the package name of the component
+ *  that desires to log information.
+ *  The category provides users the ability to specify what log information they
+ *  are interested in.
+ *  Multiple categories can be selected and combined with regular expressions.
+ *  This allows for both broad and narrow logging information to be acquired.
+ *  For example, you might be interested in all logging information under
+ *  the "mx.messaging" and "mx.rpc" packages and want the output from these
+ *  packages to be formatted as XML.
+ *  To get the all of the logging information under the "mx.messaging" category
+ *  including sub-packages and components a wildcard expression is required, such as
+ *  "mx.messaging.~~".
+ *  See the code example below for more details.
+ *

+ *
Targets provide the output mechanism of the data being logged.
+ *  This mechanism typically includes formatting, transmission, or storage, but
+ *  can be anything possible under the VM.
+ *  There are two targets provided: MiniDebugTarget and
+ *  TraceTarget.
+ *  Each of these writers take the current log information and "sends" it
+ *  somewhere for display and/or storage.
+ *  Targets also provide the specification of what log data to output.
+ *

+ *
+ *  @example
+ *

+ *  ...
+ *  import mx.logging.targets.*;
+ *  import mx.logging.*;
+ *
+ *  private function initLogging():void {
+ *      // Create a target.
+ *      var logTarget:TraceTarget = new TraceTarget();
+ *
+ *      // Log only messages for the classes in the mx.rpc.* and
+ *      // mx.messaging packages.
+ *      logTarget.filters=["mx.rpc.*","mx.messaging.*"];
+ *
+ *      // Log all log levels.
+ *      logTarget.level = LogEventLevel.ALL;
+ *
+ *      // Add date, time, category, and log level to the output.
+ *      logTarget.includeDate = true;
+ *      logTarget.includeTime = true;
+ *      logTarget.includeCategory = true;
+ *      logTarget.includeLevel = true;
+ *
+ *      // Begin logging.
+ *      Log.addTarget(logTarget);
+ *  }
+ *  ...
+ *

+ */
+public class Log
+{
+    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class variables
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     *  Sentinal value for the target log level to indicate no logging.
+     */
+    private static var NONE:int = int.MAX_VALUE;
+
+    /**
+     *  @private
+     *  The most verbose supported log level among registered targets.
+     */
+    private static var _targetLevel:int = NONE;
+        // Initialize target level to a value out of range.
+
+    /**
+     *  @private
+     *  An associative Array of existing loggers keyed by category
+     */
+    private static var _loggers:Array;
+
+    /**
+     *  @private
+     *  Array of targets that should be searched any time
+     *  a new logger is created.
+     */
+    private static var _targets:Array = [];
+
+	/**
+	 *  @private
+	 *  Storage for the resourceManager getter.
+	 *  This gets initialized on first access,
+	 *  not at static initialization time, in order to ensure
+	 *  that the Singleton registry has already been initialized.
+	 */
+	private static var _resourceManager:IResourceManager;
+
+	/**
+	 *  @private
+     *  A reference to the object which manages
+     *  all of the application's localized resources.
+     *  This is a singleton instance which implements
+     *  the IResourceManager interface.
+	 */
+	private static function get resourceManager():IResourceManager
+	{
+		if (!_resourceManager)
+			_resourceManager = ResourceManager.getInstance();
+
+		return _resourceManager;
+	}
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class methods
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Indicates whether a fatal level log event will be processed by a
+     *  log target.
+     *
+     *  @return true if a fatal level log event will be logged; otherwise false.
+     */
+    public static function isFatal():Boolean
+    {
+        return (_targetLevel <= LogEventLevel.FATAL) ? true : false;
+    }
+
+    /**
+     *  Indicates whether an error level log event will be processed by a
+     *  log target.
+     *
+     *  @return true if an error level log event will be logged; otherwise false.
+     */
+    public static function isError():Boolean
+    {
+        return (_targetLevel <= LogEventLevel.ERROR) ? true : false;
+    }
+
+    /**
+     *  Indicates whether a warn level log event will be processed by a
+     *  log target.
+     *
+     *  @return true if a warn level log event will be logged; otherwise false.
+     */
+    public static function isWarn():Boolean
+    {
+        return (_targetLevel <= LogEventLevel.WARN) ? true : false;
+    }
+
+    /**
+     *  Indicates whether an info level log event will be processed by a
+     *  log target.
+     *
+     *  @return true if an info level log event will be logged; otherwise false.
+     */
+    public static function isInfo():Boolean
+    {
+        return (_targetLevel <= LogEventLevel.INFO) ? true : false;
+    }
+
+    /**
+     *  Indicates whether a debug level log event will be processed by a
+     *  log target.
+     *
+     *  @return true if a debug level log event will be logged; otherwise false.
+     */
+    public static function isDebug():Boolean
+    {
+        return (_targetLevel <= LogEventLevel.DEBUG) ? true : false;
+    }
+
+    /**
+     *  Allows the specified target to begin receiving notification of log
+     *  events.
+     *
+     *  @param The specific target that should capture log events.
+     */
+    public static function addTarget(target:ILoggingTarget):void
+    {
+        if (target)
+        {
+            var filters:Array = target.filters;
+            var logger:ILogger;
+            // need to find what filters this target matches and set the specified
+            // target as a listener for that logger.
+            for (var i:String in _loggers)
+            {
+                if (categoryMatchInFilterList(i, filters))
+                    target.addLogger(ILogger(_loggers[i]));
+            }
+            // if we found a match all is good, otherwise we need to
+            // put the target in a waiting queue in the event that a logger
+            // is created that this target cares about.
+            _targets.push(target);
+
+            if (_targetLevel == NONE)
+                _targetLevel = target.level
+            else if (target.level < _targetLevel)
+                _targetLevel = target.level;
+        }
+        else
+        {
+            var message:String = resourceManager.getString(
+                "logging", "invalidTarget");
+            throw new ArgumentError(message);
+        }
+    }
+
+    /**
+     *  Stops the specified target from receiving notification of log
+     *  events.
+     *
+     *  @param The specific target that should capture log events.
+     */
+    public static function removeTarget(target:ILoggingTarget):void
+    {
+        if (target)
+        {
+            var filters:Array = target.filters;
+            var logger:ILogger;
+            // Disconnect this target from any matching loggers.
+            for (var i:String in _loggers)
+            {
+                if (categoryMatchInFilterList(i, filters))
+                {
+                    target.removeLogger(ILogger(_loggers[i]));
+                }
+            }
+            // Remove the target.
+            for (var j:int = 0; j<_targets.length; j++)
+            {
+                if (target == _targets[j])
+                {
+                    _targets.splice(j, 1);
+                    j--;
+                }
+            }
+            resetTargetLevel();
+        }
+        else
+        {
+            var message:String = resourceManager.getString(
+                "logging", "invalidTarget");
+            throw new ArgumentError(message);
+        }
+    }
+
+    /**
+     *  Returns the logger associated with the specified category.
+     *  If the category given doesn't exist a new instance of a logger will be
+     *  returned and associated with that category.
+     *  Categories must be at least one character in length and may not contain
+     *  any blanks or any of the following characters:
+     *  []~$^&\/(){}<>+=`!#%?,:;'"@
+     *  This method will throw an InvalidCategoryError if the
+     *  category specified is malformed.
+     *
+     *  @param category The category of the logger that should be returned.
+     *
+     *  @return An instance of a logger object for the specified name.
+     *  If the name doesn't exist, a new instance with the specified
+     *  name is returned.
+     */
+    public static function getLogger(category:String):ILogger
+    {
+        checkCategory(category);
+        if (!_loggers)
+            _loggers = [];
+
+        // get the logger for the specified category or create one if it
+        // doesn't exist
+        var result:ILogger = _loggers[category];
+        if (result == null)
+        {
+            result = new LogLogger(category);
+            _loggers[category] = result;
+        }
+
+        // check to see if there are any targets waiting for this logger.
+        var target:ILoggingTarget;
+        for (var i:int = 0; i < _targets.length; i++)
+        {
+            target = ILoggingTarget(_targets[i]);
+            if (categoryMatchInFilterList(category, target.filters))
+                target.addLogger(result);
+        }
+
+        return result;
+    }
+
+    /**
+     *  This method removes all of the current loggers from the cache.
+     *  Subsquent calls to the getLogger() method return new instances
+     *  of loggers rather than any previous instances with the same category.
+     *  This method is intended for use in debugging only.
+     */
+    public static function flush():void
+    {
+        _loggers = [];
+        _targets = [];
+        _targetLevel = NONE;
+    }
+
+    /**
+     *  This method checks the specified string value for illegal characters.
+     *
+     *  @param value The String to check for illegal characters.
+     *            The following characters are not valid:
+     *                []~$^&\/(){}<>+=`!#%?,:;'"@
+     *  @return   true if there are any illegal characters found,
+     *            false otherwise
+     */
+    public static function hasIllegalCharacters(value:String):Boolean
+    {
+        return value.search(/[\[\]\~\$\^\&\\(\)\{\}\+\?\/=`!@#%,:;'"<>\s]/) != -1;
+    }
+
+    // private members
+    /**
+     *  This method checks that the specified category matches any of the filter
+     *  expressions provided in the filters Array.
+     *
+     *  @param category The category to match against
+     *  @param filters A list of Strings to check category against.
+     *  @return true if the specified category matches any of the
+     *            filter expressions found in the filters list, false
+     *            otherwise.
+     *  @private
+     */
+    private static function categoryMatchInFilterList(category:String, filters:Array):Boolean
+    {
+        var result:Boolean = false;
+        var filter:String;
+        var index:int = -1;
+        for (var i:uint = 0; i < filters.length; i++)
+        {
+            filter = filters[i];
+            // first check to see if we need to do a partial match
+            // do we have an asterisk?
+            index = filter.indexOf("*");
+
+            if (index == 0)
+                return true;
+
+            index = index < 0 ? index = category.length : index -1;
+
+            if (category.substring(0, index) == filter.substring(0, index))
+                return true;
+        }
+        return false;
+    }
+
+    /**
+     *  This method will ensure that a valid category string has been specified.
+     *  If the category is not valid an InvalidCategoryError will
+     *  be thrown.
+     *  Categories can not contain any blanks or any of the following characters:
+     *    []`*~,!#$%^&()]{}+=\|'";?><./@ or be less than 1 character in length.
+     *  @private
+     */
+    private static function checkCategory(category:String):void
+    {
+        var message:String;
+
+        if (category == null || category.length == 0)
+        {
+            message = resourceManager.getString(
+                "logging", "invalidLen");
+            throw new InvalidCategoryError(message);
+        }
+
+        if (hasIllegalCharacters(category) || (category.indexOf("*") != -1))
+        {
+            message = resourceManager.getString(
+                "logging", "invalidChars");
+            throw new InvalidCategoryError(message);
+        }
+    }
+
+    /**
+     *  @private
+     *  This method resets the Log's target level to the most verbose log level
+     *  for the currently registered targets.
+     */
+    private static function resetTargetLevel():void
+    {
+        var minLevel:int = NONE;
+        for (var i:int = 0; i < _targets.length; i++)
+        {
+            if (minLevel == NONE || _targets[i].level < minLevel)
+                minLevel = _targets[i].level;
+        }
+        _targetLevel = minLevel;
+    }
+}
+
+}


Transferred from the Adobe Open Source Subversion Repository

Revision: 9715
Author:   aharui@adobe.com
Date:     2009-08-27T21:20:28.280781Z

Log Message:
-----------
Introduce tabFocusEnabled to IFocusManagerComponent.  This replaces tabEnabled as the way to remove a component from the tabbing loop.  tabEnabled should be set to true for any component that can receive focus, and tabFocusEnabled determines whether the FocusManager will actually give it focus.  If tabEnabled=false on a non-TextField, the player will sometimes momentarily remove focus and dispatch a focusOut when the component has focus and is later clicked on.  This is now quite common with TLF-based text components so we are forced to make this change.

QE Notes: tests using tabEnabled must now use tabFocusEnabled
Doc Notes: needs documentation
Bugs: SDK-22731
Reviewer: Gordon
API Change: Yes
Is noteworthy for integration: Yes
tests: checkintests cyclone

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/Window.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ComboBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/FlexHTMLLoader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/accordionClasses/AccordionHeader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/IFocusManagerComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/HTML.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flash-integration/src/mx/flash/UIMovieClip.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ButtonBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateChooser.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/FlexEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Accordion.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/FocusManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Menu.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Container.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/sliderClasses/Slider.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Image.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/TabNavigator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/SWFLoader.as</path>

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

--- frameworks/projects/mx/src/mx/controls/ComboBase.as
+++ frameworks/projects/mx/src/mx/controls/ComboBase.as
@@ -310,6 +310,7 @@
         super();

         tabEnabled = true;
+        tabFocusEnabled = true;
     }

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


Transferred from the Adobe Open Source Subversion Repository

Revision: 2185
Author:   jimurphy@adobe.com
Date:     2008-06-23T20:04:23.150071Z

Log Message:
-----------
Merged 3.0.x revisions [2108,2111,2113,2142,2145,2147,2149-2150,2171,2178,2183] -> trunk

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/templates/html-templates/express-installation-with-history/history/historyFrame.html</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/compiler/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/xml/XMLDecoder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/swfutils/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/binding/utils/BindingUtils.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/TextInput.as</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/debugger/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/asc/build/java/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Container.as</path>
<path kind="file" action="M">/flex/sdk/trunk/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/antTasks/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/NavBar.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/templates/html-templates/client-side-detection-with-history/history/historyFrame.html</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/binding/Binding.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/soap/types/SOAPArrayType.as</path>
<path kind="file" action="M">/flex/sdk/trunk/templates/html-templates/no-player-detection-with-history/history/historyFrame.html</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/TabNavigator.as</path>

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

--- frameworks/projects/mx/src/mx/controls/TextInput.as
+++ frameworks/projects/mx/src/mx/controls/TextInput.as
@@ -245,7 +245,7 @@
  *    paddingRight="0"
  *    shadowDirection="center"
  *    shadowDistance="2"
- *    textAlign="lift|right|center"
+ *    textAlign="left|right|center"
  *    textDecoration="none|underline"
  *    textIndent="0"
  *


Transferred from the Adobe Open Source Subversion Repository

Revision: 16545
Author:   chiedozi@adobe.com
Date:     2010-06-14T03:42:53.505665Z

Log Message:
-----------
Added MobileApplication, ViewNavigator, PersistenceManager and ViewTransition prototypes to mobile components swc.

mobilecomponents and mobiletheme eclipse projects now link to airglobal.swc instead of playerglobal.swc so that MobileApplication can respond to StageOrientation and NativeApplication events.

QE notes:
Doc notes:
Bugs:
Reviewer:
Tests run: checkintests

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/manifest.xml</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/View.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/.actionScriptProperties</path>
<path kind="file" action="A">/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/defaults.css</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/core/managers/PersistenceManager.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/effects/ViewTransition.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/MobileThemeClasses.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/ViewNavigator.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/core/managers/IPersistenceManager.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/effects/IViewTransition.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/MobileApplication.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ViewData.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/.actionScriptProperties</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ViewNavigatorSkin.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/effects/SlideViewTransition.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/ActionBar.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/events/FlexEvent.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ViewNavigatorSection.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/events/ViewNavigatorEvent.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/MobileApplicationSkin.as</path>

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

--- frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ViewDescriptor.as
+++ frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ViewDescriptor.as
@@ -0,0 +1,72 @@
+package spark.components.supportClasses
+{
+import flash.utils.IDataInput;
+import flash.utils.IDataOutput;
+import flash.utils.IExternalizable;
+import flash.utils.getDefinitionByName;
+import flash.utils.getQualifiedClassName;
+
+import spark.components.View;
+
+public class ViewData implements IExternalizable
+{
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10
+     *  @playerversion AIR 1.5
+     *  @productversion Flex 4
+     */
+    public function ViewData(factory:Class = null, data:Object = null, instance:View = null)
+    {
+        this.factory = factory;
+        this.data = data;
+        this.instance = instance;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+    public var instance:View;
+
+    // Runtime data
+    public var data:Object;
+
+    // Serialized data
+    public var persistedData:Object;
+
+    public var factory:Class;
+
+
+    //--------------------------------------------------------------------------
+    //
+    //  Methods: IExternalizable
+    //
+    //--------------------------------------------------------------------------
+
+    public function writeExternal(output:IDataOutput):void
+    {
+        output.writeObject(persistedData);
+
+        // Need to get class name using describe type
+        output.writeObject(getQualifiedClassName(factory));
+    }
+
+    public function readExternal(input:IDataInput):void
+    {
+        persistedData = input.readObject();
+
+        var className:String = input.readObject();
+        factory = getDefinitionByName(className) as Class;
+    }
+}
+}


IMetaDataContainer.getMetaData() now returns an array of MetaData objects

--- src/as3reflect/IMetaDataContainer.as
+++ src/as3reflect/IMetaDataContainer.as
@@ -39,10 +39,10 @@
 		function hasMetaData(key:String):Boolean;

 		/**
-		 * Returns the MetaData object that corresponds to the given key. If no MetaData object was found, null is
-		 * returned.
+		 * Returns the array of MetaData object that corresponds to the given key. If no MetaData object was found,
+		 * an empty array is returned.
 		 */
-		function getMetaData(key:String):MetaData;
+		function getMetaData(key:String):Array;

 		/**
 		 * Returns an array of all metadata objects in this container.


Transferred from the Adobe Open Source Subversion Repository

Revision: 17396
Author:   chiedozi@adobe.com
Date:     2010-08-19T23:20:11.495099Z

Log Message:
-----------
Removed the enabled property from IPersistenceManager
Fixed a small issue where the timestamp wasn't correctly saved when an application's state was persisted

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

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/core/managers/IPersistenceManager.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/MobileApplication.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/TabbedMobileApplication.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/core/managers/PersistenceManager.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/MobileApplicationBase.as</path>

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

--- frameworks/projects/mobilecomponents/src/spark/components/TabbedViewNavigatorApplication.as
+++ frameworks/projects/mobilecomponents/src/spark/components/TabbedViewNavigatorApplication.as
@@ -196,13 +196,10 @@
     {
         super.restoreApplicationState();

-        if (persistenceManager.enabled)
-        {
-            var savedState:Object = persistenceManager.getProperty("navigatorState");
-
-            if (savedState)
-                navigator.restoreViewData(savedState);
-        }
+        var savedState:Object = persistenceManager.getProperty("navigatorState");
+
+        if (savedState)
+            navigator.restoreViewData(savedState);
     }

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