Transferred from the Adobe Open Source Subversion Repository

Revision: 11727
Author:   dsubrama@adobe.com
Date:     2009-11-12T20:58:37.583423Z

Log Message:
-----------
You can't just assume the first shader filter in a maskee object's filter array is the luminosity shader when rendering a luminosity mask. Instead, we now loop through all the filters in the array and search for the luminosity shader.

QE notes: None
Doc notes: None
Bugs: SDK-24180
Reviewer: Ryan
Tests run: FXG runtime, FXG static
Is noteworthy for integration: No

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

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

--- frameworks/projects/spark/src/spark/primitives/supportClasses/GraphicElement.as
+++ frameworks/projects/spark/src/spark/primitives/supportClasses/GraphicElement.as
@@ -368,9 +368,9 @@
         var previous:Boolean = needsDisplayObject;
         _alpha = value;

-	// The product of _alpha and the designLayer's
-	// alpha is the effectiveAlpha which is
-	// committed in commitProperties()
+    // The product of _alpha and the designLayer's
+    // alpha is the effectiveAlpha which is
+    // committed in commitProperties()
         if (designLayer)
             value = value * designLayer.effectiveAlpha;

@@ -3197,7 +3197,7 @@
             else if (_maskType == MaskType.LUMINOSITY)
             {
                 _mask.cacheAsBitmap = true;
-		drawnDisplayObject.cacheAsBitmap = true;
+                drawnDisplayObject.cacheAsBitmap = true;

                 // Create the shader wrapper class which wraps the pixel bender filter
                 var luminosityMaskShader:LuminosityMaskShader = new LuminosityMaskShader();
@@ -3627,21 +3627,28 @@

                 if (_mask && _maskType == MaskType.LUMINOSITY && _mask.filters.length > 0)
                 {
-                    // Grab the shader filter and clear out the mask
-                    var shaderFilter:ShaderFilter = _mask.filters[0];
+                    // Grab the shader filter
+                    var shaderFilterIndex:int;
+                    var shaderFilter:ShaderFilter;
+                    var len:int = _mask.filters.length;
+                    for (shaderFilterIndex = 0; shaderFilterIndex < len; shaderFilterIndex++)
+                    {
+                        if (_mask.filters[shaderFilterIndex] is ShaderFilter &&
+                            ShaderFilter(_mask.filters[shaderFilterIndex]).shader is LuminosityMaskShader)
+                        {
+                            shaderFilter = _mask.filters[shaderFilterIndex];
+                            break;
+                        }
+                    }

-                    if (shaderFilter && (shaderFilter.shader is LuminosityMaskShader))
+                    if (shaderFilter)
                     {
-                        // Clear out the mask's filters because we could potentially
-                        // have a rendering change by setting the mode dynamically
-                        // while the filters have been set.
-                        _mask.filters = [];
-
                         // Reset the mode property
                         LuminosityMaskShader(shaderFilter.shader).mode = calculateLuminositySettings();

                         // Re-apply the filter to the mask
-                        _mask.filters = [shaderFilter];
+                        _mask.filters[shaderFilterIndex] = shaderFilter;
+                        _mask.filters = _mask.filters;
                     }
                 }
             }


accessibility Signed-off-by:delfi <delfi@segonquart.localhost>

accessibility
Signed-off-by:delfi <7a08856f93580430fa9b7f49ec8380a13169718b@segonquart.localhost>

--- as/form/includes/idiomesForm.as
+++ as/form/includes/idiomesForm.as
@@ -8,9 +8,8 @@
         var caSend
 :String = "Enviar Email!";
         //
-        contact_txt._accProps:Object = new Object();
-        send_txt._accProps
-:Object = new Object();
+        var contact_txt._accProps:Object = new Object();
+        var send_txt._accProps :Object = new Object();
         //
         if (System.capabilities.language == "en" || System.capabilities.language == "de")
     {
@@ -19,6 +18,7 @@
         this.contact_txt.kerning = 0.7;
         //
         this.contact_txt._accProps.name = enContact;
+        this.contact_txt._accProps.description = "your email";
         this.send_txt._accProps.name = enSend;
         Accessibility.updateProperties ();
     }
@@ -29,6 +29,7 @@
         this.ok_mc.send_txt.text = frSend;
         //
         this.contact_txt._accProps.name = frContact;
+        this.contact_txt._accProps.description = "votre email";
         this.send_txt._accProps.name = frSend;
         Accessibility.updateProperties ();
     }
@@ -36,17 +37,19 @@
     {
         this.contact_txt.text = esContact;
         this.ok_mc.send_txt.text = esSend;
-
+        //
         this.contact_txt._accProps.name = esContact;
+        this.contact_txt._accProps.description = "su email";
         this.send_txt._accProps.name = esSend;
         Accessibility.updateProperties ();
-
-    } else
+    }
+else
     {
         this.contact_txt.text = caContact;
         this.ok_mc.send_txt.text = caSend;
         //
         this.contact_txt._accProps.name = caContact;
+        this.contact_txt._accProps.description = "el vostre email";
         this.send_txt._accProps.name = caSend;
         Accessibility.updateProperties ();
     }


accessibility methods Signed-off-by:delfi <delfi@segonquart.localhost>

accessibility methods
Signed-off-by:delfi <7a08856f93580430fa9b7f49ec8380a13169718b@segonquart.localhost>

--- as/form/includes/idiomesForm.as
+++ as/form/includes/idiomesForm.as
@@ -1,34 +1,52 @@
-
 var esContact:String = "_Contacto";
-var esSend:String = "Enviar Email!";
-var enContact:String = "_Contact";
-var enSend:String = "Send Email!";
-var frContact:String = "_Contact";
-var frSend:String = "Envoyer Email!";
-var caContact:String = "_Contacte";
-var caSend:String = "Enviar Email!";
-
-if (System.capabilities.language == "en" || System.capabilities.language == "de")
-{
-	this.contact_txt.text = enContact;
-	this.ok_mc.send_txt.text = enSend;
-	this.contact_txt.kerning = 0.7;
-}
+        var esSend:String = "Enviar Email!";
+        var enContact:String = "_Contact";
+        var enSend:String = "Send Email!";
+        var frContact:String = "_Contact";
+        var frSend:String = "Envoyer Email!";
+        var caContact:String = "_Contacte";
+        var caSend
+:String = "Enviar Email!";
+        //
+        contact_txt._accProps:Object = new Object();
+        send_txt._accProps
+:Object = new Object();
+        //
+        if (System.capabilities.language == "en" || System.capabilities.language == "de")
+    {
+        this.contact_txt.text = enContact;
+        this.ok_mc.send_txt.text = enSend;
+        this.contact_txt.kerning = 0.7;
+        //
+        this.contact_txt._accProps.name = enContact;
+        this.send_txt._accProps.name = enSend;
+        Accessibility.updateProperties ();
+    }

 if (System.capabilities.language == "fr")
-{
-	this.contact_txt.text = frContact;
-	this.ok_mc.send_txt.text = frSend;
-}
+    {
+        this.contact_txt.text = frContact;
+        this.ok_mc.send_txt.text = frSend;
+        //
+        this.contact_txt._accProps.name = frContact;
+        this.send_txt._accProps.name = frSend;
+        Accessibility.updateProperties ();
+    }
 if (System.capabilities.language == "es")
-{
-	this.contact_txt.text = esContact;
-	this.ok_mc.send_txt.text = esSend;
-}
-else
-{
-	this.contact_txt.text = caContact;
-	this.ok_mc.send_txt.text = caSend;
-}
+    {
+        this.contact_txt.text = esContact;
+        this.ok_mc.send_txt.text = esSend;

+        this.contact_txt._accProps.name = esContact;
+        this.send_txt._accProps.name = esSend;
+        Accessibility.updateProperties ();

+    } else
+    {
+        this.contact_txt.text = caContact;
+        this.ok_mc.send_txt.text = caSend;
+        //
+        this.contact_txt._accProps.name = caContact;
+        this.send_txt._accProps.name = caSend;
+        Accessibility.updateProperties ();
+    }


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

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

--- frameworks/projects/framework/src/mx/resources/ResourceManager.as
+++ frameworks/projects/framework/src/mx/resources/ResourceManager.as
@@ -89,6 +89,12 @@
     {
         if (!instance)
         {
+            CONFIG::performanceInstrumentation
+            {
+                var perfUtil:mx.utils.PerfUtil = mx.utils.PerfUtil.getInstance();
+                perfUtil.markTime("ResourceManager.getInstance().start");
+            }
+
 			if (!Singleton.getClass("mx.resources::IResourceManager"))
 				// install ResourceManagerImpl if not registered already
 				Singleton.registerClass("mx.resources::IResourceManager",
@@ -110,6 +116,11 @@
 				// its own ResourceManagerImpl.
 				instance = new ResourceManagerImpl();
 			}
+
+            CONFIG::performanceInstrumentation
+            {
+                perfUtil.markTime("ResourceManager.getInstance().end");
+            }
         }

         return instance;


Transferred from the Adobe Open Source Subversion Repository

Revision: 4492
Author:   gosmith@adobe.com
Date:     2009-01-12T22:47:10.154251Z

Log Message:
-----------
Simplified how an accessibility class gets hooked into its corresponding component class.

We now do the hooking in the static method enableAccessibility(), which is called by code that is autogenerated by the compiler. Previously this method did nothing and the hooking happened at static initialization time. This allows us to remove the static var accessibilityHooked and the static method hookAccessibility() in each accessibility class.

QE Notes: None
Doc Notes: None
Bugs: None
Reviewer: Deepa and Alex

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/ButtonAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/ListAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/ColorPickerAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/AccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/DataGridAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/DateFieldAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/SliderAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/CheckBoxAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/LinkButtonAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/MenuBarAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/RadioButtonAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/ComboBaseAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/TabBarAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/TreeAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/PanelAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/DateChooserAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/UIComponentAccProps.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/MenuAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/ListBaseAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/AlertAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/ComboBoxAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/TitleWindowAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/AccordionHeaderAccImpl.as</path>

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

--- frameworks/projects/mx/src/mx/accessibility/ColorPickerAccImpl.as
+++ frameworks/projects/mx/src/mx/accessibility/ColorPickerAccImpl.as
@@ -27,74 +27,71 @@

 use namespace mx_internal;

+/**
+ *  ColorPickerAccImpl is a subclass of AccessibilityImplementation
+ *  which implements accessibility for the ColorPicker class.
+ */
 public class ColorPickerAccImpl extends ComboBaseAccImpl
 {
 	include "../core/Version.as";

 	//--------------------------------------------------------------------------
 	//
-	//  Class initialization
-	//
-	//--------------------------------------------------------------------------
-
-	/**
-	 *  @private
-	 *  Static variable triggering the hookAccessibility() method.
-	 *  This is used for initializing DateChooserAccImpl class to hook its
-	 *  createAccessibilityImplementation() method to DateChooser class
-	 *  before it gets called from UIComponent.
-	 */
-	private static var accessibilityHooked:Boolean = hookAccessibility();
-
-	/**
-	 *  @private
-	 *  Static method for swapping the createAccessibilityImplementation()
-	 *  method of Slider withthe SliderAccImpl class.
-	 */
-	private static function hookAccessibility():Boolean
+	//  Class constants
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 */
+	private static const EVENT_OBJECT_VALUECHANGE:uint = 0x800E;
+
+	/**
+	 *  @private
+	 */
+	private static const EVENT_OBJECT_SELECTION:uint = 0x8006;
+
+		/**
+	 *  @private
+	 */
+	private static const STATE_SYSTEM_FOCUSED:uint = 0x00000004;
+
+	/**
+	 *  @private
+	 */
+	private static const STATE_SYSTEM_SELECTABLE:uint = 0x00200000;
+
+	/**
+	 *  @private
+	 */
+	private static const STATE_SYSTEM_SELECTED:uint = 0x00000002;
+
+	//--------------------------------------------------------------------------
+	//
+	//  Class methods
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  Enables accessibility in the ColorPicker class.
+	 *
+	 *
This method is called by application startup code
+	 *  that is autogenerated by the MXML compiler.
+	 *  Afterwards, when instances of ColorPicker are initialized,
+	 *  their accessibilityImplementation property
+	 *  will be set to an instance of this class.

+	 */
+	public static function enableAccessibility():void
 	{
 		ColorPicker.createAccessibilityImplementation =
 			createAccessibilityImplementation;
-
-		return true;
-	}
-
-	/**
-	 *  @private
-	 */
-	private static const EVENT_OBJECT_VALUECHANGE:uint = 0x800E;
-
-	/**
-	 *  @private
-	 */
-	private static const EVENT_OBJECT_SELECTION:uint = 0x8006;
-
-		/**
-	 *  @private
-	 */
-	private static const STATE_SYSTEM_FOCUSED:uint = 0x00000004;
-
-	/**
-	 *  @private
-	 */
-	private static const STATE_SYSTEM_SELECTABLE:uint = 0x00200000;
-
-	/**
-	 *  @private
-	 */
-	private static const STATE_SYSTEM_SELECTED:uint = 0x00000002;
-
-//--------------------------------------------------------------------------
-	//
-	//  Class methods
-	//
-	//--------------------------------------------------------------------------
-
-	/**
-	 *  @private
-	 *  Method for creating the Accessibility class.
-	 *  This method is called from UIComponent.
-	 *  @review
+	}
+
+	/**
+	 *  @private
+	 *  Creates a ColorPicker's AccessibilityImplementation object.
+	 *  This method is called from UIComponent's
+	 *  initializeAccessibility() method.
 	 */
 	mx_internal static function createAccessibilityImplementation(
 								component:UIComponent):void
@@ -103,17 +100,6 @@
 			new ColorPickerAccImpl(component);
 	}

-	/**
-	 *  Method call for enabling accessibility for a component.
-	 *  This method is required for the compiler to activate
-	 *  the accessibility classes for a component.
-	 */
-	public static function enableAccessibility():void
-	{
-		//SwatchPanelAccImpl.enableAccessibility();
-	}
-
-
 	//--------------------------------------------------------------------------
 	//
 	//  Constructor
@@ -173,7 +159,6 @@
 	 *  @param childID uint
 	 *
 	 *  @return Name String
-	 *  @review
 	 */
 	override protected function getName(childID:uint):String
 	{


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

--- frameworks/projects/mx/src/mx/controls/scrollClasses/ScrollBar.as
+++ frameworks/projects/mx/src/mx/controls/scrollClasses/ScrollBar.as
@@ -0,0 +1,1477 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2003-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.scrollClasses
+{
+
+import flash.display.DisplayObject;
+import flash.events.Event;
+import flash.events.EventDispatcher;
+import flash.events.MouseEvent;
+import flash.events.TimerEvent;
+import flash.geom.Point;
+import flash.ui.Keyboard;
+import flash.utils.Timer;
+import mx.controls.Button;
+import mx.core.FlexVersion;
+import mx.core.UIComponent;
+import mx.core.mx_internal;
+import mx.events.FlexEvent;
+import mx.events.ScrollEvent;
+import mx.events.ScrollEventDetail;
+import mx.styles.ISimpleStyleClient;
+import mx.styles.StyleProxy;
+
+use namespace mx_internal;
+
+//--------------------------------------
+//  Styles
+//--------------------------------------
+
+include "../../styles/metadata/SkinStyles.as"
+
+/**
+ *  Name of the class to use as the default skin for the down arrow button of
+ *  the scroll bar.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="downArrowSkin", type="Class", inherit="no", states="up, over, down, disabled")]
+
+/**
+ *  Name of the class to use as the skin for the down arrow button of the
+ *  scroll bar when it is disabled.
+ *
+ *  If you change the skin, either graphically or programmatically,
+ *  you should ensure that the new skin is the same height
+ *  (for horizontal ScrollBars) or width (for vertical ScrollBars) as the track.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="downArrowDisabledSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the down arrow button of the
+ *  scroll bar when you click the arrow button
+ * .
+ *  If you change the skin, either graphically or programmatically,
+ *  you should ensure that the new skin is the same height
+ *  (for horizontal ScrollBars) or width (for vertical ScrollBars) as the track.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="downArrowDownSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the down arrow button of the
+ *  scroll bar when the mouse pointer is over the arrow button.
+ *
+ *  If you change the skin, either graphically or programmatically,
+ *  you should ensure that the new skin is the same height
+ *  (for horizontal ScrollBars) or width (for vertical ScrollBars) as the track.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="downArrowOverSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the down arrow button of
+ *  the scroll bar.
+ *
+ *  If you change the skin, either graphically or programmatically,
+ *  you should ensure that the new skin is the same height
+ *  (for horizontal ScrollBars) or width (for vertical ScrollBars) as the track.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="downArrowUpSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the default skin for the down arrow button of
+ *  the scroll bar.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="thumbSkin", type="Class", inherit="no", states="up, over, down")]
+
+/**
+ *  Name of the class to use as the skin for the thumb of the scroll bar
+ *  when you click the thumb.
+ *
+ *  @default mx.skins.halo.ScrollThumbSkin
+ */
+[Style(name="thumbDownSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the icon for the thumb of the scroll bar.
+ *
+ *  @default "undefined"
+ */
+[Style(name="thumbIcon", type="Class", inherit="no")]
+
+/**
+ *  The number of pixels to offset the scroll thumb from the center of the scroll bar.
+ *
+ *  @default 0
+ */
+[Style(name="thumbOffset", type="Number", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the thumb of the scroll bar
+ *  when the mouse pointer is over the thumb.
+ *
+ *  @default mx.skins.halo.ScrollThumbSkin
+ */
+[Style(name="thumbOverSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the thumb of the scroll bar.
+ *
+ *  @default mx.skins.halo.ScrollThumbSkin
+ */
+[Style(name="thumbUpSkin", type="Class", inherit="no")]
+
+/**
+ *  The colors of the track, as an array of two colors.
+ *  You can use the same color twice for a solid track color.
+ *
+ *  @default [0x94999b, 0xe7e7e7]
+ */
+[Style(name="trackColors", type="Array", arrayType="uint", format="Color", inherit="no")]
+
+
+/**
+ *  Name of the class to use as the default skin for the track of the scroll bar.
+ *
+ *  @default mx.skins.halo.ScrollTrackSkin
+ */
+[Style(name="trackSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the track of the scroll bar
+ *  when the scroll bar is disabled.
+ *
+ *  @default undefined
+ */
+[Style(name="trackDisabledSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the track of the scroll bar
+ *  when you click on the track.
+ *
+ *  @default undefined
+ */
+[Style(name="trackDownSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the track of the scroll bar
+ *  when the mouse pointer is over the scroll bar.
+ *
+ *  @default undefined
+ */
+[Style(name="trackOverSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the track of the scroll bar.
+ *
+ *  @default undefined
+ */
+[Style(name="trackUpSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the default skin for the up arrow button of the scroll bar.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="upArrowSkin", type="Class", inherit="no", states="up, over, down, disabled")]
+
+/**
+ *  Name of the class to use as the skin for the up arrow button of the scroll bar
+ *  when it is disabled.
+ *
+ *  If you change the skin, either graphically or programmatically,
+ *  you should ensure that the new skin is the same height
+ *  (for horizontal ScrollBars) or width (for vertical ScrollBars) as the track.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="upArrowDisabledSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the up arrow button of the scroll bar
+ *  when you click the arrow button.
+ *
+ *  If you change the skin, either graphically or programmatically,
+ *  you should ensure that the new skin is the same height
+ *  (for horizontal ScrollBars) or width (for vertical ScrollBars) as the track.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="upArrowDownSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the up arrow button of the scroll bar
+ *  when the mouse pointer is over the arrow button.
+ *
+ *  If you change the skin, either graphically or programmatically,
+ *  you should ensure that the new skin is the same height
+ *  (for horizontal ScrollBars) or width (for vertical ScrollBars) as the track.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="upArrowOverSkin", type="Class", inherit="no")]
+
+/**
+ *  Name of the class to use as the skin for the up arrow button of the
+ *  scroll bar.
+ *
+ *  If you change the skin, either graphically or programmatically,
+ *  you should ensure that the new skin is the same height
+ *  (for horizontal ScrollBars) or width (for vertical ScrollBars) as the track.
+ *
+ *  @default mx.skins.halo.ScrollArrowSkin
+ */
+[Style(name="upArrowUpSkin", type="Class", inherit="no")]
+
+//--------------------------------------
+//  Excluded APIs
+//--------------------------------------
+
+[Exclude(name="doubleClickEnabled", kind="property")]
+
+[Exclude(name="errorColor", kind="style")]
+[Exclude(name="focusBlendMode", kind="style")]
+[Exclude(name="focusSkin", kind="style")]
+[Exclude(name="focusThickness", kind="style")]
+
+/**
+ *  The ScrollBar class is the base class for the HScrollBar and VScrollBar
+ *  controls.
+ *  A ScrollBar consists of two arrow buttons, a track between them,
+ *  and a variable-size scroll thumb. The scroll thumb can move by
+ *  clicking on either of the two arrow buttons, dragging the scroll thumb
+ *  along the track, or clicking on the track.
+ *
+ *
The width of a scroll bar is equal to the largest width of its subcomponents
+ *  (up arrow, down arrow, thumb, and track).
+ *  Every subcomponent is centered in the scroll bar.

+ *
+ *  @mxml
+ *
+ *
The <mx:ScrollBar> tag inherits all of the tag attributes
+ *  of its superclass, and adds the following tag attributes:

+ *
+ *

+ *  <mx:ScrollBar
+ *    Properties
+ *    direction="vertical|horizontal"
+ *    lineScrollSize="1"
+ *    maxScrollPosition="0"
+ *    minScrollPosition="0"
+ *    pageScrollSize="Reset to the pageSize parameter of setScrollProperties"
+ *    pageSize="0"
+ *    scrollPosition="0"
+ *
+ *    Styles
+ *    borderColor="0xB7BABC"
+ *    cornerRadius="0"
+ *    disabledIconColor="0x999999"
+ *    downArrowDisabledSkin="mx.skins.halo.ScrollArrowSkin"
+ *    downArrowDownSkin="mx.skins.halo.ScrollArrowSkin"
+ *    downArrowOverSkin="mx.skins.halo.ScrollArrowSkin"
+ *    downArrowUpSkin="mx.skins.halo.ScrollArrowSkin"
+ *    fillAlphas="[0.6, 0.4]"
+ *    fillColors="[0xFFFFFF, 0xCCCCCC]"
+ *    highlightAlphas="[0.3, 0.0]"
+ *    iconColor="0x111111"
+ *    thumbDownSkin="mx.skins.halo.ScrollThumbSkin"
+ *    thumbIcon="undefined"
+ *    thumbOffset="0"
+ *    thumbOverSkin="mx.skins.halo.ScrollThumbSkin"
+ *    thumbUpSkin="mx.skins.halo.ScrollThumbSkin"
+ *    trackColors="[0x94999b, 0xe7e7e7]"
+ *    trackSkin="mx.skins.halo.ScrollTrackSkin"
+ *    upArrowDisabledSkin="mx.skins.halo.ScrollArrowSkin"
+ *    upArrowDownSkin="mx.skins.halo.ScrollArrowSkin"
+ *    upArrowOverSkin="mx.skins.halo.ScrollArrowSkin"
+ *    upArrowUpSkin="mx.skins.halo.ScrollArrowSkin"
+ *  />
+ *

+ *
+ *  @see mx.controls.HScrollBar
+ *  @see mx.controls.VScrollBar
+ *  @see mx.controls.Button
+ *  @see mx.controls.scrollClasses.ScrollThumb
+ *
+ */
+public class ScrollBar extends UIComponent
+{
+    include "../../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class constants
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  The width of a vertical scrollbar, or the height of a horizontal
+     *  scrollbar, in pixels.
+     */
+    public static const THICKNESS:Number = 16;
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     */
+    public function ScrollBar()
+    {
+        super();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     *  The up arrow button.
+     */
+    mx_internal var upArrow:Button;
+
+    /**
+     *  @private
+     *  The down arrow button.
+     */
+    mx_internal var downArrow:Button;
+
+    /**
+     *  @private
+     *  The scroll track
+     */
+    mx_internal var scrollTrack:Button;
+
+    /**
+     *  @private
+     *  The scroll thumb
+     */
+    mx_internal var scrollThumb:ScrollThumb;
+
+    /**
+     *  @private
+     *  Used to keep track of minimums because of the orientation change.
+     */
+    mx_internal var _minWidth:Number = 16;
+
+    /**
+     *  @private
+     */
+    mx_internal var _minHeight:Number = 32;
+
+    /**
+     *  @private
+     *  true if servicing a scroll event.
+     */
+    mx_internal var isScrolling:Boolean;
+
+    /**
+     *  @private
+     *  Timer used to autoscroll when holding the mouse down on the track.
+     */
+    private var trackScrollTimer:Timer;
+
+    /**
+     *  @private
+     *  The direction we're going when in track scroll repeat.
+     */
+    private var trackScrollRepeatDirection:int;
+
+    /**
+     *  @private
+     *  The direction we're going when in track scroll repeat.
+     */
+    private var trackScrolling:Boolean = false;
+
+    /**
+     *  @private
+     *  Where the mouse is on the track.
+     */
+    private var trackPosition:Number;
+
+    /**
+     *  @private
+     *  Old position, used to compute deltas when button presses are auto
+     *  repeated
+     */
+    mx_internal var oldPosition:Number;
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  doubleClickEnabled
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Scrollbars cannot be doubleClickEnabled.
+     *  It messes up fast clicking on its buttons.
+     */
+    override public function set doubleClickEnabled(value:Boolean):void
+    {
+    }
+
+    //----------------------------------
+    //  enabled
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Turn off buttons, or turn on buttons and resync thumb.
+     */
+    override public function set enabled(value:Boolean):void
+    {
+        super.enabled = value;
+
+        invalidateDisplayList();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  direction
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the direction property.
+     */
+    private var _direction:String = ScrollBarDirection.VERTICAL;
+
+    [Bindable("directionChanged")]
+    [Inspectable(category="General", enumeration="vertical,horizontal", defaultValue="vertical")]
+
+    /**
+     *  Specifies whether the ScrollBar is for horizontal or vertical scrolling.
+     *  Valid values in MXML are "vertical" and "horizontal".
+     *
+     *
In ActionScript, you use the following constants
+     *  to set this property:
+     *  ScrollBarDirection.VERTICAL and
+     *  ScrollBarDirection.HORIZONTAL.

+     *
+     *  @default ScrollBarDirection.VERTICAL
+     *
+     *  @see mx.controls.scrollClasses.ScrollBarDirection
+     */
+    public function get direction():String
+    {
+        return _direction;
+    }
+
+    /**
+     *  @private
+     */
+    public function set direction(value:String):void
+    {
+        _direction = value;
+
+        invalidateSize();
+        invalidateDisplayList();
+
+        dispatchEvent(new Event("directionChanged"));
+    }
+
+    //----------------------------------
+    //  downArrowStyleFilters
+    //----------------------------------
+
+    /**
+     *  Set of styles to pass from the ScrollBar to the down arrow.
+     *  @see mx.styles.StyleProxy
+     */
+    protected function get downArrowStyleFilters():Object
+    {
+        return null;
+    }
+
+    //----------------------------------
+    //  lineMinusDetail
+    //----------------------------------
+
+    /**
+     *  @private
+     *  String used to set the detail property of a ScrollEvent.
+     */
+    mx_internal function get lineMinusDetail():String
+    {
+        return direction == ScrollBarDirection.VERTICAL ?
+               ScrollEventDetail.LINE_UP :
+               ScrollEventDetail.LINE_LEFT;
+    }
+
+    //----------------------------------
+    //  linePlusDetail
+    //----------------------------------
+
+    /**
+     *  @private
+     *  String used to set the detail property of a ScrollEvent.
+     */
+    mx_internal function get linePlusDetail():String
+    {
+        return direction == ScrollBarDirection.VERTICAL ?
+               ScrollEventDetail.LINE_DOWN :
+               ScrollEventDetail.LINE_RIGHT;
+    }
+
+    //----------------------------------
+    //  lineScrollSize
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the lineScrollSize property.
+     */
+    private var _lineScrollSize:Number = 1;
+
+    [Inspectable(category="Other", defaultValue="1")]
+
+    /**
+     *  Amount to scroll when an arrow button is pressed, in pixels.
+     *
+     *  @default 1
+     */
+    public function get lineScrollSize():Number
+    {
+        return _lineScrollSize;
+    }
+
+    /**
+     *  @private
+     */
+    public function set lineScrollSize(value:Number):void
+    {
+        _lineScrollSize = value;
+    }
+
+    //----------------------------------
+    //  maxDetail
+    //----------------------------------
+
+    /**
+     *  @private
+     *  String used to set the detail property of a ScrollEvent.
+     */
+    private function get maxDetail():String
+    {
+        return direction == ScrollBarDirection.VERTICAL ?
+               ScrollEventDetail.AT_BOTTOM :
+               ScrollEventDetail.AT_RIGHT;
+    }
+
+    //----------------------------------
+    //  maxScrollPosition
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the maxScrollPosition property.
+     */
+    private var _maxScrollPosition:Number = 0;
+
+    [Inspectable(category="Other", defaultValue="0")]
+
+    /**
+     *  Number which represents the maximum scroll position.
+     *
+     *  @default 0
+     */
+    public function get maxScrollPosition():Number
+    {
+        return _maxScrollPosition;
+    }
+
+    /**
+     *  @private
+     */
+    public function set maxScrollPosition(value:Number):void
+    {
+        _maxScrollPosition = value;
+    }
+
+    //----------------------------------
+    //  minDetail
+    //----------------------------------
+
+    /**
+     *  @private
+     *  String used to set the detail property of a ScrollEvent.
+     */
+    private function get minDetail():String
+    {
+        return direction == ScrollBarDirection.VERTICAL ?
+               ScrollEventDetail.AT_TOP :
+               ScrollEventDetail.AT_LEFT;
+    }
+
+    //----------------------------------
+    //  minScrollPosition
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the minScrollPosition property.
+     */
+    private var _minScrollPosition:Number = 0;
+
+    [Inspectable(category="Other", defaultValue="0")]
+
+    /**
+     *  Number that represents the minimum scroll position.
+     *
+     *  @default 0
+     */
+    public function get minScrollPosition():Number
+    {
+        return _minScrollPosition;
+    }
+
+    /**
+     *  @private
+     */
+    public function set minScrollPosition(value:Number):void
+    {
+        _minScrollPosition = value;
+    }
+
+    //----------------------------------
+    //  pageMinusDetail
+    //----------------------------------
+
+    /**
+     *  @private
+     *  String used to set the detail property of a ScrollEvent.
+     */
+    mx_internal function get pageMinusDetail():String
+    {
+        return direction == ScrollBarDirection.VERTICAL ?
+               ScrollEventDetail.PAGE_UP :
+               ScrollEventDetail.PAGE_LEFT;
+    }
+
+    //----------------------------------
+    //  pagePlusDetail
+    //----------------------------------
+
+    /**
+     *  @private
+     *  String used to set the detail property of a ScrollEvent.
+     *  Can be ScrollEventDetail.PAGE_RIGHT or
+     *  ScrollEventDetail.PAGE_DOWN.
+     */
+    mx_internal function get pagePlusDetail():String
+    {
+        return direction == ScrollBarDirection.VERTICAL ?
+               ScrollEventDetail.PAGE_DOWN :
+               ScrollEventDetail.PAGE_RIGHT;
+    }
+
+    //----------------------------------
+    //  pageSize
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the pageSize property.
+     */
+    private var _pageSize:Number = 0;
+
+    [Inspectable(category="Other", defaultValue="0")]
+
+    /**
+     *  The number of lines equivalent to one page.
+     *
+     *  @default 0
+     */
+    public function get pageSize():Number
+    {
+        return _pageSize;
+    }
+
+    /**
+     *  @private
+     */
+    public function set pageSize(value:Number):void
+    {
+        _pageSize = value;
+    }
+
+    //----------------------------------
+    //  pageScrollSize
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the pageScrollSize property.l
+     */
+    private var _pageScrollSize:Number = 0;
+
+    [Inspectable(category="Other", defaultValue="0")]
+
+    /**
+     *  Amount to move the scroll thumb when the scroll bar
+     *  track is pressed, in pixels.
+     *
+     *  @default 0
+     */
+    public function get pageScrollSize():Number
+    {
+        return _pageScrollSize;
+    }
+
+    /**
+     *  @private
+     */
+    public function set pageScrollSize(value:Number):void
+    {
+        _pageScrollSize = value;
+    }
+
+    //----------------------------------
+    //  scrollPosition
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the scrollPosition property.
+     */
+    private var _scrollPosition:Number = 0;
+
+    [Inspectable(category="Other", defaultValue="0")]
+
+    /**
+     *  Number that represents the current scroll position.
+     *
+     *  The value is between minScrollPosition and
+     *  maxScrollPosition inclusively.
+     *
+     *  @default 0
+     */
+    public function get scrollPosition():Number
+    {
+        return _scrollPosition;
+    }
+
+    /**
+     *  @private
+     */
+    public function set scrollPosition(value:Number):void
+    {
+        _scrollPosition = value;
+
+        if (scrollThumb)
+        {
+            // Turn on bitmap caching whenever we start scrolling.  Turn it
+            // off whenever we resize the scrollbar (because caching hurts
+            // performance during a resize animation)
+            if (!cacheAsBitmap)
+                cacheHeuristic = scrollThumb.cacheHeuristic = true;
+
+            if (!isScrolling)
+            {
+                // Update thumb.
+                value = Math.min(value, maxScrollPosition);
+                value = Math.max(value, minScrollPosition);
+
+                var denom:Number = maxScrollPosition - minScrollPosition;
+                var y:Number = (denom == 0 || isNaN(denom)) ? 0 :
+                    ((value - minScrollPosition) * (trackHeight - scrollThumb.height) /
+                    (denom)) + trackY;
+
+                var x:Number = (virtualWidth - scrollThumb.width) / 2  + getStyle("thumbOffset");
+                scrollThumb.move(Math.round(x), Math.round(y));
+            }
+        }
+    }
+
+    //----------------------------------
+    //  thumbStyleFilters
+    //----------------------------------
+
+    /**
+     *  Set of styles to pass from the ScrollBar to the thumb.
+     *  @see mx.styles.StyleProxy
+     */
+    protected function get thumbStyleFilters():Object
+    {
+        return null;
+    }
+
+    //----------------------------------
+    //  trackHeight
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    private function get trackHeight():Number
+    {
+        return virtualHeight -
+               (upArrow.getExplicitOrMeasuredHeight() +
+                downArrow.getExplicitOrMeasuredHeight());
+    }
+
+    //----------------------------------
+    //  trackY
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    private function get trackY():Number
+    {
+        return upArrow.getExplicitOrMeasuredHeight();
+    }
+
+    //----------------------------------
+    //  upArrowStyleFilters
+    //----------------------------------
+
+    /**
+     *  Set of styles to pass from the ScrollBar to the up arrow.
+     *  @see mx.styles.StyleProxy
+     */
+    protected function get upArrowStyleFilters():Object
+    {
+        return null;
+    }
+
+    //----------------------------------
+    //  virtualHeight
+    //----------------------------------
+
+    /**
+     *  @private
+     *  For internal use only.
+     *  Used by horizontal bar to deal with rotation.
+     */
+    mx_internal function get virtualHeight():Number
+    {
+        return unscaledHeight;
+    }
+
+    //----------------------------------
+    //  virtualWidth
+    //----------------------------------
+
+    /**
+     *  @private
+     *  For internal use only.
+     *  Used by horizontal bar to deal with rotation.
+     */
+    mx_internal function get virtualWidth():Number
+    {
+        return unscaledWidth;
+    }
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UIComponent
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     *  Create child objects.
+     */
+    override protected function createChildren():void
+    {
+        super.createChildren();
+
+        // Create the scroll track.
+        if (!scrollTrack)
+        {
+            scrollTrack = new Button();
+            scrollTrack.focusEnabled = false;
+            scrollTrack.skinName = "trackSkin";
+            scrollTrack.upSkinName = "trackUpSkin";
+            scrollTrack.overSkinName = "trackOverSkin";
+            scrollTrack.downSkinName = "trackDownSkin";
+            scrollTrack.disabledSkinName = "trackDisabledSkin";
+
+            if (scrollTrack is ISimpleStyleClient)
+                ISimpleStyleClient(scrollTrack).styleName = this;
+
+            addChild(scrollTrack);
+
+            scrollTrack.validateProperties();
+        }
+
+        // Create the up-arrow button, layered above the track.
+        if (!upArrow)
+        {
+            upArrow = new Button();
+
+            // It will get enabled later in setScrollProperties().
+            upArrow.enabled = false;
+
+            // Holding it down will cause continuous scrolling.
+            upArrow.autoRepeat = true;
+
+            upArrow.focusEnabled = false;
+
+            // This button is a 4-state Button
+            // that by default uses the ScrollArrowSkin.
+            upArrow.upSkinName = "upArrowUpSkin";
+            upArrow.overSkinName = "upArrowOverSkin";
+            upArrow.downSkinName = "upArrowDownSkin";
+            upArrow.disabledSkinName = "upArrowDisabledSkin";
+            upArrow.skinName = "upArrowSkin";
+            upArrow.upIconName = "";
+            upArrow.overIconName = "";
+            upArrow.downIconName = "";
+            upArrow.disabledIconName = "";
+
+            addChild(upArrow);
+
+            upArrow.styleName = new StyleProxy(this, upArrowStyleFilters);
+
+            upArrow.validateProperties();
+            upArrow.addEventListener(FlexEvent.BUTTON_DOWN, upArrow_buttonDownHandler);
+        }
+
+        // Create the down-arrow button, layered above the track.
+        if (!downArrow)
+        {
+            downArrow = new Button();
+
+            // It will get enabled later in setScrollProperties().
+            downArrow.enabled = false;
+
+            // Holding it down will cause continuous scrolling.
+            downArrow.autoRepeat = true;
+
+            downArrow.focusEnabled = false;
+
+            // This button is a 4-state Button
+            // that by default uses the ScrollArrowSkin.
+            downArrow.upSkinName = "downArrowUpSkin";
+            downArrow.overSkinName = "downArrowOverSkin";
+            downArrow.downSkinName = "downArrowDownSkin";
+            downArrow.disabledSkinName = "downArrowDisabledSkin";
+            downArrow.skinName = "downArrowSkin";
+            downArrow.upIconName = "";
+            downArrow.overIconName = "";
+            downArrow.downIconName = "";
+            downArrow.disabledIconName = "";
+
+            addChild(downArrow);
+
+            downArrow.styleName = new StyleProxy(this, downArrowStyleFilters);
+
+            downArrow.validateProperties();
+            downArrow.addEventListener(FlexEvent.BUTTON_DOWN, downArrow_buttonDownHandler);
+        }
+    }
+
+    /**
+     *  @private
+     *  Determine our min width/height based on the up and down
+     *  arrow sizes.
+     */
+    override protected function measure():void
+    {
+        super.measure();
+
+        //make sure arrows have required values
+        upArrow.validateSize();
+        downArrow.validateSize();
+        scrollTrack.validateSize();
+
+        if (FlexVersion.compatibilityVersion >= FlexVersion.VERSION_3_0)
+        {
+            _minWidth = scrollThumb ? scrollThumb.getExplicitOrMeasuredWidth() : 0;
+            _minWidth = Math.max(scrollTrack.getExplicitOrMeasuredWidth(), upArrow.getExplicitOrMeasuredWidth(),
+                                 downArrow.getExplicitOrMeasuredWidth(), _minWidth);
+        }
+        else
+        {
+            _minWidth = upArrow.getExplicitOrMeasuredWidth();
+        }
+        _minHeight = upArrow.getExplicitOrMeasuredHeight() +
+                     downArrow.getExplicitOrMeasuredHeight();
+    }
+
+    /**
+     *  @private
+     *  Size changed so re-position everything.
+     */
+    override protected function updateDisplayList(unscaledWidth:Number,
+                                                  unscaledHeight:Number):void
+    {
+        if ($height == 1)
+            return;
+
+        if (!upArrow)
+            return;
+
+        super.updateDisplayList(unscaledWidth, unscaledHeight);
+
+        // Turn on bitmap caching whenever we start scrolling.  Turn it
+        // off whenever we resize the scrollbar (because caching hurts
+        // performance during a resize animation)
+        if (cacheAsBitmap)
+            cacheHeuristic = scrollThumb.cacheHeuristic = false;
+
+        upArrow.setActualSize(upArrow.getExplicitOrMeasuredWidth(),
+                              upArrow.getExplicitOrMeasuredHeight());
+
+        if (FlexVersion.compatibilityVersion >= FlexVersion.VERSION_3_0)
+            upArrow.move((virtualWidth - upArrow.width) / 2, 0);
+        else
+            upArrow.move(0,0);
+
+        scrollTrack.setActualSize(scrollTrack.getExplicitOrMeasuredWidth(), virtualHeight);
+
+        if (FlexVersion.compatibilityVersion >= FlexVersion.VERSION_3_0)
+            scrollTrack.x = (virtualWidth - scrollTrack.width) / 2;
+        scrollTrack.y = 0;
+
+        downArrow.setActualSize(downArrow.getExplicitOrMeasuredWidth(),
+                                downArrow.getExplicitOrMeasuredHeight());
+        if (FlexVersion.compatibilityVersion >= FlexVersion.VERSION_3_0)
+        {
+            downArrow.move((virtualWidth - downArrow.width) / 2,
+                            virtualHeight - downArrow.getExplicitOrMeasuredHeight());
+        }
+        else
+        {
+            downArrow.move(0, virtualHeight - downArrow.getExplicitOrMeasuredHeight());
+        }
+
+
+        setScrollProperties(pageSize, minScrollPosition,
+                            maxScrollPosition, _pageScrollSize);
+
+        // Reset thumb position.
+        scrollPosition = _scrollPosition;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Methods
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Sets the range and viewport size of the ScrollBar control.
+     *
+     *  The ScrollBar control updates the state of the arrow buttons and
+     *  size of the scroll thumb accordingly.
+     *
+     *  @param pageSize Number which represents the size of one page.
+     *
+     *  @param minScrollPosition Number which represents the bottom of the
+     *  scrolling range.
+     *
+     *  @param maxScrollPosition Number which represetns the top of the
+     *  scrolling range.
+     *
+     *  @param pageScrollSize Number which represents the increment to move when
+     *  the scroll track is pressed.
+     *
+     */
+    public function setScrollProperties(pageSize:Number,
+                                        minScrollPosition:Number,
+                                        maxScrollPosition:Number,
+                                        pageScrollSize:Number = 0):void
+    {
+        var thumbHeight:Number;
+
+        this.pageSize = pageSize;
+
+        _pageScrollSize = (pageScrollSize > 0) ? pageScrollSize : pageSize;
+
+        this.minScrollPosition = Math.max(minScrollPosition, 0);
+        this.maxScrollPosition = Math.max(maxScrollPosition, 0);
+
+        _scrollPosition = Math.max(this.minScrollPosition, _scrollPosition);
+        _scrollPosition = Math.min(this.maxScrollPosition, _scrollPosition);
+
+        // If the ScrollBar is enabled and has a nonzero range ...
+        if (this.maxScrollPosition - this.minScrollPosition > 0 && enabled)
+        {
+            upArrow.enabled = true;
+            downArrow.enabled = true;
+            scrollTrack.enabled = true;
+
+            addEventListener(MouseEvent.MOUSE_DOWN,
+                             scrollTrack_mouseDownHandler);
+            addEventListener(MouseEvent.MOUSE_OVER,
+                             scrollTrack_mouseOverHandler);
+            addEventListener(MouseEvent.MOUSE_OUT,
+                             scrollTrack_mouseOutHandler);
+
+            if (!scrollThumb)
+            {
+                scrollThumb = new ScrollThumb();
+
+                scrollThumb.focusEnabled = false;
+
+                // Add the thumb above the up arrow but below the down arrow
+                addChildAt(scrollThumb, getChildIndex(downArrow));
+
+                scrollThumb.styleName = new StyleProxy(this, thumbStyleFilters);
+
+                // This button is a 4-state Button
+                // that by default uses the ScrollThumbSkin.
+                scrollThumb.upSkinName = "thumbUpSkin";
+                scrollThumb.overSkinName = "thumbOverSkin";
+                scrollThumb.downSkinName = "thumbDownSkin";
+                scrollThumb.iconName = "thumbIcon";
+                scrollThumb.skinName = "thumbSkin";
+            }
+
+            thumbHeight = trackHeight < 0 ? 0 : Math.round(
+                pageSize /
+                (this.maxScrollPosition - this.minScrollPosition + pageSize) *
+                trackHeight);
+
+            if (thumbHeight < scrollThumb.minHeight)
+            {
+                if (trackHeight < scrollThumb.minHeight)
+                {
+                    scrollThumb.visible = false;
+                }
+                else
+                {
+                    thumbHeight = scrollThumb.minHeight;
+                    scrollThumb.visible = true;
+                    scrollThumb.setActualSize(scrollThumb.measuredWidth, scrollThumb.minHeight);
+                }
+            }
+            else
+            {
+                scrollThumb.visible = true;
+                scrollThumb.setActualSize(scrollThumb.measuredWidth, thumbHeight);
+            }
+
+            scrollThumb.setRange(upArrow.getExplicitOrMeasuredHeight() + 0,
+                                 virtualHeight -
+                                 downArrow.getExplicitOrMeasuredHeight() -
+                                 scrollThumb.height,
+                                 this.minScrollPosition,
+                                 this.maxScrollPosition);
+
+            scrollPosition = Math.max(Math.min(scrollPosition, this.maxScrollPosition), this.minScrollPosition);
+        }
+        else
+        {
+            upArrow.enabled = false;
+            downArrow.enabled = false;
+            scrollTrack.enabled = false;
+
+            if (scrollThumb)
+                scrollThumb.visible = false;
+        }
+    }
+
+    /**
+     *  @private
+     */
+    mx_internal function lineScroll(direction:int):void
+    {
+        var delta:Number = _lineScrollSize;
+
+        var newPos:Number = _scrollPosition + direction * delta;
+        if (newPos > maxScrollPosition)
+            newPos = maxScrollPosition;
+        else if (newPos < minScrollPosition)
+            newPos = minScrollPosition;
+
+        if (newPos != scrollPosition)
+        {
+            var oldPosition:Number = scrollPosition;
+            scrollPosition = newPos;
+            var detail:String = direction < 0 ? lineMinusDetail : linePlusDetail;
+            dispatchScrollEvent(oldPosition, detail);
+        }
+    }
+
+    /**
+     *  @private
+     */
+    mx_internal function pageScroll(direction:int):void
+    {
+        var delta:Number = _pageScrollSize != 0 ? _pageScrollSize : pageSize;
+
+        var newPos:Number = _scrollPosition + direction * delta;
+        if (newPos > maxScrollPosition)
+            newPos = maxScrollPosition;
+        else if (newPos < minScrollPosition)
+            newPos = minScrollPosition;
+
+        if (newPos != scrollPosition)
+        {
+            var oldPosition:Number = scrollPosition;
+            scrollPosition = newPos;
+            var detail:String = direction < 0 ? pageMinusDetail : pagePlusDetail;
+            dispatchScrollEvent(oldPosition, detail);
+        }
+    }
+
+    /**
+     *  @private
+     *  Dispatch a scroll event.
+     */
+    mx_internal function dispatchScrollEvent(oldPosition:Number,
+                                             detail:String):void
+    {
+        var event:ScrollEvent = new ScrollEvent(ScrollEvent.SCROLL);
+        event.detail = detail;
+        event.position = scrollPosition;
+        event.delta = scrollPosition - oldPosition;
+        event.direction = direction;
+        dispatchEvent(event);
+    }
+
+    /**
+     *  @private
+     *  Returns true if it is a scrollbar key.
+     *  It will execute the equivalent code for that key as well.
+     */
+    mx_internal function isScrollBarKey(key:uint):Boolean
+    {
+        var oldPosition:Number;
+
+        if (key == Keyboard.HOME)
+        {
+            if (scrollPosition != 0)
+            {
+                oldPosition = scrollPosition;
+                scrollPosition = 0;
+                dispatchScrollEvent(oldPosition, minDetail);
+            }
+            return true;
+        }
+
+        else if (key == Keyboard.END)
+        {
+            if (scrollPosition < maxScrollPosition)
+            {
+                oldPosition = scrollPosition;
+                scrollPosition = maxScrollPosition;
+                dispatchScrollEvent(oldPosition, maxDetail);
+            }
+            return true;
+        }
+
+        return false;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Event handlers
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     *  Callback when the up-arrow button is pressed or autorepeated.
+     */
+    private function upArrow_buttonDownHandler(event:FlexEvent):void
+    {
+        if (isNaN(oldPosition))
+            oldPosition = scrollPosition;
+
+        lineScroll(-1);
+    }
+
+    /**
+     *  @private
+     *  Callback when the down-arrow button is pressed or autorepeated.
+     */
+    private function downArrow_buttonDownHandler(event:FlexEvent):void
+    {
+        if (isNaN(oldPosition))
+            oldPosition = scrollPosition;
+
+        lineScroll(1);
+    }
+
+    /**
+     *  @private
+     *  Show the over skin of the scrollTrack if there is one.
+     */
+    private function scrollTrack_mouseOverHandler(event:MouseEvent):void
+    {
+        if (!(event.target == this || event.target == scrollTrack))
+            return;
+
+        if (trackScrolling)
+            trackScrollTimer.start();
+    }
+
+    /**
+     *  @private
+     *  Hide the over skin of the scrollTrack.
+     */
+    private function scrollTrack_mouseOutHandler(event:MouseEvent):void
+    {
+        if (trackScrolling)
+            trackScrollTimer.stop();
+    }
+
+    /**
+     *  @private
+     *  Set up the repeating events when pressing on the track.
+     */
+    private function scrollTrack_mouseDownHandler(event:MouseEvent):void
+    {
+        if (!(event.target == this || event.target == scrollTrack))
+            return;
+
+        trackScrolling = true;
+
+        systemManager.addEventListener(
+            MouseEvent.MOUSE_UP, scrollTrack_mouseUpHandler, true);
+        systemManager.addEventListener(
+            MouseEvent.MOUSE_MOVE, scrollTrack_mouseMoveHandler, true);
+        // in case we go offscreen
+        systemManager.stage.addEventListener(MouseEvent.MOUSE_MOVE,
+                            stage_scrollTrack_mouseMoveHandler);
+        // in case we go offscreen
+        systemManager.stage.addEventListener(Event.MOUSE_LEAVE,
+                            scrollTrack_mouseLeaveHandler);
+
+        var pt:Point = new Point(event.localX, event.localY);
+        pt = event.target.localToGlobal(pt);
+        pt = globalToLocal(pt);
+
+        trackPosition = pt.y;
+
+        if (isNaN(oldPosition))
+            oldPosition = scrollPosition;
+
+        trackScrollRepeatDirection =
+            scrollThumb.y + scrollThumb.height < pt.y ? 1 :
+            scrollThumb.y > pt.y ? -1 : 0;
+        pageScroll(trackScrollRepeatDirection);
+
+        if (!trackScrollTimer)
+        {
+            trackScrollTimer = new Timer(getStyle("repeatDelay"), 1);
+            trackScrollTimer.addEventListener(TimerEvent.TIMER, trackScrollTimerHandler);
+        }
+        trackScrollTimer.start();
+    }
+
+    /**
+     *  @private
+     *  This gets called at certain intervals
+     *  to repeat the scroll event when pressing the track.
+     */
+    private function trackScrollTimerHandler(event:Event):void
+    {
+        if (trackScrollRepeatDirection == 1)
+            if (scrollThumb.y + scrollThumb.height > trackPosition)
+                return;
+
+        if (trackScrollRepeatDirection == -1)
+            if (scrollThumb.y < trackPosition)
+                return;
+
+        pageScroll(trackScrollRepeatDirection);
+        if (trackScrollTimer && trackScrollTimer.repeatCount == 1)
+        {
+            trackScrollTimer.delay = getStyle("repeatInterval");
+            trackScrollTimer.repeatCount = 0;
+        }
+    }
+
+    /**
+     *  @private
+     *  Stop repeating events because the track is no longer pressed
+     *  special case to restore focus when we've released the mouse
+     */
+    private function scrollTrack_mouseUpHandler(event:MouseEvent):void
+    {
+        scrollTrack_mouseLeaveHandler(event);
+    }
+    private function scrollTrack_mouseLeaveHandler(event:Event):void
+    {
+        trackScrolling = false;
+
+        systemManager.removeEventListener(
+            MouseEvent.MOUSE_UP, scrollTrack_mouseUpHandler, true);
+        systemManager.removeEventListener(
+            MouseEvent.MOUSE_MOVE, scrollTrack_mouseMoveHandler, true);
+        // in case we go offscreen
+        systemManager.stage.removeEventListener(MouseEvent.MOUSE_MOVE,
+                            stage_scrollTrack_mouseMoveHandler);
+        // in case we go offscreen
+        systemManager.stage.removeEventListener(Event.MOUSE_LEAVE,
+                            scrollTrack_mouseLeaveHandler);
+
+        if (trackScrollTimer)
+            trackScrollTimer.reset();
+
+        if (event.target != scrollTrack)
+            return;
+
+        var detail:String = oldPosition > scrollPosition ?
+                            pageMinusDetail :
+                            pagePlusDetail;
+        dispatchScrollEvent(oldPosition, detail);
+
+        oldPosition = NaN;
+    }
+
+    private function stage_scrollTrack_mouseMoveHandler(event:MouseEvent):void
+    {
+        if (event.target != stage)
+            return;
+
+        scrollTrack_mouseMoveHandler(event);
+    }
+
+    /**
+     *  @private
+     *  Stop repeating events because the track is no longer pressed
+     *  special case to restore focus when we've released the mouse
+     */
+    private function scrollTrack_mouseMoveHandler(event:MouseEvent):void
+    {
+        if (trackScrolling)
+        {
+            var pt:Point = new Point(event.stageX, event.stageY);
+            pt = globalToLocal(pt);
+            trackPosition = pt.y;
+        }
+    }
+
+}
+
+}


Transferred from the Adobe Open Source Subversion Repository

Revision: 7448
Author:   jszeto@adobe.com
Date:     2009-05-29T21:11:34.571514Z

Log Message:
-----------
http://bugs.adobe.com/jira/browse/SDK-18373 - Defaults for some properties of Flex graphics classes do not match defaults in FXG xsd

Updated SolidColorStroke, GradientStroke, LinearGradientStroke and RadialGradientStroke with new default values. This shouldn't change the default behavior for caps and joints because the Player defaults to "round" if the value is null.

Updated GlowFilter and GradientGlowFilter

http://bugs.adobe.com/jira/browse/SDK-21493 - BitmapImage resizeMode default value is repeat should be normal

Updated the ASDoc comments to set default to "repeat"

QE Notes: None
Doc Notes: I made lots of small ASDoc changes
Bugs: SDK-18373, SDK-21493
Reviewer: Deepa

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/BitmapImage.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/LinearGradientStroke.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/SolidColorStroke.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/RadialGradientStroke.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/filters/GradientGlowFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/GradientStroke.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/spark/filters/GlowFilter.as</path>

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

--- frameworks/projects/spark/src/spark/filters/GradientGlowFilter.as
+++ frameworks/projects/spark/src/spark/filters/GradientGlowFilter.as
@@ -90,8 +90,8 @@
 	 * @param type The placement of the filter effect. Possible values are the
 	 * flash.filters.BitmapFilterType constants:
 	 *

-	 *
BitmapFilterType.OUTER — Glow on the outer edge of the object

-	 *
BitmapFilterType.INNER — Glow on the inner edge of the object; the default.

+	 *
BitmapFilterType.OUTER — Glow on the outer edge of the object; the default.

+	 *
BitmapFilterType.INNER — Glow on the inner edge of the object

 	 *
BitmapFilterType.FULL — Glow on top of the object

 	 *

 	 *
@@ -110,7 +110,7 @@
 									   colors:Array = null, alphas:Array = null,
 									   ratios:Array = null, blurX:Number = 4.0,
 									   blurY:Number = 4.0, strength:Number = 1,
-									   quality:int = 1, type:String = "inner",
+									   quality:int = 1, type:String = "outer",
 									   knockout:Boolean = false)
 	{
 		this.distance = distance;


Transferred from the Adobe Open Source Subversion Repository

Revision: 18385
Author:   jasonsj@adobe.com
Date:     2010-10-30T00:16:31.091793Z

Log Message:
-----------
Mobile Theme feature work. TextArea now supports borderVisible and promptDisplay. Refactored common TextInput and TextArea behavior to TextSkinBase.

QE notes: TextArea borderVisible style and prompt property.
Doc notes:
Bugs:
Reviewer: gruehle
Tests run: checkintests
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/TextAreaSkin.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/TextInputSkin.as</path>
<path kind="file" action="A">/private/flex/sdk/branches/hero_private/frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/TextSkinBase.as</path>

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

--- frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/TextSkinBase.as
+++ frameworks/projects/mobiletheme/src/spark/skins/mobile/supportClasses/TextSkinBase.as
@@ -0,0 +1,257 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2010 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.mobile.supportClasses
+{
+
+import flash.display.DisplayObject;
+
+import mx.core.mx_internal;
+import mx.events.PropertyChangeEvent;
+
+import spark.components.supportClasses.StyleableTextField;
+import spark.skins.mobile.assets.TextInput_border;
+
+use namespace mx_internal;
+
+/**
+ *  Actionscript based skin for mobile text input.
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 10
+ *  @playerversion AIR 2.5
+ *  @productversion Flex 4.5
+ */
+public class TextSkinBase extends MobileSkin
+{
+    //--------------------------------------------------------------------------
+    //
+    //  Class statics
+    //
+    //--------------------------------------------------------------------------
+
+    // StylableTextField padding
+    protected static const TEXT_WIDTH_PADDING:int = 4;
+    protected static const TEXT_HEIGHT_PADDING:int = 2;
+
+    // FXG measurements
+    private static const BORDER_SIZE:uint = 1;
+    private static const CORNER_ELLIPSE_SIZE:uint = 16;
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+    public function TextSkinBase()
+    {
+        super();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  textDisplay skin part.
+     */
+    public var textDisplay:StyleableTextField;
+
+    [Bindable]
+    /**
+     *  Bindable promptDisplay skin part. Bindings fire when promptDisplay is
+     *  removed and added for proper updating by the SkinnableTextBase.
+     */
+    public var promptDisplay:StyleableTextField;
+
+    /**
+     *  @private
+     *
+     *  Instance of the border graphics.
+     */
+    private var border:DisplayObject;
+
+    private var borderVisibleChanged:Boolean = false;
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    override protected function createChildren():void
+    {
+        super.createChildren();
+
+        border = new TextInput_border;
+        addChild(border);
+
+        textDisplay = StyleableTextField(createInFontContext(StyleableTextField));
+        textDisplay.styleProvider = this;
+        textDisplay.editable = true;
+        addChild(textDisplay);
+
+        createPromptDisplay();
+    }
+
+    protected function createPromptDisplay():void
+    {
+        promptDisplay = StyleableTextField(createInFontContext(StyleableTextField));
+        promptDisplay.styleProvider = this;
+        promptDisplay.editable = false;
+        promptDisplay.mouseEnabled = false;
+        addChild(promptDisplay);
+    }
+
+    /**
+     *  @private
+     */
+    override protected function commitProperties():void
+    {
+        super.commitProperties();
+
+        if (borderVisibleChanged)
+        {
+            borderVisibleChanged = false;
+
+            var borderVisible:Boolean = getStyle("borderVisible") == true;
+
+            if (borderVisible && !border)
+            {
+                border = new TextInput_border();
+                addChild(border);
+            }
+            else if (!borderVisible && border)
+            {
+                removeChild(border);
+                border = null;
+            }
+        }
+    }
+
+    /**
+     *  @private
+     */
+    override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void
+    {
+        super.updateDisplayList(unscaledWidth, unscaledHeight);
+
+        var borderSize:uint = (border) ? BORDER_SIZE : 0;
+        var borderWidth:uint = borderSize * 2;
+
+        // Draw the contentBackgroundColor
+        graphics.clear();
+        graphics.beginFill(getStyle("contentBackgroundColor"), getStyle("contentBackgroundAlpha"));
+        graphics.drawRoundRect(borderSize, borderSize, unscaledWidth - borderWidth, unscaledHeight - borderWidth, CORNER_ELLIPSE_SIZE, CORNER_ELLIPSE_SIZE);
+        graphics.endFill();
+
+        // position & size border
+        if (border)
+        {
+            resizePart(border, unscaledWidth, unscaledHeight);
+            positionPart(border, 0, 0);
+        }
+
+        // position & size the text
+        var paddingLeft:Number = getStyle("paddingLeft");
+        var paddingRight:Number = getStyle("paddingRight");
+        var paddingTop:Number = getStyle("paddingTop");
+        var paddingBottom:Number = getStyle("paddingBottom");
+
+        var unscaledTextWdith:Number = unscaledWidth - paddingLeft - paddingRight;
+        var unscaledTextHeight:Number = unscaledHeight - paddingTop - paddingBottom;
+
+        var textTopPosition:Number = getTextTop(unscaledHeight, paddingTop);
+
+        if (textDisplay)
+        {
+            textDisplay.commitStyles();
+
+            resizePart(textDisplay, unscaledTextWdith, unscaledTextHeight);
+            positionPart(textDisplay, paddingLeft, textTopPosition);
+        }
+
+        if (promptDisplay)
+        {
+            promptDisplay.commitStyles();
+            resizePart(promptDisplay, unscaledTextWdith, unscaledTextHeight);
+            positionPart(promptDisplay, paddingLeft, textTopPosition);
+        }
+    }
+
+    /**
+     *  @private
+     *  Specifies the location of the textDisplay and promptDisplay skin parts.
+     *  Default verticalAlign="center".
+     */
+    mx_internal function getTextTop(unscaledHeight:Number, paddingTop:Number):Number
+    {
+        if (textDisplay)
+            return Math.max(Math.round((unscaledHeight - textDisplay.textHeight) / 2), paddingTop);
+
+        return paddingTop;
+    }
+
+    /**
+     *  @private
+     */
+    override public function styleChanged(styleProp:String):void
+    {
+        var allStyles:Boolean = !styleProp || styleProp == "styleName";
+
+        if (allStyles || styleProp == "borderVisible")
+        {
+            borderVisibleChanged = true;
+            invalidateProperties();
+        }
+
+        if (allStyles || styleProp.indexOf("padding") == 0)
+        {
+            invalidateDisplayList();
+        }
+
+        if (textDisplay)
+            textDisplay.styleChanged(styleProp);
+
+        if (promptDisplay)
+            promptDisplay.styleChanged(styleProp);
+
+        super.styleChanged(styleProp);
+    }
+
+    /**
+     *  @private
+     */
+    override protected function commitCurrentState():void
+    {
+        super.commitCurrentState();
+
+        alpha = currentState.indexOf("disabled") == -1 ? 1 : 0.5;
+
+        var showPrompt:Boolean = currentState.indexOf("WithPrompt") >= 0;
+
+        if (showPrompt && !promptDisplay)
+        {
+            createPromptDisplay();
+        }
+        else if (!showPrompt && promptDisplay)
+        {
+            removeChild(promptDisplay);
+            promptDisplay = null;
+        }
+    }
+}
+}


Transferred from the Adobe Open Source Subversion Repository

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

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

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

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

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

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

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

--- frameworks/projects/advancedgrids/src/mx/collections/GroupingField.as
+++ frameworks/projects/advancedgrids/src/mx/collections/GroupingField.as
@@ -0,0 +1,485 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  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
+{
+
+//--------------------------------------
+//  Other metadata
+//--------------------------------------
+
+[DefaultProperty("summaries")]
+
+/**
+ *  The GroupingField class represents individual data fields
+ *  that you use to group flat data for display by the AdvancedDataGrid control.
+ *
+ *
To populate the AdvancedDataGrid control with grouped data,
+ *  you create an instance of the GroupingCollection class from your flat data,
+ *  and then pass that GroupingCollection instance to the data provider
+ *  of the AdvancedDataGrid control.
+ *  To specify the grouping fields of your flat data,
+ *  you pass a Grouping instance to
+ *  the GroupingCollection.grouping property.
+ *  The Grouping instance contains an Array of GroupingField instances,
+ *  one per grouping field.

+ *
+ *
The following example uses the Grouping class to define
+ *  two grouping fields: Region and Territory.

+ *
+ *

+ *  <mx:AdvancedDataGrid id="myADG"
+ *    <mx:dataProvider>
+ *      <mx:GroupingCollection id="gc" source="{dpFlat}">
+ *        <mx:grouping>
+ *          <mx:Grouping>
+ *            <mx:GroupingField name="Region"/>
+ *            <mx:GroupingField name="Territory"/>
+ *          </mx:Grouping>
+ *        </mx:grouping>
+ *      </mx:GroupingCollection>
+ *    </mx:dataProvider>
+ *
+ *    <mx:columns>
+ *      <mx:AdvancedDataGridColumn dataField="Region"/>
+ *      <mx:AdvancedDataGridColumn dataField="Territory"/>
+ *      <mx:AdvancedDataGridColumn dataField="Territory_Rep"/>
+ *      <mx:AdvancedDataGridColumn dataField="Actual"/>
+ *      <mx:AdvancedDataGridColumn dataField="Estimate"/>
+ *    </mx:columns>
+ *  </mx:AdvancedDataGrid>
+ *

+ *
+ *  @mxml
+ *
+ *  The <mx.GroupingField> inherits all the tag attributes of its superclass,
+ *  and defines the following tag attributes:

+ *
+ *

+ *  <mx:GroupingField
+ *  Properties
+ *    caseInsensitive="false|true"
+ *    compareFunction="No default"
+ *    descending="false|true"
+ *    groupingFunction="No default"
+ *    groupingObjectFunction="No default"
+ *    name="null"
+ *    numeric="false|true"
+ *    summaries="No default"
+ *  />
+ *

+ *
+ *  @see mx.controls.AdvancedDataGrid
+ *  @see mx.collections.GroupingCollection
+ *  @see mx.collections.Grouping
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class GroupingField
+{
+    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *
+     *  @param name The name of the property that this field uses for
+     *              comparison.
+     *              If the object is a simple type, pass null.
+     *  @param caseInsensitive When sorting strings, tells the comparitor
+     *              whether to ignore the case of the values.
+     *  @param descending Tells the comparator whether to arrange items in
+     *              descending order.
+     *  @param numeric Tells the comparitor whether to compare sort items as
+     *              numbers, instead of alphabetically.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function GroupingField(name:String=null,
+                                caseInsensitive:Boolean=false,
+                                descending:Boolean=false,
+                                numeric:Boolean=false)
+    {
+        super();
+
+        _name = name;
+        _caseInsensitive = caseInsensitive;
+        _descending = descending;
+        _numeric = numeric;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+
+    //---------------------------------
+    //  caseInsensitive
+    //---------------------------------
+
+    /**
+     *  @private
+     *  Storage for the caseInsensitive property.
+     */
+    private var _caseInsensitive:Boolean;
+
+    [Inspectable(category="General")]
+
+    /**
+     *  Set to true if the sort for this field should be case-insensitive.
+     *
+     *  @default false
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get caseInsensitive():Boolean
+    {
+        return _caseInsensitive;
+    }
+
+    /**
+     *  @private
+     */
+    public function set caseInsensitive(value:Boolean):void
+    {
+        if (value != _caseInsensitive)
+        {
+            _caseInsensitive = value;
+        }
+    }
+
+    //---------------------------------
+    //  compareFunction
+    //---------------------------------
+
+    /**
+     *  @private
+     *  Storage for the compareFunction property.
+     */
+    private var _compareFunction:Function;
+
+    [Inspectable(category="General")]
+
+    /**
+     *  The function that compares two items during a sort of items for the
+     *  associated collection. If you specify a compareFunction
+     *  property in a Grouping object, Flex ignores any compareFunction
+     *  properties of the GroupingField objects.
+     *
+     *
The compare function must have the following signature:

+     *
+     *
function myCompare(a:Object, b:Object):int

+     *
+     *
This function must return the following values:

+     *

+     *
-1, if a should appear before b in
+     *        the sorted sequence.

+     *
0, if a equals b.

+     *
1, if a should appear after b in the
+     *        sorted sequence.

+     *

+     *
+     *
The default value is an internal compare function that can perform
+     *  a string, numeric, or date comparison in ascending or descending order,
+     *  with case-sensitive or case-insensitive string comparisons.
+     *  Specify your own function only if you need a custom comparison algorithm.
+     *  This is normally only the case if a calculated field is used in a display.

+     *
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get compareFunction():Function
+    {
+        return _compareFunction;
+    }
+
+    /**
+     *  @private
+     */
+    public function set compareFunction(c:Function):void
+    {
+        _compareFunction = c;
+    }
+
+    //---------------------------------
+    //  descending
+    //---------------------------------
+
+    /**
+     *  @private
+     *  Storage for the descending property.
+     */
+    private var _descending:Boolean;
+
+    [Inspectable(category="General")]
+
+    /**
+     *  Set to true if the sort for this field should be
+     *  in descending order.
+     *
+     *  @default false
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get descending():Boolean
+    {
+        return _descending;
+    }
+
+    /**
+     *  @private
+     */
+    public function set descending(value:Boolean):void
+    {
+        if (_descending != value)
+        {
+            _descending = value;
+        }
+    }
+
+    //---------------------------------
+    //  name
+    //---------------------------------
+
+    /**
+     *  @private
+     *  Storage for the name property.
+     */
+    private var _name:String;
+
+    [Inspectable(category="General")]
+
+    /**
+     *  The name of the field to be sorted.
+     *
+     *  @default null
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get name():String
+    {
+        return _name;
+    }
+
+    /**
+     *  @private
+     */
+    public function set name(n:String):void
+    {
+        _name = n;
+    }
+
+    //---------------------------------
+    //  numeric
+    //---------------------------------
+
+    /**
+     *  @private
+     *  Storage for the numeric property.
+     */
+    private var _numeric:Boolean;
+
+    [Inspectable(category="General")]
+
+    /**
+     *  Specifies that if the field being sorted contains numeric
+     *  (Number/int/uint) values, or String representations of numeric values,
+     *  the comparitor uses a numeric comparison.
+     *  If this property is false, fields with String representations
+     *  of numbers are sorted using String comparison, so 100 precedes 99,
+     *  because "1" is a lower string value than "9".
+     *
+     *  @default false
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get numeric():Boolean
+    {
+        return _numeric;
+    }
+
+    /**
+     *  @private
+     */
+    public function set numeric(value:Boolean):void
+    {
+        if (_numeric != value)
+        {
+            _numeric = value;
+        }
+    }
+
+    //---------------------------------
+    //  groupingFunction
+    //---------------------------------
+
+    /**
+     *  A function that determines the label for this group.
+     *  By default,
+     *  the group displays the text for the field in the data that matches the
+     *  filed specified by the name property.
+     *  However, sometimes you want to group the items based on
+     *  more than one field in the data, or group based on something that is
+     *  not a simple String field.
+     *  In such a case, you specify a callback function by using
+     *  the groupingFunction property.
+     *
+     *
A callback function might convert a number for the month into
+     *  the String for the month, or group multiple items into a single group
+     *  based on some criteria other than the actual value of the field.

+     *
+     *
For the GroupField, the method signature has the following form:

+     *
+     *
groupingFunction(item:Object, field:GroupField):String

+     *
+     *
Where item contains the data item object, and
+     *  field contains the GroupField object.

+     *
+     *  For example, a groupingFunction which returns the
+     *  first character as the group name can be written as -
+     *

+     *  private function groupFunc(item:Object, field:GroupingField):String
+     *  {
+     *      return item[field.name].toString().substr(0, 1);
+     *  }
+     *

+     *
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public var groupingFunction:Function;
+
+    //---------------------------------
+    //  groupingObjectFunction
+    //---------------------------------
+
+    /**
+     *  A callback function to run on each group node to determine the
+     *  grouping object.
+     *  By default, a new Object will be created for group nodes.
+     *
+     *
You can supply a groupingObjectFunction that provides the
+     *  appropriate Object for group nodes.

+     *
+     *
The method signature is:

+     *

+     *  myGroupObjectFunction(label:String):Object

+     *
+     *
Where label contains the value that will be
+     *  shown for that group node.
+     *  The function returns an Object that will be used for group nodes.

+     *
+     *  For example, a groupingObjectFunction which returns an Object
+     *  containing a "name" property with value as "Bob" can be written as -
+     *

+     *  private function groupObjFunction(label:String):Object
+     *  {
+     *      var obj:Object = {};
+     *      obj.name = "Bob";
+     *
+     *      return obj;
+     *  }
+     *

+     *
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public var groupingObjectFunction:Function;
+
+    //---------------------------------
+    //  summaries
+    //---------------------------------
+
+    /**
+     *  Array of SummaryRow instances that define the group-level summaries.
+     *  Specify one or more SummaryRow instances to define the data summaries,
+     *  as the following example shows:
+     *
+     *

+     *  <mx:AdvancedDataGrid id="myADG"
+     *     width="100%" height="100%"
+     *     initialize="gc.refresh();">
+     *     <mx:dataProvider>
+     *         <mx:GroupingCollection id="gc" source="{dpFlat}">
+     *             <mx:Grouping>
+     *                 <mx:GroupingField name="Region">
+     *                   <mx:summaries>
+     *                       <mx:SummaryRow summaryPlacement="group">
+     *                         <mx:fields>
+     *                             <mx:SummaryField dataField="Actual"
+     *                                 label="Min Actual" operation="MIN"/>
+     *                             <mx:SummaryField dataField="Actual"
+     *                                 label="Max Actual" operation="MAX"/>
+     *                         </mx:fields>
+     *                       </mx:SummaryRow>
+     *                     </mx:summaries>
+     *                 </mx:GroupingField>
+     *             </mx:Grouping>
+     *         </mx:GroupingCollection>
+     *     </mx:dataProvider>
+     *
+     *     <mx:columns>
+     *         <mx:AdvancedDataGridColumn dataField="Region"/>
+     *         <mx:AdvancedDataGridColumn dataField="Territory_Rep"
+     *             headerText="Territory Rep"/>
+     *         <mx:AdvancedDataGridColumn dataField="Actual"/>
+     *         <mx:AdvancedDataGridColumn dataField="Estimate"/>
+     *         <mx:AdvancedDataGridColumn dataField="Min Actual"/>
+     *         <mx:AdvancedDataGridColumn dataField="Max Actual"/>
+     *     </mx:columns>
+     *  </mx:AdvancedDataGrid>
+     *

+     *
+     *  @see mx.collections.SummaryRow
+     *  @see mx.collections.SummaryField
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public var summaries:Array;
+}
+
+}


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

--- frameworks/projects/charts/src/mx/charts/chartClasses/AxisLabelSet.as
+++ frameworks/projects/charts/src/mx/charts/chartClasses/AxisLabelSet.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.charts.chartClasses
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 10606
Author:   egeorgie@adobe.com
Date:     2009-09-25T23:01:50.455888Z

Log Message:
-----------
White space cleanup.

Doc notes: None
Bugs: None
Reviewer: Evtim
Tests run: build
Is noteworthy for integration: Nope

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/DropDownList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/geom/TransformOffsets.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/states/AddItems.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/OnDemandEventDispatcher.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/VideoDisplay.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/PopUpAnchor.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/MatrixUtil.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/supportClasses/Block.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/ViewStack.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/ToggleButtonBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/EffectManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/geom/CompoundTransform.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/effects/Effect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/LayoutElementUIComponentUtils.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/BitmapFill.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/ArrayList.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/graphics/GradientBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/DropDownController.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/BasicLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/collections/ListCollectionView.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/geom/Transform.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/scrollClasses/ScrollBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/supportClasses/LinearLayoutVector.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/Path.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/utils/DescribeTypeCache.as</path>
<path kind="file" action="M">/flex/sdk/trunk/development/eclipse/flex/sparkTest/src/testWheel.mxml</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/layouts/TileLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/skins/SparkSkin.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ComboBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/supportClasses/AnimateTransformInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/SkinnableComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Scroller.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/DataGroup.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/AdvancedLayoutFeatures.as</path>

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

--- frameworks/projects/framework/src/mx/utils/OnDemandEventDispatcher.as
+++ frameworks/projects/framework/src/mx/utils/OnDemandEventDispatcher.as
@@ -49,7 +49,7 @@
      */
         public function addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
         {
-            if(_dispatcher == null)
+            if (_dispatcher == null)
             {
                 _dispatcher = new EventDispatcher(this);
             }
@@ -67,7 +67,7 @@
      */
         public function dispatchEvent(event:Event):Boolean
         {
-            if(_dispatcher != null)
+            if (_dispatcher != null)
                 return _dispatcher.dispatchEvent(event);
             return true;
         }
@@ -82,7 +82,7 @@
      */
         public function hasEventListener(type:String):Boolean
         {
-            if(_dispatcher != null)
+            if (_dispatcher != null)
                 return _dispatcher.hasEventListener(type);
             return false;
         }
@@ -97,7 +97,7 @@
      */
         public function removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void
         {
-            if(_dispatcher != null)
+            if (_dispatcher != null)
                 _dispatcher.removeEventListener(type,listener,useCapture);
         }

@@ -111,7 +111,7 @@
      */
         public function willTrigger(type:String):Boolean
         {
-            if(_dispatcher != null)
+            if (_dispatcher != null)
                 return _dispatcher.willTrigger(type);
             return false;
         }