Transferred from the Adobe Open Source Subversion Repository

Revision: 17055
Author:   cframpto@adobe.com
Date:     2010-07-24T13:07:46.799146Z

Log Message:
-----------
PARB changes for DataGrid selection from signoff review

missed renaming a method - setSelectedIndices(Vector.<int>) -> selectIndices(startRowIndex, endRowIndex)

https://zerowing.corp.adobe.com/display/flex/Data+Grid+Selection has been updated

QE notes: API changes so expect some test breakage
Doc notes:
Bugs:
Reviewer: Hans
Tests run: none
Is noteworthy for integration: no

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

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

--- frameworks/projects/spark/src/spark/components/Grid.as
+++ frameworks/projects/spark/src/spark/components/Grid.as
@@ -1776,15 +1776,15 @@
          *  mode ends when the selection is cleared using
          *  clearSelection or reset using one of
          *  setSelectedCell, setSelectedCells,
-         *  setSelectedIndex, setSelectedIndices.

+         *  setSelectedIndex, selectIndices.

          *
          *  @return True if the selection changed.
          *
          *  @see spark.components.Grid#clearSelection
+         *  @see spark.components.Grid#selectIndices
          *  @see spark.components.Grid#setSelectedCell
          *  @see spark.components.Grid#setSelectedCells
          *  @see spark.components.Grid#setSelectedIndex
-         *  @see spark.components.Grid#setSelectedIndices
          *
          *  @langversion 3.0
          *  @playerversion Flash 10
@@ -2026,7 +2026,7 @@
          *  @playerversion AIR 2.0
          *  @productversion Flex 4.5
          */
-        public function setSelectedIndices(startRowIndex:int, endRowIndex:int):Boolean
+        public function selectIndices(startRowIndex:int, endRowIndex:int):Boolean
         {
             const selectionChanged:Boolean =
                 gridSelection.setRows(startRowIndex, endRowIndex);


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

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


Transferred from the Adobe Open Source Subversion Repository

Revision: 19601
Author:   cframpto@adobe.com
Date:     2011-01-05T18:56:10.495840Z

Log Message:
-----------
Per Jacob, revert this piece of rev 19582.  I forgot about updating all the broken tests.

Modified Paths:
--------------
/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/primitives/Path.as

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

--- frameworks/projects/spark/src/spark/primitives/Path.as
+++ frameworks/projects/spark/src/spark/primitives/Path.as
@@ -1037,24 +1037,15 @@
         var sy:Number = naturalBounds.height == 0 ? 1 : height / naturalBounds.height;

         var origin:Point = new Point(drawX, drawY);
-        var bounds:Rectangle = new Rectangle(
-                                    drawX + measuredX * sx,
-                                    drawY + measuredY * sy,
-                                    width,
-                                    height);
+        var bounds:Rectangle = new Rectangle(drawX + measuredX * sx,
+            drawY + measuredY * sy,
+            width,
+            height);
         if (stroke)
-		{
-			var strokeBounds:Rectangle = getStrokeBounds();
-            // Objects drawn in shared display objects are drawn at x,y rather
-            // than 0,0 so need to move the strokeBounds if sharing.
-			strokeBounds.offsetPoint(origin);
-            stroke.apply(g, strokeBounds, origin);
-		}
+            stroke.apply(g, getStrokeBounds(), origin);
         else
-		{
             g.lineStyle();
-		}
-
+
         if (fill)
             fill.begin(g, bounds, origin);
     }


* fixed test compile error in XmlNode

* fixed test compile error in XmlNode

--- scripts/engine/xml/XmlNode.as
+++ scripts/engine/xml/XmlNode.as
@@ -23,7 +23,7 @@

 	public void setParent(XmlNode parent)
 	{
-		mParent = parent
+		mParent = parent;
 	}

 	public string getValue()


fixed documentation

fixed documentation

Change-Id: Ib4d213979d5ea847e69ba10d9deb84b9155aa97b

--- WeaveData/src/weave/data/BinningDefinitions/CustomSplitBinningDefinition.as
+++ WeaveData/src/weave/data/BinningDefinitions/CustomSplitBinningDefinition.as
@@ -50,9 +50,7 @@
 		public const splitValues:LinkableString = newLinkableChild(this, LinkableString);

 		/**
-		 * getBinClassifiersForColumn - implements IBinningDefinition Interface
-		 * @param column
-		 * @param output
+		 * @inheritDoc
 		 */
 		override public function generateBinClassifiersForColumn(column:IAttributeColumn):void
 		{


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

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

--- frameworks/projects/framework/src/mx/effects/effectClasses/CompositeEffectInstance.as
+++ frameworks/projects/framework/src/mx/effects/effectClasses/CompositeEffectInstance.as
@@ -0,0 +1,372 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2005-2007 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.effects.effectClasses
+{
+
+import flash.events.Event;
+import mx.core.mx_internal;
+import mx.effects.EffectInstance;
+import mx.effects.IEffectInstance;
+import mx.effects.Tween;
+import mx.events.EffectEvent;
+
+use namespace mx_internal;
+
+/**
+ *  The CompositeEffectInstance class implements the instance class
+ *  for the CompositeEffect class.
+ *  Flex creates an instance of this class  when it plays a CompositeEffect;
+ *  you do not create one yourself.
+ *
+ *  @see mx.effects.CompositeEffect
+ */
+public class CompositeEffectInstance extends EffectInstance
+{
+    include "../../core/Version.as";
+
+	//--------------------------------------------------------------------------
+	//
+	//  Constructor
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  Constructor.
+	 *
+	 *  @param target This argument is ignored for Composite effects.
+	 *  It is included only for consistency with other types of effects.
+	 */
+	public function CompositeEffectInstance(target:Object)
+	{
+		super(target);
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Variables
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 *  Internal queue of EffectInstances that are currently playing or waiting to be played.
+	 *  Used internally by subclasses.
+	 */
+	mx_internal var activeEffectQueue:Array /* of EffectInstance */ = [];
+
+	//--------------------------------------------------------------------------
+	//
+	//  Overridden properties
+	//
+	//--------------------------------------------------------------------------
+
+	//----------------------------------
+	//  actualDuration
+	//----------------------------------
+
+	/**
+	 *  @private
+	 *  Used internally to retrieve the actual duration,
+	 *  which includes startDelay, repeatCount, and repeatDelay.
+	 */
+	override mx_internal function get actualDuration():Number
+	{
+		var value:Number = NaN;
+
+		if (repeatCount > 0)
+		{
+			value = durationWithoutRepeat * repeatCount +
+					(repeatDelay * repeatCount - 1) + startDelay;
+		}
+
+		return value;
+	}
+
+	//----------------------------------
+	//  playheadTime
+	//----------------------------------
+
+	/**
+	 *  @private
+	 */
+	private var _playheadTime:Number = 0;
+
+	/**
+	 *  @private
+	 */
+	override public function get playheadTime():Number
+	{
+		return _playheadTime + super.playheadTime;
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Properties
+	//
+	//--------------------------------------------------------------------------
+
+	//----------------------------------
+	//  childSets
+	//----------------------------------
+
+	/**
+	 *  @private
+	 */
+	mx_internal var childSets:Array = [];
+
+	//----------------------------------
+	//  durationWithoutRepeat
+	//----------------------------------
+
+	/**
+	 *  @private
+	 *  Used internally to calculate the duration from the children effects
+	 *  for one repetition of this effect.
+	 */
+	mx_internal function get durationWithoutRepeat():Number
+	{
+		return 0;
+	}
+
+	//----------------------------------
+	//  endEffectCalled
+	//----------------------------------
+
+	/**
+	 *  @private
+	 */
+	mx_internal var endEffectCalled:Boolean;
+
+	//----------------------------------
+	//  timerTween
+	//----------------------------------
+
+	/**
+	 *  @private
+	 *  Used internally to obtain the playheadTime for the composite effect.
+	 */
+	mx_internal var timerTween:Tween;
+
+	//--------------------------------------------------------------------------
+	//
+	//  Overridden methods
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 */
+	override public function play():void
+	{
+		timerTween = new Tween(this,0,0,durationWithoutRepeat);
+
+		super.play();
+	}
+
+	/**
+	 *  @private
+	 */
+	override public function pause():void
+	{
+		super.pause();
+
+		if (timerTween)
+			timerTween.pause();
+	}
+
+	/**
+	 *  @private
+	 */
+	override public function stop():void
+	{
+		super.stop();
+
+		if (timerTween)
+			timerTween.stop();
+	}
+
+	/**
+	 *  @private
+	 */
+	override public function resume():void
+	{
+		super.resume();
+
+		if (timerTween)
+			timerTween.resume();
+	}
+
+	/**
+	 *  @private
+	 */
+	override public function reverse():void
+	{
+		super.reverse();
+
+		super.playReversed = !playReversed;
+
+		if (timerTween)
+			timerTween.reverse();
+	}
+
+	/**
+	 *  @private
+	 */
+	override public function finishEffect():void
+	{
+		activeEffectQueue = null;
+
+		super.finishEffect();
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Methods
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  Adds a new set of child effects to this Composite effect.
+	 *  A Sequence effect plays each child effect set one at a time,
+	 *  in the order that it is added.
+	 *  A Parallel effect plays all child effect sets simultaneously;
+	 *  the order in which they are added doesn't matter.
+	 *
+	 *  @param childSet Array of child effects to be added
+	 *  to the CompositeEffect.
+	 */
+	public function addChildSet(childSet:Array):void
+	{
+		if (childSet)
+		{
+			var n:int = childSet.length;
+			if (n > 0)
+			{
+				if (!childSets)
+					childSets = [ childSet ];
+				else
+					childSets.push(childSet);
+
+
+				for (var i:int = 0; i < n; i++)
+				{
+					childSet[i].addEventListener(EffectEvent.EFFECT_END,
+												 effectEndHandler);
+					childSet[i].mx_internal::parentCompositeEffectInstance =
+						this;
+				}
+			}
+		}
+	}
+
+	/**
+	 *  @private
+	 *  Check if we have a RotateInstance in one of our childSets array elements
+	 */
+	mx_internal function hasRotateInstance():Boolean
+	{
+		if (childSets)
+		{
+			for (var i:int = 0; i < childSets.length; i++)
+			{
+				if (childSets[i].length > 0)
+				{
+					var compChild:CompositeEffectInstance = childSets[i][0] as CompositeEffectInstance;
+
+					if (childSets[i][0] is RotateInstance || (compChild && compChild.hasRotateInstance()))
+					{
+						return true;
+					}
+				}
+			}
+		}
+
+		return false;
+	}
+
+	/**
+	 *  @private
+	 */
+	override mx_internal function playWithNoDuration():void
+	{
+		super.playWithNoDuration();
+		end();
+	}
+
+	/**
+	 *  Called each time one of the child effects has finished playing.
+	 *  Subclasses must implement this function.
+	 *
+	 *  @param The child effect.
+	 */
+	protected function onEffectEnd(childEffect:IEffectInstance):void
+	{
+		// Needs to be overridden
+	}
+
+	/**
+	 *  Used internally to keep track of the value of
+	 *  the playheadTime property.
+	 */
+	public function onTweenUpdate(value:Object):void
+	{
+		_playheadTime = timerTween ?
+						timerTween.mx_internal::playheadTime :
+						_playheadTime;
+	}
+
+	/**
+	 *  Used internally to keep track of the value of
+	 *  the playheadTime property.
+	 */
+	public function onTweenEnd(value:Object):void
+	{
+		_playheadTime = timerTween ?
+						timerTween.mx_internal::playheadTime :
+						_playheadTime;
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Overridden event handlers
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 */
+	override public function initEffect(event:Event):void
+	{
+		super.initEffect(event);
+
+		var n:int = childSets.length;
+		for (var i:int = 0; i < n; i++)
+		{
+			var instances:Array = childSets[i];
+			var m:int = instances.length;
+			for (var j:int = 0; j < m; j++)
+			{
+				instances[j].initEffect(event);
+			}
+		}
+	}
+
+	/**
+	 *  @private
+	 */
+	mx_internal function effectEndHandler(event:EffectEvent):void
+	{
+		onEffectEnd(event.effectInstance);
+	}
+}
+
+}


somehow host was null but dragImage wasn't

--- frameworks/as/projects/FlexJSUI/src/org/apache/flex/html/beads/controllers/DragMouseController.as
+++ frameworks/as/projects/FlexJSUI/src/org/apache/flex/html/beads/controllers/DragMouseController.as
@@ -273,7 +273,7 @@
             dragging = false;
             dragSource = null;
             dragInitiator = null;
-            if (dragImage)
+            if (dragImage && host)
                 host.removeElement(dragImage);
             dragImage = null;
             DisplayObject(_strand).stage.removeEventListener(MouseEvent.MOUSE_MOVE, dragMouseMoveHandler);


Transferred from the Adobe Open Source Subversion Repository

Revision: 7176
Author:   cframpto@adobe.com
Date:     2009-05-21T14:55:47.815652Z

Log Message:
-----------
Rework autoSizing.  If height and width specified, they will be used, even if autoSize=true.  Make sure RichEditableTextContainerManager.drawBackgroundAndSetScrollRect() does the right thing for the autoSizing case.

autoSize may return true even if not actually autoSizing in the cases where height and width are explicitly set or this component is the viewport of a scroller (ie TextArea).

QA Notes: TextArea and TextInput tests pass
Doc Notes:
Bugs: SDK-21312
Reviewers: Gordon

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/RichEditableText.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/supportClasses/RichEditableTextContainerManager.as</path>

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

--- frameworks/projects/spark/src/spark/components/supportClasses/RichEditableTextContainerManager.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/RichEditableTextContainerManager.as
@@ -90,11 +90,20 @@
         var width:Number = compositionWidth;
         var height:Number = compositionHeight;

-        if (isNaN(width) || isNaN(height))
+        if (!textView.actuallyAutoSizing && (isNaN(width) || isNaN(height)))
             return false;  // just measuring!

         var contentBounds:Rectangle = getContentBounds();

+        // If autoSize, use the content values rather than the composition
+        // values. The composition values allow room for growth
+        // (width=maxWidth, height=NaN).
+        if (textView.actuallyAutoSizing)
+        {
+            width = contentBounds.width;
+            height = contentBounds.height;
+        }
+
         if (scrollX == 0 &&
             scrollY == 0 &&
             contentBounds.width <= width &&


Fixed a small, but critical, typo.

Fixed a small, but critical, typo.

--- frameworks/projects/HTML/as/src/org/apache/flex/html/beads/ContainerView.as
+++ frameworks/projects/HTML/as/src/org/apache/flex/html/beads/ContainerView.as
@@ -180,7 +180,7 @@
 		 */
 		public function get numElements():int
 		{
-			return contentView.numElements();
+			return contentView.numElements;
 		}

 		/**


Transferred from the Adobe Open Source Subversion Repository

Revision: 16590
Author:   egeorgie@adobe.com
Date:     2010-06-17T18:17:44.460154Z

Log Message:
-----------
Additional perf instrumentation added to the framework

- Instrumented bootstrapping, createChildren, validateSize, validateDisplayList
- updated build.xml for the flex & flash-integration projects with reference to framework-config.xml as these reference instrumented code from the framework.

QE notes: None
Doc notes: None
Bugs: N/A
Reviewer: Glenn
Tests run: ant main, doc, checkintests
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/managers/SystemManager.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/resources/ResourceManager.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/managers/systemClasses/ChildManager.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/tests/performance/PerfLib/src/perflib/impl/PerfReporter.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/flex/.actionScriptProperties</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/flash-integration/build.xml</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/flex/build.xml</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/managers/LayoutManager.as</path>

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

--- frameworks/projects/framework/src/mx/managers/systemClasses/ChildManager.as
+++ frameworks/projects/framework/src/mx/managers/systemClasses/ChildManager.as
@@ -299,10 +299,22 @@
 	 */
 	public function initializeTopLevelWindow(width:Number, height:Number):void
 	{
+        CONFIG::performanceInstrumentation
+        {
+            var perfUtil:mx.utils.PerfUtil = mx.utils.PerfUtil.getInstance();
+            perfUtil.markTime("ChildManager.initializeTopLevelWindow().start");
+            perfUtil.markTime("SystemManager.create().start");
+        }
+
 		var app:IUIComponent;
 		// Create a new instance of the toplevel class
         systemManager.document = app = topLevelWindow = IUIComponent(systemManager.create());
-
+
+        CONFIG::performanceInstrumentation
+        {
+            perfUtil.markTime("SystemManager.create().end");
+        }
+
 		if (systemManager.document)
 		{
 			// Add listener for the creationComplete event
@@ -338,12 +350,28 @@
 			// Leter, when we actually attach the Application instance,
 			// we call super.addChild(), which is the bare player method.
 			addingChild(DisplayObject(app));
-			childAdded(DisplayObject(app)); // calls app.createChildren()
+
+            CONFIG::performanceInstrumentation
+            {
+                perfUtil.markTime("Application.createChildren().start");
+            }
+
+            childAdded(DisplayObject(app)); // calls app.createChildren()
+
+            CONFIG::performanceInstrumentation
+            {
+                perfUtil.markTime("Application.createChildren().end");
+            }
 		}
 		else
 		{
 			systemManager.document = this;
 		}
+
+        CONFIG::performanceInstrumentation
+        {
+            perfUtil.markTime("ChildManager.initializeTopLevelWindow().end");
+        }
 	}

  	/**


Transferred from the Adobe Open Source Subversion Repository

Revision: 5099
Author:   gauravj@adobe.com
Date:     2009-02-27T03:43:02.639229Z

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:
--------------
147 paths were modified

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

--- frameworks/projects/rpc/src/mx/messaging/management/MBeanConstructorInfo.as
+++ frameworks/projects/rpc/src/mx/messaging/management/MBeanConstructorInfo.as
@@ -18,11 +18,23 @@

 /**
  * Client representation of metadata for a MBean constructor.
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion BlazeDS 4
+ *  @productversion LCDS 3
  */
 public class MBeanConstructorInfo extends MBeanFeatureInfo
 {
     /**
      *  Creates a new instance of an empty MBeanConstructorInfo.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion BlazeDS 4
+     *  @productversion LCDS 3
      */
     public function MBeanConstructorInfo()
 	{
@@ -31,6 +43,12 @@

 	/**
 	 * The parameter data types that make up the constructor signature.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion BlazeDS 4
+	 *  @productversion LCDS 3
 	 */
 	public var signature:Array;


dateDisplayFormat metadata respected even when no dateFormat specified. #WEAVE-492 Fixed

--- WeaveJS/src/weavejs/data/column/DateColumn.as
+++ WeaveJS/src/weavejs/data/column/DateColumn.as
@@ -93,16 +93,12 @@

 			_dateFormat = DateFormat.convertDateFormat_c_to_moment(_dateFormat);

-			// read dateDisplayFormat metadata, default to the input format if none is specified.
+			// read dateDisplayFormat metadata
 			_dateDisplayFormat = getMetadata(ColumnMetadata.DATE_DISPLAY_FORMAT);

 			if (_dateDisplayFormat)
 			{
 				_dateDisplayFormat = DateFormat.convertDateFormat_c_to_moment(_dateDisplayFormat);
-			}
-			else
-			{
-				_dateDisplayFormat = _dateFormat;
 			}

 			// compile the number format function from the metadata
@@ -174,11 +170,12 @@
 		private static const MINUTE:Number = 60 * 1000;
 		private static const HOUR:Number = 60 * 60 * 1000;

+		/* When formatting date, default to input format if no display format specified. */
 		private function formatDate(value:Object):String
 		{
 			if (_durationMode)
 				return DateUtils.formatDuration(value);
-			return DateUtils.format(value, _dateDisplayFormat);
+			return DateUtils.format(value, _dateDisplayFormat || _dateFormat);
 		}

 		private function _asyncIterate(stopTime:int):Number
@@ -298,7 +295,7 @@
 				if (value === undefined)
 					return '';

-				if (_dateFormat)
+				if (_dateDisplayFormat || _dateFormat)
 					string = formatDate(value);
 				else
 					string = value.toString();


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

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

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

--- frameworks/projects/charts/src/mx/charts/LinearAxis.as
+++ frameworks/projects/charts/src/mx/charts/LinearAxis.as
@@ -0,0 +1,691 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  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.charts
+{
+
+import flash.events.Event;
+import mx.charts.chartClasses.AxisLabelSet;
+import mx.charts.chartClasses.NumericAxis;
+import mx.core.mx_internal;
+
+use namespace mx_internal;
+
+/**
+ *  The LinearAxis class maps numeric values evenly
+ *  between a minimum and maximum value along a chart axis.
+ *  By default, it determines minimum, maximum,
+ *  and interval values from the charting data
+ *  to fit all of the chart elements on the screen.
+ *  You can also explicitly set specific values for these properties.
+ *
+ *
The auto-determination of range values works as follows:
+ *
+ *

+ *
 Flex determines a minimum and maximum value
+ *    that accomodates all the data being displayed in the chart.

+ *
 If the autoAdjust and baseAtZero properties
+ *    are set to true, Flex makes the following adjustments:
+ *

+ *
If all values are positive,
+ *        Flex sets the minimum property to zero.

+ *
If all values are negative,
+ *        Flex sets the maximum property to zero.

+ *

+ *

+ *
 If the autoAdjust property is set to true,
+ *    Flex adjusts values of the minimum and maximum
+ *    properties by rounding them up or down.

+ *
 Flex checks if any of the elements displayed in the chart
+ *    require extra padding to display properly (for example, for labels).
+ *    It adjusts the values of the minimum and
+ *    maximum properties accordingly.

+ *
 Flex determines if you have explicitly specified any padding
+ *    around the minimum and maximum values,
+ *    and adjusts their values accordingly.

+ *

+ *

+ *
+ *  @mxml
+ *
+ *
The <mx:LinearAxis> tag inherits all the properties
+ *  of its parent classes and adds the following properties:

+ *
+ *

+ *  <mx:LinearAxis
+ *    Properties
+ *    interval="null"
+ *    maximum="null"
+ *    maximumLabelPrecision="null"
+ *    minimum="null"
+ *    minorInterval="null"
+ *  />
+ *

+ *
+ *  @see mx.charts.chartClasses.IAxis
+ *
+ *  @includeExample examples/HLOCChartExample.mxml
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class LinearAxis extends NumericAxis
+{
+    include "../core/Version.as";
+
+	//--------------------------------------------------------------------------
+	//
+	//  Constructor
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *	Constructor.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public function LinearAxis()
+	{
+		super();
+	}
+
+	//-------------------------------------------------------------------------
+	//
+	//   Variables
+	//
+	//-------------------------------------------------------------------------
+
+    private var _actualAssignedMaximum:Number;
+
+    private var _actualAssignedMinimum:Number;
+
+
+	//-----------------------------------------------------------------------
+	//
+	// Overridden properties
+	//
+	//-----------------------------------------------------------------------
+
+	//------------------------------------------
+	// direction
+	//------------------------------------------
+	[Inspectable(category="General", enumeration="normal,inverted", defaultValue="normal")]
+	/**
+	 *  @private
+	 */
+	override public function set direction(value:String):void
+	{
+		if(value == "inverted")
+		{
+			if(!(isNaN(_actualAssignedMaximum)))
+			{
+				computedMinimum = -_actualAssignedMaximum;
+				assignedMinimum = -_actualAssignedMaximum;
+			}
+			if(!(isNaN(_actualAssignedMinimum)))
+			{
+				computedMaximum = -_actualAssignedMinimum;
+				assignedMaximum = -_actualAssignedMinimum;
+			}
+		}
+		else
+		{
+			if(!(isNaN(_actualAssignedMaximum)))
+			{
+				computedMaximum = _actualAssignedMaximum;
+				assignedMaximum = _actualAssignedMaximum;
+			}
+			if(!(isNaN(_actualAssignedMinimum)))
+			{
+				computedMinimum = _actualAssignedMinimum;
+				assignedMinimum = _actualAssignedMinimum;
+			}
+		}
+		super.direction = value;
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Properties
+	//
+	//--------------------------------------------------------------------------
+
+	//--------------------------------------------
+	// alignLabelsToInterval
+	//--------------------------------------------
+
+	/**
+	 *  @private
+	 *  Storage for alignLabelsToInterval property
+	 */
+	private var _alignLabelsToInterval:Boolean = true;
+
+
+    /**
+	 * @private
+	 */
+	public function get alignLabelsToInterval():Boolean
+	{
+		return _alignLabelsToInterval;
+	}
+	/**
+	* @private
+	*/
+	public function set alignLabelsToInterval(value:Boolean):void
+	{
+		if (value != _alignLabelsToInterval)
+		{
+			_alignLabelsToInterval = value;
+			invalidateCache();
+			dispatchEvent(new Event("mappingChange"));
+			dispatchEvent(new Event("axisChange"));
+		}
+	}
+
+
+	//----------------------------------
+	//  interval
+	//----------------------------------
+
+	/**
+	 *  @private
+	 */
+	private var _userInterval:Number;
+
+	[Inspectable(category="General")]
+
+	/**
+	 *  Specifies the numeric difference between label values along the axis.
+	 *  Flex calculates the interval if this property
+	 *  is set to NaN.
+	 *  The default value is NaN.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public function get interval():Number
+	{
+		return computedInterval;
+	}
+
+	/**
+	 *  @private
+	 */
+	public function set interval(value:Number):void
+	{
+		if (value <= 0)
+			value = NaN;
+
+		_userInterval = value;
+
+		computedInterval = value;
+		invalidateCache();
+
+		dispatchEvent(new Event("axisChange"));
+	}
+
+	//----------------------------------
+	//  maximum
+	//----------------------------------
+
+    [Inspectable(category="General")]
+
+	/**
+	 *  Specifies the maximum value for an axis label.
+	 *  If you set the autoAdjust property to true,
+	 *  Flex calculates this value.
+	 *  If NaN, Flex determines the maximum value
+	 *  from the data in the chart.
+	 *  The default value is NaN.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public function get maximum():Number
+	{
+		if(direction == "inverted")
+			return -computedMinimum;
+		else
+			return computedMaximum;
+	}
+
+	/**
+	 *  @private
+	 */
+	public function set maximum(value:Number):void
+	{
+		if(direction == "inverted")
+		{
+			assignedMinimum = -value;
+			computedMinimum = -value;
+		}
+		else
+		{
+			assignedMaximum = value;
+			computedMaximum = value;
+		}
+		_actualAssignedMaximum = value;
+		invalidateCache();
+
+		dispatchEvent(new Event("mappingChange"));
+		dispatchEvent(new Event("axisChange"));
+	}
+
+	//----------------------------------
+	//  maximumLabelPrecision
+	//----------------------------------
+
+	/**
+	 *  @private
+	 *  Storage for maximumLabelPrecision property
+	 */
+	private var _maximumLabelPrecision:Number;
+
+	/**
+	 *  @private
+	 */
+	public function get maximumLabelPrecision():Number
+	{
+		return _maximumLabelPrecision;
+	}
+
+	/**
+	 *  Specifies the maximum number of decimal places for representing fractional values on the labels
+	 *  generated by this axis. By default, the axis autogenerates this value from the labels themselves.
+	 *  A value of 0 rounds to the nearest integer value, while a value of 2 rounds to the nearest 1/100th
+	 *  of a value.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public function set maximumLabelPrecision(value:Number):void
+	{
+		_maximumLabelPrecision = value;
+
+		invalidateCache();
+	}
+
+	//----------------------------------
+	//  minimum
+	//----------------------------------
+
+    [Inspectable(category="General")]
+
+	/**
+	 *  Specifies the minimum value for an axis label.
+	 *  If NaN, Flex determines the minimum value
+	 *  from the data in the chart.
+	 *  The default value is NaN.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public function get minimum():Number
+	{
+		if(direction == "inverted")
+			return -computedMaximum;
+		else
+			return computedMinimum;
+	}
+
+	/**
+	 *  @private
+	 */
+	public function set minimum(value:Number):void
+	{
+		if(direction == "inverted")
+		{
+			assignedMaximum = -value;
+			computedMaximum = -value;
+		}
+		else
+		{
+			assignedMinimum = value;
+			computedMinimum = value;
+		}
+		_actualAssignedMinimum = value;
+		invalidateCache();
+
+		dispatchEvent(new Event("mappingChange"));
+		dispatchEvent(new Event("axisChange"));
+
+	}
+
+	//----------------------------------
+	//  minorInterval
+	//----------------------------------
+
+	/**
+	 *  @private
+	 *  Storage for the minorInterval property.
+	 */
+	private var _minorInterval:Number;
+
+	/**
+	 *  @private
+	 */
+	private var _userMinorInterval:Number;
+
+    [Inspectable(category="General")]
+
+	/**
+	 *  Specifies the numeric difference between minor tick marks along the axis.
+	 *  Flex calculates the difference if this property
+	 *  is set to NaN.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public function get minorInterval():Number
+	{
+		return _minorInterval;
+	}
+
+	/**
+	 *  @private
+	 */
+	public function set minorInterval(value:Number):void
+	{
+		if (value <= 0)
+			value = NaN;
+
+		_userMinorInterval = value;
+		_minorInterval = value;
+
+		invalidateCache();
+
+		dispatchEvent(new Event("axisChange"));
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Overridden methods: NumericAxis
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 */
+	override protected function buildLabelCache():Boolean
+	{
+		if (labelCache)
+			return false;
+
+		labelCache = [];
+
+		var r:Number = computedMaximum - computedMinimum;
+
+		var labelBase:Number = labelMinimum -
+			Math.floor((labelMinimum - computedMinimum) / computedInterval) *
+			computedInterval;
+
+		if (_alignLabelsToInterval)
+			labelBase = Math.ceil(labelBase / computedInterval) * computedInterval;
+
+		var labelTop:Number = computedMaximum;
+
+		var i:Number;
+
+		var precision:Number = _maximumLabelPrecision;
+		if (isNaN(precision))
+		{
+			var decimal:Number = Math.abs(computedInterval) -
+								 Math.floor(Math.abs(computedInterval));
+
+			precision =
+				decimal == 0 ? 1 : -Math.floor(Math.log(decimal) / Math.LN10);
+
+			decimal = Math.abs(computedMinimum) -
+					  Math.floor(Math.abs(computedMinimum));
+
+			precision = Math.max(precision,
+				decimal == 0 ? 1: -Math.floor(Math.log(decimal) / Math.LN10));
+		}
+		var roundBase:Number = Math.pow(10, precision);
+
+		var labelFunction:Function = this.labelFunction;
+
+		var roundedValue:Number;
+
+		if (labelFunction != null)
+		{
+			var previousValue:Number = NaN;
+			for (i = labelBase; i <= labelTop; i += computedInterval)
+			{
+				roundedValue = Math.round(i * roundBase) / roundBase;
+				if(direction == "inverted")
+					roundedValue = -roundedValue;
+
+				labelCache.push(new AxisLabel(
+					(i - computedMinimum) / r, i,
+					labelFunction(roundedValue, previousValue, this)));
+
+				previousValue = roundedValue;
+			}
+		}
+		else
+		{
+			for (i = labelBase; i <= labelTop; i += computedInterval)
+			{
+				roundedValue = Math.round(i * roundBase) / roundBase;
+				if(direction == "inverted")
+					roundedValue = -roundedValue;
+				labelCache.push(new AxisLabel(
+					(i - computedMinimum) / r, i, roundedValue.toString()));
+			}
+		}
+
+		return true;
+	}
+
+	/**
+	 *  @private
+	 */
+	override public function reduceLabels(intervalStart:AxisLabel,
+										  intervalEnd:AxisLabel):AxisLabelSet
+	{
+		// What's this calculation?
+		// We're trying to figure out how many labels we need to skip.
+		// If we assume that every adjacent label is 1 computedInterval apart,
+		// then we can guess the ordinal distance between any two labels by
+		// dividing the difference in their values by computedInterval.
+		// So, what's with the round? Well, in theory, the distance
+		// between any two labels is an integral number of _intervals.
+		// but floating-point rounding errors, especially on small intervals,
+		// can throw us off by a little bit. So we add in a round()
+		// to get us back to a nice whole integer.
+		var intervalMultiplier:Number =
+			Math.round((Number(intervalEnd.value) -
+			Number(intervalStart.value)) / computedInterval) + 1;
+
+		var newMinorInterval:Number = intervalMultiplier * _minorInterval;
+
+		var labels:Array /* of AxisLabel */ = [];
+		var newMinorTicks:Array /* of Number */ = [];
+		var newTicks:Array /* of Number */ = [];
+
+		var n:int = labelCache.length;
+		for (var i:int = 0; i < n; i += intervalMultiplier)
+		{
+			labels.push(labelCache[i]);
+			newTicks.push(labelCache[i].position);
+		}
+
+		var r:Number = computedMaximum - computedMinimum;
+
+		var labelBase:Number = labelMinimum -
+			Math.floor((labelMinimum - computedMinimum)/newMinorInterval) *
+			newMinorInterval;
+
+		if (_alignLabelsToInterval)
+			labelBase = Math.ceil(labelBase / newMinorInterval) * newMinorInterval;
+
+		var labelTop:Number = computedMaximum + 0.000001
+
+		for (var j:Number = labelBase; j <= labelTop; j += newMinorInterval)
+		{
+			newMinorTicks.push((j - computedMinimum) / r);
+		}
+
+		var labelSet:AxisLabelSet = new AxisLabelSet();
+		labelSet.labels = labels;
+		labelSet.minorTicks = newMinorTicks;
+		labelSet.ticks = newTicks;
+		labelSet.accurate = true;
+		return labelSet;
+	}
+
+	/**
+	 *  @private
+	 */
+	override protected function buildMinorTickCache():Array /* of Number */
+	{
+		var cache:Array /* of Number */ = [];
+
+		var r:Number = computedMaximum - computedMinimum;
+
+		var labelBase:Number = labelMinimum -
+			Math.floor((labelMinimum - computedMinimum) / _minorInterval) *
+			_minorInterval;
+
+		if (_alignLabelsToInterval)
+			labelBase = Math.ceil(labelBase / _minorInterval) * _minorInterval;
+
+		var labelTop:Number = computedMaximum;
+
+		for (var i:Number = labelBase; i <= labelTop; i += _minorInterval)
+		{
+			cache.push((i - computedMinimum) / r);
+		}
+
+		return cache;
+	}
+
+	/**
+	 *  @private
+	 */
+	override protected function adjustMinMax(minValue:Number,
+											 maxValue:Number):void
+	{
+		var interval:Number = _userInterval;
+
+		if (autoAdjust == false &&
+			!isNaN(_userInterval) &&
+			!isNaN(_userMinorInterval))
+		{
+			return;
+		}
+
+		// New calculations to accomodate negative values.
+		// Find the nearest power of ten for y_userInterval
+		// for line-grid and labelling positions.
+		if (maxValue == 0 && minValue == 0)
+			maxValue = 100;
+		var maxPowerOfTen:Number =
+			Math.floor(Math.log(Math.abs(maxValue)) / Math.LN10);
+		var minPowerOfTen:Number =
+			Math.floor(Math.log(Math.abs(minValue)) / Math.LN10);
+		var powerOfTen:Number =
+			Math.floor(Math.log(Math.abs(maxValue - minValue)) / Math.LN10)
+
+		var y_userInterval:Number;
+
+		if (isNaN(_userInterval))
+		{
+			y_userInterval = Math.pow(10, powerOfTen);
+
+			if (Math.abs(maxValue - minValue) / y_userInterval < 4)
+			{
+				powerOfTen--;
+				y_userInterval = y_userInterval * 2 / 10;
+			}
+		}
+		else
+		{
+			y_userInterval = _userInterval;
+		}
+
+		// Bug 148745:
+		// Using % to decide if y_userInterval divides maxValue evenly
+		// is running into floating point errors.
+		// For example, 3 % .2 == .2.
+		// Multiplication and division don't seem to have the same problems,
+		// so instead we divide, round and multiply.
+		// If we get back to the same value, it means that either it fit evenly,
+		// or the difference was trivial enough to get rounded out
+		// by imprecision.
+
+		var y_topBound:Number =
+			Math.round(maxValue / y_userInterval) * y_userInterval == maxValue ?
+			maxValue :
+			(Math.floor(maxValue / y_userInterval) + 1) * y_userInterval;
+
+		var y_lowerBound:Number;
+
+		if (isFinite(minValue))
+			y_lowerBound = 0;
+
+		if (minValue < 0 || baseAtZero == false)
+		{
+			y_lowerBound =
+				Math.floor(minValue / y_userInterval) * y_userInterval;
+
+			if (maxValue < 0 && baseAtZero)
+				y_topBound = 0;
+		}
+		else
+		{
+			y_lowerBound = 0;
+		}
+
+		// OK, we've figured out our interval.
+		// If the caller wants us to lower it based on layout rules,
+		// we have more to do. Otherwise, return here.
+		// If the user didn't provide us with an interval,
+		// we'll use the one we just generated
+
+		if (isNaN(_userInterval))
+			computedInterval = y_userInterval;
+
+		if (isNaN(_userMinorInterval))
+			_minorInterval = computedInterval / 2;
+
+		// If the user wanted to us to autoadjust the min/max
+		// to nice clean values, record the ones we just caluclated.
+		// If the user has provided us with specific min/max values,
+		// we won't blow that away here.
+		if (autoAdjust)
+		{
+			if (isNaN(assignedMinimum))
+				computedMinimum = y_lowerBound;
+
+			if (isNaN(assignedMaximum))
+				computedMaximum = y_topBound;
+		}
+	}
+}
+
+}


Fix editor camera orbiting with right mouse button when components only are selected in the hierarchy.

--- Bin/Data/Scripts/Editor/EditorView.as
+++ Bin/Data/Scripts/Editor/EditorView.as
@@ -1163,7 +1163,7 @@

                 Quaternion q = Quaternion(activeViewport.cameraPitch, activeViewport.cameraYaw, 0);
                 cameraNode.rotation = q;
-                if (input.mouseButtonDown[MOUSEB_MIDDLE] && selectedNodes.length > 0 || selectedComponents.length > 0)
+                if (input.mouseButtonDown[MOUSEB_MIDDLE] && (selectedNodes.length > 0 || selectedComponents.length > 0))
                 {
                     Vector3 centerPoint = SelectedNodesCenterPoint();
                     Vector3 d = cameraNode.worldPosition - centerPoint;


Transferred from the Adobe Open Source Subversion Repository

Revision: 12027
Author:   gosmith@adobe.com
Date:     2009-11-20T05:43:31.265390Z

Log Message:
-----------
Added selectionAnchorIndex and selectionActiveIndex getters to RichEditableTextAccImpl and SkinnableTextBaseAccImpl. The presence of these getters is supposed to make Player 10.1 and AIR 2.0 able to support text-selection-accessibility for TLF-based text; they are the ActionScript side of the GetSelection() method in Adobe's ISimpleTextSelection COM interface for screen readers like JAWS.

Although Player 10.1 and AIR 2.0 are adding a flash.accessibility.ISimpleTextSelection interface to formalize these getters, we want to be able to compile against the playerglobal.swc for Player 10.0 (or airglobal.swc for AIR 1.5). We could define our own copy of this interface in Flex, but it isn't necessary because the Player and AIR do not actually look at whether an AccessibilityImplementation class declares that it implements ISimpleTextSelection; they only look at whether an AccessibilityImplementation class has these getters.

This way of doing text-selection-accessibility replaces the ITextSupport interface that was in earlier versions of Player 10.1 and AIR 2.0, including the betas. So you try it you must have a very recent build of 10.1 and 2.0.

QE notes: None
Doc notes: None
Bugs: None
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/accessibility/RichEditableTextAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/accessibility/SkinnableTextBaseAccImpl.as</path>

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

--- frameworks/projects/spark/src/spark/accessibility/RichEditableTextAccImpl.as
+++ frameworks/projects/spark/src/spark/accessibility/RichEditableTextAccImpl.as
@@ -75,6 +75,7 @@
         component.accessibilityImplementation =
             new RichEditableTextAccImpl(component);
     }
+
     //--------------------------------------------------------------------------
     //
     //  Constructor
@@ -115,8 +116,98 @@
      */
     override protected function get eventsToHandle():Array
     {
-        return super.eventsToHandle.concat(["change"]);
-    }
+        return super.eventsToHandle.concat([ Event.CHANGE ]);
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Properties: ISimpleTextSelection
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  selectionActiveIndex
+    //----------------------------------
+
+    /**
+     *  A character position, relative to the beginning of the
+     *  text String of the RichEditableText,
+	 *  specifying the end of the selection
+     *  that moves when the selection is extended with the arrow keys.
+     *
+     *
The active position may be either the start
+     *  or the end of the selection.

+     *
+     *
For example, if you drag-select from position 12 to position 8,
+     *  then selectionAnchorPosition will be 12
+     *  and selectionActivePosition will be 8,
+     *  and when you press Left-Arrow selectionActivePosition
+     *  will become 7.

+     *
+     *
A value of -1 indicates "not set".

+	 *
+	 *
In Player 10.1 and later, and AIR 2.0 and later,
+	 *  an AccessibilityImplementation can implement
+	 *  selectionAnchorIndex and selectionAnchorIndex
+	 *  in order to make an accessibility client aware of the text selection
+	 *  in TLF text via Adobe's ISimpleTextSelection COM interface.

+     *
+     *  @default -1
+     *
+	 *  @see spark.accessibility.RichEditableTextAccImpl#selectionAnchorIndex
+     *  @see spark.components.RichEditableText#selectionActivePosition
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10.1
+     *  @playerversion AIR 2.0
+     *  @productversion Flex 4
+     */
+	public function get selectionActiveIndex():int
+	{
+		return RichEditableText(master).selectionActivePosition;
+	}
+
+    //----------------------------------
+    //  selectionAnchorIndex
+    //----------------------------------
+
+    /**
+     *  A character position, relative to the beginning of the
+     *  text String of the RichEditableText,
+	 *  specifying the end of the selection
+     *  that stays fixed when the selection is extended with the arrow keys.
+     *
+     *
The anchor position may be either the start
+     *  or the end of the selection.

+     *
+     *
For example, if you drag-select from position 12 to position 8,
+     *  then selectionAnchorPosition will be 12
+     *  and selectionActivePosition will be 8,
+     *  and when you press Left-Arrow selectionActivePosition
+     *  will become 7.

+     *
+     *
A value of -1 indicates "not set".

+	 *
+	 *
In Player 10.1 and later, and AIR 2.0 and later,
+	 *  an AccessibilityImplementation can implement
+	 *  selectionAnchorIndex and selectionAnchorIndex
+	 *  in order to make an accessibility client aware of the text selection
+	 *  in TLF text via Adobe's ISimpleTextSelection COM interface.

+     *
+     *  @default -1
+     *
+	 *  @see spark.accessibility.RichEditableTextAccImpl#selectionActiveIndex
+     *  @see spark.components.RichEditableText#selectionAnchorPosition
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10.1
+     *  @playerversion AIR 2.0
+     *  @productversion Flex 4
+     */
+	public function get selectionAnchorIndex():int
+	{
+		return RichEditableText(master).selectionAnchorPosition;
+	}

     //--------------------------------------------------------------------------
     //
@@ -175,10 +266,10 @@

         switch (event.type)
         {
-            case "change":
+            case Event.CHANGE:
             {
-                Accessibility.sendEvent(master, 0,
-                                        AccConst.EVENT_OBJECT_VALUECHANGE, true);
+                Accessibility.sendEvent(
+					master, 0, AccConst.EVENT_OBJECT_VALUECHANGE, true);
                 break;
             }
         }


advanced comparator

advanced comparator

--- src/com/kemsky/impl/Stream.as
+++ src/com/kemsky/impl/Stream.as
@@ -578,6 +578,7 @@
             {
                 callback(item);
             });
+            return this;
         }

         public function map(callback:Function):Stream


Add introspection to FlexDocumentModel

Add introspection to FlexDocumentModel

--- nuxeo-platform-ui-flex/nuxeo-flex-components/src/main/flex/org/nuxeo/ecm/flex/dto/FlexDocumentModel.as
+++ nuxeo-platform-ui-flex/nuxeo-flex-components/src/main/flex/org/nuxeo/ecm/flex/dto/FlexDocumentModel.as
@@ -74,6 +74,11 @@
     {
       return _name;
     }
+
+    public function get doctype():String
+    {
+      return _type;
+    }

     public function get contentdata():Object
     {
@@ -111,6 +116,33 @@
     public function isFolder():Boolean
     {
       return _isFolder;
+    }
+
+    public function getSchemas():Array
+    {
+      var schemas:Array = new Array();
+      var schemaName:Object;
+      for (schemaName in _data)
+      {
+      schemas.push(schemaName);
+      }
+      return schemas;
+    }
+
+    public function getSchema(schemaName:String):Object
+    {
+      return _data[schemaName];
+    }
+
+    public function getFieldNames(schemaName:String):Array
+    {
+      var fieldNames:Array = new Array();
+      var fieldName:Object;
+      for (fieldName in _data[schemaName])
+      {
+      fieldNames.push(fieldName);
+      }
+      return fieldNames;
     }


FLEX-35031 Making sure that extra asdoc information is included by placing the @inheritDoc tag after the extra comments, as explained in http://help.adobe.com/en_US/flex/using/WSd0ded3821e0d52fe1e63e3d11c2f44bc36-7ff6.htm ("You can add content to the comment before the @inheritDoc tag.")

--- frameworks/projects/advancedgrids/src/mx/collections/HierarchicalCollectionViewCursor.as
+++ frameworks/projects/advancedgrids/src/mx/collections/HierarchicalCollectionViewCursor.as
@@ -307,11 +307,11 @@
     //--------------------------------------------------------------------------

     /**
-     *  @inheritDoc
-     *
      *
Note that for this class, the view does not need to be sorted in order to
      *  call this method. Also, if the item cannot be found, the cursor location is
      *  left on the last queried object.

+     *
+     *  @inheritDoc
      *
      *  @langversion 3.0
      *  @playerversion Flash 9
@@ -333,12 +333,12 @@
     }

     /**
-     *  @inheritDoc
-     *
      *
Note that for this class, the view does not need to be sorted in order to
      *  call this method. Also, if the item cannot be found, the cursor location is
      *  left on the last queried object.

-     *
+     *
+     *  @inheritDoc
+     *
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
@@ -350,11 +350,11 @@
     }

     /**
-     *  @inheritDoc
-     *
      *
Note that for this class, the view does not need to be sorted in order to
      *  call this method. Also, if the item cannot be found, the cursor location is
      *  left on the last queried object.

+     *
+     *  @inheritDoc
      *
      *  @langversion 3.0
      *  @playerversion Flash 9


Added an extra check to ensure the values aren't all zero.

Change-Id: I5e9424f9e87082f3b51d33569e22f15a9751f12a

--- WeaveUI/src/weave/utils/DashedLine.as
+++ WeaveUI/src/weave/utils/DashedLine.as
@@ -1,4 +1,23 @@
-/*
+/*
+    Weave (Web-based Analysis and Visualization Environment)
+    Copyright (C) 2008-2011 University of Massachusetts Lowell
+
+    This file is a part of Weave.
+
+    Weave is free software: you can redistribute it and/or modify
+    it under the terms of the GNU General Public License, Version 3,
+    as published by the Free Software Foundation.
+
+    Weave is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with Weave.  If not, see <http://www.gnu.org/licenses/>.
+*/
+
+/*
 DashedLine class
 by Andy Woodruff (http://cartogrammar.com/blog || awoodruff@gmail.com)
 May 2008
@@ -33,7 +52,8 @@
 	import weave.data.CSVParser;

 	/**
-	 *
+	 * This class is an object which can draw dashed lines onto a graphics. To use this class
+	 * first set the graphics, lineStyle, and lengthsString.
 	 * @author Andy Woodruff (http://cartogrammar.com/blog || awoodruff@gmail.com)
 	 *         with modifications by kmonico
 	 */
@@ -108,13 +128,6 @@
 			_lineColor = color;
 		}

-		/**
-		 * Draw a rectangle onto the graphics.
-		 * @param xStart
-		 * @param yStart
-		 * @param width
-		 * @param height
-		 */
 		public function drawRect(xStart:Number, yStart:Number, width:Number, height:Number, corner:uint = TOP_LEFT):void
 		{
 			moveTo(xStart, yStart);
@@ -181,15 +194,19 @@
 			_startIndex = 0;
 		}

-		private function validateLengthsArray():void {
-
-		}
+		private function lengthsAllZero():Boolean {
+			for each (var num:uint in _lengthsArray)
+				if (num > 0) return false;
+
+			return true;
+		}
+
 		private const parser:CSVParser = new CSVParser();

 		public function lineTo(x:Number,y:Number):void{
-			if (lengthsArray.length == 0)
+			if (lengthsArray.length == 0 || lengthsAllZero())
 				this.lengthsArray.push(DEFAULT_GAP_LENGTH, DEFAULT_LINE_LENGTH);
-
+
 			var slope:Number = (y - _curY)/(x - _curX);	// get slope of segment to be drawn
 			// record beginning x and y
 			var startX:Number = _curX;


Oh oops, thanks Ray, this should definitely be a Number.

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

--- src/as/com/threerings/flash/path/HermiteFunc.as
+++ src/as/com/threerings/flash/path/HermiteFunc.as
@@ -54,7 +54,7 @@
     }

     /** Get the derivative of this function at a point. */
-    public function getSlope (t :Number) :int
+    public function getSlope (t :Number) :Number
     {
         if (t >= 1 || t < 0) { // cope with a funny startOffset
             return 0;


Transferred from the Adobe Open Source Subversion Repository

Revision: 19242
Author:   aharui@adobe.com
Date:     2010-12-09T22:27:31.442236Z

Log Message:
-----------
Disable MEASURED_SIZE_PRELIMINARY if icon not used.  All fix up propagation of estimatedSizes

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

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/airframework/src/mx/core/Window.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/mobiletheme/src/spark/skins/mobile/ViewNavigatorSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mx/src/mx/core/Application.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/SkinnableContainerSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/ViewNavigatorApplicationSkin.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/mobiletheme/src/spark/skins/mobile/TabbedViewNavigatorApplicationSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/Application.as</path>

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

--- frameworks/projects/mobilecomponents/src/spark/components/IconItemRenderer.as
+++ frameworks/projects/mobilecomponents/src/spark/components/IconItemRenderer.as
@@ -24,6 +24,7 @@
 import mx.core.UITextField;
 import mx.core.UITextFormat;
 import mx.core.mx_internal;
+import mx.events.FlexEvent;
 import mx.graphics.BitmapFillMode;
 import mx.graphics.BitmapScaleMode;
 import mx.styles.CSSStyleDeclaration;
@@ -178,6 +179,8 @@
             _imageCache.enableCaching = true;
             _imageCache.maxCacheEntries = 100;
         }
+
+        addEventListener(FlexEvent.MEASURED_SIZE_PRELIMINARY, measuredSizePreliminaryHandler);
     }

     //--------------------------------------------------------------------------
@@ -1889,6 +1892,17 @@
         }
     }

+    /**
+     *  @private
+     */
+    private function measuredSizePreliminaryHandler(event:FlexEvent):void
+    {
+        // block the event if there is no icon to display
+        // otherwise the size will not get cached
+        if (iconDisplay && iconDisplay.source == null)
+            event.stopImmediatePropagation();
+    }
+
 }

 }


Transferred from the Adobe Open Source Subversion Repository

Revision: 19665
Author:   eday@adobe.com
Date:     2011-01-09T19:46:39.597874Z

Log Message:
-----------
Bounce/pull bug fixes

QE notes:
Doc notes:
Bugs: SDK-29046, SDK-28972
Reviewer: Ryan
Tests run: checkintests
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/Scroller.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/VScrollBar.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/HScrollBar.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/VScrollBarSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/VScrollBarThumbSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/HScrollBarSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/HScrollBarThumbSkin.as</path>

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

--- frameworks/projects/mobiletheme/src/spark/skins/mobile/HScrollBarThumbSkin.as
+++ frameworks/projects/mobiletheme/src/spark/skins/mobile/HScrollBarThumbSkin.as
@@ -18,6 +18,8 @@
 import flash.display.LineScaleMode;

 import mx.core.DPIClassification;
+import mx.core.mx_internal;
+use namespace mx_internal;

 import spark.components.Button;
 import spark.skins.mobile.supportClasses.MobileSkin;
@@ -32,6 +34,19 @@
  */
 public class HScrollBarThumbSkin extends MobileSkin
 {
+    //--------------------------------------------------------------------------
+    //
+    //  Class constants
+    //
+    //--------------------------------------------------------------------------
+
+    // These constants are also accessed from HScrollBarSkin
+    mx_internal static const PADDING_BOTTOM_320DPI:int = 5;
+    mx_internal static const PADDING_HORIZONTAL_320DPI:int = 4;
+    mx_internal static const PADDING_BOTTOM_240DPI:int = 4;
+    mx_internal static const PADDING_HORIZONTAL_240DPI:int = 3;
+    mx_internal static const PADDING_BOTTOM_DEFAULTDPI:int = 3;
+    mx_internal static const PADDING_HORIZONTAL_DEFAULTDPI:int = 2;

     //--------------------------------------------------------------------------
     //
@@ -56,20 +71,20 @@
 		{
 			case DPIClassification.DPI_320:
 			{
-				paddingBottom = 5;
-				paddingHorizontal = 4;
+				paddingBottom = PADDING_BOTTOM_320DPI;
+				paddingHorizontal = PADDING_HORIZONTAL_320DPI;
 				break;
 			}
 			case DPIClassification.DPI_240:
 			{
-				paddingBottom = 4;
-				paddingHorizontal = 3;
+				paddingBottom = PADDING_BOTTOM_240DPI;
+				paddingHorizontal = PADDING_HORIZONTAL_240DPI;
 				break;
 			}
 			default:
 			{
-				paddingBottom = 3;
-				paddingHorizontal = 2;
+				paddingBottom = PADDING_BOTTOM_DEFAULTDPI;
+				paddingHorizontal = PADDING_HORIZONTAL_DEFAULTDPI;
 				break;
 			}
 		}


Transferred from the Adobe Open Source Subversion Repository

Revision: 5098
Author:   gauravj@adobe.com
Date:     2009-02-27T02:21:27.489350Z

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:
--------------
151 paths were modified

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

--- frameworks/projects/spark/src/spark/components/supportClasses/ItemRenderer.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/ItemRenderer.as
@@ -20,6 +20,11 @@

 /**
  *  The ItemRenderer class is the base class for List item renderers.
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
  */
 public class ItemRenderer extends MXMLComponent
 {
@@ -134,6 +139,11 @@
     /**
      * Optional item renderer label component, used primarily for
      * auto-computation of baseline.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10
+     *  @playerversion AIR 1.5
+     *  @productversion Flex 4
      */
     public var labelField:TextGraphicElement;


Code clean

Code clean

--- collect-flex/collect-flex-client/src/main/flex/org/openforis/collect/presenter/MultipleCodeInputFieldPresenter.as
+++ collect-flex/collect-flex-client/src/main/flex/org/openforis/collect/presenter/MultipleCodeInputFieldPresenter.as
@@ -1,36 +1,23 @@
 package org.openforis.collect.presenter {
-	import flash.display.DisplayObject;
 	import flash.events.Event;
-	import flash.events.MouseEvent;

 	import mx.binding.utils.ChangeWatcher;
 	import mx.collections.ArrayCollection;
 	import mx.collections.IList;
-	import mx.core.FlexGlobals;
-	import mx.events.CloseEvent;
 	import mx.events.CollectionEvent;
-	import mx.managers.PopUpManager;
 	import mx.rpc.AsyncResponder;
-	import mx.rpc.AsyncToken;
 	import mx.rpc.IResponder;
-	import mx.rpc.events.ResultEvent;

 	import org.openforis.collect.client.UpdateRequestToken;
 	import org.openforis.collect.event.ApplicationEvent;
-	import org.openforis.collect.metamodel.proxy.CodeAttributeDefinitionProxy;
-	import org.openforis.collect.metamodel.proxy.CodeListItemProxy;
 	import org.openforis.collect.model.FieldSymbol;
 	import org.openforis.collect.model.proxy.AttributeProxy;
-	import org.openforis.collect.model.proxy.CodeProxy;
 	import org.openforis.collect.model.proxy.FieldProxy;
 	import org.openforis.collect.remoting.service.UpdateRequest;
 	import org.openforis.collect.remoting.service.UpdateRequestOperation;
 	import org.openforis.collect.remoting.service.UpdateRequestOperation$Method;
 	import org.openforis.collect.remoting.service.UpdateResponse;
-	import org.openforis.collect.ui.component.input.CodeInputField;
-	import org.openforis.collect.ui.component.input.CodeListDialog;
 	import org.openforis.collect.ui.component.input.MultipleCodeInputField;
-	import org.openforis.collect.ui.component.input.TextInput;
 	import org.openforis.collect.util.ArrayUtil;
 	import org.openforis.collect.util.CollectionUtil;
 	import org.openforis.collect.util.StringUtil;
@@ -134,46 +121,7 @@
 			token.remarks = remarks;
 			dataClient.updateActiveRecord(req, token, updateResultHandler, faultHandler);
 		}
-		/*
-		override public function applyRemarks(remarks:String):void {
-			var updatedFields:ArrayCollection = new ArrayCollection();
-			var operations:ArrayCollection = new ArrayCollection();
-			for each (var a:AttributeProxy in _view.attributes) {
-				var value:String = codeAttributeToText(a);
-				var field:FieldProxy = a.getField(0);
-				var symbol:FieldSymbol = field.symbol;
-				var o:UpdateRequestOperation = getUpdateRequestOperation(UpdateRequestOperation$Method.UPDATE,
-					a.id, value, symbol, remarks);
-				operations.addItem(o);
-				updatedFields.addAll(a.fields);
-			}
-			var req:UpdateRequest = new UpdateRequest();
-			req.operations = operations;
-			var token:UpdateRequestToken = new UpdateRequestToken(UpdateRequestToken.TYPE_UPDATE_REMARKS);
-			token.remarks = remarks;
-			token.updatedFields = updatedFields;
-			dataClient.updateActiveRecord(req, token, updateResultHandler, faultHandler);
-		}

-		override public function applySymbol(symbol:FieldSymbol):void {
-			var updatedFields:ArrayCollection = new ArrayCollection();
-			var operations:ArrayCollection = new ArrayCollection();
-			var remarks:String = getRemarks();
-			for each (var a:AttributeProxy in _view.attributes) {
-				var value:String = codeAttributeToText(a);
-				var o:UpdateRequestOperation = getUpdateRequestOperation(UpdateRequestOperation$Method.UPDATE,
-					a.id, value, symbol, remarks);
-				operations.addItem(o);
-				updatedFields.addAll(a.fields);
-			}
-			var req:UpdateRequest = new UpdateRequest();
-			req.operations = operations;
-			var token:UpdateRequestToken = new UpdateRequestToken(UpdateRequestToken.TYPE_UPDATE_SYMBOL);
-			token.updatedFields = updatedFields;
-			token.symbol = symbol;
-			dataClient.updateActiveRecord(req, token, updateResultHandler, faultHandler);
-		}
-		*/
 		override protected function getRemarks():String {
 			if(CollectionUtil.isNotEmpty(_view.attributes)) {
 				var a:AttributeProxy = AttributeProxy(_view.attributes.getItemAt(0));


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

 package spark.automation.delegates.components
 {


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

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

 package mx.managers
 {


asdoc

asdoc

git-svn-id: 27326a786375daad9d33dc990c6f272e4c8f567c@1339 fda5f131-174c-0410-8613-e0905860106b

--- org.openwms/trunk/org.openwms.common/org.openwms.common.domain.as/src/main/flex/org/openwms/common/domain/types/Target.as
+++ org.openwms/trunk/org.openwms.common/org.openwms.common.domain.as/src/main/flex/org/openwms/common/domain/types/Target.as
@@ -20,6 +20,12 @@
  */
 package org.openwms.common.domain.types {

+    /**
+     * A Target is used for TransportOrders and is only a marker interface.
+     *
+     * @version $Revision: 1039 $
+     * @since 0.1
+     */
     public interface Target {
     }
 }


FEC-110 #comment fix midrolls issue

FEC-110 #comment fix midrolls issue

--- plugins/vastPlugin/src/com/kaltura/kdpfl/plugin/component/VastLinearAdProxy.as
+++ plugins/vastPlugin/src/com/kaltura/kdpfl/plugin/component/VastLinearAdProxy.as
@@ -86,11 +86,11 @@
 		/**
 		 * for vast3 ad pods: the current translator index to create elements from
 		 */
-		private var _curTranslatorIndex:int = 0;
+		private var _curTranslatorIndex:int;
 		/**
 		 * indicates we are playing sequenced ads, not a standalone ad
 		 */
-		public var sequencedAds:Boolean = false;
+		public var sequencedAds:Boolean;

 		private var _initialVpaidDuration:int;

@@ -205,6 +205,8 @@
 				_loadTimer.removeEventListener(TimerEvent.TIMER_COMPLETE, onLoadTimeout );
 				_vastDocument = (e.loadTrait as VASTLoadTrait).vastDocument;
 				_vastMediaGenerator = new VASTMediaGenerator(null, _mediaFactory);
+				_curTranslatorIndex = 0;
+				sequencedAds = false;
 				if (_vastDocument.vastVersion == VASTDataObject.VERSION_3_0)
 					setStartingTranslatorIndex();

@@ -301,7 +303,6 @@

 			//_playingAd.addEventListener("traitAdd", onAdPlayable);
-			var sequenceProxy : Object = facade.retrieveProxy("sequenceProxy");

 			if (_playingAdClickThru) {
 				playerMediator["kMediaPlayer"].addEventListener(MouseEvent.CLICK, onAdClick);
@@ -364,7 +365,7 @@
 			(playerMediator["player"] as MediaPlayer).addEventListener( MediaPlayerCapabilityChangeEvent.CAN_PLAY_CHANGE , onAdPlayable );

 			//if we're playing ad pods, don't switch elements again
-			if (_curTranslatorIndex)
+			if (sequencedAds)
 			{
 				(mediaProxy.vo.media as KSwitchingProxyElement).proxiedElement = _playingAd;
 			}


Transferred from the Adobe Open Source Subversion Repository

Revision: 13188
Author:   deeptika@adobe.com
Date:     2009-12-23T14:26:40.641841Z

Log Message:
-----------
Fix for FLEXENT-1204 ([AIR Specific]Not compiling a halo AIR App with automation_spark.swc causes an RTE)

Fix: Moving spark related AIR delegates from automation_air package to new package automation_airspark

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_air/build.xml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_air/manifest_automation_air.xml</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/manifest_automation_airspark.xml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/src/spark/automation/delegates/components/SparkWindowedApplicationAutomationImpl.as</path>
<path kind="dir" action="D">/flex/sdk/trunk/frameworks/projects/automation_air/src/spark</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/src/spark/automation/delegates/components/SparkWindowAutomationImpl.as</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/src/spark</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/src/spark/automation/delegates/components</path>
<path kind="file" action="M">/flex/sdk/trunk/build.xml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/automation_air/src/AutomationAirClasses.as</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/src/spark/automation/delegates</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/src/AutomationAirSparkClasses.as</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/src/spark/automation</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/automation_airspark/src</path>

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

--- frameworks/projects/automation_airspark/src/spark/automation/delegates/components/SparkWindowedApplicationAutomationImpl.as
+++ frameworks/projects/automation_airspark/src/spark/automation/delegates/components/SparkWindowedApplicationAutomationImpl.as
@@ -0,0 +1,209 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2009 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package spark.automation.delegates.components
+{
+	import flash.display.DisplayObject;
+	import flash.events.Event;
+
+	import mx.automation.Automation;
+	import mx.automation.IAutomationManager2;
+	import mx.automation.IAutomationObject;
+	import mx.core.mx_internal;
+	import mx.events.WindowExistenceEvent;
+
+	import spark.automation.delegates.components.SparkApplicationAutomationImpl;
+	import spark.components.WindowedApplication;
+	import mx.automation.IAutomationObjectHelper;
+
+	use namespace mx_internal;
+
+	[Mixin]
+	/**
+	 *
+	 *  Defines the methods and properties required to perform instrumentation for the
+	 *  SparkWindowedApplication class.
+	 *
+	 *  @see spark.components.WindowedApplication
+	 *
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 4
+	 */
+	public class SparkWindowedApplicationAutomationImpl extends  SparkApplicationAutomationImpl
+	{
+
+		//--------------------------------------------------------------------------
+		//
+		//  Class methods
+		//
+		//--------------------------------------------------------------------------
+
+		/**
+		 *  Registers the delegate class for a component class with automation manager.
+		 *
+		 *  @param root The SystemManger of the application.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 9
+		 *  @playerversion AIR 1.1
+		 *  @productversion Flex 4
+		 */
+		public static function init(root:DisplayObject):void
+		{
+			Automation.registerDelegateClass(spark.components.WindowedApplication, SparkWindowedApplicationAutomationImpl);
+		}
+
+		//--------------------------------------------------------------------------
+		//
+		//  Constructor
+		//
+		//--------------------------------------------------------------------------
+
+		/**
+		 *  Constructor.
+		 * @param obj WindowedApplication object to be automated.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 9
+		 *  @playerversion AIR 1.1
+		 *  @productversion Flex 4
+		 */
+		public function SparkWindowedApplicationAutomationImpl(obj:spark.components.WindowedApplication)
+		{
+			super(obj);
+			obj.showInAutomationHierarchy = true;
+
+			obj.addEventListener(WindowExistenceEvent.WINDOW_CREATE,newWindowHandler);
+			obj.addEventListener(WindowExistenceEvent.WINDOW_CREATING,newWindowCreatingHandler);
+			obj.addEventListener("menuChanged", menuChangeHandler);
+			recordClick = true;
+		}
+
+
+		/**
+		 * @private
+		 */
+		private function menuChangeHandler(event:Event):void
+		{
+			Automation.automationManager2.registerNewFlexNativeMenu(windowedApplication.menu, windowedApplication.systemManager as DisplayObject);
+
+		}
+
+		/**
+		 *  @private
+		 */
+		private function newWindowHandler(event:WindowExistenceEvent):void
+		{
+			newIncompleteWindowCount--;
+			Automation.automationManager2.registerNewWindow(event.window as DisplayObject);
+		}
+
+		/**
+		 *  @private
+		 */
+		private var newIncompleteWindowCount:int = 0;
+
+
+		/**
+		 *  @private
+		 */
+		private function newWindowCreatingHandler(event:WindowExistenceEvent):void
+		{
+			var help:IAutomationObjectHelper = Automation.automationObjectHelper;
+			newIncompleteWindowCount ++;
+			help.addSynchronization(function():Boolean
+			{
+				return newIncompleteWindowCount==0;
+			});
+		}
+
+		/**
+		 *  @private
+		 */
+		public function get windowedApplication():spark.components.WindowedApplication
+		{
+			return  uiComponent as spark.components.WindowedApplication;
+		}
+
+		/**
+		 *  @private
+		 */
+		override public function get automationName():String
+		{
+			var am:IAutomationManager2 = Automation.automationManager2;
+			return am.getUniqueApplicationID();
+		}
+
+		/**
+		 * @private
+		 */
+		override public function get numAutomationChildren():int
+		{
+			//FlexNativeMenu can also be child of WindowedApplication.
+			//So this is added if it exists. We are doing this only for Window and
+			//WindowedApplication because at present we receive menuChanged
+			//event only on these 2 controls if a FlexNativeMenu is there
+			var count:int = super.numAutomationChildren;
+			if (windowedApplication.menu)
+				return(count + 1);
+			else
+				return count;
+		}
+
+
+		override public function getAutomationChildAt(index:int):IAutomationObject
+		{
+			//FlexNativeMenu can also be child of WindowedApplication.
+			//So if it exists, it is considered to be the first child.
+			// We are doing this only for Window and
+			//WindowedApplication because at present we receive menuChanged
+			//event only on these 2 controls if a FlexNativeMenu is there
+			if (windowedApplication.menu)
+			{
+				if (index == 0)
+					return windowedApplication.menu as IAutomationObject;
+				index = index - 1;
+			}
+			return super.getAutomationChildAt(index);
+		}
+
+
+		/**
+		 * @private
+		 */
+		override public function getAutomationChildren():Array
+		{
+			var childList:Array = new Array();
+
+			// add the menu as the first element
+			if(windowedApplication.menu)
+				childList.push(windowedApplication.menu as IAutomationObject);
+
+			var tempList:Array = super.getAutomationChildren();
+			if (tempList)
+			{
+				var n:int  = tempList.length;
+				for(var i:int=0; i<n; i++)
+				{
+					childList.push(tempList[i] as IAutomationObject);
+				}
+			}
+
+			return childList;
+		}
+
+
+	}
+
+}


support 120 and 640 dpi in mustella tests

--- mustella/as3/src/mustella/ConditionalValue.as
+++ mustella/as3/src/mustella/ConditionalValue.as
@@ -52,7 +52,7 @@
 		public var targetOS:String = null;

 		// General, "marketing number" pixel density
-		[Inspectable(enumeration="160,240,320,480")]
+		[Inspectable(enumeration="120,160,240,320,480,640")]
 		public var deviceDensity:Number = -1;

 		// Exact pixel density reported by AIR's Capabilities.screenDPI


Cleanup code.

Cleanup code.

--- HLSPlugin/src/org/denivip/osmf/net/httpstreaming/hls/HTTPStreamingMP2PESVideo.as
+++ HLSPlugin/src/org/denivip/osmf/net/httpstreaming/hls/HTTPStreamingMP2PESVideo.as
@@ -46,7 +46,6 @@

 		public function HTTPStreamingMP2PESVideo()
 		{
-			dataReturnTag = new ByteArray();
 			_scState = 0;
 			_nalData = new ByteArray();
 			_vTag = null;
@@ -55,7 +54,7 @@

 		override public function processES(pusi:Boolean, packet:ByteArray, flush:Boolean = false): ByteArray
 		{
-			dataReturnTag.clear();
+			dataReturnTag = new ByteArray();
 			var i:int, l:int;
 			if(pusi)
 			{
@@ -133,7 +132,6 @@
 				var dStart:uint = packet.position;	// assume that the copy will be from start-of-data

 			var nal:HTTPStreamingH264NALU;
-			var avccTag:FLVTagVideo = null;
 			if(flush)
 			{
 				nal = new HTTPStreamingH264NALU(_nalData); // full length to end, don't need to trim last 3 bytes
@@ -267,12 +265,12 @@
 				avcc = new ByteArray();
 				var spsLength:Number = spsNAL.length;
 				var ppsLength:Number = ppsNAL.length;
-				tag = new FLVTagVideo();
+				avccTag = new FLVTagVideo();

 				//tag.timestamp = _timestamp;
-				tag.codecID = FLVTagVideo.CODEC_ID_AVC;
-				tag.frameType = FLVTagVideo.FRAME_TYPE_KEYFRAME;
-				tag.avcPacketType = FLVTagVideo.AVC_PACKET_TYPE_SEQUENCE_HEADER;
+				avccTag.codecID = FLVTagVideo.CODEC_ID_AVC;
+				avccTag.frameType = FLVTagVideo.FRAME_TYPE_KEYFRAME;
+				avccTag.avcPacketType = FLVTagVideo.AVC_PACKET_TYPE_SEQUENCE_HEADER;

 				avcc.writeByte(0x01); // avcC version 1
 				// profile, compatibility, level
@@ -287,39 +285,12 @@
 				avcc.writeByte(ppsLength);
 				avcc.writeBytes(ppsNAL.NALdata, 0, ppsLength);

-				tag.data = avcc;
-
-				//	writeReturnTag(tag);
-				// doing this later on in the AUD
-				avccTag = tag;
+				// writeReturnTag(avccTag); // doing this later on in the AUD, doing it here may cause the decoder to skip frames.
+
+				avccTag.data = avcc;

 				spsNAL = null;
-				ppsNAL = null;
-
-			}else if(avccTag){
-				//update the spsNAL nal if it exists
-				if (spsNAL) {
-					avcc = avccTag.data;
-					avcc.position = 1;
-					avcc.writeBytes(spsNAL.NALdata, 1, 3);
-					avcc.writeByte(0xff); // 111111 + 2 bit NAL size - 1
-					avcc.writeByte(0xe1); // number of SPS
-					avcc.writeByte(spsLength >> 8); // 16-bit SPS byte count
-					avcc.writeByte(spsLength);
-					avcc.writeBytes(spsNAL.NALdata, 0, spsLength); // the SPS
-				}
-				//update the ppsNAL nal if it exists
-				if (ppsNAL) {
-					avcc = avccTag.data;
-					avcc.position = 8;
-					var l:int = avcc.readByte();
-					avcc.position += l;
-
-					avcc.writeByte(0x01); // number of PPS
-					avcc.writeByte(ppsLength >> 8); // 16-bit PPS byte count
-					avcc.writeByte(ppsLength);
-					avcc.writeBytes(ppsNAL.NALdata, 0, ppsLength);
-				}
+				ppsNAL = null;
 			}

 			//http://gentlelogic.blogspot.nl/2011/11/exploring-h264-part-2-h264-bitstream.html
@@ -337,15 +308,15 @@
 					}
 				}

+				if(avccTag)
+				{
+					avccTag.timestamp = _vTag.timestamp;
+					writeReturnTag(avccTag);
+					avccTag = null;
+				}
+
 				if(_vTag && _vTagData.length > 0)
 				{
-
-					if(avccTag)
-					{
-						avccTag.timestamp = _vTag.timestamp;
-						writeReturnTag(avccTag);
-						//avccTag = null;
-					}
 					_vTag.data = _vTagData; // set at end (see below)
 					writeReturnTag(_vTag);
 					if (VideoInfo.glitchMode) {
@@ -398,4 +369,5 @@
 		}

 	} // class
+
 } // package


ADDED @private to internal API getters

ADDED @private to internal API getters

--- actionscript/src/com/marpies/ane/vk/VKRequest.as
+++ actionscript/src/com/marpies/ane/vk/VKRequest.as
@@ -117,14 +117,23 @@
             mErrorCallback = value;
         }

+        /**
+         * @private
+         */
         internal function get hasErrorCallback():Boolean {
             return mErrorCallback !== null;
         }

+        /**
+         * @private
+         */
         internal function get hasResponseCallback():Boolean {
             return mResponseCallback !== null;
         }

+        /**
+         * @private
+         */
         internal function get hasAnyCallback():Boolean {
             return hasErrorCallback || hasResponseCallback;
         }


Reversion. Once again, skip recursion on IXObjReferences

--- as3/xobjas3/src/com/rpath/xobj/XObjXMLEncoder.as
+++ as3/xobjas3/src/com/rpath/xobj/XObjXMLEncoder.as
@@ -299,14 +299,14 @@
         }
         else if (recurse)
         {
-            /* TODO: answer the question as to WHY we do not encode refs recursively
-            No longer clear on this use case
+            // TODO: answer the question as to WHY we do not encode refs recursively
+            // No longer clear on this use case
             if (obj is IXObjReference)
             {
                 // don't recurse refs
                 return internal_encodeValue(obj, qname, parentNode, false);
             }
-            else*/
+            else
                 return internal_encodeValue(obj, qname, parentNode);
         }
         else


Nasty fix for allowing encoding to support the same hacked implied collection semantics as decoding. Needed for descriptor roundtrips per RCE-1005

--- as3/xobjas3/src/com/rpath/xobj/XObjXMLEncoder.as
+++ as3/xobjas3/src/com/rpath/xobj/XObjXMLEncoder.as
@@ -146,7 +146,7 @@
     //--------------------------------------------------------------------------

-    public function XObjXMLEncoder(typeMap:*=null, nmMap: *=null, myXML:XML=null)
+    public function XObjXMLEncoder(typeMap:*=null, nmMap: *=null)
     {
         super();

@@ -237,7 +237,7 @@
         return encodeValue(obj, q, parentNode, false, true);
     }

-    internal function encodeValue(obj:Object, q:*, parentNode:XML, recurse:Boolean=true, referenceOnly:Boolean=false, isRoot:Boolean=false):XML
+    internal function encodeValue(obj:Object, q:*, parentNode:XML, recurse:Boolean=true, referenceOnly:Boolean=false, isRoot:Boolean=false, propName:String=null):XML
     {
         var qname:XObjQName;

@@ -292,7 +292,7 @@
             // unwrap XObjStrings to their naked value
             if (obj.value != null || encodeNullElements)
             {
-                newNode = encodeValue(obj.value, qname, parentNode);
+                newNode = encodeValue(obj.value, qname, parentNode,true,false,false,propName);
             }
             else
             {
@@ -306,11 +306,11 @@
         }
         else if (isRoot)
         {
-            return internal_encodeValue(obj, qname, parentNode, true, referenceOnly);
+            return internal_encodeValue(obj, qname, parentNode, true, referenceOnly, propName);
         }
         else if (referenceOnly)
         {
-            return internal_encodeValue(obj, qname, parentNode, false, true);
+            return internal_encodeValue(obj, qname, parentNode, false, true, propName);
         }
         else if (recurse)
         {
@@ -320,11 +320,11 @@
                 // don't recurse refs that have IDs since this means they are
                 // *by reference* uses relationships, not strict containment
                 // relationships.
-                return internal_encodeValue(obj, qname, parentNode, false);
+                return internal_encodeValue(obj, qname, parentNode, false, false, propName);
             }
             else
             {
-                return internal_encodeValue(obj, qname, parentNode);
+                return internal_encodeValue(obj, qname, parentNode, true, false, propName);
             }
         }
         else
@@ -338,7 +338,8 @@
                                            qname:XObjQName,
                                            parentNode:XML,
                                            recurse:Boolean=true,
-                                           referenceOnly:Boolean=false):XML
+                                           referenceOnly:Boolean=false,
+                                           propName:String=null):XML
     {
         var myElement:XML;

@@ -416,7 +417,7 @@
                             // remove elements we've handled to speed up the next iteration
                             // makes a HUGE difference on large collections of objects
                             properties.splice(k,1);
-                            encodeValue(obj[propName], entry.qname, myElement, recurse, XObjMetadata.isPropByRef(classInfo, propName));
+                            encodeValue(obj[propName], entry.qname, myElement, recurse, XObjMetadata.isPropByRef(classInfo, propName), false, propName);
                             break;
                         }
                     }
@@ -439,50 +440,72 @@
                     continue;

                 var propQName:XObjQName = new XObjQName(null, null, fieldName);
-                encodeValue(obj[fieldName], propQName, myElement, recurse, XObjMetadata.isPropByRef(classInfo, fieldName));
+                encodeValue(obj[fieldName], propQName, myElement, recurse, XObjMetadata.isPropByRef(classInfo, fieldName), false, fieldName);
             }
         }
         else if (typeType == XObjXMLEncoder.IXOBJ_COLLECTION
             || typeType == XObjXMLEncoder.ARRAY_TYPE)
         {
-            // link us into the heirarchy so that namespaces
-            // will be resolved up the chain correctly
-            parentNode.appendChild(myElement);
-            setAttributes(myElement, obj);
-            myElement.setName(XObjUtils.encodeElementTag(qname, myElement));
-
-            // encode array elements
-            for (var j:int=0; j < obj.length; j++)
-            {
-                var localName:String = "item";  //assume item unless told otherwise
-                var member:* = obj[j];
+            var localName:String = "item";  //assume item unless told otherwise
+
+            //if (encodeNullElements || obj.length > 0)
+            //{
+                // link us into the heirarchy so that namespaces
+                // will be resolved up the chain correctly
+                var flatten:Boolean;

-                // force use of item for local name if simpleEncoderCompatible is true
-                if (!simpleEncoderCompatible)
+                if ((obj is IXObjCollection) && obj.length > 0)
                 {
-                    // look up the right qname to use
-                    if (obj is IXObjCollection)
-                    {
-                        localName = (obj as IXObjCollection).elementTagForMember(member);
-                    }
-                    else
-                    {
-                        // do we have meta?
-                        var meta:XObjMetadata = XObjMetadata.getMetadata(obj, false);
-                        if (meta && meta.arrayEntryTag)
-                            localName = meta.arrayEntryTag;
-                        else
-                            localName = tagForType(member);
-                    }
+                    var tag:String = (obj as IXObjCollection).elementTagForMember(obj[0]);
+                    // is the element tag same as propname?
+                    if (tag == propName)
+                        flatten = true;
+                }
+
+                if (flatten)
+                {
+                    // hoist children
+                    myElement = parentNode;
+                }
+                else
+                {
+                    parentNode.appendChild(myElement);
+                    setAttributes(myElement, obj);
+                    myElement.setName(XObjUtils.encodeElementTag(qname, myElement));
                 }

-                qname = new XObjQName(null, null, localName);
-
-                if (XObjUtils.isByReference(obj))
-                    encodeReference(member, qname, myElement);
-                else
-                    encodeValue(member, qname, myElement, recurse);
-            }
+                // encode array elements
+                for (var j:int=0; j < obj.length; j++)
+                {
+                    var member:* = obj[j];
+
+                    // force use of item for local name if simpleEncoderCompatible is true
+                    if (!simpleEncoderCompatible)
+                    {
+                        // look up the right qname to use
+                        if (obj is IXObjCollection)
+                        {
+                            localName = (obj as IXObjCollection).elementTagForMember(member);
+                        }
+                        else
+                        {
+                            // do we have meta?
+                            var meta:XObjMetadata = XObjMetadata.getMetadata(obj, false);
+                            if (meta && meta.arrayEntryTag)
+                                localName = meta.arrayEntryTag;
+                            else
+                                localName = tagForType(member);
+                        }
+                    }
+
+                    qname = new XObjQName(null, null, localName);
+
+                    if (XObjUtils.isByReference(obj))
+                        encodeReference(member, qname, myElement);
+                    else
+                        encodeValue(member, qname, myElement, recurse);
+                }
+            //}
         }
         else // must be simple type
         {


:memo:

:memo:

--- index.as
+++ index.as
@@ -28,8 +28,11 @@
 // [ ] Augmented Assignment for `<<=` and `>>=`

-// [ ] Functions can have generic type parameters `def method[..]`
-// [ ] `Identifier` is wrapped in a `Name` object (that can optionally have type parameters)
+// [x] Functions can have generic type parameters `def method[..]`
+// [x] `Identifier` is wrapped in a `Name` object (that can optionally have type parameters)
+// [ ] TypeDeduce in regards to `Name`
+// [ ] Duplicate instantiate should not create more things
+// [ ] Test!

 extern def printf(format: str, ...);


Transferred from the Adobe Open Source Subversion Repository

Revision: 22184
Author:   aharui@adobe.com
Date:     2011-08-24T20:18:37.535864Z

Log Message:
-----------
Allow more errors to be ignored during bindings

QE notes: none
Doc notes: none
Bugs: SDK-30491
Reviewer: Altman
Tests run: Mustella Cyclone
Is noteworthy for integration: No

Modified Paths:
--------------
/private/flex/sdk/branches/4.y/frameworks/projects/framework/src/mx/binding/Binding.as

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

--- frameworks/projects/framework/src/mx/binding/Binding.as
+++ frameworks/projects/framework/src/mx/binding/Binding.as
@@ -27,7 +27,19 @@
 {
     include "../core/Version.as";

-	//--------------------------------------------------------------------------
+    // Certain errors are normal during binding execution, so we swallow them.
+    // 1507 - invalid null argument
+    // 2005 - argument error (null gets converted to 0)
+    mx_internal static var allowedErrors:Object = generateAllowedErrors();
+    mx_internal static function generateAllowedErrors():Object
+    {
+        var o:Object = {};
+        o[1507] = 1;
+        o[2005] = 1;
+        return o;
+    }
+
+    //--------------------------------------------------------------------------
 	//
 	//  Constructor
 	//
@@ -322,9 +334,7 @@
         }
         catch(error:Error)
         {
-            // Certain errors are normal during binding execution, so we swallow them.
-            // 1507 - invalid null argument
-            if (error.errorID != 1507)
+            if (allowedErrors[error.errorID] == null)
                 throw error;
         }
         finally