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

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


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

--- frameworks/projects/spark/src/spark/utils/MaskUtil.as
+++ frameworks/projects/spark/src/spark/utils/MaskUtil.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: 9892
Author:   aharui@adobe.com
Date:     2009-09-01T23:06:51.962646Z

Log Message:
-----------
Panel skin changes per XD spec, and a few other Panel Skin bugs.  Default Panel size changed to match spec.  Panel titles are now single-line and show ellipsis.

QE Notes: Panel-related bitmap compares will need upgrading
Panel_Properties_title5
Panel_Properties_DfrdInst_none
Panel_Properties_DfrdInst_auto

Doc Notes: None
Bugs: SDK-21680, SDK-21671, SDK-21666, SDK-19962, SDK-19959
Reviewer: Ryan
API Change: No
Is noteworthy for integration: No
tests: checkintests mustella/managers/Panel

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/wireframe/src/WireframeClasses.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Panel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/skins/spark/PanelSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/wireframe/defaults.css</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/PanelSkin.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/skins/spark/ApplicationSkin.mxml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wireframe/ApplicationSkin.mxml</path>

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

--- frameworks/projects/wireframe/src/WireframeClasses.as
+++ frameworks/projects/wireframe/src/WireframeClasses.as
@@ -24,6 +24,7 @@
  */
 internal class WireframeClasses
 {
+	import spark.skins.wireframe.ApplicationSkin; ApplicationSkin;
 	import spark.skins.wireframe.ButtonBarFirstButtonSkin; ButtonBarFirstButtonSkin;
 	import spark.skins.wireframe.ButtonBarLastButtonSkin; ButtonBarLastButtonSkin;
 	import spark.skins.wireframe.ButtonBarMiddleButtonSkin; ButtonBarMiddleButtonSkin;


Comment.

Comment.

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

--- src/as/com/threerings/util/Comparable.as
+++ src/as/com/threerings/util/Comparable.as
@@ -23,6 +23,11 @@

 public interface Comparable
 {
+    /**
+     * Compare this object to the other one, and return 0 if they're equal,
+     * -1 if this object is less than the other, or 1 if this object is greater.
+     * Note: Please use [-1, 0, 1] to be compatible with flex Sort objects.
+     */
     function compareTo (other :Object) :int;
 }
 }


Fix simpleToString() per Tim's desire:
Cope with a bogus passed-in property name.

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

--- src/as/com/threerings/util/StringUtil.as
+++ src/as/com/threerings/util/StringUtil.as
@@ -414,7 +414,12 @@
             if (appended) {
                 buf.append(", ");
             }
-            buf.append(varName, "=", obj[varName]);
+            buf.append(varName, "=");
+            try {
+                buf.append(obj[varName]);
+            } catch (re :ReferenceError) {
+                buf.append("<ReferenceError>");
+            }
             appended = true;
         }
     }


Added startsWith().

Added startsWith().

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

--- src/as/com/threerings/util/StringUtil.as
+++ src/as/com/threerings/util/StringUtil.as
@@ -35,6 +35,15 @@
     }

     /**
+     * Does the specified string start with the specified substring.
+     */
+    public static function startsWith (str :String, substr :String) :Boolean
+    {
+        // just check once if it's at the beginning
+        return (str.lastIndexOf(substr, 0) == 0);
+    }
+
+    /**
      * Utility function that strips whitespace from the ends of a String.
      */
     public static function trim (str :String) :String


prevent NPE when encountering missing library items

--- exporter/src/main/as/flump/xfl/XflLibrary.as
+++ exporter/src/main/as/flump/xfl/XflLibrary.as
@@ -66,12 +66,18 @@
                 for each (var kf :KeyframeMold in layer.keyframes) {
                     if (kf.libraryItem != null) {
                         var item :Object = _libraryItems[kf.libraryItem];
-                        if (item.symbol == null) {
-                            // This unexported movie was referenced, generate a symbol name for it
-                            item.symbol = IMPLICIT_PREFIX + item.libraryItem;
-                            _symbols[item.symbol] = item;
+                        if (item == null) {
+                            addError(kf, ParseError.CRIT,
+                                "unrecognized library item '" + kf.libraryItem + "'");
+                        } else {
+                            if (item.symbol == null) {
+                                // This unexported movie was referenced,
+                                // generate a symbol name for it
+                                item.symbol = IMPLICIT_PREFIX + item.libraryItem;
+                                _symbols[item.symbol] = item;
+                            }
+                            kf.symbol = item.symbol;
                         }
-                        kf.symbol = item.symbol;
                     }
                 }
             }


Made a change to CollaborationService that should enable the proper loading of the session state when a user first joins.

--- WeaveData/src/weave/services/collaboration/CollaborationService.as
+++ WeaveData/src/weave/services/collaboration/CollaborationService.as
@@ -114,7 +114,7 @@
 		private var roomToJoin:String;
 		private var username:String;

-		//private var server:String = 			"129.63.17.121";
+		private var server:String = 			"daisy";
 		private var compName:String = 			"@conference";

 		//The port defines a secure connection
@@ -327,7 +327,7 @@

 				// handle a message from a user
 				var o:Object = decodeObject(e.data.body);
-				WeaveAPI.ErrorManager.reportError( new Error( ObjectUtil.toString( o )) );
+				//WeaveAPI.ErrorManager.reportError( new Error( ObjectUtil.toString( o )) );

 				//var room:String = e.data.from.node;
 				var userAlias:String = e.data.from.resource;
@@ -473,10 +473,11 @@
 			//if no one else is in room, start logging
 			if( userList.length == 0)
 			{
-				if( stateLog != null )
-					throw new Error();
-				stateLog = registerDisposableChild( this, new SessionStateLog( root ) );
-				getCallbackCollection( stateLog ).addImmediateCallback( this, handleStateChange );
+				if( stateLog == null )
+				{
+					stateLog = registerDisposableChild( this, new SessionStateLog( root ) );
+					getCallbackCollection( stateLog ).addImmediateCallback( this, handleStateChange );
+				}
 				stateSet = true;
 			}
 			//If you are the user at the top of the list than send session


Rename local variables.

Rename local variables.

--- dolly-framework/src/test/actionscript/dolly/ClonerTest.as
+++ dolly-framework/src/test/actionscript/dolly/ClonerTest.as
@@ -57,33 +57,33 @@

 	[Test]
 	public function testCloneWithClassLevelMetadata():void {
-		const clone1:ClassLevelCloneable = Cloner.clone(classMarkedAsCloneable) as ClassLevelCloneable;
+		const clone:ClassLevelCloneable = Cloner.clone(classMarkedAsCloneable) as ClassLevelCloneable;

-		assertNotNull(clone1);
-		assertNotNull(clone1.property1);
-		assertEquals(clone1.property1, classMarkedAsCloneable.property1);
-		assertNotNull(clone1.property2);
-		assertEquals(clone1.property2, classMarkedAsCloneable.property2);
-		assertNotNull(clone1.property3);
-		assertEquals(clone1.property3, classMarkedAsCloneable.property3);
-		assertNotNull(clone1.writableField);
-		assertEquals(clone1.writableField, classMarkedAsCloneable.writableField);
+		assertNotNull(clone);
+		assertNotNull(clone.property1);
+		assertEquals(clone.property1, classMarkedAsCloneable.property1);
+		assertNotNull(clone.property2);
+		assertEquals(clone.property2, classMarkedAsCloneable.property2);
+		assertNotNull(clone.property3);
+		assertEquals(clone.property3, classMarkedAsCloneable.property3);
+		assertNotNull(clone.writableField);
+		assertEquals(clone.writableField, classMarkedAsCloneable.writableField);
 	}

 	[Test]
 	public function testCloneWithPropertyLevelMetadata():void {
-		const clone2:PropertyLevelCloneable = Cloner.clone(
+		const clone:PropertyLevelCloneable = Cloner.clone(
 				classWithSomeCloneableFields
 		) as PropertyLevelCloneable;

-		assertNotNull(clone2);
-		assertNull(clone2.property1);
-		assertNotNull(clone2.property2);
-		assertEquals(clone2.property2, classWithSomeCloneableFields.property2);
-		assertNotNull(clone2.property3);
-		assertEquals(clone2.property3, classWithSomeCloneableFields.property3);
-		assertNotNull(clone2.writableField);
-		assertEquals(clone2.writableField, classWithSomeCloneableFields.writableField);
+		assertNotNull(clone);
+		assertNull(clone.property1);
+		assertNotNull(clone.property2);
+		assertEquals(clone.property2, classWithSomeCloneableFields.property2);
+		assertNotNull(clone.property3);
+		assertEquals(clone.property3, classWithSomeCloneableFields.property3);
+		assertNotNull(clone.writableField);
+		assertEquals(clone.writableField, classWithSomeCloneableFields.writableField);
 	}
 }
 }


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

--- frameworks/projects/framework/src/mx/graphics/codec/IImageEncoder.as
+++ frameworks/projects/framework/src/mx/graphics/codec/IImageEncoder.as
@@ -0,0 +1,86 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  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.graphics.codec
+{
+
+import flash.display.BitmapData;
+import flash.utils.ByteArray;
+
+/**
+ *  The IImageEncoder interface defines the interface
+ *  that image encoders implement to take BitmapData objects,
+ *  or ByteArrays containing raw ARGB pixels, as input
+ *  and convert them to popular image formats such as PNG or JPEG.
+ *
+ *  @see PNGEncoder
+ *  @see JPEGEncoder
+ */
+public interface IImageEncoder
+{
+	//--------------------------------------------------------------------------
+	//
+	//  Properties
+	//
+	//--------------------------------------------------------------------------
+
+	//----------------------------------
+	//  contentType
+	//----------------------------------
+
+    /**
+     *  The MIME type for the image format that this encoder produces.
+     */
+    function get contentType():String;
+
+	//--------------------------------------------------------------------------
+	//
+	//  Methods
+	//
+	//--------------------------------------------------------------------------
+
+    /**
+     *  Encodes a BitmapData object as a ByteArray.
+     *
+     *  @param bitmapData The input BitmapData object.
+     *
+     *  @returns A ByteArray object containing encoded image data.
+     */
+    function encode(bitmapData:BitmapData):ByteArray;
+
+    /**
+     *  Encodes a ByteArray object containing raw pixels
+	 *  in 32-bit ARGB (Alpha, Red, Green, Blue) format
+	 *  as a new ByteArray object containing encoded image data.
+	 *  The original ByteArray is left unchanged.
+     *
+     *  @param byteArray The input ByteArray object containing raw pixels.
+	 *  This ByteArray should contain
+	 *  4 * width * height bytes.
+	 *  Each pixel is represented by 4 bytes, in the order ARGB.
+	 *  The first four bytes represent the top-left pixel of the image.
+	 *  The next four bytes represent the pixel to its right, etc.
+	 *  Each row follows the previous one without any padding.
+     *
+     *  @param width The width of the input image, in pixels.
+     *
+     *  @param height The height of the input image, in pixels.
+     *
+     *  @param transparent If false,
+	 *  alpha channel information is ignored.
+     *
+     *  @returns A ByteArray object containing encoded image data.
+     */
+    function encodeByteArray(byteArray:ByteArray, width:int, height:int,
+							 transparent:Boolean = true):ByteArray;
+}
+
+}


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

--- frameworks/projects/mx/src/mx/skins/halo/DateChooserYearArrowSkin.as
+++ frameworks/projects/mx/src/mx/skins/halo/DateChooserYearArrowSkin.as
@@ -20,6 +20,11 @@
 /**
  *  The skin for all the states of the next-year and previous-year
  *  buttons in a DateChooser.
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 public class DateChooserYearArrowSkin extends Border
 {
@@ -33,6 +38,11 @@

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


Transferred from the Adobe Open Source Subversion Repository

Revision: 7557
Author:   hmuller@adobe.com
Date:     2009-06-04T18:20:14.485851Z

Log Message:
-----------
Fix for virtual TileLayout hang, one virtual layout3D problem.   Third time for the DataGroup
changes.   This time I (really) mean it.

QE Notes:
Doc Notes:
Bugs: sdk-21538, sdk-21519
Reviewer: Evtim

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/DataGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/layouts/TileLayout.as</path>

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

--- frameworks/projects/spark/src/spark/layouts/TileLayout.as
+++ frameworks/projects/spark/src/spark/layouts/TileLayout.as
@@ -1211,7 +1211,7 @@
             {
                 visibleStartIndex = (visibleRow0 * _columnCount);
                 visibleEndIndex = Math.min(eltCount - 1, (visibleRow1 * _columnCount) + visibleCol1);
-                visibleStartY = visibleRow0 * rwg;
+                visibleStartY = visibleRow0 * rwg;
             }
             else
             {
@@ -1235,19 +1235,17 @@
      {
         var oldVisibleStartIndex:int = visibleStartIndex;
         var oldVisibleEndIndex:int = visibleEndIndex;
-        calculateDisplayParameters(unscaledWidth, unscaledHeight);
+        calculateDisplayParameters(unscaledWidth, unscaledHeight);  // compute new visibleStart,EndIndex values

-        // We're responsible for the laying *all* of the elements requested
+        // We're responsible for laying out *all* of the elements requested
         // with getVirtualElementAt(), even if they don't fall within the final
         // visible range.  Hide any extra ones.  On the next layout pass, they'll
         // be added to DataGroup::freeRenderers

         var layoutTarget:GroupBase = target;
-        var start:int = Math.min(visibleStartIndex, oldVisibleStartIndex);
-        var end:int = Math.max(visibleEndIndex, oldVisibleEndIndex);
-        for(var i:int = start; i <= end; i++)
-        {
-            if (i == visibleStartIndex)
+        for(var i:int = oldVisibleStartIndex; i <= oldVisibleEndIndex; i++)
+        {
+            if ((i >= visibleStartIndex) && (i <= visibleEndIndex)) // skip past the visible range
             {
                 i = visibleEndIndex;
                 continue;


modified for use in iOS simulator (no longer supported in simulator)

--- actionscript/src/com/freshplanet/ane/AirCrashlytics/AirCrashlytics.as
+++ actionscript/src/com/freshplanet/ane/AirCrashlytics/AirCrashlytics.as
@@ -40,7 +40,7 @@
 		 * Is AirCrashlytics supported on the current platform
 		 */
 		public static function get isSupported():Boolean {
-			return Capabilities.manufacturer.indexOf("iOS") > -1 || Capabilities.manufacturer.indexOf("Android") > -1;
+			return (Capabilities.manufacturer.indexOf("iOS") > -1 && Capabilities.os.indexOf("x86_64") < 0 && Capabilities.os.indexOf("i386") < 0) || Capabilities.manufacturer.indexOf("Android") > -1;
 		}

 		/**


fix Mesh.computedVisibility to take material and material.effect availability into account: mesh without material/effect are now considered as hidden

--- src/aerys/minko/scene/node/Mesh.as
+++ src/aerys/minko/scene/node/Mesh.as
@@ -161,9 +161,9 @@

         override public function get computedVisibility() : Boolean
         {
-            return scene
-				? super.computedVisibility && _visibility.computedVisibility
-				: super.computedVisibility;
+			var visibility : Boolean = super.computedVisibility && _material && _material.effect;
+
+            return scene ? visibility && _visibility.computedVisibility : visibility;
         }

 		public function get frustumCulling() : uint


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

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

 package mx.charts.chartClasses
 {


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

--- frameworks/projects/mx/src/mx/controls/sliderClasses/SliderDataTip.as
+++ frameworks/projects/mx/src/mx/controls/sliderClasses/SliderDataTip.as
@@ -24,6 +24,11 @@
  *  @see mx.controls.sliderClasses.Slider
  *  @see mx.controls.sliderClasses.SliderLabel
  *  @see mx.controls.sliderClasses.SliderThumb
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 public class SliderDataTip extends ToolTip
 {
@@ -37,6 +42,11 @@

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


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

--- frameworks/projects/charts/src/mx/charts/renderers/LineRenderer.as
+++ frameworks/projects/charts/src/mx/charts/renderers/LineRenderer.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: 13208
Author:   chaase@adobe.com
Date:     2009-12-23T21:49:14.524642Z

Log Message:
-----------
Dealt with my FIXMEs in the code. Some went away (no longer issues), some became TODOs (still issues, but nothing that we have to solve in this release), a couple were actually resolved in this change (like the bug filed/fixed: 24848).

QE notes: 10 failures in Mustella of tests that need to be changed. They're excluded for now and QE has local fixes.
Doc notes: None
Bugs: SDK-24848
Reviewer: Jason
Tests run: checkintests, Mustella (spark/effects, mx/effects)
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/supportClasses/AnimateInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Move3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/animation/Animation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Rotate.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/supportClasses/AnimateTransitionShaderInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/CompositeEffect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/animation/MotionPath.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Move.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/PropertyChanges.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AnimateTransform.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/SliderBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/Effect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Scale3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Rotate3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/animation/Timeline.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/supportClasses/MoveInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AddAction.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Scale.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/SequenceInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/supportClasses/AnimateTransformInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/EffectTargetFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/RemoveAction.as</path>

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

--- frameworks/projects/framework/src/mx/effects/EffectTargetFilter.as
+++ frameworks/projects/framework/src/mx/effects/EffectTargetFilter.as
@@ -234,10 +234,9 @@
     public function filterInstance(propChanges:Array, semanticsProvider:IEffectTargetHost,
                                    target:Object):Boolean
     {
-        // FIXME (chaase): For better performance,
         if (filterFunction.length == 2)
             return filterFunction(propChanges, target);
-        else // if (filterFunction.length == 3)
+        else
             return filterFunction(propChanges, semanticsProvider, target);
     }


Transferred from the Adobe Open Source Subversion Repository

Revision: 17101
Author:   rfrishbe@adobe.com
Date:     2010-07-28T18:31:06.934256Z

Log Message:
-----------
Cleaning up lots of code, fixing some bugs, tweaking the API for List/Scroller, and tweaking the kinetics for Scroller.

Major API changes are:

1) Got rid of scrollAxis on IViewport.  We now just use horizontalScrollPolicy/verticalScrollPolicy.
2) No more overlay for horizontalScrollPolicy/verticalScrollPolicy.  Instead, we just key off of inputMode="touch" to determine this
3) spark.events.TouchScrollEvent moved to mx.events.TouchScrollEvent
4) Added new API to help with testing: mx.utils.GetTimerUtil.mx_internal::getTimerFunction

We now use the distance scrolled as well as the velocity of that scroll to determine how far to throw the list

QE notes: Added new API for testing purposes
Doc notes: None
Bugs: SDK-27031, SDK-27021
Reviewer: None - will review with mobile list stuff later (very soon in fact)
Tests run: checkintests, mustella Scroller, List, and ListDND
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/utils/GetTimerUtil.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/defaults.css</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/List.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/ScrollerLayout.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/TouchScrollingEasing.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/tools/dependencychecker/flex/tools/dependencychecker/FrameworkSwcDependencyRules.java</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GroupBase.as</path>
<path kind="file" action="D">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/events/TouchScrollEvent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/FrameworkClasses.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/RichEditableText.as</path>
<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/effects/animation/Animation.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/TrackBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/core/IViewport.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/ButtonBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/core/ScrollPolicy.as</path>
<path kind="file" copyfrom-path="/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/events/TouchScrollEvent.as" copyfrom-rev="17005" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/events/TouchScrollEvent.as</path>

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

--- frameworks/projects/spark/src/spark/components/RichEditableText.as
+++ frameworks/projects/spark/src/spark/components/RichEditableText.as
@@ -1077,35 +1077,6 @@
         }

         //----------------------------------
-        //  scrollAxis
-        //----------------------------------
-
-        private var _scrollAxis:String = "vertical";
-
-        /**
-         *  @copy spark.core.IViewport#scrollAxis
-         *
-         *  @default vertical
-         *
-         *  @langversion 3.0
-         *  @playerversion Flash 10
-         *  @playerversion AIR 1.5
-         *  @productversion Flex 4.5
-         */
-        public function get scrollAxis():String
-        {
-            return _scrollAxis;
-        }
-
-        /**
-         *  @private
-         */
-        public function set scrollAxis(value:String):void
-        {
-            _scrollAxis = value;
-        }
-
-        //----------------------------------
         //  verticalScrollPosition
         //----------------------------------


Added Input.clear() to clear all input states.

--- net/flashpunk/utils/Input.as
+++ net/flashpunk/utils/Input.as
@@ -197,6 +197,18 @@
 			if (mouseReleased) mouseReleased = false;
 		}

+		/**
+		 * Clears all input states.
+		 */
+		public static function clear():void
+		{
+			_press.length = _pressNum = 0;
+			_release.length = _releaseNum = 0;
+			var i:int = _key.length;
+			while (i --) _key[i] = false;
+			_keyNum = 0;
+		}
+
 		/** @private Event handler for key press. */
 		private static function onKeyDown(e:KeyboardEvent = null):void
 		{


Added documentation.

Added documentation.

Change-Id: I5bb3fc878474d34de86261d517d2e4c0e7174fc2

--- WeaveCore/src/weave/compiler/StandardLib.as
+++ WeaveCore/src/weave/compiler/StandardLib.as
@@ -66,6 +66,7 @@
 		}

 		/**
+		 * Converts a value to a non-null String
 		 * @param value A value to cast to a String.
 		 * @return The value cast to a String.
 		 */
@@ -98,15 +99,25 @@
 			return value;
 		}

+		/**
+		 * Tests if a value is anything other than undefined, null, or NaN.
+		 */
 		public static function isDefined(value:*):Boolean
 		{
 			return value !== undefined && value !== null && !(value is Number && isNaN(value));
 		}
+
+		/**
+		 * Tests if a value is undefined, null, or NaN.
+		 */
 		public static function isUndefined(value:*):Boolean
 		{
 			return value === undefined || value === null || (value is Number && isNaN(value));
 		}

+		/**
+		 * Pads a string on the left.
+		 */
 		public static function lpad(str:String, length:uint, padString:String = ' '):String
 		{
 			if (str.length >= length)
@@ -115,6 +126,10 @@
 				padString += padString;
 			return padString.substr(0, length - str.length) + str;
 		}
+
+		/**
+		 * Pads a string on the right.
+		 */
 		public static function rpad(str:String, length:uint, padString:String = ' '):String
 		{
 			if (str.length >= length)
@@ -226,6 +241,7 @@
 		}

 		/**
+		 * Converts a number to a String using a specific numeric base and optionally pads with leading zeros.
 		 * @param number The Number to convert to a String.
 		 * @param base Specifies the numeric base (from 2 to 36) to use.
 		 * @param zeroPad This is the minimum number of digits to return.  The number will be padded with zeros if necessary.
@@ -326,6 +342,7 @@
 		}

 		/**
+		 * Scales a number between 0 and 1 using specified min and max values.
 		 * @param value The value between min and max.
 		 * @param min The minimum value that corresponds to a result of 0.
 		 * @param max The maximum value that corresponds to a result of 1.
@@ -419,9 +436,10 @@
 		}

 		/**
+		 * Calculates an interpolated color for a normalized value.
 		 * @param normValue A Number between 0 and 1.
 		 * @param colors An Array or list of colors to interpolate between.  Normalized values of 0 and 1 will be mapped to the first and last colors.
-		 * @return An interpolated color associated with the given normValue based on the min,max color values.
+		 * @return An interpolated color associated with the given normValue based on the list of color values.
 		 */
 		public static function interpolateColor(normValue:Number, ...colors):Number
 		{
@@ -536,6 +554,9 @@
 			return values;
 		}

+		/**
+		 * Calculates the mean value from a list of Numbers.
+		 */
 		public static function mean(...args):Number
 		{
 			if (args.length == 1 && args[0] is Array)
@@ -546,6 +567,9 @@
 			return sum / args.length;
 		}

+		/**
+		 * Calculates the sum of a list of Numbers.
+		 */
 		public static function sum(...args):Number
 		{
 			if (args.length == 1 && args[0] is Array)


Change 20081117-maxcarlson-y by maxcarlson@Bank.local on 2008-11-17 17:33:30 PST
    in /Users/maxcarlson/openlaszlo/trunk-clean
    for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: Fix playback control for compiled-in SWF resources in swf9

Bugs Fixed: LPP-6757 - Media Resources example 4 indicates issues detecting SWF animation's frames in SWF9

Technical Reviewer: hminsky
QA Reviewer: promanik

Details: Coerce to a loader where possible to allow playback control.  See http://www.bit-101.com/blog/?p=1435 for the magic incantations...

Tests: See frames.lzx example attached to LPP-6757

git-svn-id: d62bde4b5aa582fdf07c8d403e53e0399a7ed285@11811 fa20e4f9-1d0a-0410-b5f3-dc9c16b8b17c

--- WEB-INF/lps/lfc/kernel/swf9/LzSprite.as
+++ WEB-INF/lps/lfc/kernel/swf9/LzSprite.as
@@ -1031,6 +1031,21 @@
                   this.addChildAt(asset,IMGDEPTH);

                   this.applyStretchResource();
+
+                  if (asset is MovieClip && this.totalframes == 1) {
+                    var loader:Loader = MovieClip(asset).getChildAt(0) as Loader;
+                    if (loader.content is AVM1Movie) {
+                        //no playback control for AVM1 movies...
+                    } else {
+                        // treat as a loader...
+                        // could they make this any less obvious?
+                        // see http://www.bit-101.com/blog/?p=1435
+                        this.__isinternalresource = false;
+                        this.loaderMC = MovieClip(loader.content);
+                        this.totalframes = this.loaderMC.totalFrames;
+                        this.loaderMC.gotoAndStop(fn);
+                    }
+                  }
               } else {
                   // bad resource?
               }


Added back lang() calls that were removed in merge.

--- WeaveClient/src/weave/VisApplication.as
+++ WeaveClient/src/weave/VisApplication.as
@@ -725,10 +725,10 @@
 				}

 				if(Weave.properties.enableAddDataSource.value)
-					_weaveMenu.addMenuItemToMenu(_dataMenu, new WeaveMenuItem("Add New Datasource", AddDataSourcePanel.showAsPopup, null, function():Boolean { return Weave.properties.enableAddNewDatasource.value }));
+					_weaveMenu.addMenuItemToMenu(_dataMenu, new WeaveMenuItem(lang("Add New Datasource"), AddDataSourcePanel.showAsPopup, null, function():Boolean { return Weave.properties.enableAddNewDatasource.value }));

 				if(Weave.properties.enableEditDataSource.value)
-					_weaveMenu.addMenuItemToMenu(_dataMenu, new WeaveMenuItem("Edit Datasources", EditDataSourcePanel.showAsPopup, null, function():Boolean { return Weave.properties.enableEditDatasources.value }));
+					_weaveMenu.addMenuItemToMenu(_dataMenu, new WeaveMenuItem(lang("Edit Datasources"), EditDataSourcePanel.showAsPopup, null, function():Boolean { return Weave.properties.enableEditDatasources.value }));
 			}


implemented AnimatedTexture.styleProperty

--- src/aerys/minko/scene/node/texture/AnimatedTexture.as
+++ src/aerys/minko/scene/node/texture/AnimatedTexture.as
@@ -17,12 +17,7 @@
 		private var _version	: uint		= 0;

 		private var _frame		: int		= 0;
-		private var _lastFrame	: uint		= uint(-1);
 		private var _framerate	: Number	= 0.;
-
-		private var _time		: int		= 0;
-
-		private var _current	: IScene	= null;

 		public function get version()		: uint		{ return _version; }
 		public function get framerate() 	: Number	{ return _framerate; }
@@ -33,7 +28,7 @@
 		 * @return
 		 *
 		 */
-		public function get styleProperty()	: int		{ throw new Error(); }
+		public function get styleProperty()	: int		{ return (rawChildren[_frame] as ITexture).styleProperty; }

 		public function set framerate(value : Number) : void
 		{


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

 package mx.collections
 {


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

--- frameworks/projects/advancedgrids/src/mx/collections/GroupingField.as
+++ frameworks/projects/advancedgrids/src/mx/collections/GroupingField.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: 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@1248740 13f79535-47bb-0310-9956-ffa450edef68

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


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

--- frameworks/projects/framework/src/mx/managers/HistoryManagerImpl.as
+++ frameworks/projects/framework/src/mx/managers/HistoryManagerImpl.as
@@ -122,6 +122,16 @@
 			registered() in history.swf
 			HistoryManager.load()

+	*
+
+	*  @langversion 3.0
+
+	*  @playerversion Flash 9
+
+	*  @playerversion AIR 1.1
+
+	*  @productversion Flex 3
+
 	*/

 	//--------------------------------------------------------------------------
@@ -147,6 +157,11 @@
 	 *  about multiple objects into the query parameters of an URL.
 	 *  The query parameters might look like this:
 	 *  ?8ce2-selectedIndex=1&47f0-selectedIndex=2
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */

 	/**
@@ -283,6 +298,11 @@
 	 *  @Private
 	 *  An Array of objects that will save and load state information.
 	 *  Each object must implement the IHistoryManagerClient interface.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	private var registeredObjects:Array = [];

@@ -318,6 +338,11 @@
 	 *  @param obj Object to register.
 	 *
 	 *  @see mx.managers.IHistoryManagerClient
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	public function register(obj:IHistoryManagerClient):void
 	{
@@ -485,6 +510,11 @@
 	 *  Unregisters an object with the HistoryManager.
 	 *
 	 *  @param obj Object to unregister.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	public function unregister(obj:IHistoryManagerClient):void
 	{
@@ -521,6 +551,11 @@
 	 *  If you registered an interface with the HistoryManager,
 	 *  you are responsible for calling the save() method
 	 *  when the application state changes.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	public function save():void
 	{
@@ -718,6 +753,11 @@

 	/**
 	 *  Constructor.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
 	 */
 	public function RegistrationInfo(crc:String, depth:int)
 	{


Transferred from the Adobe Open Source Subversion Repository

Revision: 7163
Author:   aharui@adobe.com
Date:     2009-05-21T02:19:55.813792Z

Log Message:
-----------
Initial checkin of frame 1 cleanup.  In an RSL linkage, more classes will now come from the RSL because they are no longer needed in frame 1, and the size of the application SWF will be smaller.

QE Notes: None
Doc Notes: Maybe.  All new classes should be undocumented, but it might be worth checking that and any changes to interfaces
Bugs:
Reviewer: darrell
tests: checkintests mustella/MarshallPlan

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/TileListItemRenderer.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/systemClasses/ActiveWindowManager.as</path>
<path kind="dir" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/marshalClasses</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/LayoutManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/RSLEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Menu.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/marshalClasses/MarshalPopUpData.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/IEmbeddedFontRegistry.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/PopUpManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ColorPicker.as</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/lang/StandardDefs.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/systemClasses/EventProxy.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UITextFormat.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/tools/dependencychecker/flex/tools/dependencychecker/FrameworkSwcDependencyRules.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/DragManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Application.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridColumn.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/StyleManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/EmbeddedFontRegistry.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/RichText.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/EmbeddedFont.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ComboBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/modules/compiler/src/java/flex2/tools/PreLink.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/preloaders/Preloader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/resources/ResourceManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ResourceModuleRSLItem.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/FrameworkClasses.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ISWFBridgeProvider.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/marshalClasses/FocusManagerMarshalMixin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/Window.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/resources/ResourceManager.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/IMarshalSystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/EventListenerRequest.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/marshalClasses/ToolTipManagerMarshalMixin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/tools/dependencychecker/frameworkSwcExceptionsList.txt</path>
<path kind="file" action="M">/flex/sdk/trunk/mustella/MustellaResultsParser.java</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Alert.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/systemClasses/ChildManager.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/systemClasses/MarshallPlan.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UITextField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManagerGlobals.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/SWFBridgeGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/alertClasses/AlertForm.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/spark/components/Window.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/treeClasses/TreeItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/ISystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework_textLayout/src/mx/core/UITLFTextField.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/marshalClasses/DragManagerMarshalMixin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/SWFLoader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/MenuBar.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/Request.as</path>
<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/framework/src/mx/styles/CSSStyleDeclaration.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/PopUpButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/FlexEvent.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/IActiveWindowManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/FocusManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/WindowedSystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Application.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/SimpleText.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/marshalClasses/PopUpManagerMarshalMixin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/SystemManagerProxy.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/messaging/config/LoaderConfig.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/IFocusManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/preloaders/DownloadProgressBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ScrollControlBase.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/ISystemManagerChildManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridItemRenderer.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/marshalClasses/CursorManagerMarshalMixin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/CursorManagerImpl.as</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/PopUpData.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ISWFBridgeGroup.as</path>

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

--- frameworks/projects/framework/src/mx/managers/SystemManagerProxy.as
+++ frameworks/projects/framework/src/mx/managers/SystemManagerProxy.as
@@ -27,6 +27,8 @@
 import mx.utils.NameUtil;
 import mx.utils.SecurityUtil;
 import mx.events.SWFBridgeRequest;
+import mx.managers.systemClasses.MarshallPlan;
+import mx.managers.systemClasses.ChildManager;

 use namespace mx_internal;

@@ -47,34 +49,42 @@
  */
 public class SystemManagerProxy extends SystemManager
 {
-        include "../core/Version.as";
-
-        /**
-         *  Constructor.
-         *
-         *  @param systemManager The system manager that this class is a proxy for.
-         *  This is the system manager in the same application domain as the popup.
+    include "../core/Version.as";
+
+    /**
+     *  Constructor.
+     *
+     *  @param systemManager The system manager that this class is a proxy for.
+     *  This is the system manager in the same application domain as the popup.
          *
          *  @langversion 3.0
          *  @playerversion Flash 9
          *  @playerversion AIR 1.1
          *  @productversion Flex 3
-         */
-        public function SystemManagerProxy(systemManager:ISystemManager)
-        {
-                super();
-
-                _systemManager = systemManager;
-
-                // We are a proxy for a popup - we are the hightest system manager.
+     */
+    public function SystemManagerProxy(systemManager:ISystemManager)
+    {
+        super();
+
+        _systemManager = systemManager;
+
+		mp = MarshallPlan(systemManager.getImplementation("mx.managers::IMarshalSystemManager"));
+
+        // We are a proxy for a popup - we are the hightest system manager.
         topLevel = true;

-                // Capture mouseDown so we can switch top level windows and activate
-                // the right focus manager before the components inside start
-                // processing the event.
-                super.addEventListener(MouseEvent.MOUSE_DOWN, proxyMouseDownHandler, true);
-        }
+        // Capture mouseDown so we can switch top level windows and activate
+        // the right focus manager before the components inside start
+        // processing the event.
+        super.addEventListener(MouseEvent.MOUSE_DOWN, proxyMouseDownHandler, true);
+
+        registerImplementation("mx.managers::IActiveWindowManager", new SystemManagerProxyActivePopUpManager(this));
+
+        childManager = new ChildManager(this);
+    }

+	private var mp:MarshallPlan;
+
     //--------------------------------------------------------------------------
     //
     //  Overriden properties
@@ -91,6 +101,17 @@
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
      *  @productversion Flex 3
+     */
+    override public function get isProxy():Boolean
+    {
+        return true;
+    }
+
+    //----------------------------------
+    //  screen
+    //----------------------------------
+    /**
+     *  @inheritDoc
      */
     override public function get screen():Rectangle
     {
@@ -113,10 +134,19 @@
      *  @playerversion AIR 1.1
      *  @productversion Flex 3
      */
+    override public function get topLevelSystemManager():ISystemManager
+    {
+        // The document of this proxy is its pop up.
+        return systemManager.topLevelSystemManager;
+    }
+
+    /**
+     *  @inheritDoc
+     */
     override public function get document():Object
     {
         // The document of this proxy is its pop up.
-        return findFocusManagerContainer(this);
+        return mp.findFocusManagerContainer(this);
     }

     /**
@@ -130,7 +160,7 @@
     //  systemManager
     //----------------------------------

-        /**
+    /**
      *  @private
      */
     private var _systemManager:ISystemManager;
@@ -145,10 +175,10 @@
      *  @playerversion AIR 1.1
      *  @productversion Flex 3
      */
-        public function get systemManager():ISystemManager
-        {
-                return _systemManager;
-        }
+    public function get systemManager():ISystemManager
+    {
+        return _systemManager;
+    }

     //--------------------------------------------------------------------------
     //
@@ -156,74 +186,37 @@
     //
     //--------------------------------------------------------------------------

-        /**
-         *  @inheritDoc
+    /**
+     *  @inheritDoc
          *
          *  @langversion 3.0
          *  @playerversion Flash 9
          *  @playerversion AIR 1.1
          *  @productversion Flex 3
-         */
-        override public function getDefinitionByName(name:String):Object
-        {
-                return _systemManager.getDefinitionByName(name);
-        }
-
-    /**
-     *  @inheritDoc
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
-     */
-        override public function create(... params):Object
-        {
-                return IFlexModuleFactory(_systemManager).create.apply(this, params);
-        }
-
-    /**
-     *  Add a bridge to talk to the child owned by owner.
-     *
-     *  @param bridge The bridge used to talk to the parent.
-     *  @param owner The display object that owns the bridge.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
-     */
-    override public function addChildBridge(bridge:IEventDispatcher, owner:DisplayObject):void
-    {
-        _systemManager.addChildBridge(bridge, owner);
-    }
-
-    /**
-     *  Remove a child bridge.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
-     */
-    override public function removeChildBridge(bridge:IEventDispatcher):void
-    {
-        _systemManager.removeChildBridge(bridge);
-    }
-
-    /**
-     *  @inheritDoc
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
-     */
-        override public function useSWFBridge():Boolean
-        {
-                return _systemManager.useSWFBridge();
-        }
-
+     */
+    override public function getDefinitionByName(name:String):Object
+    {
+        return _systemManager.getDefinitionByName(name);
+    }
+
+    /**
+     *  @inheritDoc
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function create(... params):Object
+    {
+        return IFlexModuleFactory(_systemManager).create.apply(this, params);
+    }
+
+	override public function getImplementation(interfaceName:String):Object
+	{
+		return _systemManager.getImplementation(interfaceName);
+	}
+
     /**
      *  @inheritDoc
      *
@@ -253,76 +246,20 @@
         _systemManager.removeEventListener(type, listener, useCapture);
     }

-        /**
-         *  @inheritDoc
+	/**
+	 *  @private
          *
          *  @langversion 3.0
          *  @playerversion Flash 9
          *  @playerversion AIR 1.1
          *  @productversion Flex 3
-         */
-        override public function activate(f:IFocusManagerContainer):void
-        {
-                // trace("SM Proxy: activate " + f );
-
-                // Activate the proxied SystemManager.
-
-                var bridge:IEventDispatcher =
-            _systemManager.swfBridgeGroup ?
-                        _systemManager.swfBridgeGroup.parentBridge :
-            null;
-
-                if (bridge)
-                {
-                        var mutualTrust:Boolean =
-                SecurityUtil.hasMutualTrustBetweenParentAndChild(ISWFBridgeProvider(_systemManager));
-
-                        var bridgeEvent:SWFBridgeEvent = new SWFBridgeEvent(
-                SWFBridgeEvent.BRIDGE_WINDOW_ACTIVATE,
-                false, false,
-                { notifier: bridge,
-                  window: mutualTrust ? this : NameUtil.displayObjectToString(this)
-                });
-
-            _systemManager.getSandboxRoot().dispatchEvent(bridgeEvent);
-                }
-        }
-
-    /**
-     *  @inheritDoc
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
-     */
-        override public function deactivate(f:IFocusManagerContainer):void
-        {
-                // trace("SM Proxy: deactivate " + f );
-
-        // Deactivate the proxied SystemManager.
-
-                var sm:ISystemManager = _systemManager;
-
-        var bridge:IEventDispatcher =
-            sm.swfBridgeGroup ? sm.swfBridgeGroup.parentBridge : null;
-
-        if (bridge)
-                {
-                        var mutualTrust:Boolean =
-                SecurityUtil.hasMutualTrustBetweenParentAndChild(ISWFBridgeProvider(_systemManager));
-
-            var bridgeEvent:SWFBridgeEvent = new SWFBridgeEvent(
-                SWFBridgeEvent.BRIDGE_WINDOW_DEACTIVATE,
-                                false, false,
-                { notifier: bridge,
-                  window: mutualTrust ? this : NameUtil.displayObjectToString(this)
-                });
-
-                        _systemManager.getSandboxRoot().dispatchEvent(bridgeEvent);
-                }
-        }
-
+	 */
+	override public function isTopLevel():Boolean
+	{
+		return systemManager.isTopLevel();
+	}
+
+
     /**
      *  @inheritdoc
      *
@@ -338,15 +275,6 @@
         return _systemManager.getVisibleApplicationRect(bounds);
     }

-    override public function get swfBridgeGroup():ISWFBridgeGroup
-    {
-        return _systemManager.swfBridgeGroup;
-    }
-
-    override public function set swfBridgeGroup(bridgeGroup:ISWFBridgeGroup):void
-    {
-    }
-
     //--------------------------------------------------------------------------
     //
     //  Methods
@@ -364,10 +292,12 @@
      *  @playerversion AIR 1.1
      *  @productversion Flex 3
      */
-        public function activateByProxy(f:IFocusManagerContainer):void
-        {
-                super.activate(f);
-        }
+    public function activateByProxy(f:IFocusManagerContainer):void
+    {
+		var awm:IActiveWindowManager =
+			IActiveWindowManager(systemManager.getImplementation("mx.managers::IActiveWindowManager"));
+        awm.activate(f);
+    }

     /**
      *  Deactivates the focus manager for the popup window
@@ -380,11 +310,11 @@
      *  @playerversion AIR 1.1
      *  @productversion Flex 3
      */
-        public function deactivateByProxy(f:IFocusManagerContainer):void
-        {
-                if (f)
-            f.focusManager.deactivate();
-        }
+    public function deactivateByProxy(f:IFocusManagerContainer):void
+    {
+        if (f)
+	        f.focusManager.deactivate();
+    }

     //--------------------------------------------------------------------------
     //
@@ -401,9 +331,123 @@
         // Tell our parent system manager we are active if our child
         // is a focus container. If our child is not a focus manager
         // container we will not be able to activate pop up in this proxy.
-        if (findFocusManagerContainer(this))
-            SystemManager(_systemManager).dispatchActivatedWindowEvent(this);
-    }
+        if (mp.findFocusManagerContainer(this))
+            mp.dispatchActivatedWindowEvent(this);
+    }
+
+
 }

 }
+
+
+import flash.display.DisplayObject;
+import flash.events.IEventDispatcher;
+import mx.core.ISWFBridgeProvider;
+import mx.events.SWFBridgeEvent;
+import mx.managers.IActiveWindowManager;
+import mx.managers.IFocusManagerContainer;
+import mx.managers.IMarshalSystemManager;
+import mx.managers.ISystemManager;
+import mx.utils.NameUtil;
+import mx.utils.SecurityUtil;
+
+class SystemManagerProxyActivePopUpManager implements IActiveWindowManager
+{
+
+	private var systemManager:ISystemManager;
+
+	public function SystemManagerProxyActivePopUpManager(systemManager:ISystemManager)
+	{
+		this.systemManager = systemManager;
+	}
+
+    /**
+     *  @inheritDoc
+     */
+    public function activate(f:Object):void
+    {
+        // trace("SM Proxy: activate " + f );
+
+        // Activate the proxied SystemManager.
+		var mp:IMarshalSystemManager =
+			IMarshalSystemManager(systemManager.getImplementation("mx.managers::IMarshalSystemManager"));
+
+        var bridge:IEventDispatcher =
+	        mp.swfBridgeGroup ? mp.swfBridgeGroup.parentBridge : null;
+
+        if (bridge)
+        {
+            var mutualTrust:Boolean =
+		        SecurityUtil.hasMutualTrustBetweenParentAndChild(ISWFBridgeProvider(systemManager));
+
+            var bridgeEvent:SWFBridgeEvent = new SWFBridgeEvent(
+		        SWFBridgeEvent.BRIDGE_WINDOW_ACTIVATE,
+				false, false,
+				{ notifier: bridge,
+					window: mutualTrust ? systemManager : NameUtil.displayObjectToString(DisplayObject(systemManager))
+				});
+
+			systemManager.getSandboxRoot().dispatchEvent(bridgeEvent);
+        }
+    }
+
+	/**
+	 *  @inheritDoc
+	 */
+    public function deactivate(f:Object):void
+    {
+        // trace("SM Proxy: deactivate " + f );
+
+	    // Deactivate the proxied SystemManager.
+
+		var mp:IMarshalSystemManager =
+			IMarshalSystemManager (systemManager.getImplementation("mx.managers::IMarshalSystemManager"));
+
+		var bridge:IEventDispatcher =
+			mp.swfBridgeGroup ? mp.swfBridgeGroup.parentBridge : null;
+
+	    if (bridge)
+        {
+            var mutualTrust:Boolean =
+		        SecurityUtil.hasMutualTrustBetweenParentAndChild(ISWFBridgeProvider(systemManager));
+
+			var bridgeEvent:SWFBridgeEvent = new SWFBridgeEvent(
+				SWFBridgeEvent.BRIDGE_WINDOW_DEACTIVATE,
+                false, false,
+				{ notifier: bridge,
+				    window: mutualTrust ? systemManager : NameUtil.displayObjectToString(DisplayObject(systemManager))
+				});
+
+             systemManager.getSandboxRoot().dispatchEvent(bridgeEvent);
+         }
+    }
+
+	public function get numModalWindows():int
+	{
+		return systemManager.numModalWindows;
+	}
+
+	/**
+	 *  @private
+	 */
+	public function set numModalWindows(value:int):void
+	{
+        systemManager.numModalWindows = value;
+	}
+
+	/**
+	 *  @inheritDoc
+	 */
+	public function addFocusManager(f:IFocusManagerContainer):void
+	{
+	}
+
+	/**
+	 *  @inheritDoc
+	 */
+	public function removeFocusManager(f:IFocusManagerContainer):void
+	{
+    }
+
+}


Transferred from the Adobe Open Source Subversion Repository

Revision: 12469
Author:   jimurphy@adobe.com
Date:     2009-12-03T22:04:16.560316Z

Log Message:
-----------
fix offsets for FB.  Convert line ending from lf to crlf in svn for the proects directory only.  When checking project files in, be sure to save you files this way.  Another update to make sure happens is set the svn properties svn:eol-style = native and svn:mime-type = text/plain (these have been updated on theses files as well)

QE notes: make sure the proper class is selected
Doc notes: no
Bugs: http://bugs.adobe.com/jira/browse/SDK-24498
Reviewer:
Tests run: checkintests
Is noteworthy for integration: no

Modified Paths:
--------------
133 paths were modified

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

--- frameworks/projects/spark/src/spark/layouts/supportClasses/Block.as
+++ frameworks/projects/spark/src/spark/layouts/supportClasses/Block.as
@@ -41,4 +41,4 @@
     }
 }

-}+}


Outgoing message throttle for ActionScript. This uses a timer rather than a
frame listener so that it has a chance of working out of the box on Thane.

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

--- src/as/com/threerings/presents/client/Communicator.as
+++ src/as/com/threerings/presents/client/Communicator.as
@@ -22,14 +22,14 @@
 package com.threerings.presents.client {

 import flash.errors.IOError;
-
 import flash.events.Event;
 import flash.events.IOErrorEvent;
+import flash.events.TimerEvent;

 import flash.net.Socket;
-
 import flash.utils.ByteArray;
 import flash.utils.Endian;
+import flash.utils.Timer;

 import com.threerings.util.Log;

@@ -59,11 +59,28 @@
         _outBuffer = new ByteArray();
         _outBuffer.endian = Endian.BIG_ENDIAN;
         _outStream = new ObjectOutputStream(_outBuffer);
-
         _inStream = new ObjectInputStream();
+
+        // start up our message writer
+        _writer = new Timer(1);
+        _writer.addEventListener(TimerEvent.TIMER, sendPendingMessages);
+        _writer.start();

         _portIdx = 0;
         logonToPort();
+    }
+
+    public function logoff () :void
+    {
+        if (_socket == null) {
+            return;
+        }
+        postMessage(new LogoffRequest());
+    }
+
+    public function postMessage (msg :UpstreamMessage) :void
+    {
+        _outq.push(msg);
     }

     /**
@@ -80,8 +97,7 @@
                 return false;
             }
             if (_portIdx != 0) {
-                _client.reportLogonTribulations(
-                    new LogonError(AuthCodes.TRYING_NEXT_PORT, true));
+                _client.reportLogonTribulations(new LogonError(AuthCodes.TRYING_NEXT_PORT, true));

                 removeListeners();
             }
@@ -94,8 +110,7 @@
             _socket.addEventListener(Event.CLOSE, socketClosed);

             _frameReader = new FrameReader(_socket);
-            _frameReader.addEventListener(FrameAvailableEvent.FRAME_AVAILABLE,
-                inputFrameReceived);
+            _frameReader.addEventListener(FrameAvailableEvent.FRAME_AVAILABLE, inputFrameReceived);
         }

         var host :String = _client.getHostname();
@@ -108,8 +123,7 @@
             _portIdx = -1; // indicate that we're no longer trying new ports

         } else {
-            Log.getLog(this).info(
-                "Connecting [host=" + host + ", port=" + port + "].");
+            log.info("Connecting [host=" + host + ", port=" + port + "].");
             _socket.connect(host, port);
         }

@@ -122,24 +136,7 @@
         _socket.removeEventListener(IOErrorEvent.IO_ERROR, socketError);
         _socket.removeEventListener(Event.CLOSE, socketClosed);

-        _frameReader.removeEventListener(FrameAvailableEvent.FRAME_AVAILABLE,
-            inputFrameReceived);
-    }
-
-    public function logoff () :void
-    {
-        if (_socket == null) {
-            return;
-        }
-
-        sendMessage(new LogoffRequest());
-
-        shutdown(null);
-    }
-
-    public function postMessage (msg :UpstreamMessage) :void
-    {
-        sendMessage(msg); // send it now: we have no out queue
+        _frameReader.removeEventListener(FrameAvailableEvent.FRAME_AVAILABLE, inputFrameReceived);
     }

     protected function shutdown (logonError :Error) :void
@@ -149,7 +146,7 @@
                 try {
                     _socket.close();
                 } catch (err :Error) {
-                    Log.getLog(this).warning("Error closing failed socket [error=" + err + "].");
+                    log.warning("Error closing failed socket [error=" + err + "].");
                 }
             }
             removeListeners();
@@ -160,21 +157,59 @@
             _outBuffer = null;
         }

+        if (_writer != null) {
+            _writer.stop();
+            _writer = null;
+        }
+
         _client.notifyObservers(ClientEvent.CLIENT_DID_LOGOFF, null);
         _client.cleanup(logonError);
     }

+    /**
+     * Sends all pending messages from our outgoing message queue. If we hit our throttle while
+     * sending, we stop and wait for the next time around when we'll try sending them again.
+     */
+    protected function sendPendingMessages (event :TimerEvent) :void
+    {
+        while (_outq.length > 0) {
+            // if we've exceeded our throttle, stop for now
+            if (_client.getOutgoingMessageThrottle().throttleOp()) {
+                if (_tqsize != _outq.length) {
+                    // only log when our outq size changes
+                    _tqsize = _outq.length;
+                    log.info("Throttling outgoing messages", "queue", _outq.length,
+                             "throttle", _client.getOutgoingMessageThrottle());
+                }
+                return;
+            }
+            _tqsize = 0;
+
+            // grab the next message from the queue and send it
+            var msg :UpstreamMessage = (_outq.shift() as UpstreamMessage);
+            sendMessage(msg);
+
+            // if this was a logoff request, shutdown
+            if (msg is LogoffRequest) {
+                shutdown(null);
+            }
+        }
+    }
+
+    /**
+     * Writes a single message to our outgoing socket.
+     */
     protected function sendMessage (msg :UpstreamMessage) :void
     {
         if (_outStream == null) {
-            Log.getLog(this).warning("No socket, dropping msg [msg=" + msg + "].");
+            log.warning("No socket, dropping msg [msg=" + msg + "].");
             return;
         }

         // write the message (ends up in _outBuffer)
         _outStream.writeObject(msg);

-//        Log.debug("outBuffer: " + StringUtil.unhexlate(_outBuffer));
+//         Log.debug("outBuffer: " + StringUtil.unhexlate(_outBuffer));

         // Frame it by writing the length, then the bytes.
         // We add 4 to the length, because the length is of the entire frame
@@ -192,47 +227,25 @@
     }

     /**
-     * Returns the time at which we last sent a packet to the server.
-     */
-    internal function getLastWrite () :uint
-    {
-        return _lastWrite;
-    }
-
-    /**
-     * Makes a note of the time at which we last communicated with the server.
-     */
-    internal function updateWriteStamp () :void
-    {
-        _lastWrite = flash.utils.getTimer();
-    }
-
-    /**
-     * Called when a frame of data from the server is ready to be
-     * decoded into a DownstreamMessage.
+     * Called when a frame of data from the server is ready to be decoded into a DownstreamMessage.
      */
     protected function inputFrameReceived (event :FrameAvailableEvent) :void
     {
         // convert the frame data into a message from the server
         var frameData :ByteArray = event.getFrameData();
-        //Log.debug("length of in frame: " + frameData.length);
-        //Log.debug("inBuffer: " + StringUtil.unhexlate(frameData));
         _inStream.setSource(frameData);
         var msg :DownstreamMessage;
         try {
             msg = (_inStream.readObject() as DownstreamMessage);
         } catch (e :Error) {
-            var log :Log = Log.getLog(this);
             log.warning("Error processing downstream message: " + e);
             log.logStackTrace(e);
             return;
         }

         if (frameData.bytesAvailable > 0) {
-            Log.getLog(this).warning(
-                "Beans! We didn't fully read a frame, surely there's " +
-                "a bug in some streaming code. " +
-                "[bytesLeftOver=" + frameData.bytesAvailable + ", msg=" + msg + "].");
+            log.warning("Beans! We didn't fully read a frame, is there a bug in some streaming " +
+                "code? [bytesLeftOver=" + frameData.bytesAvailable + ", msg=" + msg + "].");
         }

         if (_omgr != null) {
@@ -241,7 +254,7 @@
             return;
         }

-        // Otherwise, this would be the AuthResponse to our logon attempt.
+        // otherwise, this would be the AuthResponse to our logon attempt
         var rsp :AuthResponse = (msg as AuthResponse);
         var data :AuthResponseData = rsp.getData();
         if (data.code !== AuthResponseData.SUCCESS) {
@@ -261,9 +274,8 @@
     {
         logonToPort(true);
         // well that's great! let's logon
-        var req :AuthRequest = new AuthRequest(
-            _client.getCredentials(), _client.getVersion(), _client.getBootGroups());
-        sendMessage(req);
+        postMessage(new AuthRequest(_client.getCredentials(), _client.getVersion(),
+                                    _client.getBootGroups()));
     }

     /**
@@ -280,9 +292,9 @@
         }

         // total failure
-        Log.getLog(this).warning("socket error: " + event + ", target=" + event.target);
+        log.warning("Socket error: " + event, "target", event.target);
         Log.dumpStack();
-        shutdown(new Error("socket closed unexpectedly."));
+        shutdown(new Error("Socket closed unexpectedly."));
     }

     /**
@@ -290,9 +302,25 @@
      */
     protected function socketClosed (event :Event) :void
     {
-        Log.getLog(this).info("socket was closed: " + event);
+        log.info("Socket was closed: " + event);
         _client.notifyObservers(ClientEvent.CLIENT_CONNECTION_FAILED);
-        logoff();
+        shutdown(null);
+    }
+
+    /**
+     * Returns the time at which we last sent a packet to the server.
+     */
+    internal function getLastWrite () :uint
+    {
+        return _lastWrite;
+    }
+
+    /**
+     * Makes a note of the time at which we last communicated with the server.
+     */
+    internal function updateWriteStamp () :void
+    {
+        _lastWrite = flash.utils.getTimer();
     }

     protected var _client :Client;
@@ -305,8 +333,13 @@
     protected var _frameReader :FrameReader;

     protected var _socket :Socket;
-
     protected var _lastWrite :uint;
+
+    protected var _outq :Array = new Array();
+    protected var _writer :Timer;
+    protected var _tqsize :int = 0;
+
+    protected const log :Log = Log.getLog(this);

     /** The current port we'll try to connect to. */
     protected var _portIdx :int = -1;


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

--- frameworks/projects/framework/src/mx/managers/IMarshalSystemManager.as
+++ frameworks/projects/framework/src/mx/managers/IMarshalSystemManager.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  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.managers
 {


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

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

 package mx.controls.treeClasses
 {


Improvements to decoder generation

Improvements to decoder generation

--- as3/xobjas3/src/com/rpath/xobj/XObjDecoderGenerator.as
+++ as3/xobjas3/src/com/rpath/xobj/XObjDecoderGenerator.as
@@ -10,6 +10,7 @@
 {
 import flash.utils.Dictionary;

+import mx.collections.ArrayCollection;
 import mx.core.mx_internal;

 public class XObjDecoderGenerator
@@ -24,7 +25,9 @@
      */
     public static var generateClasses:Boolean = false;

-    /** stashTypeInfo builds up an index of all types, and all properties
+    private static var _typeInfoByClassName:Dictionary = new Dictionary();
+
+    /** recordPropertyInfo() builds up an index of all types, and all properties
      * so that we can consider code-generation of decoding classes
      */

@@ -40,7 +43,18 @@
         props[typeInfo.propName] = typeInfo;
     }

-    private static var _typeInfoByClassName:Dictionary = new Dictionary();
+
+    private static function getKeys(d:Dictionary):Array
+    {
+        var a:Array = new Array();
+
+        for (var key:Object in d)
+        {
+            a.push(key);
+        }
+
+        return a;
+    }

     public static function dumpClasses():void
     {
@@ -52,7 +66,9 @@
                 continue;

             var clazz:Class = XObjUtils.getClassByName(c);
-            if (clazz == null)
+            if (clazz == null || clazz == Object ||
+                clazz == String || clazz == Array ||
+                clazz == ArrayCollection)
                 continue;

             var cname:String = XObjUtils.getUnqualfiedClassName(clazz);
@@ -95,8 +111,14 @@
             var props:Dictionary = _typeInfoByClassName[c];
             if (props)
             {
-                for each (var t:XObjTypeInfo in props)
+                // sort keys
+                var propNames:Array = getKeys(props);
+                propNames.sort();
+
+                for each (var propName:String in propNames)
                 {
+                    var t:XObjTypeInfo = props[propName];
+
                     var xe:String = "xml."+ (t.isAttribute ? "@" : "")+t.propName;
                     var op:String = "m."+t.propName;

@@ -142,5 +164,6 @@
             trace(line);
         }
     }
+
 }
 }


Transferred from the Adobe Open Source Subversion Repository

Revision: 5797
Author:   jimurphy@adobe.com
Date:     2009-03-31T15:35:34.544076Z

Log Message:
-----------
Merged revisions 3.x 5505,5526-5527,5535,5540,5542,5572,5616-5617,5656-5657,5671,5674,5683,5687-5688,5690,5698,5708-5709,5713-5716,5719-5723,5726,5728-5729,5736,5752,5754,5761,5774,5780,5784 -> trunk

most of these are user submitted patches! very cool.

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/VideoDisplay.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/resources/IResourceManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ToggleButtonBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Menu.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Container.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/CalendarLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/halo/ProgressIndeterminateSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/controls/FileSystemComboBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/NavBar.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="D">/flex/sdk/trunk/modules/compiler/FlexCompilerShell-license.txt</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DateField.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/DividedBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/formatters/DateFormatter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/FormItem.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/SWFLoader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/managers/NativeDragManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridColumn.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/validators/PhoneNumberValidator.as</path>
<path kind="file" copyfrom-path="/flex/sdk/branches/3.x/frameworks/projects/framework/src/mx/validators/NumberValidatorDomainType.as" copyfrom-rev="5784" action="A">/flex/sdk/trunk/frameworks/projects/framework/src/mx/validators/NumberValidatorDomainType.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/PopUpButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/ToolTipManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/ObjectUtil.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/validators/NumberValidator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/FocusManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/validators/CurrencyValidator.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Form.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/resources/ResourceManagerImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Label.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DataGrid.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/CalendarLayoutChangeEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/events/DataGridEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/sliderClasses/Slider.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/PopUpMenuButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Text.as</path>

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

--- frameworks/projects/framework/src/mx/controls/SWFLoader.as
+++ frameworks/projects/framework/src/mx/controls/SWFLoader.as
@@ -17,13 +17,13 @@
 import flash.display.DisplayObjectContainer;
 import flash.display.Loader;
 import flash.display.LoaderInfo;
-import flash.display.Shape;
 import flash.display.Sprite;
 import flash.events.Event;
 import flash.events.EventDispatcher;
 import flash.events.HTTPStatusEvent;
 import flash.events.IEventDispatcher;
 import flash.events.IOErrorEvent;
+import flash.events.MouseEvent;
 import flash.events.ProgressEvent;
 import flash.events.SecurityErrorEvent;
 import flash.geom.Point;
@@ -38,22 +38,17 @@
 import mx.core.FlexGlobals;
 import mx.core.FlexLoader;
 import mx.core.FlexVersion;
-import mx.core.ISWFLoader;
 import mx.core.IFlexDisplayObject;
-import mx.core.ISWFBridgeProvider;
 import mx.core.ISWFLoader;
 import mx.core.IUIComponent;
 import mx.core.UIComponent;
 import mx.core.mx_internal;
 import mx.events.FlexEvent;
+import mx.events.InterManagerRequest;
 import mx.events.InvalidateRequestData;
-import mx.events.InterManagerRequest;
 import mx.events.SWFBridgeEvent;
 import mx.events.SWFBridgeRequest;
 import mx.managers.CursorManager;
-import mx.managers.FocusManager;
-import mx.managers.IFocusManager;
-import mx.managers.IFocusManagerComponent;
 import mx.managers.ISystemManager;
 import mx.managers.SystemManagerGlobals;
 import mx.styles.ISimpleStyleClient;
@@ -394,6 +389,7 @@

         addEventListener(FlexEvent.INITIALIZE, initializeHandler);
         addEventListener(Event.ADDED_TO_STAGE, addedToStageHandler);
+        addEventListener(MouseEvent.CLICK, clickHandler);

         showInAutomationHierarchy = false;
     }
@@ -418,6 +414,11 @@
      *  @private
      */
     private var scaleContentChanged:Boolean = false;
+
+    /**
+     *  @private
+     */
+    private var smoothBitmapContentChanged:Boolean = false;

     /**
      *  @private
@@ -1098,6 +1099,49 @@
     }

     //----------------------------------
+    //  smoothBitmapContent
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the smoothBitmapContent property.
+     */
+    private var _smoothBitmapContent:Boolean = false;
+
+    [Bindable("smoothBitmapContentChanged")]
+    [Inspectable(category="General", defaultValue="false")]
+
+    /**
+     *  A flag that indicates whether to smooth the content when it
+     *  is scaled. Only Bitmap content can be smoothed.
+     *  If true, and the content is a Bitmap then smoothing property
+     *  of the content is set to true.
+     *  If false, the content isn't smoothed.
+     *
+     *  @default false
+     */
+    public function get smoothBitmapContent():Boolean
+    {
+        return _smoothBitmapContent;
+    }
+
+    /**
+     *  @private
+     */
+    public function set smoothBitmapContent(value:Boolean):void
+    {
+        if (_smoothBitmapContent != value)
+        {
+            _smoothBitmapContent = value;
+
+            smoothBitmapContentChanged = true;
+            invalidateDisplayList();
+        }
+
+        dispatchEvent(new Event("smoothBitmapContentChanged"));
+    }
+
+    //----------------------------------
     //  source
     //----------------------------------

@@ -1408,6 +1452,11 @@
                 doScaleLoader();

             scaleContentChanged = false;
+
+            if (smoothBitmapContentChanged) {
+            	doSmoothBitmapContent();
+            	smoothBitmapContentChanged = false;
+            }
         }

         if (brokenImage && !brokenImageBorder)
@@ -1560,7 +1609,7 @@
         if (!_source || _source == "")
             return;

-        contentHolder = loadContent(_source);
+        loadContent(_source);
     }

     /**
@@ -1637,7 +1686,7 @@
      *  RectangularBorder.updateDisplayList()
      *  to see if changes are needed there as well.
      */
-    private function loadContent(classOrString:Object):DisplayObject
+    private function loadContent(classOrString:Object):void
     {
         var child:DisplayObject;
         var cls:Class;
@@ -1691,7 +1740,7 @@
         else if (byteArray)
         {
             loader = new FlexLoader();
-            child = loader;
+            contentHolder = child = loader;
             addChild(child);

             loader.contentLoaderInfo.addEventListener(
@@ -1699,6 +1748,8 @@
             loader.contentLoaderInfo.addEventListener(
                 Event.INIT, contentLoaderInfo_initEventHandler);
             loader.contentLoaderInfo.addEventListener(
+                IOErrorEvent.IO_ERROR, contentLoaderInfo_ioErrorEventHandler);
+            loader.contentLoaderInfo.addEventListener(
                 Event.UNLOAD, contentLoaderInfo_unloadEventHandler);

             // if loaderContext null, it will use default, which is AppDomain
@@ -1709,7 +1760,7 @@
         {
             // Create an instance of the Flash Player Loader class to do all the work
             loader = new FlexLoader();
-            child = loader;
+            contentHolder = child = loader;

             // addChild needs to be called before load()
             addChild(loader);
@@ -1812,8 +1863,6 @@
         }

         invalidateDisplayList();
-
-        return child;
     }

     /**
@@ -2060,6 +2109,15 @@
         contentHolder.x = (w - contentHolderWidth) * getHorizontalAlignValue();
         contentHolder.y = (h - contentHolderHeight) * getVerticalAlignValue();
     }
+
+    /**
+     *  @private
+     */
+    private function doSmoothBitmapContent():void
+    {
+    	if (content is Bitmap)
+    		(content as Bitmap).smoothing = _smoothBitmapContent;
+    }

     /**
      *  @private
@@ -2543,6 +2601,24 @@

         return pt;
     }
+
+    /**
+     *  The default handler for the MouseEvent.CLICK event.
+     *
+     *  @param The event object.
+     */
+    protected function clickHandler(event:MouseEvent):void
+    {
+        if (!enabled)
+        {
+            // Prevent the propagation of click from a disabled component.
+            // This is conceptually a higher-level event and
+            // developers will expect their click handlers not to fire
+            // if the Button is disabled.
+            event.stopImmediatePropagation();
+            return;
+        }
+    }
 }

 }