Transferred from the Adobe Open Source Subversion Repository

Revision: 20078
Author:   klin@adobe.com
Date:     2011-02-02T23:41:09.401228Z

Log Message:
-----------
Recommit 19979. Fixed missing parameter in TransformUtil's needAdvancedLayout call.

Refactoring shared transformation code in UIComponent, SpriteVisualElement, and UIMovieClip into a utility class, TransformUtil. The methods transformAround() and transformPointToParent() are now delegated to the new class. For transformAround, the components also pass in their AdvancedLayoutFeatures and initAdvancedLayoutFeatures() method so that TransformUtil can create and initialize the layout features object if necessary.

QE notes: No
Doc notes: No
Bugs: SDK-22637
Reviewer: Evtim
Tests run: cyclone server, checkintests
Is noteworthy for integration: Yes, possibly for FC

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/framework/src/mx/utils/TransformUtil.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/core/SpriteVisualElement.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/flash-integration/src/mx/flash/UIMovieClip.as</path>

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

--- frameworks/projects/spark/src/spark/core/SpriteVisualElement.as
+++ frameworks/projects/spark/src/spark/core/SpriteVisualElement.as
@@ -53,6 +53,7 @@
 import mx.graphics.shaderClasses.SoftLightShader;
 import mx.managers.ILayoutManagerClient;
 import mx.utils.MatrixUtil;
+import mx.utils.TransformUtil;

 import spark.components.ResizeMode;
 import spark.utils.MaskUtil;
@@ -136,18 +137,12 @@

     /**
      *  @private
-     *  Static point for use in transformPointToParent
-     */
-    private static var xformPt:Point;
-
-    /**
-     *  @private
      *  Initializes the implementation and storage of some of the less
      *  frequently used advanced layout features of a component.
      *  Call this function before attempting to use any of the
      *  features implemented by the AdvancedLayoutFeatures object.
      */
-    private function initAdvancedLayoutFeatures():void
+    private function initAdvancedLayoutFeatures():AdvancedLayoutFeatures
     {
         var features:AdvancedLayoutFeatures = new AdvancedLayoutFeatures();

@@ -169,6 +164,7 @@
         _layoutFeatures = features;

         invalidateTransform();
+        return features;
     }

     /**
@@ -2835,102 +2831,43 @@
             _includeInLayout = false;
         }

-        if (_layoutFeatures == null)
-        {
-            // TODO (chaase): should provide a way to return to having no
-            // layoutFeatures if we call this later with a more trivial
-            // situation
-            var needAdvancedLayout:Boolean =
-                (scale != null && ((!isNaN(scale.x) && scale.x != 1) ||
-                    (!isNaN(scale.y) && scale.y != 1) ||
-                    (!isNaN(scale.z) && scale.z != 1))) ||
-                (rotation != null && ((!isNaN(rotation.x) && rotation.x != 0) ||
-                    (!isNaN(rotation.y) && rotation.y != 0) ||
-                    (!isNaN(rotation.z) && rotation.z != 0))) ||
-                (translation != null && translation.z != 0 && !isNaN(translation.z)) ||
-                postLayoutScale != null ||
-                postLayoutRotation != null ||
-                (postLayoutTranslation != null &&
-                    (postLayoutTranslation.x != translation.x ||
-                        postLayoutTranslation.y != translation.y ||
-                        postLayoutTranslation.z != translation.z));
-            if (needAdvancedLayout)
-                initAdvancedLayoutFeatures();
-        }
-        if (_layoutFeatures)
-        {
-            _layoutFeatures.transformAround(transformCenter, scale, rotation, translation,
-                postLayoutScale, postLayoutRotation, postLayoutTranslation);
+        TransformUtil.transformAround(this,
+                                      transformCenter,
+                                      scale,
+                                      rotation,
+                                      translation,
+                                      postLayoutScale,
+                                      postLayoutRotation,
+                                      postLayoutTranslation,
+                                      _layoutFeatures,
+                                      initAdvancedLayoutFeatures);
+
+        if (_layoutFeatures != null)
+        {
             invalidateTransform();

             // Will not invalidate parent if we have set _includeInLayout to false
             // in the beginning of the method
             invalidateParentSizeAndDisplayList();
         }
-        else
-        {
-            if (translation == null && transformCenter != null)
-            {
-                if (xformPt == null)
-                    xformPt = new Point();
-                xformPt.x = transformCenter.x;
-                xformPt.y = transformCenter.y;
-                var xformedPt:Point =
-                    transform.matrix.transformPoint(xformPt);
-            }
-            if (rotation != null && !isNaN(rotation.z))
-                this.rotation = rotation.z;
-            if (scale != null)
-            {
-                scaleX = scale.x;
-                scaleY = scale.y;
-            }
-            if (transformCenter == null)
-            {
-                if (translation != null)
-                {
-                    x = translation.x;
-                    y = translation.y;
-                }
-            }
-            else
-            {
-                if (xformPt == null)
-                    xformPt = new Point();
-                xformPt.x = transformCenter.x;
-                xformPt.y = transformCenter.y;
-                var postXFormPoint:Point =
-                    transform.matrix.transformPoint(xformPt);
-                if (translation != null)
-                {
-                    x += translation.x - postXFormPoint.x;
-                    y += translation.y - postXFormPoint.y;
-                }
-                else
-                {
-                    x += xformedPt.x - postXFormPoint.x;
-                    y += xformedPt.y - postXFormPoint.y;
-                }
-            }
-        }

         if (!invalidateLayout)
             _includeInLayout = oldIncludeInLayout;
     }

     /**
-     * A utility method to transform a point specified in the local
-     * coordinates of this object to its location in the object's parent's
-     * coordinates. The pre-layout and post-layout result will be set on
-     * the position and postLayoutPosition
-     * parameters, if they are non-null.
-     *
-     * @param localPosition The point to be transformed, specified in the
-     * local coordinates of the object.
-     * @param position A Vector3D point that will hold the pre-layout
-     * result. If null, the parameter is ignored.
-     * @param postLayoutPosition A Vector3D point that will hold the post-layout
-     * result. If null, the parameter is ignored.
+     *  A utility method to transform a point specified in the local
+     *  coordinates of this object to its location in the object's parent's
+     *  coordinates. The pre-layout and post-layout result will be set on
+     *  the position and postLayoutPosition
+     *  parameters, if they are non-null.
+     *
+     *  @param localPosition The point to be transformed, specified in the
+     *  local coordinates of the object.
+     *  @param position A Vector3D point that will hold the pre-layout
+     *  result. If null, the parameter is ignored.
+     *  @param postLayoutPosition A Vector3D point that will hold the post-layout
+     *  result. If null, the parameter is ignored.
      *
      *  @langversion 3.0
      *  @playerversion Flash 10
@@ -2941,41 +2878,11 @@
                                            position:Vector3D,
                                            postLayoutPosition:Vector3D):void
     {
-        if (_layoutFeatures != null)
-        {
-            _layoutFeatures.transformPointToParent(true, localPosition,
-                position, postLayoutPosition);
-        }
-        else
-        {
-            if (xformPt == null)
-                xformPt = new Point();
-            if (localPosition)
-            {
-                xformPt.x = localPosition.x;
-                xformPt.y = localPosition.y;
-            }
-            else
-            {
-                xformPt.x = 0;
-                xformPt.y = 0;
-            }
-            var tmp:Point = (transform.matrix != null) ?
-                transform.matrix.transformPoint(xformPt) :
-                xformPt;
-            if (position != null)
-            {
-                position.x = tmp.x;
-                position.y = tmp.y;
-                position.z = 0;
-            }
-            if (postLayoutPosition != null)
-            {
-                postLayoutPosition.x = tmp.x;
-                postLayoutPosition.y = tmp.y;
-                postLayoutPosition.z = 0;
-            }
-        }
+        TransformUtil.transformPointToParent(this,
+                                             localPosition,
+                                             position,
+                                             postLayoutPosition,
+                                             _layoutFeatures);
     }

     /**


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

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

--- frameworks/projects/spark/src/spark/filters/DropShadowFilter.as
+++ frameworks/projects/spark/src/spark/filters/DropShadowFilter.as
@@ -1,4 +1,4 @@
-package mx.filters
+package spark.filters
 {
 import flash.filters.BitmapFilter;
 import flash.filters.DropShadowFilter;


Check for class marking as cloneable only once in method Cloner.findAllWritableFieldsForType().

--- dolly-framework/src/main/actionscript/dolly/Cloner.as
+++ dolly-framework/src/main/actionscript/dolly/Cloner.as
@@ -39,18 +39,11 @@
 	public static function clone(source:*):* {
 		const type:Type = Type.forInstance(source);

-		if (!isTypeCloneable(type)) {
-			throw new CloningError(
-					CloningError.CLASS_IS_NOT_CLONEABLE_MESSAGE,
-					CloningError.CLASS_IS_NOT_CLONEABLE_CODE
-			);
-		}
-
-		const clonedInstance:* = new (type.clazz)();
-
 		// Find all public writable fields in a hierarchy of a source object
 		// and assign their values to a clone object.
 		const fieldsToClone:Vector.<Field> = findAllWritableFieldsForType(type);
+		const clonedInstance:* = new (type.clazz)();
+
 		var name:String;
 		for each(var field:Field in fieldsToClone) {
 			name = field.name;


Added a isThumbPressed getter. Also Slider now automatically centers the thumb and the trackSkin.

--- src/org/openPyro/controls/Slider.as
+++ src/org/openPyro/controls/Slider.as
@@ -37,11 +37,14 @@
 		}

 		/**
-		 * Property that determines whether the trackSkin
-		 * is centered within this component.
-		 */
-		public var centerTrackSkin:Boolean = true;
-
+		 * Returns a boolean value indicating whether
+		 * the thumb button is currently pressed or
+		 * not
+		 */
+		public function get isThumbPressed():Boolean{
+			return _isThumbPressed;
+		}
+
 		override public function initialize():void
 		{
 			super.initialize()
@@ -246,6 +249,7 @@
 			//this.stopDrag();
 			_thumbButton.stopDrag();
 			this._isThumbPressed=false;
+			dispatchEvent(new SliderEvent(SliderEvent.THUMB_RELEASE));
 			//this.forceInvalidateDisplayList = true;
 			//this.invalidateDisplayList()
 		}
@@ -310,24 +314,15 @@
 					}
 				}

-
-				/*
-				Position the thumb button wherever it was supposed to
-				be. For some reason updateDisplaylist keeps sending the button
-				to 0,0
-				*/
-				//this._thumbButton.y = this.thumbButtonY;
-				//this._thumbButton.x = this.thumbButtonX;
-				//_trackSkin.y = 0
-				// center the trackskin
-				if(centerTrackSkin){
-					if(this.direction == Direction.HORIZONTAL){
-						_trackSkin.y = (unscaledHeight-_trackSkin.height)/2;
-					}
-					else{
-						_trackSkin.x = (unscaledWidth-_trackSkin.width)/2;
-					}
-				}
+				// center the trackskin and the thumbButton
+				if(this.direction == Direction.HORIZONTAL){
+					_trackSkin.y = (unscaledHeight - _trackSkin.height)/2;
+					_thumbButton.y = (unscaledHeight - _thumbButton.height)/2;
+				}
+				else{
+					_trackSkin.x = (unscaledWidth-_trackSkin.width)/2;
+					_thumbButton.x = (unscaledHeight - _thumbButton.height)/2;
+				}

 			}
 		}


fixed bug where selection/probing was not working on point data

Change-Id: I19cc50fb1ea2e0cd7dbca340241d1df196b8b512

--- WeaveUI/src/weave/utils/SpatialIndex.as
+++ WeaveUI/src/weave/utils/SpatialIndex.as
@@ -284,12 +284,10 @@
 		 */
 		public function getKeysOverlappingBounds(bounds:IBounds2D, minImportance:Number = 0):Array
 		{
-			var keys:Array;
+			var keys:Array = getKeysOverlappingCollectiveBounds(bounds, 0);
 			// if this index isn't for an IPlotterWithGeometries OR the user wants legacy probing
 			if (_keyToGeometriesMap == null || !Weave.properties.enableGeometryProbing.value == true)
-				return getKeysOverlappingCollectiveBounds(bounds, 0);
-			else
-				keys = getKeysOverlappingCollectiveBounds(bounds, minImportance);
+				return keys;

 			// if there are 0 keys
 			if (keys.length == 0)
@@ -317,7 +315,7 @@
 						var genGeomIsPoly:Boolean = genGeom.isPolygon();
 						var genGeomIsLine:Boolean = genGeom.isLine();
 						var genGeomIsPoint:Boolean = genGeom.isPoint();
-						var simplifiedGeom:Vector.<Vector.<BLGNode>> = genGeom.getSimplifiedGeometry(minImportance, bounds);
+						var simplifiedGeom:Vector.<Vector.<BLGNode>> = genGeom.getSimplifiedGeometry(minImportance);

 						// for each part, build the vertices polygon and check for the overlap
 						for (var iPart:int = 0; iPart < simplifiedGeom.length; ++iPart)


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

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


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

--- frameworks/projects/mx/src/mx/skins/halo/PanelSkin.as
+++ frameworks/projects/mx/src/mx/skins/halo/PanelSkin.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  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.skins.halo
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 12796
Author:   cframpto@adobe.com
Date:     2009-12-10T18:05:16.265768Z

Log Message:
-----------
Because TLF does not have the concept of "auto" fontLookup like we have at the Flex-level, we have had to rework the meaning of the fontLookup attribute so it is possible to have spans with device text in a component whose fontLookup is "embeddedCFF" without requiring fontLookup "device" to be explicitly specified for those spans.

For Spark text components, the default fontLookup has been changed from "auto" to "embeddedCFF".  The default fontFamily is "Arial".

If the component level fontLookup either defaults to "embeddedCFF" or is explicitly set to "embeddedCFF", for each element that is not explicitly set to fontLookup "device", it will first look for the embedded font, and failing that, will fail back to the device font.  All fonts for a given text component must be in the same swf context.

If the component-level fontLookup is "device" or the component-level fontFamily is not found in the swf context, the font lookup for all elements in the component will revert to "device".

If the player doesn't find the device font it will fallback to one of the builtin default fonts.

QE notes: probably need some new mustella tests to cover all the cases - 5 RichText truncation tests fail but I'm not sure this change has anything to do with that
Doc notes:
Bugs: SDK-24470
Reviewer: Gordon
Tests run: checkintests, TextArea, Label, RichText
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/TextBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/RichText.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/spark/src/spark/utils/TextUtil.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Label.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/defaults.css</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/RichEditableText.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/IEmbeddedFontRegistry.as</path>

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

--- frameworks/projects/spark/src/spark/utils/TextUtil.as
+++ frameworks/projects/spark/src/spark/utils/TextUtil.as
@@ -12,24 +12,26 @@
 package spark.utils
 {

-import flash.text.TextFormat;
-import flash.text.engine.ElementFormat;
-import flash.text.engine.FontDescription;
-import flash.text.engine.FontLookup;
-import flash.text.engine.TextBlock;
-import flash.text.engine.TextElement;
-import flash.text.engine.TextLine;
-import flash.utils.describeType;
-
+import flashx.textLayout.compose.ISWFContext;
 import flashx.textLayout.elements.FlowLeafElement;
 import flashx.textLayout.elements.ParagraphElement;
 import flashx.textLayout.elements.SpanElement;
 import flashx.textLayout.elements.TextFlow;
+import flash.text.engine.ElementFormat;
+import flash.text.engine.FontLookup;
 import flashx.textLayout.formats.ITextLayoutFormat;

+import mx.core.EmbeddedFont;
+import mx.core.IEmbeddedFontRegistry;
+import mx.core.IFlexModuleFactory;
+import mx.core.Singleton;
+import mx.core.UIComponent;
+import mx.core.mx_internal;
 import mx.resources.IResourceManager;
 import mx.resources.ResourceManager;
 import mx.utils.StringUtil;
+
+use namespace mx_internal;

 [ExcludeClass]

@@ -154,8 +156,41 @@
 		var resourceManager:IResourceManager = ResourceManager.getInstance();
 		return resourceManager.getString("textLayout", resourceName, args);
 	}
-
-
+
+    /**
+     * @private
+     * The callback used for changing the FontLookup based on SWFcontext.
+     * The function will be called each time a TLF ElementFormat is computed.
+     * It gives us the opportunity to modify the FontLookup setting.
+     *
+     * There will only be a swfContext if the component-level font was
+     * embedded.
+     */
+    public static function resolveFontLookup(
+                    swfContext:ISWFContext, format:ITextLayoutFormat):String
+    {
+        // If the font isn't embedded as advertised, first fall back to
+        // corresponding device font and, only if that fails, fail back to the
+        // player's default font.
+        if (swfContext && format.fontLookup == FontLookup.EMBEDDED_CFF)
+        {
+            var name:String = format.fontFamily;
+            var bold:Boolean = format.fontWeight == "bold";
+            var italic:Boolean = format.fontStyle == "italic";
+            var font:EmbeddedFont = new EmbeddedFont(name, bold, italic);
+
+            var registry:IEmbeddedFontRegistry =
+                UIComponent.embeddedFontRegistry;
+
+            if (registry &&
+                registry.isFontRegistered(font, IFlexModuleFactory(swfContext)))
+            {
+                return FontLookup.EMBEDDED_CFF;
+            }
+        }
+
+        return FontLookup.DEVICE;
+    }
 }

 }


- added first code for debugging interface to DocumentView

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

--- src/reprise/ui/DocumentView.as
+++ src/reprise/ui/DocumentView.as
@@ -11,8 +11,13 @@

 package reprise.ui
 {
+	import flash.display.DisplayObject;
+	import flash.display.Sprite;
 	import flash.display.StageScaleMode;
 	import flash.events.Event;
+	import flash.events.KeyboardEvent;
+	import flash.events.MouseEvent;
+	import flash.geom.Point;
 	import flash.utils.clearTimeout;
 	import flash.utils.getTimer;
 	import flash.utils.setTimeout;
@@ -55,6 +60,9 @@

 		protected var m_stageInvalidationTimeout : int;

+		protected var m_debuggingMode : Boolean;
+		protected var m_debugInterface : Sprite;
+
 		/***************************************************************************
 		*							public methods								   *
 		***************************************************************************/
@@ -232,6 +240,7 @@
 			stage.addEventListener(Event.RESIZE, stage_resize);
 			super.initialize();
 			stage.addEventListener(Event.RENDER, stage_render);
+			stage.addEventListener(KeyboardEvent.KEY_DOWN, key_down);
 		}

 		protected override function initDefaultStyles() : void
@@ -339,6 +348,82 @@
 			clearTimeout(m_stageInvalidationTimeout);
 			stage.invalidate();
 		}
+		protected function toggleDebuggingMode() : void
+		{
+			if (m_debuggingMode)
+			{
+				deactivateDebuggingMode();
+			}
+			else
+			{
+				activateDebuggingMode();
+			}
+		}
+		protected function activateDebuggingMode() : void
+		{
+			if (m_debuggingMode)
+			{
+				return;
+			}
+			m_debuggingMode = true;
+
+			m_debugInterface = new Sprite();
+			m_debugInterface.mouseEnabled = false;
+			addChild(m_debugInterface);
+
+			stage.addEventListener(MouseEvent.MOUSE_OVER, debugging_mouseOver, true, 100);
+		}
+		protected function deactivateDebuggingMode() : void
+		{
+			if (!m_debuggingMode)
+			{
+				return;
+			}
+			m_debuggingMode = false;
+
+			removeChild(m_debugInterface);
+			m_debugInterface = null;
+
+			stage.removeEventListener(MouseEvent.MOUSE_OVER, debugging_mouseOver, true);
+		}
+		protected function debugMarkElement(element : UIComponent) : void
+		{
+			var output : String = 'Element: ' + element + '\n';
+
+			var display : Sprite = element.valueForKey('m_contentDisplay');
+			var position : Point = new Point(display.x, display.y);
+			position = element.localToGlobal(position);
+			m_debugInterface.x = position.x;
+			m_debugInterface.y = position.y;
+
+			m_debugInterface.graphics.clear();
+			m_debugInterface.graphics.lineStyle(1, 0xffff);
+
+			var boxWidth : Number = element.valueForKey('m_borderBoxWidth');
+			var boxHeight : Number = element.valueForKey('m_borderBoxHeight');
+			output += 'Border Box: width ' + boxWidth + ', height ' + boxHeight + '\n';
+			m_debugInterface.graphics.drawRect(-element.valueForKey('m_borderLeftWidth'),
+				-element.valueForKey('m_borderTopWidth'), boxWidth, boxHeight);
+
+			boxWidth -= element.valueForKey('m_borderLeftWidth');
+			boxWidth -= element.valueForKey('m_borderRightWidth');
+			boxHeight -= element.valueForKey('m_borderTopWidth');
+			boxHeight -= element.valueForKey('m_borderBottomWidth');
+			output += 'Padding Box: width ' + boxWidth + ', height ' + boxHeight + '\n';
+			m_debugInterface.graphics.endFill();
+			m_debugInterface.graphics.drawRect(0, 0, boxWidth, boxHeight);
+
+			boxWidth -= element.valueForKey('m_paddingLeft');
+			boxWidth -= element.valueForKey('m_paddingRight');
+			boxHeight -= element.valueForKey('m_paddingTop');
+			boxHeight -= element.valueForKey('m_paddingBottom');
+			output += 'Content Box: width ' + boxWidth + ', height ' + boxHeight + '\n';
+			m_debugInterface.graphics.endFill();
+			m_debugInterface.graphics.drawRect(element.valueForKey('m_paddingLeft'),
+				element.valueForKey('m_paddingTop'), boxWidth, boxHeight);
+
+			log(output);
+		}

 		protected function stage_resize(event : Event) : void
 		{
@@ -355,5 +440,32 @@
 		{
 			validateElements();
 		}
+
+		protected function key_down(event : KeyboardEvent) : void
+		{
+			if (event.shiftKey && event.ctrlKey && event.keyCode == 4)
+			{
+				toggleDebuggingMode();
+			}
+		}
+		protected function debugging_mouseOver(event : MouseEvent) : void
+		{
+			var parent : DisplayObject = DisplayObject(event.target);
+			var element : UIComponent;
+			while (parent)
+			{
+				if (parent is UIComponent)
+				{
+					element = UIComponent(parent);
+					break;
+				}
+				parent = parent.parent;
+			}
+			if (!element)
+			{
+				return;
+			}
+			debugMarkElement(element);
+		}
 	}
 }


Transferred from the Adobe Open Source Subversion Repository

Revision: 14966
Author:   klin@adobe.com
Date:     2010-03-23T21:53:53.095287Z

Log Message:
-----------
Merge 14965 from 4.x to trunk.

Fix for http://bugs.adobe.com/jira/browse/SDK-25909 and another underlying List/Tree/DataGrid issue. The bug was that the dragProxy for a TileList and HorizontalList didn't have the right layoutDirection causing it to be incorrectly positioned. While investigating the issue, I found that there was some fallout from changing SpriteAsset. The selection and rollover highlights on a List were disappearing. It turns out that List and DataGrid create their own SpriteAssets for creating certain indicators (like highlight and selection), while Tree creates it to wrap the disclosureIcon.

The fix for first bug is to set the layoutDirection of the dragProxy to “rtl” when the dragInitiator is also "rtl". It doesn’t inherit the layoutDirection because it is a child of the systemManager. I’ve also included the fix for the fallout from SpriteAsset by setting layoutDirection on those specific instances to null (inheriting) instead of their default “ltr”.

QE notes: Need updates to mirrored Tree bitmaps.
Doc notes: No
Bugs: SDK-25909
Reviewer: Jason
Tests run: checkintests
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/treeClasses/TreeItemRenderer.as</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/controls/dataGridClasses/DataGridBase.as</path>

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

--- frameworks/projects/framework/src/mx/managers/DragManagerImpl.as
+++ frameworks/projects/framework/src/mx/managers/DragManagerImpl.as
@@ -302,6 +302,12 @@
 			}
 		}

+        // Set the layoutDirection of the dragProxy and dragImage to match the dragInitiator
+        // to ensure that they will be in the right position and orientation.
+        if (dragInitiator is ILayoutDirectionElement &&
+            ILayoutDirectionElement(dragInitiator).layoutDirection == LayoutDirection.RTL)
+            dragProxy.layoutDirection = LayoutDirection.RTL;
+
 		dragImage.setActualSize(proxyWidth, proxyHeight);
 		dragProxy.setActualSize(proxyWidth, proxyHeight);

@@ -335,17 +341,8 @@
 		var mouseX:Number = point.x;
 		var mouseY:Number = point.y;

-        // If the target's layout is rtl that means the proxy origin x
-        // is currently offset from the right edge of the dragInitiator. Fix that:
-        var originX:Number = -xOffset;
-        if (dragInitiator is ILayoutDirectionElement)
-        {
-            if (ILayoutDirectionElement(dragInitiator).layoutDirection == LayoutDirection.RTL)
-                originX += dragInitiator.getExplicitOrMeasuredWidth();
-        }
-
         // Find the proxy origin in global space
-        var proxyOrigin:Point = DisplayObject(dragInitiator).localToGlobal(new Point(originX, -yOffset));
+        var proxyOrigin:Point = DisplayObject(dragInitiator).localToGlobal(new Point(-xOffset, -yOffset));
         proxyOrigin = DisplayObject(sandboxRoot).globalToLocal(proxyOrigin);

         // Set dragProxy.offset to the mouse offset within the drag proxy.


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

--- frameworks/projects/advancedgrids/src/mx/styles/metadata/GapStyles.as
+++ frameworks/projects/advancedgrids/src/mx/styles/metadata/GapStyles.as
@@ -1,4 +1,24 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  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.
+//
+////////////////////////////////////////////////////////////////////////////////

+/**
+ *  Number of pixels between children in the horizontal direction.
+ *  The default value depends on the component class;
+ *  if not overriden for the class, the default value is 8.
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
 [Style(name="horizontalGap", type="Number", format="Length", inherit="no")]

 /**


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

--- frameworks/projects/charts/src/mx/charts/chartClasses/ChartElement.as
+++ frameworks/projects/charts/src/mx/charts/chartClasses/ChartElement.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: 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@1261166 13f79535-47bb-0310-9956-ffa450edef68

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

 package mx.graphics
 {


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

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

 package mx.messaging.config
 {


export menu now says "Weave 2.x"

export menu now says "Weave 2.x"

--- WeaveUI/src/weave/menus/ExportMenu.as
+++ WeaveUI/src/weave/menus/ExportMenu.as
@@ -27,22 +27,11 @@
 		{
 			super({
 				shown: function():Boolean { return ExportMenu.shown; },
-				label: lang("Weave 2.0"),
+				label: lang("Weave 2.x"),
 				children: [
 					{
 						label: lang("Export to HTML5"),
 						click: export
-					},
-					{
-						enabled: function():Boolean { return exported; },
-						label: lang("Copy layout from HTML5"),
-						click: function():void {
-							JavaScript.exec(
-								jsVars(false),
-								'var obj = window[WEAVE_EXTERNAL_TOOLS][windowName];',
-								'this.path("Layout").request("FlexibleLayout").state(obj.window.weave.path("Layout").getState())'
-							);
-						}
 					}
 				]
 			});


fixed bug where part markers weren't decoded correctly.

Change-Id: Ic35acc194e78c152b47a9aa343090db0cfd7a9f9

--- WeaveData/src/weave/utils/GeometryStreamDecoder.as
+++ WeaveData/src/weave/utils/GeometryStreamDecoder.as
@@ -598,7 +598,7 @@
 								if (geometryID < geometries.length && geometries[geometryID] is GeneralizedGeometry)
 								{
 									if (importance == -1)
-										(geometries[geometryID] as GeneralizedGeometry).addPartMarker(vertexID);
+										(geometries[geometryID] as GeneralizedGeometry).addPartMarker(vertexIDArray[i]);
 									else
 										(geometries[geometryID] as GeneralizedGeometry).addPoint(vertexIDArray[i], importance, x, y);
 								}


simplifying code

simplifying code

--- WeaveUI/src/weave/visualization/plotters/WMSPlotter.as
+++ WeaveUI/src/weave/visualization/plotters/WMSPlotter.as
@@ -21,10 +21,6 @@
 {
 	import flash.display.Bitmap;
 	import flash.display.BitmapData;
-	import flash.display.BlendMode;
-	import flash.display.Graphics;
-	import flash.display.IBitmapDrawable;
-	import flash.display.LineScaleMode;
 	import flash.display.Shape;
 	import flash.display.TriangleCulling;
 	import flash.geom.ColorTransform;
@@ -32,7 +28,6 @@
 	import flash.geom.Point;
 	import flash.geom.Rectangle;
 	import flash.text.TextField;
-	import flash.text.TextFieldType;
 	import flash.utils.Dictionary;

 	import org.openscales.proj4as.ProjConstants;
@@ -40,9 +35,7 @@
 	import weave.api.WeaveAPI;
 	import weave.api.data.IProjectionManager;
 	import weave.api.data.IProjector;
-	import weave.api.data.IQualifiedKey;
 	import weave.api.disposeObjects;
-	import weave.api.getCallbackCollection;
 	import weave.api.newLinkableChild;
 	import weave.api.primitives.IBounds2D;
 	import weave.api.registerLinkableChild;
@@ -50,13 +43,12 @@
 	import weave.core.LinkableBoolean;
 	import weave.core.LinkableNumber;
 	import weave.core.LinkableString;
-	import weave.data.ProjectionManager;
 	import weave.primitives.Bounds2D;
 	import weave.services.wms.ModestMapsWMS;
 	import weave.services.wms.OnEarthProvider;
 	import weave.services.wms.WMSProviders;
 	import weave.services.wms.WMSTile;
-	import weave.utils.BitmapText;
+	import weave.utils.Dictionary2D;

 	/**
 	 * WMSPlotter
@@ -108,25 +100,7 @@
 		private const _normalizedGridBounds:IBounds2D = new Bounds2D();
 		private const _tempReprojPoint:Point = new Point(); // reusable object for reprojections
 		private const projManager:IProjectionManager = WeaveAPI.ProjectionManager; // reprojecting tiles
-		private const _tileSRSToShapeCache:Dictionary = new Dictionary(true); // use WeakReferences to be GC friendly
-
-		private function getCachedShape(tile:WMSTile, srs:String):ProjectedShape
-		{
-			var srsToShape:Object = _tileSRSToShapeCache[tile];
-
-			if (srsToShape == null)
-				return null;
-
-			return srsToShape[srs];
-		}
-
-		private function setCachedShape(shape:ProjectedShape, tile:WMSTile, srs:String):void
-		{
-			if (_tileSRSToShapeCache[tile] == null)
-				_tileSRSToShapeCache[tile] = new Dictionary(true);
-
-			_tileSRSToShapeCache[tile][srs] = shape;
-		}
+		private const _tileSRSToShapeCache:Dictionary2D = new Dictionary2D(true, true); // use WeakReferences to be GC friendly

 		private function getDestinationSRS():String
 		{
@@ -142,7 +116,7 @@
 		private function getShape(tile:WMSTile):ProjectedShape
 		{
 			// check if this tile has a cached shape
-			var cachedValue:ProjectedShape = getCachedShape(tile, getDestinationSRS());
+			var cachedValue:ProjectedShape = _tileSRSToShapeCache.get(tile, getDestinationSRS());
 			if (cachedValue != null)
 				return cachedValue;

@@ -230,7 +204,7 @@
 			reprojectedDataBounds.makeSizePositive();
 			projShape.bounds = reprojectedDataBounds;

-			setCachedShape(projShape, tile, getDestinationSRS());
+			_tileSRSToShapeCache.set(tile, getDestinationSRS(), projShape);

 			return projShape;
 		}


Allow URL.url for lazy modelling

Allow URL.url for lazy modelling

--- as3/xobjas3/src/com/rpath/xobj/URL.as
+++ as3/xobjas3/src/com/rpath/xobj/URL.as
@@ -79,5 +79,14 @@
         return value;
     }

+    public function set url(s:String):void
+    {
+        value = s;
+    }
+
+    public function get url():String
+    {
+        return value;
+    }
 }
 }


Update ladder after ladder view offset change.

--- bin/Data/AngelScript/Components/ServerCommandUi.as
+++ bin/Data/AngelScript/Components/ServerCommandUi.as
@@ -420,9 +420,15 @@
         if (eventData ["Element"].GetPtr () is sendMessageButton_)
             SendChatMessage ();
         else if (eventData ["Element"].GetPtr () is increaseLadderViewOffsetButton_)
+        {
             ladderViewOffset_ += 1;
+            timeUntilLadderUpdate_ = 0.0f;
+        }
         else if (eventData ["Element"].GetPtr () is decreaseLadderViewOffsetButton_)
+        {
             ladderViewOffset_ -= 1;
+            timeUntilLadderUpdate_ = 0.0f;
+        }
         else if (eventData ["Element"].GetPtr () is spawnAiButton_)
             SendSpawnAiRequest ();
         else


Re #82 - release v.0.0.8.1 fix time rounding while parsing crontime

git-svn-id: 5c313c7b604ce6bf72d7224b35e7462ee01c5e2b@141 7a690eda-67ec-4556-b061-4c86d960b817

--- exe/SWPlayer/src/eu/screenwerk/components/SWCollection.as
+++ exe/SWPlayer/src/eu/screenwerk/components/SWCollection.as
@@ -41,14 +41,16 @@

 			var from_split:Array = cronline_a[6].toString().split('-');
 			this.valid_from_date = new Date(from_split[0], from_split[1], from_split[2]);
-			this.valid_from_J = uint(this.valid_from_date.getTime() / 1000 / 60 / 60 / 24 +.5 );
+			this.valid_from_J = Math.floor( this.valid_from_date.getTime() / 1000 / 60 / 60 / 24 );

 			var to_split:Array = cronline_a[7].toString().split('-');
 			this.valid_to_date = new Date(to_split[0], to_split[1], to_split[2]);
-			this.valid_to_J = uint(this.valid_to_date.getTime() / 1000 / 60 / 60 / 24 +.5 );
+			this.valid_to_J = Math.floor( this.valid_to_date.getTime() / 1000 / 60 / 60 / 24 );

 			this.setLastDate();
 			this.setNextDate();
+
+			Application.application.log( "Created collection " + this.sw_id + ' - ' + this.lastDate.toTimeString() + '..' + this.nextDate.toTimeString() );

 			this.addEventListener(Event.ADDED, play, false, 0, true);
 		}
@@ -115,8 +117,6 @@
 			this.addChild(this.current_layout);
 		}

-
-
 		private function playNextLayoutOnTimer(event:TimerEvent):void
 		{
 			event.stopPropagation();
@@ -159,8 +159,8 @@
 			var last_date:Date = null;

 			var now:Date = new Date();
-			var now_J:uint = uint( now.getTime() / 1000 / 60 / 60 / 24 +.5 );
-			var i_date:Date = new Date(now.getTime());
+			var now_J:uint = Math.floor( now.getTime() / 1000 / 60 / 60 / 24 );
+			var i_date:Date = new Date(Math.floor(now.getTime()/1000/60)*60*1000);

 			for (var i:uint=0;i<366;i++)
 			{
@@ -169,7 +169,8 @@
 				if (now_J-i > this.valid_to_J) continue;
 				if (now_J-i < this.valid_from_J) break;

-				i_date = new Date(now.getTime()-i*1000*60*60*24);
+				//i_date = new Date(now.getTime()-i*1000*60*60*24);
+				i_date.setTime(i_date.getTime()-1000*60*60*24);

 	            if (this.instring(this.cron_day.toString(), i_date.getDate().toString()) == false) continue;
 	            if (this.instring(this.cron_month.toString(), i_date.getMonth().toString()) == false) continue;
@@ -215,9 +216,9 @@
 			var next_date:Date = null;

 			var now:Date = new Date();
-			var now_J:uint = uint( ( now.getTime() / 1000 + 1 ) / 60 / 60 / 24 +.5 );
-			var i_date:Date = new Date(now.getTime());
-
+			var now_J:uint = Math.floor( now.getTime() / 1000 / 60 / 60 / 24 );
+			var i_date:Date = new Date(Math.floor(now.getTime()/1000/60)*60*1000);
+
 			for (var i:uint=0;i<366;i++)
 			{
 				next_date = null;
@@ -225,7 +226,8 @@
 				if (now_J+i < this.valid_from_J) continue;
 				if (now_J+i > this.valid_to_J) break;

-				i_date = new Date(now.getTime()+i*1000*60*60*24);
+				//i_date = new Date(now.getTime()+i*1000*60*60*24);
+				i_date.setTime(i_date.getTime()+1000*60*60*24);

 	            if (this.instring(this.cron_day.toString(), i_date.getDate().toString()) == false) continue;
 	            if (this.instring(this.cron_month.toString(), i_date.getMonth().toString()) == false) continue;


Transferred from the Adobe Open Source Subversion Repository

Revision: 20920
Author:   build@adobe.com
Date:     2011-03-18T19:54:14.958635Z

Log Message:
-----------
Version update to 4.5.1

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/airspark/src/spark/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/automation_air/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/automation_spark/src/spark/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/flex-config.xml</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/automation_spark/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/automation/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/spark_dmv/src/spark/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/rpc/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/mx/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/charts/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/automation_flashflexkit/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/automation_dmv/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/modules/compiler/src/java/flex2/tools/VersionInfo.java</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Version.as</path>
<path kind="file" action="M">/private/flex/sdk/trunk/frameworks/projects/advancedgrids/src/mx/core/Version.as</path>

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

--- frameworks/projects/automation_air/src/mx/core/Version.as
+++ frameworks/projects/automation_air/src/mx/core/Version.as
@@ -15,4 +15,4 @@
  *  @private
  *  Version string for this class.
  */
-mx_internal static const VERSION:String = "4.5.0.0";
+mx_internal static const VERSION:String = "4.5.1.0";


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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


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

--- frameworks/projects/rpc/src/mx/rpc/xml/SchemaDatatypes.as
+++ frameworks/projects/rpc/src/mx/rpc/xml/SchemaDatatypes.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2006-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.rpc.xml
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 3297
Author:   jimurphy@adobe.com
Date:     2008-09-22T17:59:53.303960Z

Log Message:
-----------
Merge 3.0.x revisions 3260,3262,3266,3271,3276,3282,3285,3292,3294 -> trunk

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/events/FaultEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ProgressBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/events/ResultEvent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/channels/DirectHTTPChannel.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/managers/dragClasses/DragProxy.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/framework/src/mx/managers/SystemManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/AbstractInvoker.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/soap/Operation.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</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/managers/SystemManagerProxy.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/rpc/src/mx/messaging/messages/AbstractMessage.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/Fault.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ISWFBridgeProvider.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/dataGridClasses/DataGridHeader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/SWFLoader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ISWFBridgeGroup.as</path>

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

--- frameworks/projects/rpc/src/mx/messaging/channels/DirectHTTPChannel.as
+++ frameworks/projects/rpc/src/mx/messaging/channels/DirectHTTPChannel.as
@@ -37,6 +37,7 @@
 import mx.netmon.NetworkMonitor;
 import mx.resources.IResourceManager;
 import mx.resources.ResourceManager;
+import flash.events.HTTPStatusEvent;

 use namespace mx_internal;

@@ -166,6 +167,7 @@
         urlLoader.addEventListener(IOErrorEvent.IO_ERROR, httpMsgResp.errorHandler);
         urlLoader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, httpMsgResp.securityErrorHandler);
         urlLoader.addEventListener(Event.COMPLETE, httpMsgResp.completeHandler);
+        urlLoader.addEventListener(HTTPStatusEvent.HTTP_STATUS, httpMsgResp.httpStatusHandler);
         urlLoader.load(urlRequest);
     }

@@ -266,12 +268,14 @@
 import mx.messaging.MessageAgent;
 import mx.messaging.MessageResponder;
 import mx.messaging.channels.DirectHTTPChannel;
+import mx.messaging.messages.AbstractMessage;
 import mx.messaging.messages.AcknowledgeMessage;
 import mx.messaging.messages.HTTPRequestMessage;
 import mx.messaging.messages.ErrorMessage;
 import mx.messaging.messages.IMessage;
 import mx.resources.IResourceManager;
 import mx.resources.ResourceManager;
+import flash.events.HTTPStatusEvent;

 use namespace mx_internal;

@@ -300,18 +304,31 @@
         clientId = channel.clientId;
     }

+    //--------------------------------------------------------------------------
+    //
+    // Variables
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     * @private
+     */
+    private var clientId:String;
+
+    /**
+     * @private
+     */
+    private var lastStatus:int;
+
+    /**
+     * @private
+     */
+    private var resourceManager:IResourceManager = ResourceManager.getInstance();
+
     /**
      *  The URLLoader associated with this responder.
      */
     public var urlLoader:URLLoader;
-
-    private var clientId:String;
-
-    /**
-     * @private
-     */
-	private var resourceManager:IResourceManager =
-									ResourceManager.getInstance();

 	//--------------------------------------------------------------------------
 	//
@@ -347,6 +364,8 @@
         msg.faultDetail = resourceManager.getString(
 			"messaging", "httpRequestError.details", [ details ]);
         msg.rootCause = event;
+        msg.body = URLLoader(event.target).data;
+        msg.headers[AbstractMessage.STATUS_CODE_HEADER] = lastStatus;
         agent.fault(msg, message);
     }

@@ -368,10 +387,12 @@
         msg.correlationId = message.messageId;
         msg.faultCode = "Channel.Security.Error";
         msg.faultString = resourceManager.getString(
-			"messaging", "securityError");
+            "messaging", "securityError");
         msg.faultDetail = resourceManager.getString(
-			"messaging", "securityError.details", [ message.destination ]);
+            "messaging", "securityError.details", [ message.destination ]);
         msg.rootCause = event;
+        msg.body = URLLoader(event.target).data;
+        msg.headers[AbstractMessage.STATUS_CODE_HEADER] = lastStatus;
         agent.fault(msg, message);
     }

@@ -385,9 +406,18 @@
         ack.clientId = clientId;
         ack.correlationId = message.messageId;
         ack.body = URLLoader(event.target).data;
+        ack.headers[AbstractMessage.STATUS_CODE_HEADER] = lastStatus;
         agent.acknowledge(ack, message);
     }
-
+
+    /**
+     *  @private
+     */
+    public function httpStatusHandler(event:HTTPStatusEvent):void
+    {
+        lastStatus = event.status;
+    }
+
     /**
      *  Handle a request timeout by closing our associated URLLoader and
      *  faulting the message to the agent.
@@ -398,8 +428,9 @@
         urlLoader.removeEventListener(IOErrorEvent.IO_ERROR, errorHandler);
 	    urlLoader.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, securityErrorHandler);
 	    urlLoader.removeEventListener(Event.COMPLETE, completeHandler);
+	    urlLoader.removeEventListener(HTTPStatusEvent.HTTP_STATUS, httpStatusHandler);
         urlLoader.close();
-
+
         status(null);
         // send the ack
         var ack:AcknowledgeMessage = new AcknowledgeMessage();


Transferred from the Adobe Open Source Subversion Repository

Revision: 3593
Author:   smgilson@adobe.com
Date:     2008-10-13T17:42:13.039023Z

Log Message:
-----------
ASdoc updates

Checkin Test Passed: Yes
QA: No
Bug:
Doc: No

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/FxRange.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/FxTrackBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/FxSlider.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/FxScrollBar.as</path>

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

--- frameworks/projects/spark/src/spark/components/supportClasses/Range.as
+++ frameworks/projects/spark/src/spark/components/supportClasses/Range.as
@@ -19,20 +19,17 @@
 import mx.events.FlexEvent;

 /**
- *  The FxRange class holds a value and a legal range for that
- *  value, defined by a minimum and maximum property.
+ *  The FxRange class holds a value and an allowed range for that
+ *  value, defined by a minimum and maximum properties.
  *  The value property
  *  is always constrained to be between the current minimum and
  *  maximum, and the minimum,
  *  and maximum are always constrained
- *  to be in the proper numerical order such that, at any time,
+ *  to be in the proper numerical order such that
  *  (minimum <= value <= maximum) is true.
- *  The value is also constrained to be multiples of
- *  valueInterval if valueInterval is not 0.
- *
- *
FxRange has a stepSize property to control
- *  how much value will change based on small
- *  stepping operations.

+ *  If valueInterval is not 0,
+ *  then value is also constrained to be a multiple of
+ *  valueInterval.
  *
  *
FxRange is a base class for various controls that require range
  *  functionality, including FxTrackBase and FxSpinner.

@@ -209,10 +206,12 @@

     /**
      *  If greater than 0, valueInterval constrains
-     *  value to multiples of itself. If it is 0, then
-     *  value can be any number between minimum and
-     *  maximum. Also, value may always be set to the
-     *  minimum and maximum.
+     *  value to multiples of valueInterval.
+     *  If it is 0, then
+     *  value can be any number between minimum and
+     *  maximum.
+     *  You can alsways set value to
+     *  minimum or maximum.
      *  Changing valueInterval also may change
      *  stepSize to be a multiple of
      *  valueInterval and >= valueInterval.
@@ -285,15 +284,15 @@
     }

     /**
-     *  Round a value (such as stepSize)
-     *  to the closets multiple of interval.
+     *  Round a value
+     *  to the closets multiple of the specified interval.
      *
      *  @param value The value to round.
      *
      *  @param interval The interval.
      *
-     *  @return The closets multiple of interval.
-     *  The minimum value returned is interval.
+     *  @return The multiple of interval closesst to value.
+     *  The minimum returned Number is interval.
      */
     protected function nearestValidInterval(value:Number, interval:Number):Number
     {
@@ -307,15 +306,15 @@
     }

     /**
-     *  Rounds value to the closest multiple of
-     *  interval, and constrain the result to the range
-     *  defined by Range.
-     *  If interval is 0, then the value
+     *  Rounds a value to the closest multiple of
+     *  the specified interval, and constrains the result to the range
+     *  defined by the FxRange object.
+     *
+     *  @param value The value to round.
+     *
+     *  @param interval The interval to round the value against.
+     *  If interval is 0, then the returned Number
      *  is only bound to the range.
-     *
-     *  @param value The value to round.
-     *
-     *  @param interval The interval to round the value against.
      *
      *  @return The rounded value, or 0 if value is NaN.
      */


Transferred from the Adobe Open Source Subversion Repository

Revision: 11170
Author:   rfrishbe@adobe.com
Date:     2009-10-26T23:15:30.879444Z

Log Message:
-----------
ItemRenderer changes.  Fixing some bugs with the autoDrawBackground flag.  Also making some PARB changes:

1.  IItemRenderer.index -> itemIndex (affects DefaultItemRenderer, ItemRenderer, and ButtonBarButton).
2.  GroupBase.renderBackgroundFill() (protected method) -> drawBackground() (mx_internal method)
3.  ItemRenderer.handleBackgroundFill -> autoDrawBackground
4.  Removed contentBackgroundColor from ItemRenderer

Also, DefaultItemRenderer is now no longer an MXML file, but it is an AS-only class that extends UIComponent.

QE notes: -
Doc notes: Yes - Can you please look at the ASDocs for DefaultItemRenderer.as and the autoDrawBackground flag on ItemRenderer
Bugs: -
Reviewer: Deepa
Tests run: checkintests, Mustella List, DataGroup, DropDownList
Is noteworthy for integration: Yes

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/List.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/ButtonBarButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Group.as</path>
<path kind="file" copyfrom-path="/flex/sdk/trunk/frameworks/projects/spark/src/spark/skins/spark/DefaultItemRenderer.mxml" copyfrom-rev="11100" action="A">/flex/sdk/trunk/frameworks/projects/spark/src/spark/skins/spark/DefaultItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/IItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/skins/spark/DefaultComplexItemRenderer.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/ItemRenderer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/ButtonBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/GroupBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/DataGroup.as</path>
<path kind="file" action="D">/flex/sdk/trunk/frameworks/projects/spark/src/spark/skins/spark/DefaultItemRenderer.mxml</path>

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

--- frameworks/projects/spark/src/spark/skins/spark/DefaultItemRenderer.as
+++ frameworks/projects/spark/src/spark/skins/spark/DefaultItemRenderer.as
@@ -1,61 +1,591 @@
-<?xml version="1.0" encoding="utf-8"?>
-
-
-
-
-<s:ItemRenderer focusEnabled="false" xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark">
-
-    <s:states>
-        <s:State name="normal" />
-        <s:State name="hovered" />
-        <s:State name="selected" />
-        <s:State name="normalAndShowsCaret"/>
-        <s:State name="hoveredAndShowsCaret"/>
-        <s:State name="selectedAndShowsCaret"/>
-    </s:states>
-
-    <s:Rect left="0" right="0" top="0" bottom="0">
-        <s:stroke.normalAndShowsCaret>
-            <s:SolidColorStroke
-                color="{getStyle('selectionColor')}"
-                weight="1"/>
-        </s:stroke.normalAndShowsCaret>
-        <s:stroke.hoveredAndShowsCaret>
-            <s:SolidColorStroke
-                color="{getStyle('selectionColor')}"
-                weight="1"/>
-        </s:stroke.hoveredAndShowsCaret>
-        <s:stroke.selectedAndShowsCaret>
-            <s:SolidColorStroke
-                color="{getStyle('selectionColor')}"
-                weight="1"/>
-        </s:stroke.selectedAndShowsCaret>
-        <s:fill>
-            <s:SolidColor
-            	color.normal="{contentBackgroundColor}"
-                color.normalAndShowsCaret="{contentBackgroundColor}"
-                color.hovered="{getStyle('rollOverColor')}"
-                color.hoveredAndShowsCaret="{getStyle('rollOverColor')}"
-            	color.selected="{getStyle('selectionColor')}"
-                color.selectedAndShowsCaret="{getStyle('selectionColor')}"
-            	/>
-        </s:fill>
-    </s:Rect>
-    <s:Label id="labelDisplay" verticalCenter="0" left="3" right="3" top="6" bottom="4"/>
-
-</s:ItemRenderer>
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2004-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 spark.skins.spark
+{
+
+import flash.display.DisplayObject;
+import flash.events.MouseEvent;
+import flash.geom.Point;
+import flash.geom.Rectangle;
+
+import mx.controls.listClasses.*;
+import mx.core.IDataRenderer;
+import mx.core.IFlexDisplayObject;
+import mx.core.IFlexModuleFactory;
+import mx.core.IFontContextComponent;
+import mx.core.IToolTip;
+import mx.core.IUITextField;
+import mx.core.UIComponent;
+import mx.core.UITextField;
+import mx.core.mx_internal;
+import mx.events.FlexEvent;
+import mx.events.InterManagerRequest;
+import mx.events.ToolTipEvent;
+import mx.managers.ISystemManager;
+
+import spark.components.IItemRenderer;
+import spark.components.Label;
+import spark.components.supportClasses.TextBase;
+
+use namespace mx_internal;
+
+//--------------------------------------
+//  Events
+//--------------------------------------
+
+/**
+ *  Dispatched when the data property changes.
+ *
+ *
When you use a component as an item renderer,
+ *  the data property contains the data to display.
+ *  You can listen for this event and update the component
+ *  when the data property changes.

+ *
+ *  @eventType mx.events.FlexEvent.DATA_CHANGE
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Event(name="dataChange", type="mx.events.FlexEvent")]
+
+//--------------------------------------
+//  Styles
+//--------------------------------------
+
+include "../../styles/metadata/BasicInheritingTextStyles.as"
+include "../../styles/metadata/AdvancedInheritingTextStyles.as"
+include "../../styles/metadata/SelectionFormatTextStyles.as"
+
+/**
+ *  The colors to use for the backgrounds of the items in the list.
+ *  The value is an array of two or more colors.
+ *  The backgrounds of the list items alternate among the colors in the array.
+ *
+ *  @default undefined
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
+ */
+[Style(name="alternatingItemColors", type="Array", arrayType="uint", format="Color", inherit="yes", theme="spark")]
+
+/**
+ *  The alpha of the content background for this component.
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
+ */
+[Style(name="contentBackgroundAlpha", type="Number", inherit="yes", theme="spark")]
+
+/**
+ *  Color of the fill of an item renderer
+ *
+ *  @default 0xFFFFFF
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
+ */
+[Style(name="contentBackgroundColor", type="uint", format="Color", inherit="yes", theme="spark")]
+
+/**
+ *  Color of focus ring when the component is in focus
+ *
+ *  @default 0x70B2EE
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
+ */
+[Style(name="focusColor", type="uint", format="Color", inherit="yes", theme="spark")]
+
+/**
+ *  Color of the highlights when the mouse is over the component
+ *
+ *  @default 0xCEDBEF
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
+ */
+[Style(name="rollOverColor", type="uint", format="Color", inherit="yes", theme="spark")]
+
+/**
+ *  Color of any symbol of a component. Examples include the check mark of a CheckBox or
+ *  the arrow of a scroll button
+ *
+ *  @default 0x000000
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 1.5
+ *  @productversion Flex 4
+ */
+[Style(name="symbolColor", type="uint", format="Color", inherit="yes", theme="spark")]
+
+//--------------------------------------
+//  Excluded APIs
+//--------------------------------------
+
+[Exclude(name="focusThickness", kind="style")]
+
+/**
+ *  The DefaultItemRenderer class defines the default item renderer
+ *  for a List control.
+ *  The default item renderer just draws the text associated
+ *  with each item in the list.
+ *
+ *
You can override the default item renderer
+ *  by creating a custom item renderer.

+ *
+ *  @see spark.components.List
+ *  @see mx.core.IDataRenderer
+ *  @see spark.components.IItemRenderer
+ *  @see spark.components.supportClasses.ItemRenderer
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class DefaultItemRenderer extends UIComponent
+    implements IDataRenderer, IItemRenderer
+{
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function DefaultItemRenderer()
+    {
+        super();
+
+        addHandlers();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+
+    //--------------------------------------------------------------------------
+    //
+    //  Private Properties
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     *  Flag that is set when the mouse is hovered over the item renderer.
+     */
+    private var hovered:Boolean = false;
+
+    //--------------------------------------------------------------------------
+    //
+    //  Public Properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  itemIndex
+    //----------------------------------
+
+    /**
+     *  @private
+     *  storage for the itemIndex property
+     */
+    private var _itemIndex:int;
+
+    /**
+     *  @inheritDoc
+     *
+     *  @default false
+     */
+    public function get itemIndex():int
+    {
+        return _itemIndex;
+    }
+
+    /**
+     *  @private
+     */
+    public function set itemIndex(value:int):void
+    {
+        if (value == _itemIndex)
+            return;
+
+        _itemIndex = value;
+        invalidateDisplayList();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden properties: UIComponent
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  baselinePosition
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    override public function get baselinePosition():Number
+    {
+        if (!validateBaselinePosition() || !labelDisplay)
+            return super.baselinePosition;
+
+        var labelPosition:Point = globalToLocal(labelDisplay.parent.localToGlobal(
+            new Point(labelDisplay.x, labelDisplay.y)));
+
+        return labelPosition.y + labelDisplay.baselinePosition;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  data
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the data property.
+     */
+    private var _data:Object;
+
+    [Bindable("dataChange")]
+
+    /**
+     *  The implementation of the data property
+     *  as defined by the IDataRenderer interface.
+     *  When set, it stores the value and invalidates the component
+     *  to trigger a relayout of the component.
+     *
+     *  @see mx.core.IDataRenderer
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get data():Object
+    {
+        return _data;
+    }
+
+    /**
+     *  @private
+     */
+    public function set data(value:Object):void
+    {
+        _data = value;
+
+        dispatchEvent(new FlexEvent(FlexEvent.DATA_CHANGE));
+    }
+
+    //----------------------------------
+    //  label
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage var for label
+     */
+    private var _label:String = "";
+
+    /**
+     *  @inheritDoc
+     *
+     *  @default ""
+     */
+    public function get label():String
+    {
+        return _label;
+    }
+
+    /**
+     *  @private
+     */
+    public function set label(value:String):void
+    {
+        if (value != _label)
+            _label = value;
+
+        //Push the label down into the labelDisplay,
+        //if it exists
+        if (labelDisplay)
+            labelDisplay.text = _label;
+    }
+
+    //----------------------------------
+    //  labelDisplay
+    //----------------------------------
+
+    /**
+     *  Optional item renderer label component.
+     *  This component is used to determine the value of the
+     *  baselinePosition property in the host component of
+     *  the item renderer.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10
+     *  @playerversion AIR 1.5
+     *  @productversion Flex 4
+     */
+    public var labelDisplay:TextBase;
+
+    //----------------------------------
+    //  showsCaret
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the showsCaret property
+     */
+    private var _showsCaret:Boolean = false;
+
+    /**
+     *  @inheritDoc
+     *
+     *  @default false
+     */
+    public function get showsCaret():Boolean
+    {
+        return _showsCaret;
+    }
+
+    /**
+     *  @private
+     */
+    public function set showsCaret(value:Boolean):void
+    {
+        if (value == _showsCaret)
+            return;
+
+        _showsCaret = value;
+        invalidateDisplayList();
+    }
+
+    //----------------------------------
+    //  selected
+    //----------------------------------
+    /**
+     *  @private
+     *  storage for the selected property
+     */
+    private var _selected:Boolean = false;
+
+    /**
+     *  @inheritDoc
+     *
+     *  @default false
+     */
+    public function get selected():Boolean
+    {
+        return _selected;
+    }
+
+    /**
+     *  @private
+     */
+    public function set selected(value:Boolean):void
+    {
+        if (value != _selected)
+        {
+            _selected = value;
+            invalidateDisplayList();
+        }
+    }
+
+    //----------------------------------
+    //  dragging
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the dragging property.
+     */
+    private var _dragging:Boolean = false;
+
+    /**
+     *  @inheritDoc
+     */
+    public function get dragging():Boolean
+    {
+        return _dragging;
+    }
+
+    /**
+     *  @private
+     */
+    public function set dragging(value:Boolean):void
+    {
+        if (value == _dragging)
+            return;
+
+        _dragging = value;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UIComponent
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    override protected function createChildren():void
+    {
+        super.createChildren();
+
+        if (!labelDisplay)
+        {
+            labelDisplay = new Label();
+            addChild(DisplayObject(labelDisplay));
+        }
+    }
+
+    /**
+     *  @private
+     */
+    override protected function measure():void
+    {
+        super.measure();
+
+        // label had padding of 3 on left and right and padding of 5 on top and bottom.
+        measuredWidth = labelDisplay.getExplicitOrMeasuredWidth() + 6;
+        measuredHeight = labelDisplay.getExplicitOrMeasuredHeight() + 10;
+    }
+
+    /**
+     *  @private
+     */
+    override protected function updateDisplayList(unscaledWidth:Number,
+                                                  unscaledHeight:Number):void
+    {
+        super.updateDisplayList(unscaledWidth, unscaledHeight);
+
+        graphics.clear();
+
+        var backgroundColor:uint;
+        if (selected)
+            backgroundColor = getStyle("selectionColor");
+        else if (hovered)
+            backgroundColor = getStyle("rollOverColor");
+        else
+        {
+            var alternatingColors:Array = getStyle("alternatingItemColors");
+
+            if (alternatingColors && alternatingColors.length > 0)
+            {
+                // translate these colors into uints
+                styleManager.getColorNames(alternatingColors);
+
+                backgroundColor = alternatingColors[itemIndex % alternatingColors.length];
+            }
+            else
+            {
+                backgroundColor = getStyle("contentBackgroundColor");
+            }
+        }
+        graphics.beginFill(backgroundColor, 1);
+
+        if (showsCaret)
+        {
+            graphics.lineStyle(1, getStyle("selectionColor"));
+            graphics.drawRect(0.5, 0.5, unscaledWidth-1, unscaledHeight-1);
+        }
+        else
+        {
+            graphics.lineStyle();
+            graphics.drawRect(0, 0, unscaledWidth, unscaledHeight);
+        }
+
+        graphics.endFill();
+
+        labelDisplay.move(3, 5);
+        labelDisplay.setActualSize(unscaledWidth - 6, unscaledHeight - 10);
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Event handling
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     *  Attach the mouse events.
+     */
+    private function addHandlers():void
+    {
+        addEventListener(MouseEvent.ROLL_OVER, itemRenderer_rollOverHandler);
+        addEventListener(MouseEvent.ROLL_OUT, itemRenderer_rollOutHandler);
+    }
+
+    private function anyButtonDown(event:MouseEvent):Boolean
+    {
+        var type:String = event.type;
+        return event.buttonDown || (type == "middleMouseDown") || (type == "rightMouseDown");
+    }
+
+    /**
+     *  @private
+     *  Mouse rollOver event handler.
+     */
+    protected function itemRenderer_rollOverHandler(event:MouseEvent):void
+    {
+        if (!anyButtonDown(event))
+        {
+            hovered = true;
+            invalidateDisplayList();
+        }
+    }
+
+    /**
+     *  @private
+     *  Mouse rollOut event handler.
+     */
+    protected function itemRenderer_rollOutHandler(event:MouseEvent):void
+    {
+        hovered = false;
+        invalidateDisplayList();
+    }
+
+}
+
+}


Ajout de la validation du Sudoku par bloc

--- tp3.as
+++ tp3.as
@@ -254,7 +254,7 @@

 LigneInvalide:
-  set   redinvalide, %o0        ! Affichage d'un message disant que la ligne est invalide
+  set   resinvalide, %o0        ! Affichage d'un message disant que la ligne est invalide
   call  printf
   nop

@@ -276,9 +276,6 @@
   nop
   /* end Aff */

-  ba    ValiderColonnes02     ! Lancer la validation des colonnes
-  nop
-
 ValiderColonnes02:
   set   validcolon2, %o0        ! Afficher qu'on valider la colonne courante
   mov   %l1, %o1
@@ -298,7 +295,7 @@
   add   %l0, %l1, %l0

   cmp   %l1, 9                    ! Si on a fait le tour du Sudoku, on passe au mode de validation suivant
-  be    FinProgramme
+  be    VB00
   nop

   ba    ValiderColonnes02
@@ -370,11 +367,192 @@
     Partie 5 : Validation par bloc
     ---------------------------------------------------
 */
-!TODO
-
-
-
-FinProgramme:
+VB00:
+  set   validbloc1, %o0
+  call  printf
+  nop
+
+  mov   0, %l0          ! Y
+
+VB02:
+  cmp   %l0, 3          ! Après avoir testé tous les blocs, on quitte le programme
+  be    SudokuFin
+  nop
+
+  mov   0, %l1          ! X
+  ba    VB04            ! On valide les blocs sur la rangée l1
+  nop
+
+VB03:
+  inc   %l0             ! On passe à la rangée de bloc suivante
+  ba    VB02
+  nop
+
+VB04:
+  cmp   %l1, 3          ! Si on a testé les 3 blocs sur la rangée, on passe à la prochaine
+  be    VB03
+  nop
+
+  /* start AFF */
+  set   validbloc2, %o0
+  umul  %l0, 3, %o1
+  add   %l1, %o1, %o1
+  call  printf
+  nop
+  /* end AFF */
+
+  umul  %l1, 3,  %o0    ! Calculer l'indice du premier element du bloc dans le vecteur
+  umul  %l0, 27, %o1
+  add   %o0, %o1, %o2   ! Index calculé
+  set   vecteur, %o3
+  call  VB10            ! Valider le bloc commençant a cet indice
+  nop
+
+  inc   %l1             ! On passe au bloc suivant sur la même rangée
+  ba    VB04
+  nop
+
+VB10:
+  save  %sp, -96, %sp   ! On concerve les registres. L'index du début va se trouver dans i2
+  mov   0, %l0
+
+VB11:
+  cmp   %l0, 21
+  be    VB20            ! Restore
+  nop
+
+  mov   %l0, %o0        ! Si le nombre est un multiple de 3, on change de ligne dans le Sudoku
+  mov   3, %o1
+  call  MultipleDe
+  nop
+
+  cmp   %o0, 1          ! Puisque c'est un multiple de 3, on doit changer de ligne
+  be    VB13
+  nop
+
+  ba    VB14            ! Tester le reste du bloc avec le chiffre
+  nop
+
+VB12:
+  inc   %l0             ! Tester le prochain nombre courant
+  ba    VB11
+  nop
+
+VB13:
+  add   %l0, 6, %l0     ! Changer de ligne
+
+VB14:
+  add   %i2, %l0, %l5   ! Index du chiffre qu'on veut aller chercher
+  ldub  [%i3+%l5], %l3  ! Charger le chiffre courant dans l3
+  add   %l0, 1, %l1     ! Chiffre testeur
+
+VB15:
+  cmp   %l1, 21
+  be   VB12
+  nop
+
+  mov   %l1, %o0        ! Si le nombre est un multiple de 3, on change de ligne dans le Sudoku
+  mov   3, %o1
+  call  MultipleDe
+  nop
+
+  cmp   %o0, 1          ! Puisque c'est un multiple de 3, on doit changer de ligne
+  bne   VB17
+  nop
+
+VB16:
+  add   %l1, 6, %l1     ! Changer de ligne
+
+VB17:
+  add   %i2, %l1, %l5   ! Index du chiffre qu'on veut aller chercher
+  ldub  [%i3+%l5], %l4  ! Charger le chiffre a tester dans l4
+
+  /* start AFF */
+  !set   validation1, %o0
+  !mov   %l0, %o1
+  !mov   %l3, %o2
+  !mov   %l1, %o3
+  !mov   %l4, %o4
+  !call  printf
+  !nop
+  /* end AFF */
+
+  cmp   %l3, %l4        ! S'assurer que les 2 chiffres sont différents
+  bne   VB19
+  nop
+
+VB18:
+  set   resinvalide, %o0    ! Afficher que le bloc n'est pas valide
+  call  printf
+  nop
+
+  ba    SudokuFin           ! Fin du programme
+  nop
+
+VB19:
+  inc   %l1             ! Tester le nombre courant avec un autre chiffre dans le bloc
+  ba    VB15
+  nop
+
+VB20:
+  set   resvalide, %o0
+  call  printf
+  nop
+
+  ret                   ! Passer au bloc suivant
+  restore
+
+/*
+    Vérifier si le nombre donné dans o0 est un multiple de o1.
+    Résultat : o0 -> 0 = n'est pas un multiple, 1 = c'est un multiple
+*/
+MultipleDe:
+  save  %sp, -104, %sp  ! Concerver les registres.
+  mov   0, %y			! initialise %y pour la division
+
+  cmp   %i0, 0          ! Si le nombre est 0, il ne peut être un multiple
+  be    MultipleDe02
+  nop
+
+  udiv  %i0, %i1, %i2
+  umul  %i2, %i1, %i3
+
+  /* DEBUG */
+  !set   debugmultiple1, %o0
+  !mov   %i0, %o1
+  !mov   %i1, %o2
+  !mov   %i2, %o3
+  !call  printf
+  !nop
+
+  !set   debugmultiple2, %o0
+  !mov   %i2, %o1
+  !mov   %i1, %o2
+  !mov   %i3, %o3
+  !call  printf
+  !nop
+  /* END DEBUG */
+
+  cmp   %i0, %i3        ! Comparer le nombre initial et le nombre divisé puis multiplié par le même nombre
+  be    MultipleDe04    ! C'est un multiple
+  nop
+
+MultipleDe02:
+  mov   0, %i0          ! Ce n'est pas un multiple
+  ba    MultipleDe06
+  nop
+
+MultipleDe04:
+  mov   1, %i0          ! C'est un multiple
+
+MultipleDe06:
+  ret                   ! Retour au programme
+  restore
+
+/*
+    Fin du programme
+*/
+SudokuFin:
   call  exit
   nop

@@ -395,18 +573,21 @@
   validation1:       .asciz  "Validation entre %d[%d] et %d[%d]...\n"
   validcolon1:       .asciz  "Validation des colonnes du Sudoku\n"
   validcolon2:       .asciz  " - Validation de la colonne #%d... "
+  validbloc1:        .asciz  "Validation des blocs du Sudoku\n"
+  validbloc2:        .asciz  " - Validation du bloc #%d... "
   resvalide:         .asciz  "Valide !\n"
-  redinvalide:       .asciz  "Invalide !\n"
+  resinvalide:       .asciz  "Invalide !\n"
+  debugmultiple1:    .asciz  "## %d / %d = %d +-+ "
+  debugmultiple2:    .asciz  "%d * %d = %d\n"

 /* Espace mémoire */

 .section ".bss"

             .align 	1   ! Octet
-  !vecteur: 	.skip	81  ! 81 espaces mémoire pour le vecteur du Sudoku
+  !vecteur: .skip	81  ! 81 espaces mémoire pour le vecteur du Sudoku

 .section ".data"

   lecture:  .byte   0   ! Espace pour la lecture du chiffre en entrée
   vecteur:  .byte   8,3,2,5,9,1,6,7,4,4,9,6,3,8,7,2,5,1,5,7,1,2,6,4,9,8,3,1,8,5,7,4,6,3,9,2,2,6,7,9,5,3,4,1,8,9,4,3,8,1,2,7,6,5,7,1,4,6,3,8,5,2,9,3,2,9,1,7,5,8,4,6,6,5,8,4,2,9,1,3,7
-!3


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

--- actionscript/src/com/freshplanet/ane/AirAACPlayer/AirAACPlayer.as
+++ actionscript/src/com/freshplanet/ane/AirAACPlayer/AirAACPlayer.as
@@ -212,7 +212,7 @@
         }

 	    private static function get isIOS():Boolean {
-		    return Capabilities.manufacturer.indexOf("iOS") > -1;
+		    return Capabilities.manufacturer.indexOf("iOS") > -1 && Capabilities.os.indexOf("x86_64") < 0 && Capabilities.os.indexOf("i386") < 0;;
 	    }

 	    private static function get isAndroid():Boolean {


SDP: parse all fmtp parameters

SDP: parse all fmtp parameters

--- src/com/axis/rtspclient/SDP.as
+++ src/com/axis/rtspclient/SDP.as
@@ -2,6 +2,8 @@

   import flash.utils.ByteArray;
   import flash.external.ExternalInterface;
+
+  import mx.utils.StringUtil;

   public class SDP {
     private var version:int = -1;
@@ -23,10 +25,12 @@
       var success:Boolean = true;
       var currentMediaBlock:Object = null;

-      /* Could end up with '\r' in the 'line' variable, just keep in mind when matching */
       for each (var line:String in content.toString().split("\n")) {
-        line = line.replace(/\r/, '');
-        if (0 === line.length) continue;
+        line = line.replace(/\r/, ''); /* Delimiter '\r\n' is allowed, if this is the case, remove '\r' too */
+        if (0 === line.length) {
+          /* Empty row (last row perhaps), skip to next */
+          continue;
+        }

         switch (line.charAt(0)) {
         case 'v':
@@ -178,9 +182,9 @@
         return true;
       }

-      var matches:Array; /* Used in some cases of below switch-case */
+      var matches:Array; /* Used for some cases of below switch-case */
       var separator:int    = line.indexOf(':');
-      var attribute:String = line.substr(0, (-1 === separator) ? 0x7FFFFFFF : separator);
+      var attribute:String = line.substr(0, (-1 === separator) ? 0x7FFFFFFF : separator); /* 0x7FF.. is default */

       switch (attribute) {
       case 'a=recvonly':
@@ -214,14 +218,10 @@
           return false;
         }

-        for each (var param:String in matches[2].split('; ')) {
+        media.fmtp = new Object();
+        for each (var param:String in matches[2].split(';')) {
           var idx:int = param.indexOf('=');
-          if (param.substr(0, idx) !== 'sprop-parameter-sets') {
-            /* Only store sprop-parameter-sets for now */
-            continue;
-          }
-
-          media.spropParameterSets = param.substr(idx + 1);
+          media.fmtp[StringUtil.trim(param.substr(0, idx))] = StringUtil.trim(param.substr(idx + 1));
         }

         break;