Transferred from the Adobe Open Source Subversion Repository

Revision: 10464
Author:   rfrishbe@adobe.com
Date:     2009-09-21T17:40:30.663638Z

Log Message:
-----------
Removing support in Flex framework for compatibility version < 3.  We won't support compatibility-version 2 or 2.01 anymore.  We only keep compatibility-version for one full release, so for Flex 4, we only support compatibility-version = 3.x.

This should reduce our code-size some as we no longer need this old code.  I didn't clean up the compiler's support for compatibility-versioning as it didn't seem worth the effort.

QE notes: -
Doc notes: -
Bugs: SDK-15360
Reviewer: Kevin
Tests run: checkintests, Joan ran all mustella tests
Is noteworthy for integration: Yes

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/TileListItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/halo/HaloBorder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ProgressBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/RadioButton.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/containers/utilityClasses/CanvasLayout.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/spark/src/mx/core/UITLFTextField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/NumericStepper.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/halo/ScrollArrowSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/halo/AccordionHeaderSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Alert.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/NavBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Button.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UITextField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ColorPicker.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/TextArea.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridHeaderBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/StyleProxy.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/treeClasses/TreeItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/TabNavigator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/FormItem.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/dataGridClasses/DataGridHeader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/CheckBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/SWFLoader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/halo/DateChooserYearArrowSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/LinkButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/MenuBar.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/framework/src/mx/controls/menuClasses/MenuBarItem.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/halo/PanelSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/menuClasses/MenuItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/StyleManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/PopUpButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/scrollClasses/ScrollBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Panel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/colorPickerClasses/SwatchPanel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Accordion.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/TextInput.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/StyleProtoChain.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ComboBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/List.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Label.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DataGrid.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/halo/ScrollTrackSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/utilityClasses/Flex.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/LinkBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/sliderClasses/Slider.as</path>

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

--- frameworks/projects/mx/src/mx/controls/dataGridClasses/DataGridHeaderBase.as
+++ frameworks/projects/mx/src/mx/controls/dataGridClasses/DataGridHeaderBase.as
@@ -26,7 +26,6 @@
 import mx.controls.DataGrid;
 import mx.core.EdgeMetrics;
 import mx.core.FlexSprite;
-import mx.core.FlexVersion;
 import mx.core.IFlexDisplayObject;
 import mx.core.UIComponent;
 import mx.core.UIComponentGlobals;


fix uint instead of int for nodeId argument that might cause infinite loop in TransformController.updateAncestorsAndSelfLocalToWorldTransform()

--- src/aerys/minko/scene/controller/TransformController.as
+++ src/aerys/minko/scene/controller/TransformController.as
@@ -113,7 +113,7 @@
             }
         }

-        private function updateAncestorsAndSelfLocalToWorld(nodeId : uint) : void
+        private function updateAncestorsAndSelfLocalToWorld(nodeId : int) : void
         {
             var dirtyRoot : int = -1;


Fix local to world transform update when an object is added.

--- src/aerys/minko/scene/controller/TransformController.as
+++ src/aerys/minko/scene/controller/TransformController.as
@@ -22,18 +22,19 @@
 	 */
 	public final class TransformController extends AbstractController
 	{
-		private var _target					: ISceneNode;
-
-		private var _invalidList			: Boolean;
-
-		private var _nodeToId				: Dictionary;
-		private var _idToNode				: Vector.<ISceneNode>
-		private var _transforms				: Vector.<Matrix4x4>;
-		private var _localToWorldTransforms : Vector.<Matrix4x4>;
-        private var _worldToLocalTransforms : Vector.<Matrix4x4>;
-		private var _numChildren			: Vector.<uint>;
-		private var _firstChildId			: Vector.<uint>;
-		private var _parentId				: Vector.<int>;
+		private var _target								: ISceneNode;
+
+		private var _invalidList						: Boolean;
+
+		private var _nodeToId							: Dictionary;
+		private var _idToNode							: Vector.<ISceneNode>
+		private var _transforms							: Vector.<Matrix4x4>;
+		private var _localToWorldTransformsInitialized	: Vector.<Boolean>;
+		private var _localToWorldTransforms 			: Vector.<Matrix4x4>;
+        private var _worldToLocalTransforms 			: Vector.<Matrix4x4>;
+		private var _numChildren						: Vector.<uint>;
+		private var _firstChildId						: Vector.<uint>;
+		private var _parentId							: Vector.<int>;

 		public function TransformController()
 		{
@@ -44,26 +45,15 @@
 		}

 		private function renderingBeginHandler(scene			: Scene,
-										  viewport		: Viewport,
-										  destination	: BitmapData,
-										  time			: Number) : void
+											   viewport		: Viewport,
+											   destination	: BitmapData,
+											   time			: Number) : void
 		{
 			if (_invalidList)
 				updateTransformsList();

 			if (_transforms.length)
-			{
-				var rootTransform 	: Matrix4x4	= _transforms[0];
-				var isDirty			: Boolean	= rootTransform._hasChanged;
-
-				if (isDirty)
-				{
-					_localToWorldTransforms[0].copyFrom(rootTransform);
-					rootTransform._hasChanged = false;
-				}
-
 				updateLocalToWorld();
-			}
 		}

 		private function updateLocalToWorld(nodeId : uint = 0) : void
@@ -74,13 +64,15 @@
 			var rootTransform		: Matrix4x4		= _transforms[nodeId];
 			var root				: ISceneNode	= _idToNode[childId];

-			if (rootTransform._hasChanged)
+			if (rootTransform._hasChanged || !_localToWorldTransformsInitialized[nodeId])
 			{
 				rootLocalToWorld.copyFrom(rootTransform);

 				if (nodeId != 0)
 					rootLocalToWorld.append(_localToWorldTransforms[_parentId[nodeId]]);

+				rootTransform._hasChanged = false;
+				_localToWorldTransformsInitialized[nodeId] = true;
 				root.localToWorldTransformChanged.execute(root, rootLocalToWorld);
 			}

@@ -88,19 +80,22 @@
 			{
 				var localToWorld 	: Matrix4x4	= _localToWorldTransforms[nodeId];
 				var numChildren		: uint		= _numChildren[nodeId];
-				var isDirty			: Boolean	= localToWorld._hasChanged;
 				var firstChildId	: uint		= _firstChildId[nodeId];
 				var lastChildId		: uint		= firstChildId + numChildren;
+				var isDirty			: Boolean	= localToWorld._hasChanged ||
+												  !_localToWorldTransformsInitialized[nodeId];

 				localToWorld._hasChanged = false;
+				_localToWorldTransformsInitialized[nodeId] = true;

 				for (var childId : uint = firstChildId; childId < lastChildId; ++childId)
 				{
 					var childTransform		: Matrix4x4		= _transforms[childId];
 					var childLocalToWorld	: Matrix4x4		= _localToWorldTransforms[childId];
-					var childIsDirty		: Boolean		= isDirty || childTransform._hasChanged;
+					var childIsDirty		: Boolean		= isDirty || childTransform._hasChanged
+						|| !_localToWorldTransformsInitialized[childId];

-					if (childIsDirty)
+					if (childIsDirty || _localToWorldTransformsInitialized[childId])
 					{
 						var child	: ISceneNode	= _idToNode[childId];

@@ -109,7 +104,7 @@
 							.append(localToWorld);

 						childTransform._hasChanged = false;
-
+						_localToWorldTransformsInitialized[childId] = true;
 						child.localToWorldTransformChanged.execute(child, childLocalToWorld);
 					}
 				}
@@ -118,11 +113,12 @@

         private function getDirtyRoot(nodeId : int) : int
         {
-            var dirtyRoot : int = nodeId;
+            var dirtyRoot : int = -1;

             while (nodeId >= 0)
             {
-                if ((_transforms[nodeId] as Matrix4x4)._hasChanged)
+                if ((_transforms[nodeId] as Matrix4x4)._hasChanged ||
+					!_localToWorldTransformsInitialized[nodeId])
                     dirtyRoot = nodeId;

                 nodeId = _parentId[nodeId];
@@ -175,6 +171,7 @@

 			_nodeToId = null;
 			_transforms = null;
+			_localToWorldTransformsInitialized = null;
 			_localToWorldTransforms = null;
             _worldToLocalTransforms = null;
 			_numChildren = null;
@@ -220,6 +217,7 @@

 			_nodeToId = new Dictionary(true);
 			_transforms = new <Matrix4x4>[];
+			_localToWorldTransformsInitialized = new <Boolean>[];
 			_localToWorldTransforms = new <Matrix4x4>[];
             _worldToLocalTransforms = new <Matrix4x4>[];
 			_numChildren = new <uint>[];
@@ -236,7 +234,8 @@
 				_idToNode[nodeId] = node;
 				_transforms[nodeId] = node.transform;
 				_localToWorldTransforms[nodeId] = new Matrix4x4().lock();
-
+				_localToWorldTransformsInitialized[nodeId] = false;
+
 				if (group)
 				{
 					var numChildren 	: uint = group.numChildren;


fix DiffuseShaderPart.getDiffuseColor() to use vertexUV if the provided uv argument is null

--- src/aerys/minko/render/shader/part/DiffuseShaderPart.as
+++ src/aerys/minko/render/shader/part/DiffuseShaderPart.as
@@ -25,7 +25,8 @@
 		public function getDiffuseColor(killOnAlphaThreshold : Boolean = true, uv : SFloat = null) : SFloat
 		{
 			var diffuseColor : SFloat	= null;
-
+			var useVertexUv  : Boolean  = uv == null;
+
             uv ||= vertexUV.xy;

 			if (meshBindings.propertyExists(BasicProperties.UV_SCALE))
@@ -33,8 +34,9 @@

 			if (meshBindings.propertyExists(BasicProperties.UV_OFFSET))
 				uv.incrementBy(meshBindings.getParameter(BasicProperties.UV_OFFSET, 2));
-
-			uv = interpolate(uv);
+
+			if (useVertexUv)
+				uv = interpolate(uv);

 			if (meshBindings.propertyExists(BasicProperties.DIFFUSE_MAP) && meshBindings.propertyExists(VertexComponent.UV.nativeFormatString))
 			{


Fix for infinite localToWorld transform update

--- src/aerys/minko/scene/controller/TransformController.as
+++ src/aerys/minko/scene/controller/TransformController.as
@@ -201,9 +201,10 @@

 		private function updateLocalToWorldPath(path : Vector.<uint> = null) : void
 		{
-			var numNodes 	    : uint 	    = path.length;
-			var nodeId          : uint      = path[uint(numNodes - 1)];
-			var localToWorld 	: Matrix4x4	= _localToWorldTransforms[nodeId];
+			var numNodes				: uint		= path.length;
+			var nodeId					: uint		= path[uint(numNodes - 1)];
+			var localToWorld 			: Matrix4x4	= _localToWorldTransforms[nodeId];
+			var prevChildLocalToWorld	: Matrix4x4	= new Matrix4x4();

 			updateRootLocalToWorld(nodeId);

@@ -215,12 +216,15 @@
 				var childFlags          : uint          = _flags[childId];
 				var child	            : ISceneNode	= _idToNode[childId];

+				prevChildLocalToWorld.copyFrom(childLocalToWorld);
+
 				if (childFlags & FLAG_LOCK_TRANSFORMS)
 					childLocalToWorld.lock();

 				childLocalToWorld
-				.copyFrom(childTransform)
+					.copyFrom(childTransform)
 					.append(localToWorld);
+

 				if (childFlags & FLAG_LOCK_TRANSFORMS)
 					childLocalToWorld.unlock();
@@ -248,7 +252,7 @@

 				var localToWorldTransformChanged : Signal = child.localToWorldTransformChanged;

-				if (localToWorldTransformChanged.enabled)
+				if (localToWorldTransformChanged.enabled && !prevChildLocalToWorld.compareTo(childLocalToWorld))
 					localToWorldTransformChanged.execute(child, childLocalToWorld);

 				localToWorld = childLocalToWorld;
@@ -264,7 +268,8 @@

 			while (tmpNodeId >= 0)
 			{
-				if ((_transforms[tmpNodeId] as Matrix4x4)._hasChanged
+				if ((_transforms[tmpNodeId] as Matrix4x4)._hasChanged
+					|| (tmpNodeId != nodeId && _localToWorldTransforms[tmpNodeId]._hasChanged)
 					|| !(_flags[nodeId] & FLAG_INIT_LOCAL_TO_WORLD))
 					dirtyRoot = tmpNodeId;


Publicize addChatter().

Publicize addChatter().

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

--- src/as/com/threerings/crowd/chat/client/ChatDirector.as
+++ src/as/com/threerings/crowd/chat/client/ChatDirector.as
@@ -187,6 +187,33 @@
     }

     /**
+     * Adds a chatter to our list of recent chatters. This is normally done
+     * automatically by the ChatDirector, but may be called to also to
+     * forcibly add a chatter. The ChatterValidator will have to approve
+     * of the chatter.
+     */
+    public function addChatter (name :Name) :void
+    {
+        // check to see if the chatter validator approves..
+        if ((_chatterValidator != null) &&
+            (!_chatterValidator.isChatterValid(name))) {
+            return;
+        }
+
+        var wasThere :Boolean = ArrayUtil.removeAll(_chatters, name);
+        _chatters.unshift(name);
+
+        if (!wasThere) {
+            if (_chatters.length > MAX_CHATTERS) {
+                _chatters.length = MAX_CHATTERS; // truncate array
+            }
+
+            // we only notify on a change to the contents, not just reordering
+            notifyChatterObservers();
+        }
+    }
+
+    /**
      * Registers a chat command handler.
      *
      * @param msg the message bundle via which the slash command will be
@@ -897,30 +924,6 @@
     }

     /**
-     * Adds a chatter to our list of recent chatters.
-     */
-    protected function addChatter (name :Name) :void
-    {
-        // check to see if the chatter validator approves..
-        if ((_chatterValidator != null) &&
-            (!_chatterValidator.isChatterValid(name))) {
-            return;
-        }
-
-        var wasThere :Boolean = ArrayUtil.removeAll(_chatters, name);
-        _chatters.unshift(name);
-
-        if (!wasThere) {
-            if (_chatters.length > MAX_CHATTERS) {
-                _chatters.length = MAX_CHATTERS; // truncate array
-            }
-
-            // we only notify on a change to the contents, not just reordering
-            notifyChatterObservers();
-        }
-    }
-
-    /**
      * Notifies all registered {@link ChatterObserver}s that the list of
      * chatters has changed.
      */


adds testing of immutable command mapping list during execution

--- test/robotlegs/bender/extensions/eventCommandMap/impl/EventCommandMapTest.as
+++ test/robotlegs/bender/extensions/eventCommandMap/impl/EventCommandMapTest.as
@@ -10,14 +10,12 @@
 	import flash.events.Event;
 	import flash.events.EventDispatcher;
 	import flash.events.IEventDispatcher;
-
 	import org.hamcrest.assertThat;
 	import org.hamcrest.collection.array;
 	import org.hamcrest.core.not;
 	import org.hamcrest.object.equalTo;
 	import org.hamcrest.object.instanceOf;
 	import org.swiftsuspenders.Injector;
-
 	import robotlegs.bender.extensions.commandCenter.dsl.ICommandMapper;
 	import robotlegs.bender.extensions.commandCenter.dsl.ICommandUnmapper;
 	import robotlegs.bender.extensions.commandCenter.support.CallbackCommand;
@@ -204,7 +202,7 @@
 		[Test]
 		public function unspecified_untyped_event_is_injected_into_command_as_untyped_event():void
 		{
-			const eventType : String = 'eventType';
+			const eventType:String = 'eventType';
 			var injectedEvent:Event = null;
 			injector.map(Function, 'executeCallback').toValue(function(command:SupportEventTriggeredSelfReportingCallbackCommand):void
 			{
@@ -220,7 +218,7 @@
 		[Test]
 		public function specified_untyped_event_is_injected_into_command_as_untyped_event():void
 		{
-			const eventType : String = 'eventType';
+			const eventType:String = 'eventType';
 			var injectedEvent:Event = null;
 			injector.map(Function, 'executeCallback').toValue(function(command:SupportEventTriggeredSelfReportingCallbackCommand):void
 			{
@@ -405,6 +403,30 @@
 			assertThat(reportedExecutions, array(expectedOrder));
 		}

+		[Test]
+		public function commands_mapped_during_execution_are_not_executed():void
+		{
+			injector.map(IEventCommandMap).toValue(subject);
+			injector.map(Class, 'nestedCommand').toValue(ClassReportingCallbackCommand);
+			subject.map(SupportEvent.TYPE1, Event)
+				.toCommand(CommandMappingCommand).once();
+			dispatcher.dispatchEvent(new SupportEvent(SupportEvent.TYPE1));
+			assertThat(reportedExecutions, array());
+		}
+
+		[Test]
+		public function commands_unmapped_during_execution_are_still_executed():void
+		{
+			injector.map(IEventCommandMap).toValue(subject);
+			injector.map(Class, 'nestedCommand').toValue(ClassReportingCallbackCommand);
+			subject.map(SupportEvent.TYPE1, Event)
+				.toCommand(CommandUnmappingCommand).once();
+			subject.map(SupportEvent.TYPE1, Event)
+				.toCommand(ClassReportingCallbackCommand).once();
+			dispatcher.dispatchEvent(new SupportEvent(SupportEvent.TYPE1));
+			assertThat(reportedExecutions, array(ClassReportingCallbackCommand));
+		}
+
 		/*============================================================================*/
 		/* Private Functions                                                          */
 		/*============================================================================*/
@@ -516,3 +538,55 @@
 		callback(event);
 	}
 }
+
+class CommandMappingCommand
+{
+
+	/*============================================================================*/
+	/* Public Properties                                                          */
+	/*============================================================================*/
+
+	[Inject]
+	public var event:Event;
+
+	[Inject(name="nestedCommand")]
+	public var commandClass:Class;
+
+	[Inject]
+	public var eventCommandMap:IEventCommandMap;
+
+	/*============================================================================*/
+	/* Public Functions                                                           */
+	/*============================================================================*/
+
+	public function execute():void
+	{
+		eventCommandMap.map(event.type, Event).toCommand(commandClass);
+	}
+}
+
+class CommandUnmappingCommand
+{
+
+	/*============================================================================*/
+	/* Public Properties                                                          */
+	/*============================================================================*/
+
+	[Inject]
+	public var event:Event;
+
+	[Inject(name="nestedCommand")]
+	public var commandClass:Class;
+
+	[Inject]
+	public var eventCommandMap:IEventCommandMap;
+
+	/*============================================================================*/
+	/* Public Functions                                                           */
+	/*============================================================================*/
+
+	public function execute():void
+	{
+		eventCommandMap.unmap(event.type, Event).fromCommand(commandClass);
+	}
+}


Dropping connection on protocol errors instead of throwing an uncatchable error.

--- AS3WebSocket/src/com/worlize/websocket/WebSocket.as
+++ AS3WebSocket/src/com/worlize/websocket/WebSocket.as
@@ -508,9 +508,11 @@
 								totalLength += frameQueue[i].length;
 							}
 							if (totalLength > config.maxMessageSize) {
-								throw new WebSocketError("Message size of " + totalLength +
+								drop(WebSocketCloseStatus.MESSAGE_TOO_LARGE,
+									"Message size of " + totalLength +
 									" bytes exceeds maximum accepted message size of " +
 									config.maxMessageSize + " bytes.");
+								return;
 							}
 							for (i=0; i < frameQueue.length; i++) {
 								currentFrame = frameQueue[i];
@@ -532,7 +534,9 @@
 									event.message.utf8Data = binaryData.readMultiByte(binaryData.length, 'utf-8');
 									break;
 								default:
-									throw new WebSocketError("Unexpected first opcode in fragmentation sequence: 0x" + messageOpcode.toString(16));
+									drop(WebSocketCloseStatus.PROTOCOL_ERROR,
+										 "Unexpected first opcode in fragmentation sequence: 0x" + messageOpcode.toString(16));
+									return;
 							}
 							frameQueue = new Vector.<WebSocketFrame>();
 							fragmentationOpcode = 0x00;


Do not throw an exception when a Parser is registered twice.

--- src/aerys/minko/type/loader/SceneLoader.as
+++ src/aerys/minko/type/loader/SceneLoader.as
@@ -51,16 +51,11 @@

 		public static function registerParser(parserClass : Class) : void
 		{
+			if (REGISTERED_PARSERS.indexOf(parserClass) != -1)
+				return;
+
 			if (!(new parserClass(new ParserOptions()) is IParser))
 				throw new Error('Parsers must implement the IParser interface.');
-
-			if (REGISTERED_PARSERS.indexOf(parserClass) != -1)
-			{
-				var className : String = getQualifiedClassName(parserClass);
-				className = className.substr(className.lastIndexOf(':') + 1);
-				throw new Error(className + ' does not implement the IParser ' +
-					'interface: it cannot be registered as a parser');
-			}

 			REGISTERED_PARSERS.push(parserClass);
 		}


Transferred from the Adobe Open Source Subversion Repository

Revision: 10640
Author:   clucier@adobe.com
Date:     2009-09-28T15:26:32.513982Z

Log Message:
-----------
Added emphasizedSkin Style metadata to mx Button.  Added symbolColor style metadata to MenuBar.  Excluded baseColor style from mx LinkButton.

QE notes: None
Doc notes: None
Bugs: SDK-22522, SDK-22257, SDK-22646
Reviewer: Glenn
Tests run: Checkin
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/LinkButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/MenuBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Button.as</path>

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

--- frameworks/projects/mx/src/mx/controls/MenuBar.as
+++ frameworks/projects/mx/src/mx/controls/MenuBar.as
@@ -284,6 +284,19 @@
  *  @productversion Flex 3
  */
 [Style(name="selectionColor", type="uint", format="Color", inherit="yes")]
+
+/**
+ *  Color of any symbol of a component. Examples include the check mark of a CheckBox or
+ *  the arrow of a ScrollBar button.
+ *
+ *  @default 0x000000
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
+ */
+[Style(name="symbolColor", type="uint", format="Color", inherit="yes", theme="spark")]

 //--------------------------------------
 //  Other metadata


Added loadFromString() and saveToString() functions for loading and saving tile index data.

--- net/flashpunk/graphics/Tilemap.as
+++ net/flashpunk/graphics/Tilemap.as
@@ -139,6 +139,51 @@
 		}

 		/**
+		* Loads the Tilemap tile index data from a string.
+		* @param str			The string data, which is a set of tile values separated by the columnSep and rowSep strings.
+		* @param columnSep		The string that separates each tile value on a row, default is ",".
+		* @param rowSep			The string that separates each row of tiles, default is "\n".
+		*/
+		public function loadFromString(str:String, columnSep:String = ",", rowSep:String = "\n"):void
+		{
+			var row:Array = str.split(rowSep),
+				rows:int = row.length,
+				col:Array, cols:int, x:int, y:int;
+			for (y = 0; y < rows; y ++)
+			{
+				if (row[y] == '') continue;
+				col = row[y].split(columnSep),
+				cols = col.length;
+				for (x = 0; x < cols; x ++)
+				{
+					if (col[x] == '') continue;
+					setTile(x, y, uint(col[x]));
+				}
+			}
+		}
+
+		/**
+		* Saves the Tilemap tile index data to a string.
+		* @param columnSep		The string that separates each tile value on a row, default is ",".
+		* @param rowSep			The string that separates each row of tiles, default is "\n".
+		*/
+		public function saveToString(columnSep:String = ",", rowSep:String = "\n"): String
+		{
+			var s:String = '',
+				x:int, y:int;
+			for (y = 0; y < _rows; y ++)
+			{
+				for (x = 0; x < _columns; x ++)
+				{
+					s += getTile(x, y);
+					if (x != _columns - 1) s += columnSep;
+				}
+				if (y != _rows - 1) s += rowSep;
+			}
+			return s;
+		}
+
+		/**
 		 * Gets the index of a tile, based on its column and row in the tileset.
 		 * @param	tilesColumn		Tileset column.
 		 * @param	tilesRow		Tileset row.


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

--- frameworks/projects/advancedgrids/src/mx/events/AdvancedDataGridEventReason.as
+++ frameworks/projects/advancedgrids/src/mx/events/AdvancedDataGridEventReason.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.events
 {


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

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


Transferred from the Adobe Open Source Subversion Repository

Revision: 19687
Author:   rfrishbe@adobe.com
Date:     2011-01-11T00:27:38.796212Z

Log Message:
-----------
Fix up setElementSize() in LabelItemRenderer when NaN is passed for a StyleableTextField.  This needs to be cleaned up more later.

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

Modified Paths:
--------------
/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/LabelItemRenderer.as

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

--- frameworks/projects/mobilecomponents/src/spark/components/LabelItemRenderer.as
+++ frameworks/projects/mobilecomponents/src/spark/components/LabelItemRenderer.as
@@ -1053,10 +1053,12 @@
 		if (element is StyleableTextField)
 		{
 			// take into account text gutters
-			element.width = width + StyleableTextField.TEXT_WIDTH_PADDING;
+            if (!isNaN(width))
+			    element.width = width + StyleableTextField.TEXT_WIDTH_PADDING;

 			// take into account textTopOffset and baselineBottomOffset
-			element.height = height + StyleableTextField(element).textTopOffset + StyleableTextField(element).baselineBottomOffset;
+            if (!isNaN(height))
+			    element.height = height + StyleableTextField(element).textTopOffset + StyleableTextField(element).baselineBottomOffset;
 		}
 		else if (element is ILayoutElement)
         {


Transferred from the Adobe Open Source Subversion Repository

Revision: 18641
Author:   chiedozi@adobe.com
Date:     2010-11-17T01:26:13.734827Z

Log Message:
-----------
Updated MobileApplication api names.

MobileApplicationBase
backKeyHandler renamed to backKeyUpHandler
menuKeyHandler renamed to menuKeyUpHandler
sessionCachingEnabled renamed to persistNavigatorState
persistApplicationState() renamed to saveNavigatorState
restoreApplicationSate() renamed to loadNavigatorState
registerPersistenceClassAliases removed
nativeApplication_invokeHandler() renamed to invokeHandler()
nativeApplication_deactivateHandler() renamed to deactivateHandler()

PersistenceManager
flush() renamed to save() and return success boolean
initialize() renamed to load() and return success boolean
The applicationVersion shared object property was renamed to versionNumber.

View
deserializePersistedData() renamed to deserializeData()

ViewNavigatorBase
restoreViewData() renamed loadViewData()

Events
APPLICATION_PERSIST and APPLICATION_RESTORE removed from the framework
APPLICATION_PERSISTING renamed to NAVIGATOR_STATE_SAVING
APPLICATION_RESTORING renamed to NAVIGATOR_STATE_LOADING

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

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/TabbedViewNavigator.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/core/managers/IPersistenceManager.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/View.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ViewNavigatorBase.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>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/events/FlexEvent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/ViewNavigator.as</path>

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

--- frameworks/projects/mobilecomponents/src/spark/managers/IPersistenceManager.as
+++ frameworks/projects/mobilecomponents/src/spark/managers/IPersistenceManager.as
@@ -52,7 +52,7 @@
      *  @playerversion AIR 2.5
      *  @productversion Flex 4.5
      */
-    function flush():void;
+    function save():Boolean;

     /**
      *  Initializes the persistence manager.
@@ -62,7 +62,7 @@
      *  @playerversion AIR 2.5
      *  @productversion Flex 4.5
      */
-    function initialize():void;
+    function load():Boolean;

     /**
      *  Returns the value of a property stored in the persistence manager.


Transferred from the Adobe Open Source Subversion Repository

Revision: 20292
Author:   smgilson@adobe.com
Date:     2011-02-11T16:53:14.813687Z

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

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

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/RichEditableText.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/ScrollBarBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/styles/metadata/AdvancedNonInheritingTextStyles.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/IconItemRenderer.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/List.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/layouts/supportClasses/LayoutBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/airspark/src/spark/components/WindowedApplication.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/ListBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/airspark/src/spark/components/Window.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/SkinnableDataContainer.as</path>

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

--- frameworks/projects/spark/src/spark/components/supportClasses/ScrollBarBase.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/ScrollBarBase.as
@@ -911,6 +911,8 @@
      *  The delay before repetition begins and the delay between repeated events
      *  are determined by the repeatDelay and
      *  repeatInterval styles of the underlying Button objects.
+     *
+     *  @param event The event object.
      *
      *  @see spark.components.Button
      *
@@ -968,6 +970,8 @@
      *  Handles releasing the increment or decrement button of the scrollbar.
      *  This ends the stepping operation started by the original buttonDown
      *  event on the button.
+     *
+     *  @param event The event object.
      *
      *  @see spark.components.Button
      *


Transferred from the Adobe Open Source Subversion Repository

Revision: 4003
Author:   smgilson@adobe.com
Date:     2008-11-03T23:04:25.563105Z

Log Message:
-----------
Fix HTML in ASDoc comment

QE Notes: None
Doc Notes: None
Bugs: -

Modified Paths:
--------------
/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/FxScrollBar.as

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

--- frameworks/projects/spark/src/spark/components/supportClasses/ScrollBarBase.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/ScrollBarBase.as
@@ -207,7 +207,7 @@
      *  keep their pageSize, maximum, and value properties in sync with the
      *  viewport.   Similarly, they override their page and step methods to
      *  use the viewport's scrollPositionDelta methods to compute page and
-     *  and step offsets.

+     *  and step offsets.

      *
      *  @default null
      *  @see mx.components.FxVScrollBar


Transferred from the Adobe Open Source Subversion Repository

Revision: 5925
Author:   gruehle@adobe.com
Date:     2009-04-03T23:32:32.942708Z

Log Message:
-----------
A bunch of skin related work items and bug fixes.

Bugs:
SDK-19961 - The ControlBar default contentBackgroundColor in its Spark skin needs to be updated.
SDK-19659 - Indeterminate Halo ProgressBar with Gumbo skin draws over the border
SDK-19823 - Halo HSlider and VSlider with Gumbo skins dont look right when specifying track highlight
SDK-19767 - Halo ColorPicker with Spark skin draws stray lines when setting larger width/height
SDK-19764 - enabled and disabled Halo ColorPicker control with Gumbo skins look inconsistent
SDK-20152 - Spark FxPanel container doesnt look very wireframey
SDK-19591 - If you compile FxButtonBar with the wireframe skin, it does not use Wireframe FxToggleButtons
SDK-20151 - wireframe FxList skin item selection highlight looks inconsistent with Spark skins
SDK-20153 - scrollbar position on wireframe FxTextArea skin is inconsistent with scrollbar position on spark FxTextArea skin
SDK-19955 - Spark FxCheckBox skin includes reference to unused namespace, "geom"

Modified Paths:
--------------
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/ButtonBarFirstButtonSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/sparkskins/src/mx/skins/spark/PanelBorderSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/wireframe/src/WireframeClasses.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/sparkskins/src/mx/skins/spark/SliderTrackHighlightSkin.mxml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/ButtonBarMiddleButtonSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/ListSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/TextAreaSkin.mxml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/sparkskins/src/mx/skins/spark/ProgressIndeterminateSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/wireframe/defaults.css</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/sparkskins/src/mx/skins/spark/ProgressMaskSkin.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/ButtonBarLastButtonSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/sparkskins/src/SparkSkinsClasses.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/sparkskins/src/mx/skins/spark/ColorPickerSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/default/CheckBoxSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/defaults.css</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/PanelSkin.mxml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/ButtonBarSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/default/PanelSkin.mxml</path>

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


passed test for attempting to resolve unregistered types

--- src/asfac.tests/src/com/thedevstop/asfac/AsFactory.as
+++ src/asfac.tests/src/com/thedevstop/asfac/AsFactory.as
@@ -35,7 +35,10 @@

 		public function resolve(type:Class):*
 		{
-			return _registrations[type]();
+			if (_registrations[type] !== undefined)
+				return _registrations[type]();
+
+			return resolveByClass(type);
 		}

 		private function resolveByClass(type:Class):*


Transferred from the Adobe Open Source Subversion Repository

Revision: 5097
Author:   gauravj@adobe.com
Date:     2009-02-27T02:06:23.424936Z

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

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

Modified Paths:
--------------
<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/airframework/src/mx/controls/fileSystemClasses/FileSystemTreeDataDescriptor.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/airframework/src/mx/controls/FileSystemEnumerationMode.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/FileSystemHistoryButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/FileSystemTree.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/flash-integration/src/mx/flash/FlexContentHolder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/utils/DirectoryEnumeration.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flash-integration/src/mx/flash/ContainerMovieClip.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/FileSystemComboBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/utils/DirectoryEnumerationMode.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/events/AIREvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/FileSystemList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/windowClasses/StatusBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/events/FileEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/events/WindowExistenceEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/FileSystemDataGrid.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/skins/halo/ApplicationTitleBarBackgroundSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/fileSystemClasses/FileSystemControlHelper.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/WindowedApplication.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/NativeDragManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/events/FlexNativeMenuEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/WindowedSystemRawChildrenList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/skins/halo/WindowMinimizeButtonSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/skins/halo/WindowRestoreButtonSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/skins/halo/WindowMaximizeButtonSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/skins/halo/StatusBarBackgroundSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/IWindow.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/FileSystemSizeDisplayMode.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/WindowedSystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/events/FlexNativeWindowBoundsEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/skins/halo/WindowBackground.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/windowClasses/TitleBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/WindowedSystemChildrenList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/skins/halo/WindowCloseButtonSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/FlexNativeMenu.as</path>

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

--- frameworks/projects/airframework/src/mx/skins/halo/WindowRestoreButtonSkin.as
+++ frameworks/projects/airframework/src/mx/skins/halo/WindowRestoreButtonSkin.as
@@ -22,6 +22,10 @@
  *  The skin for the restore button in the TitleBar
  *  of a WindowedApplication or Window.
  *
+ *
+ *  @langversion 3.0
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 public class WindowRestoreButtonSkin extends UIComponent
 {
@@ -50,6 +54,10 @@

     /**
      *  Constructor.
+     *
+     *  @langversion 3.0
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public function WindowRestoreButtonSkin()
     {


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

--- frameworks/projects/mx/src/mx/effects/effectClasses/AddChildActionInstance.as
+++ frameworks/projects/mx/src/mx/effects/effectClasses/AddChildActionInstance.as
@@ -23,6 +23,11 @@
  *  an AddChildAction effect; you do not create one yourself.
  *
  *  @see mx.effects.AddChildAction
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 public class AddChildActionInstance extends ActionEffectInstance
 {
@@ -38,6 +43,11 @@
 	 *  Constructor.
 	 *
 	 *  @param target The Object to animate with this effect.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	public function AddChildActionInstance(target:Object)
 	{
@@ -56,6 +66,11 @@

 	/**
 	 *  The index of the child within the parent.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	public var index:int = -1;

@@ -65,6 +80,11 @@

 	/**
 	 *  The location where the child component is added.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	public var relativeTo:DisplayObjectContainer;

@@ -74,6 +94,11 @@

 	/**
 	 *  The position of the child component, relative to relativeTo, where it is added.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	public var position:String;


According to spec: http://xmpp.org/extensions/xep-0048.html#format-url Please note that the order of the constructor parameters have changed.

--- src/org/igniterealtime/xiff/bookmark/UrlBookmark.as
+++ src/org/igniterealtime/xiff/bookmark/UrlBookmark.as
@@ -29,39 +29,46 @@
 	import org.igniterealtime.xiff.data.ISerializable;
 	import org.igniterealtime.xiff.data.XMLStanza;

+	/**
+	 * The url element is designed for bookmarking web pages,
+	 * i.e., HTTP or HTTPS URLs.
+	 *
+	 * @see http://xmpp.org/extensions/xep-0048.html#format-url
+	 */
 	public class UrlBookmark extends XMLStanza implements ISerializable
 	{
 		public static const ELEMENT_NAME:String = "url";

 		/**
+		 * Bookmark an url.
 		 *
-		 * @param	name
-		 * @param	url
+		 * @param	url REQUIRED
+		 * @param	name RECOMMENDED
 		 */
-		public function UrlBookmark( name:String = null, url:String = null )
+		public function UrlBookmark( url:String, name:String = null )
 		{
-			if ( !name && !url )
+			xml.setLocalName( ELEMENT_NAME );
+			if (name != null)
 			{
-				return;
+				xml.@name = name;
 			}
-			else if ( !name || !url )
-			{
-				throw new Error( "Name and url cannot be null, they must either both be null or an Object" );
-			}
-
-			xml.setLocalName( ELEMENT_NAME );
-			xml.@name = name;
 			xml.@url = url;
 		}

+		/**
+		 * A friendly name for the bookmark.
+		 */
 		public function get name():String
 		{
 			return xml.@name;
 		}

+		/**
+		 * The HTTP or HTTPS URL of the web page.
+		 */
 		public function get url():String
 		{
-			return xml.@uri;
+			return xml.@url;
 		}
 	}
 }


283 Fixing possible bug in the flash_proxy loop iteration, which could have been exposed if a for each...in loop was terminated early. Values are now enumerated when nextNameIndex() is passed 0

--- raw/src/org/yellcorp/lib/core/Set.as
+++ raw/src/org/yellcorp/lib/core/Set.as
@@ -21,6 +21,8 @@
     private var dict:Dictionary;
     private var _length:uint;

+    private var _currentLoop:Array;
+
     /**
      * Creates a new Set.
      *
@@ -303,8 +305,6 @@
     }

     // proxy implementation
-    private var _currentIteration:Array;
-
     /**
      * @private
      */
@@ -312,11 +312,14 @@
     {
         if (index < _length)
         {
+            if (index == 0)
+            {
+                _currentLoop = toArray();
+            }
             return index + 1;
         }
         else
         {
-            _currentIteration = null;
             return 0;
         }
     }
@@ -326,8 +329,7 @@
      */
     override flash_proxy function nextValue(index:int):*
     {
-        if (!_currentIteration) _currentIteration = toArray();
-        return _currentIteration[index - 1];
+        return _currentLoop[index - 1];
     }

     /**


HGIMG3ヘッダの更新

HGIMG3ヘッダの更新

git-svn-id: 667ccd08e5f160307f6512a0947301cac150914e@571 ceb3ebad-0e53-d446-8596-a45b2b8d79cd

--- package/win32/common/hgimg3.as
+++ package/win32/common/hgimg3.as
@@ -101,6 +101,9 @@
 #define global SYSREQ_OBAQMATBUF 28
 #define global SYSREQ_2DFILTER2 29
 #define global SYSREQ_FPUPRESERVE 30
+#define global SYSREQ_DSSOFTWARE 31
+#define global SYSREQ_DSGLOBAL 32
+#define global SYSREQ_DSBUFSEC 33
 #define global SYSREQ_DEBUG $10000

 #define event_delobj(%1) event_prmset %1,PRMSET_FLAG,0


Transferred from the Adobe Open Source Subversion Repository

Revision: 18108
Author:   rfrishbe@adobe.com
Date:     2010-10-08T21:02:39.884361Z

Log Message:
-----------
Adding a 500 ms delay to when we load images from MobileIconItemRenderer.  This means while scrolling around, we don't always load the images.  It requires the item renderer to be on-screen and visible for 500 ms before we load it up.

I will file some other enhancements around this issue, like letting the 500 ms value be customizable and to look at Flash Player load cancellation to make sure we are doing that correctly.

This change gives us a pretty big performance boost while scrolling, especially in the non-cached case.

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

Modified Paths:
--------------
/private/flex/sdk/branches/hero_private/frameworks/projects/mobilecomponents/src/spark/components/MobileIconItemRenderer.as

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

--- frameworks/projects/mobilecomponents/src/spark/components/IconItemRenderer.as
+++ frameworks/projects/mobilecomponents/src/spark/components/IconItemRenderer.as
@@ -130,6 +130,12 @@
      */
     static mx_internal var _imageCache:ContentCache;

+    /**
+     *  @private
+     *  Time to wait before setting the source on the iconDisplay and causing a load()
+     */
+    private static const ICON_DELAY_TIME:int = 500;
+
     //--------------------------------------------------------------------------
     //
     //  Constructor
@@ -150,6 +156,7 @@

         if (_imageCache == null) {
             _imageCache = new ContentCache();
+            _imageCache.enableCaching = true;
             _imageCache.maxCacheEntries = 100;
         }
     }
@@ -216,6 +223,18 @@
      *  its display object
      */
     private var iconNeedsDisplayObjectAssignment:Boolean = false;
+
+    /**
+     *  @private
+     *  Timer, used to delay setting the source on the icon.
+     */
+    private var iconSetterDelayTimer:Timer;
+
+    /**
+     *  @private
+     *  The source to set iconDisplay to, after waiting an appropriate delay period
+     */
+    private var loadingIconSource:Object;

     //--------------------------------------------------------------------------
     //
@@ -1197,10 +1216,15 @@
         {
             iconChanged = false;

+            // we set the icon after a delay for performance benefits and
+            // so we can cancel the load if we're scrolling fast
+            // we still grab the source here so we can make sure we don't
+            // cancel a load when the data is reset (if the source is the same)
             // if icon, try setting that
+
             if (iconFunction != null)
             {
-                iconDisplay.source = iconFunction(data);
+                setIconDisplaySource(iconFunction(data));
             }
             else if (iconField)
             {
@@ -1208,12 +1232,12 @@
                 {
                     if (iconField in data)
                     {
-                        iconDisplay.source = data[iconField];
+                        setIconDisplaySource(data[iconField]);
                     }
                 }
                 catch(e:Error)
                 {
-                    iconDisplay.source = null;
+                    setIconDisplaySource(null);
                 }
             }
         }
@@ -1377,6 +1401,66 @@
     /**
      *  @private
      */
+    private function setIconDisplaySource(source:Object):void
+    {
+        // if null, do it synchronously
+        if (source == null)
+            iconDisplay.source = null;
+
+        // don't cancel this load--let it continue if it's the same source
+        if (loadingIconSource == source)
+            return;
+
+        // check the cache first:
+        var contentCache:ContentCache = iconContentLoader as ContentCache;
+        if (contentCache)
+        {
+            if (contentCache.getCacheEntry(source))
+            {
+                iconDisplay.source = source;
+                return;
+            }
+        }
+
+        // otherwise, we need to rely on the timer
+        if (!iconSetterDelayTimer)
+        {
+            iconSetterDelayTimer = new Timer(ICON_DELAY_TIME, 1);
+            iconSetterDelayTimer.addEventListener(TimerEvent.TIMER_COMPLETE, iconSetterDelayTimer_timerCompleteHandler);
+        }
+        else
+        {
+            iconSetterDelayTimer.stop();
+            iconSetterDelayTimer.reset();
+        }
+
+        // this is so we don't display the old data while we're loading
+        // FIXME (rfrishbe): perhaps we should add an iconLoadingAsset (must be embedded) property?
+        iconDisplay.source = null;
+        loadingIconSource = source;
+
+        iconSetterDelayTimer.start();
+    }
+
+    /**
+     *  @private
+     */
+    private function iconSetterDelayTimer_timerCompleteHandler(event:TimerEvent):void
+    {
+        // if we're off-screen, don't do anything
+        // when we get re-included, our data will be reset as well
+        if (!includeInLayout)
+            return;
+
+        if (iconDisplay)
+            iconDisplay.source = loadingIconSource;
+
+        loadingIconSource = null;
+    }
+
+    /**
+     *  @private
+     */
     override public function validateSize(recursive:Boolean = false):void
     {
         // Since IGraphicElement is not ILayoutManagerClient, we need to make sure we


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

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

 package spark.effects.supportClasses
 {


Fixing bug where reserved bits were ignored when the connection should have been failed.

--- AS3WebSocket/src/com/worlize/websocket/WebSocket.as
+++ AS3WebSocket/src/com/worlize/websocket/WebSocket.as
@@ -422,6 +422,12 @@
 			var event:WebSocketEvent;
 			var i:int;
 			var currentFrame:WebSocketFrame;
+
+			if (frame.rsv1 || frame.rsv2 || frame.rsv3) {
+				drop(WebSocketCloseStatus.PROTOCOL_ERROR,
+					 "Received frame with reserved bit set without a negotiated extension.");
+				return;
+			}

 			switch (frame.opcode) {
 				case WebSocketOpcode.BINARY_FRAME:


added comment

added comment

Change-Id: I6b49330417950c8894561f41824a21b43943ebb6

--- WeaveData/src/weave/data/ProjectionManager.as
+++ WeaveData/src/weave/data/ProjectionManager.as
@@ -221,8 +221,11 @@
 			var xMax:Number = bounds.xMax;
 			var yMin:Number = bounds.yMin;
 			var yMax:Number = bounds.yMax;
-			var projector:IProjector = getProjector(sourceSRS, destinationSRS); // fast projectsion
-
+			var projector:IProjector = getProjector(sourceSRS, destinationSRS); // fast projection
+
+			// NOTE: We can't just reproject the coordinates around the edges because the edges may include
+			// invalid coordinates and then we would miss the valid coordinates in the middle of the bounds.
+
 			// reproject points along the edges and zig zag inside
 			// o--o--o--o--o
 			// |  |  |  |  |


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

--- frameworks/projects/spark_dmv/src/mx/controls/advancedDataGridClasses/FTEAdvancedDataGridItemRenderer.as
+++ frameworks/projects/spark_dmv/src/mx/controls/advancedDataGridClasses/FTEAdvancedDataGridItemRenderer.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.controls.advancedDataGridClasses
 {


Change the nature and label of the export buttons based on combined setting.

--- exporter/src/main/as/flump/export/ProjectController.as
+++ exporter/src/main/as/flump/export/ProjectController.as
@@ -294,6 +294,16 @@
         }
         _win.formatOverview.text = formatNames.join(", ");

+        var hasCombined :Boolean = false;
+        for each (var exportConf :ExportConf in _conf.exports) {
+            if (exportConf.combine) {
+                hasCombined = true;
+                break;
+            }
+        }
+        _win.exportAll.label = hasCombined ? "Export Combined" : "Export All";
+        _win.exportModified.enabled = !hasCombined;
+
         updateWindowTitle();
     }


Transferred from the Adobe Open Source Subversion Repository

Revision: 6957
Author:   jimurphy@adobe.com
Date:     2009-05-15T16:11:59.737851Z

Log Message:
-----------
Merged beta1 revisions 6898,6906,6913,6915,6917,6926,6930 -> trunk

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/ImageHelper.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/Window.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Scroller.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/DropDownList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/TrackBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/VideoDisplay.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/StyleManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/VRule.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/supportClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/flash-integration/FlexComponentKit.mxp</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/fxg/swf/FXG2SWFTranscoder.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/NumericStepper.as</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/ShapeHelper.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/effects/AnimateTransform.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Container.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManager.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</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/framework/src/mx/controls/HRule.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ScrollControlBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/GlowFilterNode.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/WindowedApplication.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flash-integration/FlexComponentKit.mxi</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/TypeHelper.java</path>

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

--- frameworks/projects/mx/src/mx/controls/VideoDisplay.as
+++ frameworks/projects/mx/src/mx/controls/VideoDisplay.as
@@ -170,6 +170,8 @@
 [Event(name="stateChange", type="mx.events.VideoEvent")]

 [IconFile("VideoDisplay.png")]
+
+[Alternative(replacement="spark.components.VideoPlayer", since="4.0")]

 /**
  *  The VideoDisplay control lets you play an FLV file in a Flex application.


Transferred from the Adobe Open Source Subversion Repository

Revision: 19631
Author:   hmuller@adobe.com
Date:     2011-01-06T22:09:10.284970Z

Log Message:
-----------
Performance optimization for the DataGrid "Christmas Tree" scenario.   Revised Grid/invalidateCell(), added GridLayout/invalidateCell().

QE notes: One failing test was excluded, bitmap needs to be updated.
Doc notes:
Bugs:
Reviewer: Carol
Tests run: checkin, mustella
Is noteworthy for integration: yes

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

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

--- frameworks/projects/spark/src/spark/components/Grid.as
+++ frameworks/projects/spark/src/spark/components/Grid.as
@@ -1013,6 +1013,7 @@
         _itemRenderer = value;

         itemRendererChanged = true;
+        invalidateProperties();
         invalidateSize();
         invalidateDisplayList();

@@ -2971,9 +2972,9 @@

     /**
      *  Return the data provider indices and padding indices of the
-     *  currently visible rows.
-     *  Indices which are greater than or equal to the
-     *  dataProvider length represent padding rows.
+	 *  currently visible rows.
+	 *  Indices which are greater than or equal to the
+	 *  dataProvider length represent padding rows.
      *  Note that the item renderers for the first and last rows
      *  may only be partially visible.
      *  The returned vector's contents are in the order they're displayed.
@@ -3599,7 +3600,7 @@
      *
      *  @param rowIndex The 0-based row index of the cell that changed, or -1.
      *
-     *  @param column Index The 0-based column index of the cell that changed or -1.
+     *  @param columnIndex The 0-based column index of the cell that changed or -1.
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -3609,38 +3610,50 @@
     public function invalidateCell(rowIndex:int, columnIndex:int):void
     {
         if (!dataProvider)
-            return;
-
-        const dataProviderLength:int = dataProvider.length;
-        if (rowIndex >= dataProvider.length)
-            return;
-
-        if (!isCellVisible(rowIndex, columnIndex))
-            return;
-
-        // TODO (hmuller) this is a provisional implementation: invalidate the entire row
-
-        const column:GridColumn = getGridColumn(columnIndex);
-        const dataField:String = (column) ? column.dataField : null;
-
-        if (rowIndex >= 0)
-        {
-            // invalidate the cell or the row by invalidating the visible row
-            dataProvider.itemUpdated(dataProvider.getItemAt(rowIndex), dataField);
-        }
-        else
-        {
-            // invaliate the column by invalidating all visible rows
-            const rowIndices:Vector.<int> = getVisibleRowIndices();
-            for each (rowIndex in rowIndices)
+			return;
+
+		const dataProviderLength:int = dataProvider.length;
+		if (rowIndex >= dataProvider.length)
+			return;
+
+		if (!isCellVisible(rowIndex, columnIndex))
+			return;
+
+        if (invalidateDisplayListFlag || invalidateSizeFlag)
+            return;
+
+		if ((rowIndex >= 0) && (columnIndex >= 0))
+		{
+            gridLayout.invalidateCell(rowIndex, columnIndex);
+		}
+        else if (rowIndex >= 0)  // invalidate a row
+        {
+            const visibleColumnIndices:Vector.<int> = getVisibleColumnIndices();
+            for each (var visibleColumnIndex:int in visibleColumnIndices)
             {
-                // If there are any padding rows, skip them.
-                if (rowIndex >= dataProviderLength)
+                gridLayout.invalidateCell(rowIndex, visibleColumnIndex);
+
+                // If invalidating the cell caused the entire grid to be invalid, punt
+                if (invalidateDisplayListFlag || invalidateSizeFlag)
+                    break;
+            }
+        }
+		else if (columnIndex >= 0)  // invalidate a column
+		{
+			const visibleRowIndices:Vector.<int> = getVisibleRowIndices();
+			for each (var visibleRowIndex:int in visibleRowIndices)
+			{
+				// If there are any padding rows, skip them.
+				if (visibleRowIndex >= dataProviderLength)
+					break;
+
+                gridLayout.invalidateCell(visibleRowIndex, columnIndex);
+
+                // If invalidating the cell caused the entire grid to be invalid, punt
+                if (invalidateDisplayListFlag || invalidateSizeFlag)
                     break;
-
-                dataProvider.itemUpdated(dataProvider.getItemAt(rowIndex), dataField);
-            }
-        }
+			}
+		}
     }

     /**


Transferred from the Adobe Open Source Subversion Repository

Revision: 14571
Author:   deeptika@adobe.com
Date:     2010-03-04T07:17:40.283901Z

Log Message:
-----------
Merging revision 14570 from 4.x branch
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/automation/src/mx/automation/delegates/core/UIComponentAutomationImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_air/src/mx/automation/delegates/controls/FlexNativeMenuAutomationImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation/src/mx/automation/delegates/controls/SWFLoaderAutomationImpl.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_spark/src/spark/automation/tabularData/SparkListBaseTabularData.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_spark/src/mx/automation/delegates/core/UIFTETextFieldAutomationImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation/src/mx/automation/delegates/core/UITextFieldAutomationImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_spark/src/spark/automation/delegates/components/supportClasses/SparkDropDownListBaseAutomationImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_dmv/src/mx/automation/delegates/advancedDataGrid/AdvancedDataGridAutomationImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_spark/src/spark/automation/delegates/components/supportClasses/SparkListBaseAutomationImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation/src/mx/automation/tabularData/OLAPDataGridTabularData.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation/src/mx/automation/codec/RendererPropertyCodec.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation/src/mx/automation/delegates/TextFieldAutomationHelper.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation/src/mx/automation/codec/AutomationObjectPropertyCodec.as</path>

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

--- frameworks/projects/automation/src/mx/automation/codec/RendererPropertyCodec.as
+++ frameworks/projects/automation/src/mx/automation/codec/RendererPropertyCodec.as
@@ -11,7 +11,7 @@

 package mx.automation.codec
 {
-
+	import mx.automation.Automation;
 	import mx.automation.AutomationClass;
 	import mx.automation.AutomationIDPart;
 	import mx.automation.IAutomationClass;
@@ -133,7 +133,7 @@
 							"(" + ao[i].automationName + ")\n";
 					}

-					trace(message);
+					Automation.automationDebugTracer.traceMessage("RenderPropertyCodec","decode",message);
 				}

 				// we couldnot find the itemRenderer in the visible area


Transferred from the Adobe Open Source Subversion Repository

Revision: 22779
Author:   jszeto@adobe.com
Date:     2011-09-28T18:57:17.388322Z

Log Message:
-----------
SpinnerList RTE bug fix

SDK-31670 - Throwing a SpinnerList with no dataProvider causes an RTE

Add null check

QE notes: none
Doc notes: none
Bugs: SDK-31670
Reviewer: Tom K
Tests run: checkintests, cyclone
Is noteworthy for integration: no

Modified Paths:
--------------
/private/flex/sdk/branches/4.y/frameworks/projects/mobilecomponents/src/spark/layouts/VerticalSpinnerLayout.as

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

--- frameworks/projects/mobilecomponents/src/spark/layouts/VerticalSpinnerLayout.as
+++ frameworks/projects/mobilecomponents/src/spark/layouts/VerticalSpinnerLayout.as
@@ -376,7 +376,7 @@
 		// If the element at index % numElements) is not selectable, find the nearest one that is
         var iter:LayoutIterator = new LayoutIterator(target, startIndex);

-        if (dataGroup)
+        if (dataGroup && dataGroup.dataProvider)
         {
             while (Math.abs(distance) <= (target.numElements / 2) + 1)
             {


Transferred from the Adobe Open Source Subversion Repository

Revision: 3047
Author:   gruehle@adobe.com
Date:     2008-08-29T22:18:20.601349Z

Log Message:
-----------
Checking in for Jason.

This is the big display object sharing optimization for Group. Adjacent graphic elements that do not require their own display object now draw into a common shared display object.

There should be no functionality changes. The only exception is masks on graphic elements are broken. If you find any other functional differences, please file a bug.

The changes have been cycloned by the SDK QE and Thermo.

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/Path.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/Ellipse.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/Rect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/IDisplayObjectElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/core/Group.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/StrokedElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/graphicsClasses/GraphicElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/Line.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/FilledElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/BitmapGraphic.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/flex/graphics/graphicsClasses/TextGraphicElement.as</path>

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

--- frameworks/projects/spark/src/spark/primitives/supportClasses/GraphicElement.as
+++ frameworks/projects/spark/src/spark/primitives/supportClasses/GraphicElement.as
@@ -3,9 +3,7 @@
 import flash.display.BitmapData;
 import flash.display.BlendMode;
 import flash.display.DisplayObject;
-import flash.display.Graphics;
 import flash.display.LineScaleMode;
-import flash.display.Shape;
 import flash.display.Sprite;
 import flash.events.Event;
 import flash.events.EventDispatcher;
@@ -13,7 +11,6 @@
 import flash.geom.ColorTransform;
 import flash.geom.Matrix;
 import flash.geom.Point;
-import flash.geom.Rectangle;
 import flash.geom.Transform;

 import flex.geom.Transform;
@@ -26,8 +23,8 @@

 import mx.core.IConstraintClient;
 import mx.core.IInvalidating;
+import mx.core.UIComponentGlobals;
 import mx.core.mx_internal;
-import mx.core.UIComponentGlobals;
 import mx.events.FlexEvent;
 import mx.events.PropertyChangeEvent;
 import mx.events.PropertyChangeEventKind;
@@ -35,6 +32,7 @@
 import mx.filters.IBitmapFilter;
 import mx.graphics.IStroke;
 import mx.managers.ILayoutManagerClient;
+import flash.display.Shape;

 use namespace mx_internal;

@@ -1467,10 +1465,7 @@

     //----------------------------------
     //  x
-    //----------------------------------
-
-    // TODO!!! Change to NaN and integrate Rect/Ellipse bounds/draw functions
-
+    //----------------------------------
     /**
      *  @private
      *  Storage for the x property.
@@ -1513,10 +1508,7 @@

     //----------------------------------
     //  y
-    //----------------------------------
-
-    // TODO!!! Change to NaN and integrate Rect/Ellipse bounds/draw functions
-
+    //----------------------------------
     /**
      *  @private
      *  Storage for the y property.
@@ -1704,6 +1696,34 @@
     }

     //----------------------------------
+    //  drawX
+    //----------------------------------
+
+    /**
+     *  The x-position where the element should be drawn
+     */
+    protected function get drawX():Number
+    {
+    	// Draw position depends upon which coordinate space we are located in.
+    	// TODO!!! We need to apply all of the transforms of our ancestors
+        return displayObject ? 0 : sharedDisplayObject && sharedDisplayObject != elementHost ? x - sharedDisplayObject.x : x;
+    }
+
+    //----------------------------------
+    //  drawY
+    //----------------------------------
+
+    /**
+     *  The y-position where the element should be drawn
+     */
+    protected function get drawY():Number
+    {
+    	// Draw position depends upon which coordinate space we are located in.
+    	// TODO!!! We need to apply all of the transforms of our ancestors
+        return displayObject ? 0 : sharedDisplayObject && sharedDisplayObject != elementHost ? y - sharedDisplayObject.y : y;
+    }
+
+    //----------------------------------
     //  includeInLayout
     //----------------------------------

@@ -1813,13 +1833,56 @@
         else
             return new Sprite();
     }
-
-    /**
-     *  Documentation is not currently available.
-     */
-    public function needsDisplayObject():Boolean
-    {
-        return true;
+
+
+    public function destroyDisplayObject():void
+    {
+    	// TODO!! Figure out what cleanup to do
+    	if (displayObject)
+    	{
+	    	if (displayObject.parent)
+				displayObject.parent.removeChild(displayObject);
+			displayObject = null;
+    	}
+    }
+
+    /**
+     *  Documentation is not currently available.
+     */
+    public function get needsDisplayObject():Boolean
+    {
+    	if ((_filters && _filters.length > 0) ||
+    		_blendMode != BlendMode.NORMAL || _mask ||
+    		_scaleX != 1 || _scaleY != 1 ||
+    		_rotation != 0 || _alpha != 1 || _transform ||
+    		_transformX != 0 || _transformY != 0)
+    	{
+			return true;
+    	}
+    	else
+    		return false;
+    }
+
+    public function get nextSiblingNeedsDisplayObject():Boolean
+    {
+    	return needsDisplayObject;
+    }
+
+    private var _sharedDisplayObject:DisplayObject;
+
+    public function set sharedDisplayObject(value:DisplayObject):void
+    {
+    	_sharedDisplayObject = value;
+    }
+
+    public function get sharedDisplayObject():DisplayObject
+    {
+    	return _sharedDisplayObject;
+    }
+
+    protected function get drawnDisplayObject():DisplayObject
+    {
+    	return displayObject ? displayObject : sharedDisplayObject;
     }

     /**
@@ -1835,7 +1898,21 @@
         var oldPos:Point = actualPosition;

         setActualPosition(0, 0);
-        bitmapData.draw(displayObject, displayObject.transform.matrix);
+        if (displayObject && nextSiblingNeedsDisplayObject)
+        	bitmapData.draw(displayObject, displayObject.transform.matrix);
+		else
+		{
+			var oldDisplayObject:DisplayObject = displayObject;
+			displayObject = new Sprite();
+			invalidateDisplayList();
+			validateDisplayList();
+
+			bitmapData.draw(displayObject);
+
+			displayObject = oldDisplayObject;
+
+		}
+
         setActualPosition(oldPos.x, oldPos.y);

         return bitmapData;
@@ -2056,6 +2133,7 @@
      */
     protected function commitProperties():void
     {
+    	//trace("GraphicElement.commitProperties displayObject",displayObject,"this",this);
         if (displayObject)
         {
             if (alphaChanged)
@@ -2231,8 +2309,11 @@
      */
     public function validateDisplayList():void
     {
-        if (!invalidateDisplayListFlag)
-            return;
+    	// TODO!!! Turn this off for now because we need to clear all of the DisplayObject
+    	// graphics and thus need to redraw each graphic element
+    	// Put this back in once we implement drawingAPI2
+        /* if (!invalidateDisplayListFlag)
+            return; */
         invalidateDisplayListFlag = false;

         updateDisplayList(_width, _height);
@@ -2259,7 +2340,7 @@
      *  @param unscaledWidth Specifies the width of the component, in pixels,
      *  in the component's coordinates, regardless of the value of the
      *  scaleX property of the component.
-     *
+
      *  @param unscaledHeight Specifies the height of the component, in pixels,
      *  in the component's coordinates, regardless of the value of the
      *  scaleY property of the component.
@@ -2348,6 +2429,7 @@
      */
     public function setActualPosition(x:Number, y:Number):void
     {
+    	//trace("GraphicElement.setActualPosition x",x,"y",y,"this",this);
         x -= measuredX;
         y -= measuredY;

@@ -2373,9 +2455,26 @@
         y += strokeExtents.y * 0.5;

         // Finally commit x & y property changes:
-        _x = x;
-        _y = y;
-        commitXY();
+        var doCommit:Boolean = false;
+        if (_x != x)
+        {
+        	_x = x;
+        	doCommit = true;
+        }
+
+        if (_y != y)
+        {
+        	_y = y;
+        	doCommit = true;
+        }
+
+        if (doCommit)
+        {
+        	if (displayObject)
+        		commitXY();
+        	else
+        		invalidateDisplayList();
+        }
     }

     /**


Transferred from the Adobe Open Source Subversion Repository

Revision: 9213
Author:   jszeto@adobe.com
Date:     2009-08-11T00:29:10.884707Z

Log Message:
-----------
Adding missing ASDoc comments to GraphicElement

QE notes: None
Doc notes: Review ASDoc comment additions
Bugs: FLEXDOCS-531
Reviewer: none
Tests run: none
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/supportClasses/GraphicElement.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/spark/src/spark/primitives/supportClasses/StrokedElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/AdvancedLayoutFeatures.as</path>

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

--- frameworks/projects/spark/src/spark/primitives/supportClasses/StrokedElement.as
+++ frameworks/projects/spark/src/spark/primitives/supportClasses/StrokedElement.as
@@ -222,6 +222,9 @@
         g.endFill();
     }

+    /**
+     *  @private
+     */
     override protected function getStrokeExtents(postLayoutTransform:Boolean = true):Point
     {
         // FIXME (egeorgie): currently we take only scale into account,


Transferred from the Adobe Open Source Subversion Repository

Revision: 1686
Author:   jimurphy@adobe.com
Date:     2008-05-13T19:12:45.745206Z

Log Message:
-----------
Merged 3.0.x revisions [1673,1676] -> trunk

Modified Paths:
--------------
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UITextField.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@1260047 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/core/UITextField.as
+++ frameworks/projects/framework/src/mx/core/UITextField.as
@@ -679,15 +679,12 @@

     /**
      *  Number that specifies the maximum height of the component,
-     *  in pixels, in the component's coordinates.
-     *
-     *
This value is used by the container in calculating the size
-     *  and position of the component.
-     *  It is not used by the component itself in determining its default size.
-     *  Thus this property may not have any effect if parented by Container,
-     *  or containers that don't factor in this property.
-     *  Because the value is in component coordinates, the true maxHeight
-     *  with respect to its parent is affected by the scaleY property.

+     *  in pixels, in the component's coordinates, if the maxHeight property
+     *  is set. Because maxHeight is read-only, this method returns NaN.
+     *  You must override this method and add a setter to use this
+     *  property.
+     *
+     *  @see mx.core.UIComponent#explicitMaxHeight
      *
      *  @default NaN
      */
@@ -702,15 +699,12 @@

     /**
      *  Number that specifies the maximum width of the component,
-     *  in pixels, in the component's coordinates.
-     *
-     *
This value is used by the container in calculating the size
-     *  and position of the component.
-     *  It is not used by the component itself in determining its default size.
-     *  Thus this property may not have any effect if parented by Container,
-     *  or containers that don't factor in this property.
-     *  Because the value is in component coordinates, the true maxWidth
-     *  with respect to its parent is affected by the scaleX property.

+     *  in pixels, in the component's coordinates, if the maxWidth property
+     *  is set. Because maxWidth is read-only, this method returns NaN.
+     *  You must override this method and add a setter to use this
+     *  property.
+     *
+     *  @see mx.core.UIComponent#explicitMaxWidth
      *
      *  @default NaN
      */


Transferred from the Adobe Open Source Subversion Repository

Revision: 12333
Author:   egeorgie@adobe.com
Date:     2009-12-01T21:25:24.808652Z

Log Message:
-----------
Fix http://bugs.adobe.com/jira/browse/SDK-24407 setLayoutBoundsSize() sometimes incorrectly sets the width to 0

Fix: Make the floating point comparison with 0 account for precision loss.

QE notes: None
Doc notes: None
Bugs: SDK-24407
Reviewer: Deepa
Tests run: checkintests, mustella/tests/gumbo/layouts
Is noteworthy for integration: Yes

Modified Paths:
--------------
/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/MatrixUtil.as

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

--- frameworks/projects/framework/src/mx/utils/MatrixUtil.as
+++ frameworks/projects/framework/src/mx/utils/MatrixUtil.as
@@ -664,8 +664,14 @@
         //
         // Since we're matching height we only care about (2)

-        const b:Number = matrix.b;
-        const d:Number = matrix.d;
+        var b:Number = matrix.b;
+        var d:Number = matrix.d;
+
+        // If components are very close to zero, zero them out to handle the special cases
+        if (-1.0e-9 < b && b < +1.0e-9)
+            b = 0;
+        if (-1.0e-9 < d && d < +1.0e-9)
+            d = 0;

         // Handle special cases first
         if (b == 0)
@@ -827,8 +833,14 @@
         //
         // Since we're matching width we only care about (1)

-        const a:Number = matrix.a;
-        const c:Number = matrix.c;
+        var a:Number = matrix.a;
+        var c:Number = matrix.c;
+
+        // If components are very close to zero, zero them out to handle the special cases
+        if (-1.0e-9 < a && a < +1.0e-9)
+            a = 0;
+        if (-1.0e-9 < c && c < +1.0e-9)
+            c = 0;

         // Handle special cases first
         if (a == 0)
@@ -1125,10 +1137,20 @@
         // (2) h = abs( bx + d1y )
         //

-        const a:Number = matrix.a;
-        const b:Number = matrix.b;
-        const c:Number = matrix.c;
-        const d:Number = matrix.d;
+        var a:Number = matrix.a;
+        var b:Number = matrix.b;
+        var c:Number = matrix.c;
+        var d:Number = matrix.d;
+
+        // If components are very close to zero, zero them out to handle the special cases
+        if (-1.0e-9 < a && a < +1.0e-9)
+            a = 0;
+        if (-1.0e-9 < b && b < +1.0e-9)
+            b = 0;
+        if (-1.0e-9 < c && c < +1.0e-9)
+            c = 0;
+        if (-1.0e-9 < d && d < +1.0e-9)
+            d = 0;

         // Handle special cases.
         if (b == 0 && c == 0)
@@ -1147,7 +1169,7 @@
         {
             // No solution in the following cases since the matrix collapses
             // all points into a line.
-            if (b == 0 || c==0)
+            if (b == 0 || c == 0)
                return null;

             // (1) w = abs( ax + cy ) <=> w = abs( cy ) <=> w = abs(c)y


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

--- frameworks/projects/framework/src/mx/utils/ObjectUtil.as
+++ frameworks/projects/framework/src/mx/utils/ObjectUtil.as
@@ -1,11 +1,19 @@
 ////////////////////////////////////////////////////////////////////////////////
 //
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2005-2007 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.
 //
 ////////////////////////////////////////////////////////////////////////////////