You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by ah...@apache.org on 2017/05/01 03:48:00 UTC

[01/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - - Made the native exampes build in maven

Repository: flex-asjs
Updated Branches:
  refs/heads/develop fd709d137 -> b350e4de9


- Made the native exampes build in maven


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/3b95eca2
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/3b95eca2
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/3b95eca2

Branch: refs/heads/develop
Commit: 3b95eca281ac9da560415ca64eac4557b7a30370
Parents: 3d3914b
Author: Christofer Dutz <ch...@codecentric.de>
Authored: Fri Mar 10 16:14:30 2017 +0100
Committer: Christofer Dutz <ch...@codecentric.de>
Committed: Fri Mar 10 16:14:30 2017 +0100

----------------------------------------------------------------------
 examples/native/ButtonExample/pom.xml |  8 ++++++++
 examples/native/USStatesMap/pom.xml   | 15 +++++++++++++++
 examples/pom.xml                      |  2 +-
 3 files changed, 24 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/3b95eca2/examples/native/ButtonExample/pom.xml
----------------------------------------------------------------------
diff --git a/examples/native/ButtonExample/pom.xml b/examples/native/ButtonExample/pom.xml
index 7de1b4e..0cc09a6 100644
--- a/examples/native/ButtonExample/pom.xml
+++ b/examples/native/ButtonExample/pom.xml
@@ -46,6 +46,14 @@
           <targets>JS</targets>
         </configuration>
       </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-war-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>build-helper-maven-plugin</artifactId>
+      </plugin>
     </plugins>
   </build>
 

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/3b95eca2/examples/native/USStatesMap/pom.xml
----------------------------------------------------------------------
diff --git a/examples/native/USStatesMap/pom.xml b/examples/native/USStatesMap/pom.xml
index daed565..2dac85b 100644
--- a/examples/native/USStatesMap/pom.xml
+++ b/examples/native/USStatesMap/pom.xml
@@ -46,10 +46,25 @@
           <targets>JS</targets>
         </configuration>
       </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-war-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>build-helper-maven-plugin</artifactId>
+      </plugin>
     </plugins>
   </build>
 
   <dependencies>
+    <dependency>
+      <groupId>org.apache.flex.flexjs.framework</groupId>
+      <artifactId>Language</artifactId>
+      <version>0.8.0-SNAPSHOT</version>
+      <type>swc</type>
+      <classifier>js</classifier>
+    </dependency>
   </dependencies>
 
 </project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/3b95eca2/examples/pom.xml
----------------------------------------------------------------------
diff --git a/examples/pom.xml b/examples/pom.xml
index fee625c..2ebcc32 100644
--- a/examples/pom.xml
+++ b/examples/pom.xml
@@ -40,7 +40,7 @@
 
   <modules>
     <module>flexjs</module>
-    <!--<module>native</module>-->
+    <module>native</module>
 
     <module>examples-tests</module>
     <module>examples-integrationtests</module>


[31/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Added missing flash-media styles for Table components.

Posted by ah...@apache.org.
Added missing flash-media styles for Table components.


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/5d6519a9
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/5d6519a9
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/5d6519a9

Branch: refs/heads/develop
Commit: 5d6519a9c2ddf692cc332b32e140b92dec272572
Parents: 525d9a8
Author: Peter Ent <pe...@apache.org>
Authored: Tue Apr 25 15:15:59 2017 -0400
Committer: Peter Ent <pe...@apache.org>
Committed: Tue Apr 25 15:15:59 2017 -0400

----------------------------------------------------------------------
 .../Basic/src/main/resources/defaults.css        | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/5d6519a9/frameworks/projects/Basic/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/resources/defaults.css b/frameworks/projects/Basic/src/main/resources/defaults.css
index 20175fa..6617124 100644
--- a/frameworks/projects/Basic/src/main/resources/defaults.css
+++ b/frameworks/projects/Basic/src/main/resources/defaults.css
@@ -817,6 +817,25 @@ global
 		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.SpinnerMouseController");
 	}
 	
+	Table
+	{
+		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
+		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
+	}
+	
+	TableCell
+	{
+		IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.TableCellLayout");
+		IBeadView: ClassReference("org.apache.flex.html.beads.TableCellView");
+	}
+	
+	TableHeader
+	{
+		IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.TableHeaderLayout");
+		IBeadView: ClassReference("org.apache.flex.html.beads.TableCellView");
+	}
+
+	
 	TextArea
 	{
 		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");


[46/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Basic: NumericStepper now accepts initial values for model, shares model with internal Spinner, and listens for changes to the model

Posted by ah...@apache.org.
Basic: NumericStepper now accepts initial values for model, shares model with internal Spinner, and listens for changes to the model


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/90764bc0
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/90764bc0
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/90764bc0

Branch: refs/heads/develop
Commit: 90764bc0130b5b619a223abc627ff2daab88429d
Parents: eaba961
Author: Josh Tynjala <jo...@apache.org>
Authored: Fri Apr 28 16:03:12 2017 -0700
Committer: Josh Tynjala <jo...@apache.org>
Committed: Fri Apr 28 16:03:12 2017 -0700

----------------------------------------------------------------------
 .../flex/org/apache/flex/html/NumericStepper.as    | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/90764bc0/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as
index 984fda9..876c597 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as
@@ -24,6 +24,8 @@ package org.apache.flex.html
     {
         import goog.events;
         import org.apache.flex.core.WrappedHTMLElement;
+        import org.apache.flex.events.IEventDispatcher;
+        import org.apache.flex.core.IBead;
     }
 
 	[Event(name="valueChange", type="org.apache.flex.events.Event")]
@@ -171,6 +173,7 @@ package org.apache.flex.html
             input.positioner.style.width = '100px';
 
             spinner = new Spinner();
+			spinner.addBead(model as IBead);
             addElement(spinner);
 
             /* TODO: ajh move to view and css */
@@ -183,6 +186,12 @@ package org.apache.flex.html
 
             input.text = String(spinner.value);
 
+			IEventDispatcher(model).addEventListener("valueChange",modelChangeHandler);
+			IEventDispatcher(model).addEventListener("minimumChange",modelChangeHandler);
+			IEventDispatcher(model).addEventListener("maximumChange",modelChangeHandler);
+			IEventDispatcher(model).addEventListener("stepSizeChange",modelChangeHandler);
+			IEventDispatcher(model).addEventListener("snapIntervalChange",modelChangeHandler);
+
             return element;
         }
 
@@ -198,6 +207,14 @@ package org.apache.flex.html
             dispatchEvent(new Event('valueChange'));
         };
 
+        /**
+         * @private
+         */
+        COMPILE::JS
+        private function modelChangeHandler(event:Event):void
+        {
+            input.text = String(model.value);
+        }
 
 	}
 }


[22/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - fix some poms for dual

Posted by ah...@apache.org.
fix some poms for dual


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/9ae73e00
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/9ae73e00
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/9ae73e00

Branch: refs/heads/develop
Commit: 9ae73e007c290c0e5e09fbe359551f33bdc3d2b4
Parents: 544e2de
Author: Alex Harui <ah...@apache.org>
Authored: Fri Apr 21 21:43:11 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Apr 21 21:43:11 2017 -0700

----------------------------------------------------------------------
 examples/express/DataBindingExample/pom.xml   |  7 +++++++
 examples/express/pom.xml                      | 14 ++++++++++++++
 examples/flexjs/MDLDynamicTabsExample/pom.xml |  8 ++++++++
 3 files changed, 29 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9ae73e00/examples/express/DataBindingExample/pom.xml
----------------------------------------------------------------------
diff --git a/examples/express/DataBindingExample/pom.xml b/examples/express/DataBindingExample/pom.xml
index 958cda3..bf040ce 100644
--- a/examples/express/DataBindingExample/pom.xml
+++ b/examples/express/DataBindingExample/pom.xml
@@ -62,6 +62,13 @@
       <version>0.8.0-SNAPSHOT</version>
       <type>swc</type>
     </dependency>
+    <dependency>
+        <groupId>org.apache.flex.flexjs.framework</groupId>
+        <artifactId>Network</artifactId>
+        <version>0.8.0-SNAPSHOT</version>
+        <type>swc</type>
+        <classifier>js</classifier>
+    </dependency>
   </dependencies>
 
 </project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9ae73e00/examples/express/pom.xml
----------------------------------------------------------------------
diff --git a/examples/express/pom.xml b/examples/express/pom.xml
index e991497..70ca739 100644
--- a/examples/express/pom.xml
+++ b/examples/express/pom.xml
@@ -78,9 +78,23 @@
     </dependency>
     <dependency>
       <groupId>org.apache.flex.flexjs.framework</groupId>
+      <artifactId>Express</artifactId>
+      <version>0.8.0-SNAPSHOT</version>
+      <type>swc</type>
+      <classifier>js</classifier>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.flex.flexjs.framework</groupId>
+      <artifactId>Language</artifactId>
+      <version>0.8.0-SNAPSHOT</version>
+      <type>swc</type>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.flex.flexjs.framework</groupId>
       <artifactId>Language</artifactId>
       <version>0.8.0-SNAPSHOT</version>
       <type>swc</type>
+      <classifier>js</classifier>
     </dependency>
 
     <!-- Import the shared unit-tests we want to run on all examples -->

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9ae73e00/examples/flexjs/MDLDynamicTabsExample/pom.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/MDLDynamicTabsExample/pom.xml b/examples/flexjs/MDLDynamicTabsExample/pom.xml
index 2531f2b..47651d1 100644
--- a/examples/flexjs/MDLDynamicTabsExample/pom.xml
+++ b/examples/flexjs/MDLDynamicTabsExample/pom.xml
@@ -73,6 +73,14 @@
       <version>0.8.0-SNAPSHOT</version>
       <type>swc</type>
     </dependency>
+    <dependency>
+      <groupId>org.apache.flex.flexjs.framework</groupId>
+      <artifactId>MaterialDesignLite</artifactId>
+      <version>0.8.0-SNAPSHOT</version>
+      <type>swc</type>
+      <classifier>js</classifier>
+    </dependency>
+
   </dependencies>
 
 </project>
\ No newline at end of file


[15/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlexLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlexLayout.as
index cad6827,0000000..6fb927d
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlexLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlexLayout.as
@@@ -1,264 -1,0 +1,265 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads.layouts
 +{
 +//	import org.apache.flex.html.beads.layouts.HorizontalLayout;
 +
 +	import org.apache.flex.core.LayoutBase;
 +	import org.apache.flex.core.ILayoutChild;
 +	import org.apache.flex.core.ILayoutHost;
 +	import org.apache.flex.core.ILayoutView;
 +	import org.apache.flex.core.ILayoutParent;
 +	import org.apache.flex.core.IStrand;
 +	import org.apache.flex.core.IParentIUIBase;
 +	import org.apache.flex.core.UIBase;
 +
 +	COMPILE::SWF {
 +		import org.apache.flex.core.IUIBase;
 +		import org.apache.flex.core.ValuesManager;
 +		import org.apache.flex.events.Event;
 +		import org.apache.flex.events.IEventDispatcher;
 +		import org.apache.flex.geom.Rectangle;
 +		import org.apache.flex.utils.CSSUtils;
 +		import org.apache.flex.utils.CSSContainerUtils;
 +	}
 +
 +	public class HorizontalFlexLayout extends LayoutBase
 +	{
 +		/**
 +		 * Constructor.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function HorizontalFlexLayout()
 +		{
 +			super();
 +		}
 +
 +		private var _grow:Number = -1;
 +
 +		/**
 +		 * Sets the amount items grow in proportion to other items.
 +		 * The default is 0 which prevents the items from expanding to
 +		 * fit the space. Use a negative value to unset this property.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function get grow():Number {
 +			return _grow;
 +		}
 +		public function set grow(value:Number):void {
 +			_grow = value;
 +		}
 +
 +		private var _shrink:Number = -1;
 +
 +		/**
 +		 * Sets the amount an item may shrink in proportion to other items.
 +		 * The default is 1 which allows items to shrink to fit into the space.
 +		 * Set this to 0 if you want to allow scrolling of the space. Use a
 +		 * negative value to unset this property.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function get shrink():Number {
 +			return _shrink;
 +		}
 +		public function set shrink(value:Number):void {
 +			_shrink = value;
 +		}
 +
 +		/**
 +		 * @copy org.apache.flex.core.IBeadLayout#layout
 +		 * @flexjsignorecoercion org.apache.flex.core.ILayoutHost
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		override public function layout():Boolean
 +		{
 +			COMPILE::SWF {
 +				var contentView:ILayoutView = layoutView;
 +
 +				var n:Number = contentView.numElements;
 +				if (n == 0) return false;
 +
 +				var spacing:String = "none";
 +
 +				var maxWidth:Number = 0;
 +				var maxHeight:Number = 0;
 +				var growCount:Number = 0;
 +				var childData:Array = [];
 +				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
 +				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
 +				var hostWidth:Number = hostWidthSizedToContent ? host.width : contentView.width;
 +				var hostHeight:Number = hostHeightSizedToContent ? host.height : contentView.height;
 +
 +				var ilc:ILayoutChild;
 +				var data:Object;
 +				var canAdjust:Boolean = false;
 +				
 +				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
 +				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
 +				
 +				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
 +				// resulting adjusted value may be less than zero.
 +				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
 +				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
 +				
 +				if ((hostWidth <= 0 && !hostWidthSizedToContent) || (hostHeight <= 0 && !hostHeightSizedToContent)) return false;
 +				
 +				var remainingWidth:Number = hostWidth;
 +
 +				//trace("HorizontalFlexLayout for "+UIBase(host).id+" with remainingWidth: "+remainingWidth);
 +
 +				// First pass determines the data about the child.
 +				for(var i:int=0; i < n; i++)
 +				{
 +					var child:IUIBase = contentView.getElementAt(i) as IUIBase;
 +					if (child == null || !child.visible) {
 +						childData.push({width:0, height:0, mt:0, ml:0, mr:0, mb:0, canAdjust:false});
 +						continue;
 +					}
 +
 +					ilc = child as ILayoutChild;
 +					
 +					var margins:Object = childMargins(child, hostWidth, hostHeight);
 +
 +					var flexGrow:Object = ValuesManager.valuesImpl.getValue(child, "flex-grow");
 +					var growValue:Number = 0;
 +					if (flexGrow != null) {
 +						growValue = Number(flexGrow);
 +						if (!isNaN(growValue) && growValue > 0) growCount++;
 +						else growValue = 0;
 +					}
 +
 +					var useHeight:Number = -1;
 +					if (!hostHeightSizedToContent) {
 +						if (ilc) {
 +							if (!isNaN(ilc.percentHeight)) useHeight = hostHeight * (ilc.percentHeight/100.0);
 +							else if (!isNaN(ilc.explicitHeight)) useHeight = ilc.explicitHeight;
 +							else useHeight = hostHeight;
 +						}
 +					}
 +
 +					var useWidth:Number = -1;
 +					if (ilc) {
 +						if (!isNaN(ilc.explicitWidth)) useWidth = ilc.explicitWidth;
 +						else if (!isNaN(ilc.percentWidth)) useWidth = hostWidth * (ilc.percentWidth/100.0);
 +						else if (ilc.width > 0) useWidth = ilc.width;
 +					}
 +					if (growValue == 0 && useWidth > 0) remainingWidth -= useWidth + margins.left + margins.right;
 +					else remainingWidth -= margins.left + margins.right;
 +
 +					if (maxWidth < useWidth) maxWidth = useWidth;
 +					if (maxHeight < useHeight) maxHeight = useHeight;
 +
 +					childData.push({width:useWidth, height:useHeight, 
 +						            mt:margins.top, ml:margins.left, mr:margins.right, mb:margins.bottom, 
 +									grow:growValue, canAdjust:canAdjust});
 +				}
 +
 +				var xpos:Number = borderMetrics.left + paddingMetrics.left;
 +				var ypos:Number = borderMetrics.top + paddingMetrics.top;
 +
 +				// Second pass sizes and positions the children based on the data gathered.
 +				for(i=0; i < n; i++)
 +				{
 +					child = contentView.getElementAt(i) as IUIBase;
 +					data = childData[i];
 +					//if (data.width == 0 || data.height == 0) continue;
 +
 +					useHeight = (data.height < 0 ? maxHeight : data.height);
 +
 +					var setWidth:Boolean = true;
 +					if (data.width != 0) {
 +						if (data.grow > 0 && growCount > 0) {
 +							useWidth = remainingWidth / growCount;
 +							setWidth = false;
 +						} else {
 +							useWidth = data.width;
 +						}
 +					} else {
 +						useWidth = child.width;
 +					}
 +
 +					ilc = child as ILayoutChild;
 +					if (ilc) {
 +						ilc.setX(xpos + data.ml);
 +						ilc.setY(ypos + data.mt);
 +						if (data.height > 0) {
 +							//ilc.height = useHeight;
 +							ilc.setHeight(useHeight);
 +						}
 +						if (useWidth > 0) {
 +							if (setWidth) ilc.setWidth(useWidth);
 +							else ilc.width = useWidth;
 +						}
 +					} else {
 +						child.x = xpos + data.ml;
 +						child.y = ypos + data.mt;
 +						child.height = useHeight;
 +						if (data.width > 0) {
 +							child.width = useWidth;
 +						}
 +					}
 +
 +					xpos += useWidth + data.mr + data.ml;
 +
 +					//trace("HorizontalFlexLayout: setting child "+i+" to "+child.width+" x "+child.height+" at "+child.x+", "+child.y);
 +				}
 +
 +				//trace("HorizontalFlexLayout: complete");
 +
 +				return true;
 +			}
 +
 +			COMPILE::JS {
 +				var contentView:ILayoutView = layoutView;
 +
 +				// set the display on the contentView
 +				contentView.element.style["display"] = "flex";
 +				contentView.element.style["flex-flow"] = "row";
 +
 +				var n:int = contentView.numElements;
 +				if (n == 0) return false;
 +
 +				for(var i:int=0; i < n; i++) {
 +					var child:UIBase = contentView.getElementAt(i) as UIBase;
 +					if (grow >= 0) child.element.style["flex-grow"] = String(grow);
 +					if (shrink >= 0) child.element.style["flex-shrink"] = String(shrink);
++					child.dispatchEvent(new Event("layoutNeeded"));
 +				}
 +
 +				return true;
 +			}
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
index f495acc,0000000..c543425
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
@@@ -1,260 -1,0 +1,261 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads.layouts
 +{
 +	//import org.apache.flex.html.beads.layouts.VerticalLayout;
 +
 +	import org.apache.flex.core.LayoutBase;
 +	import org.apache.flex.core.ILayoutChild;
 +	import org.apache.flex.core.ILayoutHost;
 +	import org.apache.flex.core.ILayoutView;
 +	import org.apache.flex.core.ILayoutParent;
 +	import org.apache.flex.core.IStrand;
 +	import org.apache.flex.core.UIBase;
 +	import org.apache.flex.core.IParentIUIBase;
 +
 +	COMPILE::SWF {
 +		import org.apache.flex.core.IUIBase;
 +		import org.apache.flex.core.ValuesManager;
 +		import org.apache.flex.events.Event;
 +		import org.apache.flex.events.IEventDispatcher;
 +		import org.apache.flex.geom.Rectangle;
 +		import org.apache.flex.utils.CSSUtils;
 +		import org.apache.flex.utils.CSSContainerUtils;
 +	}
 +
 +	public class VerticalFlexLayout extends LayoutBase
 +	{
 +		/**
 +		 * Constructor.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function VerticalFlexLayout()
 +		{
 +			super();
 +		}
 +
 +		private var _grow:Number = -1;
 +
 +		/**
 +		 * Sets the amount items grow in proportion to other items.
 +		 * The default is 0 which prevents the items from expanding to
 +		 * fit the space. Use a negative value to unset this property.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function get grow():Number {
 +			return _grow;
 +		}
 +		public function set grow(value:Number):void {
 +			_grow = value;
 +		}
 +
 +		private var _shrink:Number = -1;
 +
 +		/**
 +		 * Sets the amount an item may shrink in proportion to other items.
 +		 * The default is 1 which allows items to shrink to fit into the space.
 +		 * Set this to 0 if you want to allow scrolling of the space. Use a negative
 +		 * value to unset this property.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function get shrink():Number {
 +			return _shrink;
 +		}
 +		public function set shrink(value:Number):void {
 +			_shrink = value;
 +		}
 +
 +		/**
 +		 *
 +		 *  @flexjsignorecoercion org.apache.flex.core.ILayoutHost
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		override public function layout():Boolean
 +		{
 +			COMPILE::SWF {
 +				var contentView:ILayoutView = layoutView;
 +
 +				var n:Number = contentView.numElements;
 +				if (n == 0) return false;
 +
 +				var spacing:String = "none";
 +
 +				var maxWidth:Number = 0;
 +				var maxHeight:Number = 0;
 +				var growCount:Number = 0;
 +				var childData:Array = [];
 +				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
 +				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
 +				var hostWidth:Number = hostWidthSizedToContent ? host.width : contentView.width;
 +				var hostHeight:Number = hostHeightSizedToContent ? host.height : contentView.height;
 +
 +				var ilc:ILayoutChild;
 +				var data:Object;
 +				var canAdjust:Boolean = false;
 +				
 +				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
 +				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
 +				
 +				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
 +				// resulting adjusted value may be less than zero.
 +				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
 +				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
 +				
 +				var remainingHeight:Number = hostHeight;
 +
 +				//trace("VerticalFlexLayout for "+UIBase(host).id+" with remainingHeight: "+remainingHeight);
 +
 +				// First pass determines the data about the child.
 +				for(var i:int=0; i < n; i++)
 +				{
 +					var child:IUIBase = contentView.getElementAt(i) as IUIBase;
 +					if (child == null || !child.visible) {
 +						childData.push({width:0, height:0, mt:0, ml:0, mr:0, mb:0, grow:0, canAdjust:false});
 +						continue;
 +					}
 +
 +					ilc = child as ILayoutChild;
 +					
 +					var margins:Object = childMargins(child, hostWidth, hostHeight);
 +
 +					var flexGrow:Object = ValuesManager.valuesImpl.getValue(child, "flex-grow");
 +					var growValue:Number = 0;
 +					if (flexGrow != null) {
 +						growValue = Number(flexGrow);
 +						if (!isNaN(growValue) && growValue > 0) growCount++;
 +						else growValue = 0;
 +					}
 +
 +					var useWidth:Number = -1;
 +					if (!hostWidthSizedToContent) {
 +						if (ilc) {
 +							if (!isNaN(ilc.percentWidth)) useWidth = hostWidth * (ilc.percentWidth/100.0);
 +							else if (!isNaN(ilc.explicitWidth)) useWidth = ilc.explicitWidth;
 +							else useWidth = hostWidth;
 +						}
 +					}
 +
 +					var useHeight:Number = -1;
 +					if (ilc) {
 +						if (!isNaN(ilc.explicitHeight)) useHeight = ilc.explicitHeight;
 +						else if (!isNaN(ilc.percentHeight)) useHeight = hostHeight * (ilc.percentHeight/100.0);
 +						else if (ilc.height > 0) useHeight = ilc.height;
 +					}
 +					if (growValue == 0 && useHeight > 0) remainingHeight -= useHeight + margins.top + margins.bottom;
 +					else remainingHeight -= margins.top + margins.bottom;
 +
 +					if (maxWidth < useWidth) maxWidth = useWidth;
 +					if (maxHeight < useHeight) maxHeight = useHeight;
 +
 +					childData.push({width:useWidth, height:useHeight, 
 +						            mt:margins.top, ml:margins.left, mr:margins.right, mb:margins.bottom, 
 +									grow:growValue, canAdjust:canAdjust});
 +				}
 +
 +				var xpos:Number = borderMetrics.left + paddingMetrics.left;
 +				var ypos:Number = borderMetrics.top + paddingMetrics.top;
 +
 +				// Second pass sizes and positions the children based on the data gathered.
 +				for(i=0; i < n; i++)
 +				{
 +					child = contentView.getElementAt(i) as IUIBase;
 +					data = childData[i];
 +
 +					useWidth = (data.width < 0 ? hostWidth : data.width);
 +
 +					var setHeight:Boolean = true;
 +					if (data.height != 0) {
 +						if (data.grow > 0 && growCount > 0) {
 +							useHeight = remainingHeight / growCount;
 +							setHeight = false;
 +						} else {
 +							useHeight = data.height;
 +						}
 +					} else {
 +						useHeight = child.height;
 +					}
 +
 +					ilc = child as ILayoutChild;
 +					if (ilc) {
 +						ilc.setX(xpos + data.ml);
 +						ilc.setY(ypos + data.mt);
 +						if (data.width > 0) {
 +							//ilc.width = useWidth;
 +							ilc.setWidth(useWidth);
 +						}
 +						if (useHeight > 0) {
 +							if (setHeight) ilc.setHeight(useHeight);
 +							else ilc.height = useHeight;
 +						}
 +					} else {
 +						child.x = xpos + data.ml;
 +						child.y = ypos + data.mt;
 +						child.width = useWidth;
 +						if (useHeight > 0) {
 +							child.height = useHeight;
 +						}
 +					}
 +
 +					ypos += useHeight + data.mt + data.mb;
 +
 +					//trace("VerticalFlexLayout: setting child "+i+" to "+child.width+" x "+child.height+" at "+child.x+", "+child.y);
 +				}
 +
 +				//trace("VerticalFlexLayout: complete");
 +
 +				return true;
 +			}
 +
 +			COMPILE::JS {
 +				var contentView:ILayoutView = layoutView;
 +
 +				contentView.element.style["display"] = "flex";
 +				contentView.element.style["flex-flow"] = "column";
 +
 +				var n:int = contentView.numElements;
 +				if (n == 0) return false;
 +
 +				for(var i:int=0; i < n; i++) {
 +					var child:UIBase = contentView.getElementAt(i) as UIBase;
 +					if (grow >= 0) child.element.style["flex-grow"] = String(grow);
 +					if (shrink >= 0) child.element.style["flex-shrink"] = String(shrink);
++					child.dispatchEvent(new Event("layoutNeeded"));
 +				}
 +
 +				return true;
 +			}
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/MXMLItemRenderer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/MXMLItemRenderer.as
index de1b304,0000000..d9b130e
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/MXMLItemRenderer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/MXMLItemRenderer.as
@@@ -1,84 -1,0 +1,94 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.supportClasses
 +{
 +	import org.apache.flex.core.ILayoutHost;
 +	import org.apache.flex.core.ILayoutParent;
 +	import org.apache.flex.core.ILayoutView;
 +	import org.apache.flex.core.IStrand;
 +	import org.apache.flex.core.IBead;
 +	import org.apache.flex.core.IBeadLayout;
 +	import org.apache.flex.core.IParentIUIBase;
 +    import org.apache.flex.events.Event;
 +
 +	/**
 +	 *  The MXMLItemRenderer class is the base class for itemRenderers that are MXML-based
 +	 *  and provides support for a layout and a data object.
 +	 *
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
 +	 *  @productversion FlexJS 0.0
 +	 */
 +	public class MXMLItemRenderer extends DataItemRenderer implements ILayoutParent, ILayoutHost, IStrand, ILayoutView
 +	{
 +		/**
 +		 *  constructor.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function MXMLItemRenderer()
 +		{
 +			super();
 +		}
 +
 +        [Bindable("dataChange")]
 +        override public function set data(value:Object):void
 +        {
 +            if (value != data)
 +            {
 +                super.data = value;
 +                dispatchEvent(new Event("dataChange"));
 +            }
 +        }
 +
 +		public function getLayoutHost():ILayoutHost
 +		{
 +			return this;
 +		}
 +
 +		public function get contentView():ILayoutView
 +		{
 +			return this;
 +		}
 +
 +		override public function adjustSize():void
 +		{
 +			var layout:IBeadLayout = getBeadByType(IBeadLayout) as IBeadLayout;
 +			if (layout != null) {
 +				layout.layout();
 +			}
 +		}
++		
++		public function beforeLayout():void
++		{
++			
++		}
++		
++		public function afterLayout():void
++		{
++			
++		}
 +
 +
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/TextButtonItemRenderer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/TextButtonItemRenderer.as
index 0000000,0000000..049fe9b
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/TextButtonItemRenderer.as
@@@ -1,0 -1,0 +1,244 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.supportClasses
++{
++	import org.apache.flex.core.IItemRenderer;
++	import org.apache.flex.core.IItemRendererParent;
++	import org.apache.flex.core.UIBase;
++	import org.apache.flex.core.SimpleCSSStyles;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.MouseEvent;
++	import org.apache.flex.html.TextButton;
++	import org.apache.flex.html.beads.ITextItemRenderer;
++	import org.apache.flex.events.ItemClickedEvent;
++	
++	COMPILE::JS
++	{
++		import org.apache.flex.core.WrappedHTMLElement;            
++	}
++	
++	/**
++	 * The TextButtonItemRenderer class extends TextButton and turns it into an itemRenderer
++	 * suitable for use in most DataContainer/List/DataGrid applications.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++	 */
++	public class TextButtonItemRenderer extends TextButton implements ITextItemRenderer
++	{
++		public function TextButtonItemRenderer()
++		{
++			super();
++			
++			style = new SimpleCSSStyles();
++			
++			addEventListener('click',handleClickEvent);
++		}
++		
++		private var _data:Object;
++		
++		/**
++		 *  The data to be displayed as the text value. Use this in conjunction with
++		 *  the labelField property to select an item from the dataProvider record to use
++		 *  as the text value of the button.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get data():Object
++		{
++			return _data;
++		}
++		public function set data(value:Object):void
++		{
++			_data = value;
++			
++			var valueAsString:String;
++			
++			if (value is String) {
++				valueAsString = value as String;
++			}
++			else if (value.hasOwnProperty("label")) {
++				valueAsString = String(value["label"]);
++			}
++			else if (value.hasOwnProperty("title")) {
++				valueAsString = String(value["title"]);
++			}
++			
++			if (valueAsString) text = valueAsString;
++		}
++		
++		/**
++		 * @private
++		 */
++		protected function handleClickEvent(event:MouseEvent):void
++		{
++			var newEvent:ItemClickedEvent = new ItemClickedEvent("itemClicked");
++			newEvent.multipleSelection = event.shiftKey;
++			newEvent.index = index;
++			newEvent.data = data;
++			dispatchEvent(newEvent);
++		}
++		
++		/*
++		 * IItemRenderer, ISelectableItemRenderer
++		 */
++		
++		private var _itemRendererParent:Object;
++		
++		/**
++		 * The parent container for the itemRenderer instance.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get itemRendererParent():Object
++		{
++			return _itemRendererParent;
++		}
++		public function set itemRendererParent(value:Object):void
++		{
++			_itemRendererParent = value;
++		}
++		
++		private var _labelField:String = "label";
++		
++		/**
++		 * The name of the field within the data to use as a label. Some itemRenderers use this field to
++		 * identify the value they should show while other itemRenderers ignore this if they are showing
++		 * complex information.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get labelField():String
++		{
++			return _labelField;
++		}
++		public function set labelField(value:String):void
++		{
++			_labelField = value;
++		}
++		
++		private var _listData:Object;
++		
++		[Bindable("__NoChangeEvent__")]
++		/**
++		 *  Additional data about the list structure the itemRenderer may
++		 *  find useful.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get listData():Object
++		{
++			return _listData;
++		}
++		public function set listData(value:Object):void
++		{
++			_listData = value;
++		}
++		
++		private var _index:int;
++		
++		/**
++		 *  The position with the dataProvider being shown by the itemRenderer instance.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get index():int
++		{
++			return _index;
++		}
++		public function set index(value:int):void
++		{
++			_index = value;
++		}
++		
++		private var _hovered:Boolean;
++		
++		/**
++		 *  Whether or not the itemRenderer is in a hovered state.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get hovered():Boolean
++		{
++			return _hovered;
++		}
++		public function set hovered(value:Boolean):void
++		{
++			_hovered = value;
++		}
++		
++		private var _selected:Boolean;
++		
++		/**
++		 *  Whether or not the itemRenderer is in a selected state.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get selected():Boolean
++		{
++			return _selected;
++		}
++		public function set selected(value:Boolean):void
++		{
++			_selected = value;
++		}
++		
++		private var _down:Boolean;
++		
++		/**
++		 *  Whether or not the itemRenderer is in a down (or pre-selected) state.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get down():Boolean
++		{
++			return _down;
++		}
++		public function set down(value:Boolean):void
++		{
++			_down = value;
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/resources/basic-manifest.xml
index 7dbe764,072aed9..d57c592
--- a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
@@@ -81,20 -70,13 +81,20 @@@
      <component id="Slider" class="org.apache.flex.html.Slider"/>
      <component id="NumericStepper" class="org.apache.flex.html.NumericStepper" />
      <component id="StringItemRenderer" class="org.apache.flex.html.supportClasses.StringItemRenderer"/>
 +    <component id="AccordionItemRenderer" class="org.apache.flex.html.supportClasses.AccordionItemRenderer"/>
 +    <component id="AccordionCollapseBead" class="org.apache.flex.html.beads.AccordionCollapseBead"/>
 +    <component id="DispatchInputFinishedBead" class="org.apache.flex.html.beads.DispatchInputFinishedBead"/>
 +    <component id="DispatchKeyboardEventBead" class="org.apache.flex.html.beads.DispatchKeyboardEventBead"/>
      <component id="TreeItemRenderer" class="org.apache.flex.html.supportClasses.TreeItemRenderer"/>
      <component id="DataItemRenderer" class="org.apache.flex.html.supportClasses.DataItemRenderer"/>
 -    <component id="ButtonBarButtonItemRenderer" class="org.apache.flex.html.supportClasses.ButtonBarButtonItemRenderer"/>
 +    <component id="MXMLItemRenderer" class="org.apache.flex.html.supportClasses.MXMLItemRenderer"/>
-     <component id="ButtonBarButtonItemRenderer" class="org.apache.flex.html.supportClasses.ButtonBarButtonItemRenderer"/>
 +    <component id="DateItemRenderer" class="org.apache.flex.html.supportClasses.DateItemRenderer"/>
 +    <component id="DayNameItemRenderer" class="org.apache.flex.html.supportClasses.DayNameItemRenderer"/>
++    <component id="TextButtonItemRenderer" class="org.apache.flex.html.supportClasses.TextButtonItemRenderer"/>
      <!--
       <component id="TextFieldItemRenderer" class="org.apache.flex.html.supportClasses.TextFieldItemRenderer"/>
 -    <component id="HScrollBar" class="org.apache.flex.html.supportClasses.HScrollBar"/>
 -    <component id="VScrollBar" class="org.apache.flex.html.supportClasses.VScrollBar"/>
 +     <component id="HScrollBar" class="org.apache.flex.html.supportClasses.HScrollBar"/>
 +     <component id="VScrollBar" class="org.apache.flex.html.supportClasses.VScrollBar"/>
       <component id="HRuleView" class="org.apache.flex.html.beads.HRuleView" />
       <component id="VRuleView" class="org.apache.flex.html.beads.VRuleView" />
       -->

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/resources/defaults.css
index 9ecea43,5ce20fb..02a5bdb
--- a/frameworks/projects/Basic/src/main/resources/defaults.css
+++ b/frameworks/projects/Basic/src/main/resources/defaults.css
@@@ -23,60 -23,26 +23,37 @@@
  /* Global style declaration */
  *
  {
--    font-family: "Arial";
--    font-size: 12px;
++	font-family: "Arial";
++	font-size: 12px;
  	border-width: 1px;
  }
  
  .flexjs *, . flexjs *:before, . flexjs *:after {
--    -moz-box-sizing: border-box;
--    -webkit-box-sizing: border-box;
--    box-sizing: border-box;
++	-moz-box-sizing: border-box;
++	-webkit-box-sizing: border-box;
++	box-sizing: border-box;
  }
  
- Accordion
- {
- 	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
- 	IBeadView:  ClassReference("org.apache.flex.html.beads.AccordionView");			
- 	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
- 	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout");
- 	IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
- 	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
- 	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
- 	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.AccordionItemRenderer");
- 	IViewport: ClassReference("org.apache.flex.html.supportClasses.ClippingViewport");
- 	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
- 	IAccordionCollapseBead: ClassReference("org.apache.flex.html.beads.AccordionCollapseBead");
- 	border-style: solid;
- 	border-color: #222222;
- }
- 
- AccordionItemRenderer
+ .unselectable
  {
- 	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AccordionItemRendererMouseController");
- 	IBeadView: ClassReference("org.apache.flex.html.beads.AccordionItemRendererView");
 -    -moz-user-select: -moz-none;
 -    -khtml-user-select: none;
 -    -webkit-user-select: none;
 -    -o-user-select: none;
 -    user-select: none;
++	-moz-user-select: -moz-none;
++	-khtml-user-select: none;
++	-webkit-user-select: none;
++	-o-user-select: none;
++	user-select: none;
  }
  
 +Alert
 +{
-     IBeadModel: ClassReference("org.apache.flex.html.beads.models.AlertModel");
-        
-     background-color: #FFFFFF;
-     border-style: solid;
-     border-color: #000000;
-     border-width: 1px;
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.AlertModel");
++	
++	background-color: #FFFFFF;
++	border-style: solid;
++	border-color: #000000;
++	border-width: 1px;
 +}
 +
 +
- .unselectable
- {
-     -moz-user-select: -moz-none;
-     -khtml-user-select: none;
-     -webkit-user-select: none;
-     -o-user-select: none;
-     user-select: none;
- }
- 
  Application
  {
  	padding: 0px;
@@@ -85,118 -51,77 +62,113 @@@
  
  Button
  {
--  background-color: #f8f8f8;
--  border: 1px solid #808080;
--  border-radius: 2px;
--  padding: 4px;
--  margin: 0px;
++	background-color: #f8f8f8;
++	border: 1px solid #808080;
++	border-radius: 2px;
++	padding: 4px;
++	margin: 0px;
  }
  
  Button:hover
  {
--  background-color: #e8e8e8;
--  border: 1px solid #808080;
--  padding: 4px;
++	background-color: #e8e8e8;
++	border: 1px solid #808080;
++	padding: 4px;
  }
  
  Button:active
  {
--  background-color: #d8d8d8;
--  border: 1px solid #808080;
--  padding: 4px;
++	background-color: #d8d8d8;
++	border: 1px solid #808080;
++	padding: 4px;
  }
  
  ButtonBar
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.ButtonBarView");			
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.ButtonBarLayout");
--    IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
--    IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
--    IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
--    IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.ButtonBarButtonItemRenderer");
- 
-     border-style: none;
- }
- 
- ButtonBarButtonItemRenderer
- {
-     width: 80;
-     height: 30;
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ButtonBarModel");
++	IBeadView:  ClassReference("org.apache.flex.html.beads.ButtonBarView");			
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.ButtonBarLayout");
++	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
++	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
++	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.TextButtonItemRenderer");
++	
++	border-style: none;
 +}
  
 -    border-style: none;
 +ComboBox
 +{
-     IBeadModel: ClassReference("org.apache.flex.html.beads.models.ComboBoxModel");
-     IBeadView: ClassReference("org.apache.flex.html.beads.ComboBoxView");
-     IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ComboBoxController");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ComboBoxModel");
++	IBeadView: ClassReference("org.apache.flex.html.beads.ComboBoxView");
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ComboBoxController");
 +	IPopUp: ClassReference("org.apache.flex.html.supportClasses.ComboBoxList");
  }
  
 -ButtonBarButtonItemRenderer
 +ComboBoxList
  {
 -    width: 80;
 -    height: 30;
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
++	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
 +	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
 +	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
 +	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
++	IViewport: ClassReference("org.apache.flex.html.supportClasses.ScrollingViewport");
++	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
 +	border-style: solid;
 +	border-radius: 4px;
 +	border-color: #000000;
 +	border-width: 1px;
 +	background-color: #FFFFFF;
 +}
 +
 +.ComboBoxButton {
 +	padding: 0px;
 +	margin: 0px;
  }
  
  Container
  {
--    IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.BasicLayout");
--    IContentView: ClassReference("org.apache.flex.html.supportClasses.ContainerContentArea");
++	IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.BasicLayout");
  	IViewport: ClassReference("org.apache.flex.html.supportClasses.Viewport");
  	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
  }
  
  ControlBar
  {
--	IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
--	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.FlexibleFirstChildHorizontalLayout");
++	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalFlexLayout");
  	
--    background-color: #CECECE;
--	border-style: none;
--    /*border-style: solid;
--    border-color: #000000;
--    border-width: 1px;*/
++	padding: 2px;
++	background-color: #E2E2E2;
++	border-top: solid 1px #333333;
++	height: 30px;
 +}
 +
 +DataContainer
 +{
 +	IBeadModel: ClassReference("org.apache.flex.html.beads.models.DataProviderModel");
 +	IBeadView:  ClassReference("org.apache.flex.html.beads.DataContainerView");			
 +	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
- 	IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
 +	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
 +	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
 +	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
 +	IViewport: ClassReference("org.apache.flex.html.supportClasses.Viewport");
 +	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
 +	border-style: solid;
 +	border-color: #222222;
  }
  
- 
  /* ASJS */
  DataGrid
  {
--    IDataGridPresentationModel: ClassReference("org.apache.flex.html.beads.models.DataGridPresentationModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.DataGridView");
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.DataGridModel");
--	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.DataGridLayout");
--
--    background-color: #FFFFFF;
++	IDataGridPresentationModel: ClassReference("org.apache.flex.html.beads.models.DataGridPresentationModel");
++	IBeadView: ClassReference("org.apache.flex.html.beads.DataGridView");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.DataGridModel");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");
++	
++	background-color: #FFFFFF;
  	border-style: solid;
  	border-color: #222222;
  	border-width: 1px;
@@@ -204,14 -129,14 +176,13 @@@
  
  DataGridButtonBar
  {
--	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ButtonBarModel");
  	IBeadView:  ClassReference("org.apache.flex.html.beads.ButtonBarView");			
  	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
  	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.ButtonBarLayout");
--	IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
  	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
  	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
--	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.DataGridButtonBarButtonItemRenderer");
++	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.TextButtonItemRenderer");
  	
  	border-style: none;
  }
@@@ -221,7 -146,7 +192,6 @@@ DataGridColumnList 
  	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
  	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
  	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
--	IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
  	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayList");
  	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
  	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
@@@ -233,61 -158,25 +203,72 @@@
  
  .DataGridListArea {
  	background-color: #FFFFFF;
--	border-style: solid;
--	border-color: #333333;
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalLayout");
++	IViewport: ClassReference("org.apache.flex.html.supportClasses.ScrollingViewport");
++	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
  }
  
 +/* DateChooser */
 +
  DateChooser {
--    IBeadView:   ClassReference("org.apache.flex.html.beads.DateChooserView");
--    IBeadModel:  ClassReference("org.apache.flex.html.beads.models.DateChooserModel");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DateChooserMouseController");
--    width:  280px;
-     height: 230px;
 -    height: 240px;
++	IBeadView:   ClassReference("org.apache.flex.html.beads.DateChooserView");
++	IBeadModel:  ClassReference("org.apache.flex.html.beads.models.DateChooserModel");			
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");	
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DateChooserMouseController");
++	width:  280px;
++	height: 240px;
 +}
 +
 +DateChooserList {
-     IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
++	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
 +	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-     IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.DataItemRenderer");
-     border-style: solid;
-     border-radius: 4px;
-     border-color: #000000;
-     border-width: 1px;
-     background-color: #FFFFFF;
++	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.DateItemRenderer");		
++	border-style: solid;
++	border-color: #000000;
++	border-width: 1px;
++	background-color: #FFFFFF;
++}
++
++DateChooserHeader {	
++	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.DayNameItemRenderer");
++	height: 20px;
++	border-style: solid;
++	border-color: #000000;
++	border-width: 1px;
++	background-color: #FFFFFF;
 +}
 +
- DateChooserHeader {    
-     IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.DayNameItemRenderer");               
-     border-style: solid;
-     border-color: #000000;
-     border-width: 1px;
-     background-color: #FFFFFF;
++.DateChooserMonthButtons {				
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalFlexLayout");	
++	height: 20px;
 +}
 +
 +DateItemRenderer
 +{
-     IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
-     text-align: center;
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
++	text-align: center;
++	flex-shrink: 0;
++	flex-grow: 1;
 +}
 +
 +DayNameItemRenderer
 +{
-     text-align: center;
++	text-align: center;
++	flex-shrink: 0;
++	flex-grow: 1;
  }
-  
+ 
 +/* DateField */
 +
  DateField {
--    IBeadView:   ClassReference("org.apache.flex.html.beads.DateFieldView");
--    IBeadModel:  ClassReference("org.apache.flex.html.beads.models.DateChooserModel");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DateFieldMouseController");
-     IFormatBead: ClassReference("org.apache.flex.html.accessories.DateFormatMMDDYYYYBead");
 -    IFormatBead: ClassReference("org.apache.flex.html.accessories.DateFormatYYYYMMDDBead");
++	IBeadView:   ClassReference("org.apache.flex.html.beads.DateFieldView");
++	IBeadModel:  ClassReference("org.apache.flex.html.beads.models.DateChooserModel");
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DateFieldMouseController");
++	IFormatBead: ClassReference("org.apache.flex.html.accessories.DateFormatYYYYMMDDBead");
  }
  
 +/* RangeStepper */
 +
  RangeStepper {
  	IBeadView: ClassReference("org.apache.flex.html.beads.RangeStepperView");
  	IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModelExtended");
@@@ -295,13 -184,13 +276,18 @@@
  }
  
  Form {
--    
++	
++}
++
++Group {
++	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
  }
  
  HContainer
  {
--    IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalLayout");
++	IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalLayout");
++	white-space: nowrap;
  }
  
  Image
@@@ -311,63 -200,55 +297,78 @@@
  	IBeadView:  ClassReference("org.apache.flex.html.beads.ImageView");
  }
  
++BinaryImage
++{
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.BinaryImageModel");
++	IBeadView:  ClassReference("org.apache.flex.html.beads.ImageView");
++	IBinaryImageLoader:  ClassReference("org.apache.flex.html.beads.BinaryImageLoader");
++}
++
  ImageAndTextButton
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ImageAndTextModel");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ImageAndTextModel");
  }
  
  ImageButton
  {
--    border-style: none;
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ImageModel");
++	border-style: none;
  }
  
  ImageButton:hover
  {
--    border-style: none;
++	border-style: none;
  }
  
  ImageButton:active
  {
--    border-style: none;
- }
- 
- BinaryImage
- {
- 	IBeadModel: ClassReference("org.apache.flex.html.beads.models.BinaryImageModel");
- 	IBeadView:  ClassReference("org.apache.flex.html.beads.ImageView");
- 	IBinaryImageLoader:  ClassReference("org.apache.flex.html.beads.BinaryImageLoader");
++	border-style: none;
  }
  
  VContainer
  {
--    IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
++	IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
  }
  
  List
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
--    IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
--    IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
--    IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
--    IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
--	IViewport: ClassReference("org.apache.flex.html.supportClasses.ScrollingViewport");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
++	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
++	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
++	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
++	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
++	IViewport: ClassReference("org.apache.flex.html.supportClasses.Viewport");
  	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
  	border-style: solid;
  	border-color: #222222;
 +	background-color: #FFFFFF;
  }
  
 -Tree
++Accordion
+ {
+ 	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
++	IBeadView:  ClassReference("org.apache.flex.html.beads.AccordionView");			
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout");
++	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
++	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
++	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.AccordionItemRenderer");
++	IViewport: ClassReference("org.apache.flex.html.supportClasses.ClippingViewport");
++	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
++	IAccordionCollapseBead: ClassReference("org.apache.flex.html.beads.AccordionCollapseBead");
++	border-style: solid;
++	border-color: #222222;
++}
++
 +Tree
 +{
 +	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArrayListSelectionModel");
  	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
  	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.TreeSingleSelectionMouseController");
  	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
--	IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
  	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForHierarchicalData");
  	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
  	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.TreeItemRenderer");
@@@ -379,141 -260,139 +380,163 @@@
  
  NumericStepper
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
  }
  
  Panel
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.PanelModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.PanelView");
--    
--    background-color: #FFFFFF;
--    border-style: solid;
--    border-color: #000000;
--    border-width: 1px;
--	padding: 2px;
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.PanelModel");
++	IBeadView: ClassReference("org.apache.flex.html.beads.PanelView");
++	IPanelLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");
++	
++	background-color: #FFFFFF;
++	border: solid 1px #333333
  }
  
  PanelWithControlBar
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.PanelModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.PanelWithControlBarView");
--    
--    background-color: #FFFFFF;
--    border-style: solid;
--    border-color: #000000;
--    border-width: 1px;
--	padding: 2px;
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.PanelModel");
++	IBeadView: ClassReference("org.apache.flex.html.beads.PanelWithControlBarView");
++	IPanelLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");
++	
++	background-color: #FFFFFF;
++	border: solid 1px #333333;
++}
++
++Panel .TitleBar
++{
++	border-bottom: solid 1px #333333;
  }
  
  SimpleList
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
--    IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
--    IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
--    IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
--    IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
++	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
++	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
++	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
++	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
  	IViewport: ClassReference("org.apache.flex.html.supportClasses.ScrollingViewport");
  	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
  }
  
  Slider
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
-     iBeadView:  ClassReference("org.apache.flex.html.beads.SliderView");
-     iBeadController: ClassReference("org.apache.flex.html.beads.controllers.SliderMouseController");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
++	iBeadView:  ClassReference("org.apache.flex.html.beads.SliderView");
++	iBeadController: ClassReference("org.apache.flex.html.beads.controllers.SliderMouseController");
  }
  
  Spinner
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.SpinnerView");
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
++	IBeadView:  ClassReference("org.apache.flex.html.beads.SpinnerView");
  }
  
  
  StringItemRenderer
  {
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
--    height: 16;
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
++	height: 24;
++	flex-shrink: 0;
++	flex-grow: 1;
++}
++
++AccordionItemRenderer
++{
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AccordionItemRendererMouseController");
++	IBeadView: ClassReference("org.apache.flex.html.beads.AccordionItemRendererView");
++	flex-shrink: 0;
++	flex-grow: 1;
  }
  
  TreeItemRenderer
  {
  	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
--	height: 16;
++	height: 24;
++	flex-shrink: 0;
++	flex-grow: 1;
  }
  
  TextInput
  {
--  border: 1px solid #808080;
--  border-radius: 2px;
--  padding: 4px;
--  margin: 0px;
++	border: 1px solid #808080;
++	border-radius: 2px;
++	padding: 4px;
++	margin: 0px;
  }
  
  TextArea
  {
--  border: 1px solid #808080;
--  border-radius: 2px;
--  padding: 4px;
--  resize: none;
++	border: 1px solid #808080;
++	border-radius: 2px;
++	padding: 4px;
++	resize: none;
  }
  
  TitleBar
  {
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.TitleBarModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.TitleBarView");
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.FlexibleFirstChildHorizontalLayout");
--    iMeasurementBead: ClassReference("org.apache.flex.html.beads.TitleBarMeasurementBead");
--    background-color: #E2E2E2;
--    border-style: solid;
--    border-color: #000000;
--    border-width: 1px;
++	IBeadModel: ClassReference("org.apache.flex.html.beads.models.TitleBarModel");
++	IBeadView: ClassReference("org.apache.flex.html.beads.TitleBarView");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.FlexibleFirstChildHorizontalLayout");
++	iMeasurementBead: ClassReference("org.apache.flex.html.beads.TitleBarMeasurementBead");
++	background-color: #E2E2E2;
++	padding: 2px;
++	height: 30px;
++	flex-grow: 0;
++	min-height: 30px;
++}
++
++TitleBar .TitleBarCloseButton {
++	width: 16px;
++	height: 16px;
++	margin: 0px;
++}
++
++TitleBar .TitleBarTitle {
++	font-weight: bold;
++	padding: 0;
++	margin: 0;
  }
  
  .toggleTextButton
  {
--  background-color: #f8f8f8;
--  border: 1px solid #808080;
--  padding: 4px;
++	background-color: #f8f8f8;
++	border: 1px solid #808080;
++	padding: 4px;
  }
  
  .toggleTextButton:hover
  {
--  background-color: #e8e8e8;
--  border: 1px solid #808080;
--  padding: 4px;
++	background-color: #e8e8e8;
++	border: 1px solid #808080;
++	padding: 4px;
  }
  
  .toggleTextButton_Selected
  {
--  background-color: #d8d8d8;
--  border: 1px solid #808080;
--  padding: 4px;
++	background-color: #d8d8d8;
++	border: 1px solid #808080;
++	padding: 4px;
  }
  
  .toggleTextButton_Selected:hover
  {
--  background-color: #e8e8e8;
--  border: 1px solid #808080;
--  padding: 4px;
++	background-color: #e8e8e8;
++	border: 1px solid #808080;
++	padding: 4px;
  }
  
  ToolTip
  {
--    background-color: #FFFFCC;
++	background-color: #FFFFCC;
  }
  
  View
  {
--    IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.BasicLayout");
--    IContentView: ClassReference("org.apache.flex.html.supportClasses.ContainerContentArea");
--	IViewport: ClassReference("org.apache.flex.html.supportClasses.Viewport");
--	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
++	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.BasicLayout");
  }
  
  WebBrowser
@@@ -526,280 -405,277 +549,324 @@@
  /* Global Style Declaration */
  global
  {
--    IStatesImpl: ClassReference("org.apache.flex.core.SimpleStatesImpl");
--    IEffectTimer: ClassReference("org.apache.flex.utils.EffectTimer");
--    effectTimerInterval: 10;
++	IStatesImpl: ClassReference("org.apache.flex.core.SimpleStatesImpl");
++	IEffectTimer: ClassReference("org.apache.flex.utils.EffectTimer");
++	effectTimerInterval: 10;
  }
  
  @media -flex-flash
  {
--
--Alert
--{
 -    IBeadModel: ClassReference("org.apache.flex.html.beads.models.AlertModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.AlertView");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AlertController");
--    iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
--    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
--    
 -    background-color: #FFFFFF;
 -    border-style: solid;
 -    border-color: #000000;
 -    border-width: 1px;
--}
--
--Border
--{
--  border-color: inherit;
--  border-style: inherit;
--  border-radius: inherit;
--  border-width: inherit;
--  border: inherit;
--}
--
--Button
--{
--    IBeadView: ClassReference("org.apache.flex.html.beads.CSSButtonView");
--}
--
--CheckBox
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ToggleButtonModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.CheckBoxView");			
--}
--
--CloseButton
--{
--    IBeadView: ClassReference("org.apache.flex.html.beads.CloseButtonView");
--}
--
- ComboBoxList {
- 	iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
 -ComboBox
 -{
 -    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ComboBoxModel");
 -    IBeadView: ClassReference("org.apache.flex.html.beads.ComboBoxView");
 -    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ComboBoxController");
 -    IPopUp: ClassReference("org.apache.flex.html.supportClasses.DropDownListList");
 -    IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
 -    IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
 -    IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
--}
--
--Container
--{
--    iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
--    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
--}
--
--ControlBar
--{
--	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.FlexibleFirstChildHorizontalLayout");
--    iMeasurementBead: ClassReference("org.apache.flex.html.beads.ControlBarMeasurementBead");
--    iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
--    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");    
- }
- 
- DateChooserList {
-    iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
-    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead"); 
- }
-        
- DateChooserHeader {
-     padding-top: 0px;
-     padding-bottom: 5px;
-     iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
-     iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");   
- }
-        
- DateItemRenderer {
-     margin: 0px;
-     padding: 5px;
--}
--
--DropDownList
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.DropDownListView");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DropDownListController");
--    IPopUp: ClassReference("org.apache.flex.html.supportClasses.DropDownListList");
--}
--
--DropDownListList
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
--    IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
--    IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
--    IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
--    iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
--    border-style: solid;
--    border-radius: 4px;
--    border-color: #000000;
--    border-width: 1px;
--    background-color: #FFFFFF;
--}
--
--HRule
--{
--    IBeadView:  ClassReference("org.apache.flex.html.beads.HRuleView");
--}
--
--ImageButton
--{
--    IBeadView: ClassReference("org.apache.flex.html.beads.ImageButtonView");
--}
--
--ImageAndTextButton
--{
--    IBeadView: ClassReference("org.apache.flex.html.beads.CSSImageAndTextButtonView");
--}
--
--Label
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.TextFieldView");
--	iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextFieldLabelMeasurementBead");
--}
--
--List
--{
--    iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
--    iBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
--}
--
--MultilineLabel
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.MultilineTextFieldView");
--}
--
--NumericStepper
--{
--    IBeadView: ClassReference("org.apache.flex.html.beads.NumericStepperView");
--    
--    padding: 0px;
--    border-style: solid;
--    border-color: #000000;
--    border-width: 1px;
--    background-color: #FFFFFF;
--    iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
--    iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
--}
--
--Panel
--{
--    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
--    iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");    
--}
--
--PanelWithControlBar
--{
--    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
--    iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
--}
--
--RadioButton
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ValueToggleButtonModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.RadioButtonView");			
--}
--
--VScrollBar
--{
--    IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VScrollBarLayout");
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ScrollBarModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.VScrollBarView");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.VScrollBarMouseController");
--}
--
--HScrollBar
--{
--	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HScrollBarLayout");
--	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ScrollBarModel");
--	IBeadView: ClassReference("org.apache.flex.html.beads.HScrollBarView");
--	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.HScrollBarMouseController");
--}
--
--SimpleAlert
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.AlertModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.SimpleAlertView");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AlertController");
--    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
--    iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
--    
--    background-color: #FFFFFF;
--    border-style: solid;
--    border-color: #000000;
--    border-width: 1px;
--}
--
--Slider
--{
 -    iBeadView:  ClassReference("org.apache.flex.html.beads.SliderView");
 -    iBeadController: ClassReference("org.apache.flex.html.beads.controllers.SliderMouseController");
--    iThumbView: ClassReference("org.apache.flex.html.beads.SliderThumbView");
--    iTrackView: ClassReference("org.apache.flex.html.beads.SliderTrackView");
--}
--
--Spinner
--{
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.SpinnerMouseController");
--}
--
--TextArea
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.TextAreaView");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.EditableTextKeyboardController");
--    iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
--    iBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
--    border-style: solid;
--    border-color: #000000;
--    border-width: 1px;
--    background-color: #FFFFFF;
--}
--
--TextButton
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.CSSTextButtonView");
--    iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextButtonMeasurementBead");
--}
--
--TextFieldItemRenderer
--{
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
--    height: 16;
--}
--
--TextInput
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.TextInputWithBorderView");
--    IBeadController: ClassReference("org.apache.flex.html.beads.controllers.EditableTextKeyboardController");
--    iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
--    iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
--    border-style: solid;
--    border-color: #000000;
--    border-width: 1px;
--    background-color: #FFFFFF;
--}
--
--TitleBar
--{
--    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
--    iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
--}
--
--ToggleTextButton
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.ToggleButtonModel");
--    IBeadView:  ClassReference("org.apache.flex.html.beads.CSSTextToggleButtonView");
--}
--
--View
--{
--    iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
--    iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
--}
--
--VRule
--{
--    IBeadView:  ClassReference("org.apache.flex.html.beads.VRuleView");
--}
--
--/* SVG */
--
--svg|TextButton
--{
--    IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
--    IBeadView: ClassReference("org.apache.flex.html.beads.CSSTextButtonView");
--    iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextButtonMeasurementBead");
--}
++	Accordion {
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
++	}
++	
++	Alert
++	{
++		IBeadView:  ClassReference("org.apache.flex.html.beads.AlertView");
++		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AlertController");
++		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++	}
++	
++	Border
++	{
++		border-color: inherit;
++		border-style: inherit;
++		border-radius: inherit;
++		border-width: inherit;
++		border: inherit;
++	}
++	
++	Button
++	{
++		IBeadView: ClassReference("org.apache.flex.html.beads.CSSButtonView");
++	}
++	
++	ButtonBar
++	{
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
++	}
++	
++	CheckBox
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ToggleButtonModel");
++		IBeadView:  ClassReference("org.apache.flex.html.beads.CheckBoxView");			
++	}
++	
++	CSSCheckBox
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ToggleButtonModel");
++		IBeadView:  ClassReference("org.apache.flex.html.beads.CheckBoxView");			
++	}
++	
++	CloseButton
++	{
++		IBeadView: ClassReference("org.apache.flex.html.beads.CloseButtonView");
++	}
++	
++	Container
++	{
++		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.ContainerContentArea");
++	}
++	
++	ControlBar
++	{
++		IMeasurementBead: ClassReference("org.apache.flex.html.beads.ControlBarMeasurementBead");
++		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");  
++		border: solid 1px #333333;
++	}
++	
++	ComboBoxList {
++		IBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
++	}
++	
++	DataContainer {
++		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
++	}
++	
++	DataGridButtonBar {
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
++	}
++	
++	DateChooserList {
++		iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
++		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead"); 
++	}
++	
++	DateChooserHeader {
++		padding-top: 0px;
++		padding-bottom: 5px;
++		iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
++		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");   
++	}
++	
++	DateItemRenderer {
++		margin: 0px;
++		padding: 5px;
++	}
++	
++	DropDownList
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.DropDownListView");
++		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DropDownListController");
++		IPopUp: ClassReference("org.apache.flex.html.supportClasses.DropDownListList");
++	}
++	
++	DropDownListList
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
++		IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
++		IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
++		IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
++		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
++		iBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
++		border-style: solid;
++		border-radius: 4px;
++		border-color: #333333;
++		border-width: 1px;
++		background-color: #FFFFFF;
++	}
++	
++	Group
++	{
++		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++		iBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
++	}
++	
++	HRule
++	{
++		IBeadView:  ClassReference("org.apache.flex.html.beads.HRuleView");
++	}
++	
++	ImageButton
++	{
++		IBeadView: ClassReference("org.apache.flex.html.beads.ImageButtonView");
++	}
++	
++	ImageAndTextButton
++	{
++		IBeadView: ClassReference("org.apache.flex.html.beads.CSSImageAndTextButtonView");
++	}
++	
++	Label
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.TextFieldView");
++		iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextFieldLabelMeasurementBead");
++	}
++	
++	List
++	{
++		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
++		iBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
++	}
++	
++	MultilineLabel
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.MultilineTextFieldView");
++	}
++	
++	NumericStepper
++	{
++		IBeadView: ClassReference("org.apache.flex.html.beads.NumericStepperView");
++		
++		padding: 0px;
++		border-style: solid;
++		border-color: #000000;
++		border-width: 1px;
++		background-color: #FFFFFF;
++		iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
++		iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
++	}
++	
++	Panel
++	{
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.ContainerContentArea");
++		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");    
++	}
++	
++	PanelWithControlBar
++	{
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.ContainerContentArea");
++		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++	}
++	
++	RadioButton
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ValueToggleButtonModel");
++		IBeadView:  ClassReference("org.apache.flex.html.beads.RadioButtonView");			
++	}
++	
++	VScrollBar
++	{
++		IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VScrollBarLayout");
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ScrollBarModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.VScrollBarView");
++		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.VScrollBarMouseController");
++	}
++	
++	HScrollBar
++	{
++		IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HScrollBarLayout");
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ScrollBarModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.HScrollBarView");
++		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.HScrollBarMouseController");
++	}
++	
++	SimpleAlert
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.AlertModel");
++		IBeadView:  ClassReference("org.apache.flex.html.beads.SimpleAlertView");
++		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AlertController");
++		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		
++		background-color: #FFFFFF;
++		border-style: solid;
++		border-color: #000000;
++		border-width: 1px;
++	}
++	
++	Slider
++	{
++		iThumbView: ClassReference("org.apache.flex.html.beads.SliderThumbView");
++		iTrackView: ClassReference("org.apache.flex.html.beads.SliderTrackView");
++	}
++	
++	Spinner
++	{
++		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.SpinnerMouseController");
++	}
++	
++	TextArea
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.TextAreaView");
++		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.EditableTextKeyboardController");
++		IBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
++		IBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
++		border-style: solid;
++		border-color: #000000;
++		border-width: 1px;
++		background-color: #FFFFFF;
++	}
++	
++	TextButton
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.CSSTextButtonView");
++		iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextButtonMeasurementBead");
++	}
++	
++	Tree {
++		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
++	}
++	
++	/*
++	TextFieldItemRenderer
++	{
++	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
++	height: 16;
++	}
++	*/
++	
++	TextInput
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.TextInputWithBorderView");
++		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.EditableTextKeyboardController");
++		IBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
++		IBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
++		border-style: solid;
++		border-color: #000000;
++		border-width: 1px;
++		background-color: #FFFFFF;
++	}
++	
++	TitleBar
++	{
++		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		border: solid 1px #333333;
++	}
++	
++	ToggleTextButton
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ToggleButtonModel");
++		IBeadView:  ClassReference("org.apache.flex.html.beads.CSSTextToggleButtonView");
++	}
++	
++	View
++	{
++		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
++		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
++	}
++	
++	VRule
++	{
++		IBeadView:  ClassReference("org.apache.flex.html.beads.VRuleView");
++	}
++	
++	/* SVG */
++	
++	svg|TextButton
++	{
++		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
++		IBeadView: ClassReference("org.apache.flex.html.beads.CSSTextButtonView");
++		iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextButtonMeasurementBead");
++	}
  
  }


[41/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - simply image/label pairs so they center in JS

Posted by ah...@apache.org.
simply image/label pairs so they center in JS


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/8f3c9a0e
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/8f3c9a0e
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/8f3c9a0e

Branch: refs/heads/develop
Commit: 8f3c9a0eeb5d063c3ffd560098c0be10479483fa
Parents: f4a6968
Author: Alex Harui <ah...@apache.org>
Authored: Thu Apr 27 23:56:37 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 23:56:37 2017 -0700

----------------------------------------------------------------------
 .../FlexJSStore/src/main/flex/HomeView.mxml     | 24 +++-----------------
 1 file changed, 3 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/8f3c9a0e/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml b/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml
index 3a93319..ab10fa0 100755
--- a/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml
+++ b/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml
@@ -208,13 +208,7 @@ Width and height are hard-coded in the root tag to help the Design view.
 								<js:VerticalLayout />
 							</js:beads>
  							<js:Image id="image1" src="assets/akotter.jpg" style="margin:auto;"/>							
-							<js:Group width="100%">
-							    <js:beads>
-									<js:BasicLayout />
-							    </js:beads>
-								<js:Label text="Annette Kotter" id="feat_prod_1" style="margin:auto;fontWeight:'bold';fontSize:12"/>
-							</js:Group>
-							
+							<js:Label text="Annette Kotter" id="feat_prod_1" style="textAlign:center;fontWeight:'bold';fontSize:12;"/>
 						</js:Group>
 						
 						<js:Group width="33%" height="100%">							
@@ -222,13 +216,7 @@ Width and height are hard-coded in the root tag to help the Design view.
 								<js:VerticalLayout />
 							</js:beads>
 							<js:Image id="image2" style="margin:auto;" src="assets/bcrater.jpg"/>
-							<js:Group width="100%">
-							    <js:beads>
-									<js:BasicLayout />
-							    </js:beads>
-								<js:Label text="Ben Crater" id="feat_prod_2" style="margin:auto;fontWeight:'bold';fontSize:12"/>
-							</js:Group>
-							
+							<js:Label text="Ben Crater" id="feat_prod_2" style="textAlign:center;fontWeight:'bold';fontSize:12;"/>
 						</js:Group>
 						
 						<js:Group width="33%" height="100%">
@@ -236,13 +224,7 @@ Width and height are hard-coded in the root tag to help the Design view.
 								<js:VerticalLayout />
 							</js:beads>
 							<js:Image id="image3" style="margin:auto;" src="assets/jproctor.jpg"/>
-							<js:Group width="100%">
-							    <js:beads>
-									<js:BasicLayout />
-							    </js:beads>
-								<js:Label text="Jane Proctor" id="feat_prod_3" style="margin:auto;fontWeight:'bold';fontSize:12"/>
-							</js:Group>
-							
+							<js:Label text="Jane Proctor" id="feat_prod_3" style="textAlign:center;fontWeight:'bold';fontSize:12;"/>
 						</js:Group>
 						
 					</js:Group>


[10/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ImageButton.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ImageButton.as
index b439483,f61f5ee..4b89037
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ImageButton.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ImageButton.as
@@@ -19,6 -19,6 +19,9 @@@
  package org.apache.flex.html
  {
      import org.apache.flex.core.SimpleCSSStyles;
++	import org.apache.flex.events.Event;
++    import org.apache.flex.html.beads.models.ImageModel;
++
      COMPILE::JS
      {
          import org.apache.flex.core.WrappedHTMLElement;
@@@ -27,6 -27,6 +30,7 @@@
      /**
       *  The ImageButton class presents an image as a button.
       *
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
@@@ -52,39 -52,38 +56,48 @@@
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
  		COMPILE::JS
--		override protected function createElement():WrappedHTMLElement
--		{
--			element = document.createElement("input") as WrappedHTMLElement;
--			positioner = element;
--			element.flexjs_wrapper = this;
++        override protected function createElement():WrappedHTMLElement
++        {
++            element = document.createElement('button') as WrappedHTMLElement;
++            element.setAttribute('type', 'button');
  
--			var inputElement:HTMLInputElement = element as HTMLInputElement;
--			inputElement.type = "image";
-             inputElement.setAttribute("value", " ");
-             
- 			return element;
- 		}
++            positioner = element;
++            //positioner.style.position = 'relative';
++            element.flexjs_wrapper = this;
  
 -			return element;
 -		}
++            return element;
++        }
+ 
++		[Bindable("srcChanged")]
  		/**
  		 * Sets the image for the button. This is a URL.
  		 * TODO: figure out how to set the source in the style, rather than using
  		 * backgroundImage behind the scenes.
  		 */
-         public function get source():String
+         public function get src():String
          {
--            return style.backgroundImage;
++            return ImageModel(model).url;
          }
  
-         public function set source(url:String):void
+         public function set src(url:String):void
          {
--            if (!style)
--                style = new SimpleCSSStyles();
--            style.backgroundImage = url;
++            ImageModel(model).url = url;
++            COMPILE::SWF
++            {
++                if (!style)
++                    style = new SimpleCSSStyles();
++                style.backgroundImage = url;
++            }
  
--            COMPILE::JS {
--            	var inputElement:HTMLInputElement = element as HTMLInputElement;
--				inputElement.src = url;
++            COMPILE::JS
++            {
++                var inner:String = '';
++                if (url)
++                    inner = "<img src='" + url + "'/>";
++                element.innerHTML = inner;
              }
++
++			dispatchEvent(new Event("srcChanged"));
          }
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/List.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/List.as
index 617b186,17c8b3f..fb2481f
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/List.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/List.as
@@@ -18,52 -18,52 +18,39 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html
  {
--	import org.apache.flex.core.ContainerBaseStrandChildren;
--	import org.apache.flex.core.IContentViewHost;
--	import org.apache.flex.core.IDataProviderItemRendererMapper;
--	import org.apache.flex.core.IFactory;
--	import org.apache.flex.core.IItemRendererClassFactory;
--	import org.apache.flex.core.IItemRendererProvider;
--	import org.apache.flex.core.IListPresentationModel;
  	import org.apache.flex.core.IRollOverModel;
  	import org.apache.flex.core.ISelectionModel;
--	import org.apache.flex.core.ListBase;
--	import org.apache.flex.core.UIBase;
--	import org.apache.flex.core.ValuesManager;
--    COMPILE::JS
--    {
--        import org.apache.flex.core.WrappedHTMLElement;
--        import org.apache.flex.html.beads.ListView;
--        import org.apache.flex.html.supportClasses.DataGroup;
--    }
--	import org.apache.flex.events.Event;
--	import org.apache.flex.events.IEventDispatcher;
--	import org.apache.flex.html.beads.models.ListPresentationModel;
--	
++
++	COMPILE::JS
++	{
++		import org.apache.flex.core.WrappedHTMLElement;
++	}
++
  	/**
  	 *  Indicates that the initialization of the list is complete.
--	 *  
++	 *
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
  	[Event(name="initComplete", type="org.apache.flex.events.Event")]
--	
++
  	/**
  	 * The change event is dispatched whenever the list's selection changes.
--	 *  
++	 *
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
      [Event(name="change", type="org.apache.flex.events.Event")]
--    
++
  	/**
  	 *  The List class is a component that displays multiple data items. The List uses
  	 *  the following bead types:
--	 * 
++	 *
  	 *  org.apache.flex.core.IBeadModel: the data model, which includes the dataProvider, selectedItem, and
  	 *  so forth.
  	 *  org.apache.flex.core.IBeadView:  the bead that constructs the visual parts of the list.
@@@ -71,13 -71,13 +58,13 @@@
  	 *  org.apache.flex.core.IBeadLayout: the bead responsible for the size and position of the itemRenderers.
  	 *  org.apache.flex.core.IDataProviderItemRendererMapper: the bead responsible for creating the itemRenders.
  	 *  org.apache.flex.core.IItemRenderer: the class or factory used to display an item in the list.
--	 *  
++	 *
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class List extends ListBase implements IItemRendererProvider
++	public class List extends DataContainer
  	{
  		/**
  		 *  constructor.
@@@ -90,43 -90,42 +77,7 @@@
  		public function List()
  		{
  			super();
-             addEventListener("beadsAdded", beadsAddedHandler);
-         }
- 		
- 		/**
- 		 *  The name of field within the data used for display. Each item of the
- 		 *  data should have a property with this name.
- 		 *
- 		 *  @langversion 3.0
- 		 *  @playerversion Flash 10.2
- 		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.0
- 		 */
- 		public function get labelField():String
- 		{
- 			return ISelectionModel(model).labelField;
  		}
 -		
 -		/**
 -		 *  The name of field within the data used for display. Each item of the
 -		 *  data should have a property with this name.
 -		 *
 -		 *  @langversion 3.0
 -		 *  @playerversion Flash 10.2
 -		 *  @playerversion AIR 2.6
 -		 *  @productversion FlexJS 0.0
 -		 */
 -		public function get labelField():String
 -		{
 -			return ISelectionModel(model).labelField;
 -		}
--		public function set labelField(value:String):void
--		{
--			ISelectionModel(model).labelField = value;
--		}
--		
--		/**
--		 *  The data being display by the List.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--        public function get dataProvider():Object
--        {
--            return ISelectionModel(model).dataProvider;
--        }
--        public function set dataProvider(value:Object):void
--        {
--            ISelectionModel(model).dataProvider = value;
--        }
  
  		/**
  		 *  The index of the currently selected item. Changing this value
@@@ -162,25 -161,25 +113,7 @@@
  		{
  			IRollOverModel(model).rollOverIndex = value;
  		}
--			
--		/**
--		 *  The presentation model for the list.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get presentationModel():IListPresentationModel
--		{
--			var presModel:IListPresentationModel = getBeadByType(IListPresentationModel) as IListPresentationModel;
--			if (presModel == null) {
--				presModel = new ListPresentationModel();
--				addBead(presModel);
--			}
--			return presModel;
--		}
--		
++
  		/**
  		 *  The default height of each cell in every column
  		 *
@@@ -197,9 -196,9 +130,9 @@@
  		{
  			presentationModel.rowHeight = value;
  		}
--		
++
  		/**
--		 *  The item currently selected. Changing this value also 
++		 *  The item currently selected. Changing this value also
  		 *  changes the selectedIndex property.
  		 *
  		 *  @langversion 3.0
@@@ -215,82 -214,76 +148,12 @@@
  		{
  			ISelectionModel(model).selectedItem = value;
  		}
--		
--		private var _itemRenderer:IFactory;
--		
--		/**
--		 *  The class or factory used to display each item.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get itemRenderer():IFactory
--		{
--			return _itemRenderer;
--		}
--		public function set itemRenderer(value:IFactory):void
--		{
--			_itemRenderer = value;
--		}
--		
--		/**
--		 * Returns whether or not the itemRenderer property has been set.
--		 *
--		 *  @see org.apache.flex.core.IItemRendererProvider
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get hasItemRenderer():Boolean
--		{
--			var result:Boolean = false;
--			
--			COMPILE::SWF {
--				result = _itemRenderer != null;
--			}
--			
--			COMPILE::JS {
--				var test:* = _itemRenderer;
--				result = _itemRenderer !== null && test !== undefined;
--			}
--			
--			return result;
--		}
--		
--		
--		/**
--		 * @private
++
++		/*
++		 * UIBase
  		 */
--		override public function addedToParent():void
--		{
--            super.addedToParent();
--            
-             dispatchEvent(new Event("initComplete"));
-         }
 -            if (getBeadByType(IDataProviderItemRendererMapper) == null)
 -            {
 -                var mapper:IDataProviderItemRendererMapper = new (ValuesManager.valuesImpl.getValue(this, "iDataProviderItemRendererMapper")) as IDataProviderItemRendererMapper;
 -                addBead(mapper);
 -            }
 -			var itemRendererFactory:IItemRendererClassFactory = getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
 -			if (!itemRendererFactory)
 -			{
 -				itemRendererFactory = new (ValuesManager.valuesImpl.getValue(this, "iItemRendererClassFactory")) as IItemRendererClassFactory;
 -				addBead(itemRendererFactory);
 -			}
 -			
 -			dispatchEvent(new Event("initComplete"));
 -		}
 -        
 +
          /**
-          * @private
-          */
-         private function beadsAddedHandler(e:Event):void
-         {
-             if (getBeadByType(IDataProviderItemRendererMapper) == null)
-             {
-                 var mapper:IDataProviderItemRendererMapper = new (ValuesManager.valuesImpl.getValue(this, "iDataProviderItemRendererMapper")) as IDataProviderItemRendererMapper;
-                 addBead(mapper);
-             }
-             var itemRendererFactory:IItemRendererClassFactory = getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
-             if (!itemRendererFactory)
-             {
-                 itemRendererFactory = new (ValuesManager.valuesImpl.getValue(this, "iItemRendererClassFactory")) as IItemRendererClassFactory;
-                 addBead(itemRendererFactory);
-             }
-         }
-             
-         /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
          COMPILE::JS
@@@ -298,21 -291,21 +161,8 @@@
          {
              super.createElement();
              className = 'List';
--            
--            return element;
--        }        
  
--        /**
--         * @flexjsignorecoercion org.apache.flex.html.beads.ListView 
--         * @flexjsignorecoercion org.apache.flex.html.supportClasses.DataGroup 
--         */
--        COMPILE::JS
--        override public function internalChildren():Array
--        {
--            var listView:ListView = getBeadByType(ListView) as ListView;
--            var dg:DataGroup = listView.dataGroup as DataGroup;
--            var renderers:Array = dg.internalChildren();
--            return renderers;
--        };
++            return element;
++        }
     	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/MXMLBeadView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/MXMLBeadView.as
index 1807381,1807381..4bfa105
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/MXMLBeadView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/MXMLBeadView.as
@@@ -19,7 -19,7 +19,7 @@@
  package org.apache.flex.html
  {
  	import org.apache.flex.states.State;
--	
++
  	import org.apache.flex.core.IBead;
      import org.apache.flex.core.ILayoutHost;
      import org.apache.flex.core.IParent;
@@@ -27,28 -27,28 +27,28 @@@
  	import org.apache.flex.core.IStrand;
      import org.apache.flex.core.IStatesImpl;
  	import org.apache.flex.core.ValuesManager;
--    import org.apache.flex.html.beads.ContainerView;
++    import org.apache.flex.html.beads.GroupView;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.ValueChangeEvent;
  	import org.apache.flex.utils.MXMLDataInterpreter;
  
      [DefaultProperty("mxmlContent")]
--    
++
      /**
       *  The MXMLBeadView class extends ContainerView
       *  and adds support for databinding and specification
       *  of children in MXML.
--     *  
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class MXMLBeadView extends ContainerView implements IStrand, ILayoutHost
++	public class MXMLBeadView extends GroupView implements IStrand, ILayoutHost
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -58,12 -58,12 +58,12 @@@
  		{
  			super();
  		}
--		
++
          [Bindable("strandChanged")]
          /**
           *  An MXMLBeadView doesn't create its children until it is added to
           *  the strand.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -74,21 -74,21 +74,21 @@@
              super.strand = value;
              // each MXML file can also have styles in fx:Style block
              ValuesManager.valuesImpl.init(this);
--            
--            dispatchEvent(new Event("strandChanged"));  
--            
++
++            dispatchEvent(new Event("strandChanged"));
++
              for each (var bead:IBead in beads)
                  addBead(bead);
--            
++
              dispatchEvent(new org.apache.flex.events.Event("beadsAdded"));
  
              MXMLDataInterpreter.generateMXMLInstances(this, IParent(value), MXMLDescriptor);
--            
--            dispatchEvent(new Event("initBindings"))
--            dispatchEvent(new Event("initComplete"))
++
              dispatchEvent(new Event("childrenAdded"));
++            dispatchEvent(new Event("initBindings"));
++            dispatchEvent(new Event("initComplete"));
          }
--        
++
          [Bindable("__NoChangeEvent__")]
          /**
           *  The model object.
@@@ -97,10 -97,10 +97,10 @@@
          {
              return _strand["model"];
          }
--        
++
          /**
           *  @copy org.apache.flex.core.Application#MXMLDescriptor
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -110,10 -110,10 +110,10 @@@
          {
              return null;
          }
--        
++
          /**
           *  @copy org.apache.flex.core.Application#generateMXMLAttributes()
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -123,23 -123,23 +123,23 @@@
          {
              MXMLDataInterpreter.generateMXMLProperties(this, data);
          }
--        
++
          /**
           *  @copy org.apache.flex.core.ItemRendererClassFactory#mxmlContent
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
           *  @productversion FlexJS 0.0
           */
          public var mxmlContent:Array;
--        
++
          private var _states:Array;
--        
++
          /**
           *  The array of view states. These should
           *  be instances of org.apache.flex.states.State.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -149,7 -149,7 +149,7 @@@
          {
              return _states;
          }
--        
++
          /**
           *  @private
           */
@@@ -157,7 -157,7 +157,7 @@@
          {
              _states = value;
              _currentState = _states[0].name;
--            
++
              try{
                  if (getBeadByType(IStatesImpl) == null)
                      addBead(new (ValuesManager.valuesImpl.getValue(this, "iStatesImpl")) as IBead);
@@@ -167,19 -167,19 +167,19 @@@
              {
                  COMPILE::SWF
                  {
--                    trace(e.message);                        
++                    trace(e.message);
                  }
              }
--            
++
          }
--        
++
          /**
           *  <code>true</code> if the array of states
           *  contains a state with this name.
--         * 
++         *
           *  @param state The state namem.
           *  @return True if state in state array
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -194,13 -194,13 +194,13 @@@
              }
              return false;
          }
--        
++
          private var _currentState:String;
--        
++
          [Bindable("currentStateChange")]
          /**
           *  The name of the current state.
--         * 
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -208,9 -208,9 +208,9 @@@
           */
          public function get currentState():String
          {
--            return _currentState;   
++            return _currentState;
          }
--        
++
          /**
           *  @private
           */
@@@ -220,12 -220,12 +220,12 @@@
              _currentState = value;
              dispatchEvent(event);
          }
--        
++
          private var _transitions:Array;
--        
++
          /**
           *  The array of transitions.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -233,48 -233,48 +233,48 @@@
           */
          public function get transitions():Array
          {
--            return _transitions;   
++            return _transitions;
          }
--        
++
          /**
           *  @private
           */
          public function set transitions(value:Array):void
          {
--            _transitions = value;   
++            _transitions = value;
          }
  
          /**
           *  @copy org.apache.flex.core.Application#beads
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
           *  @productversion FlexJS 0.0
           */
          public var beads:Array;
--        
++
          private var _beads:Array;
--        
++
          /**
           *  @copy org.apache.flex.core.IStrand#addBead()
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
           *  @productversion FlexJS 0.0
--         */        
++         */
          public function addBead(bead:IBead):void
          {
              if (!_beads)
                  _beads = [];
              _beads.push(bead);
--            bead.strand = this;            
++            bead.strand = this;
          }
--        
++
          /**
           *  @copy org.apache.flex.core.IStrand#getBeadByType()
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -289,16 -289,16 +289,16 @@@
              }
              return null;
          }
--        
++
          /**
           *  @copy org.apache.flex.core.IStrand#removeBead()
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
           *  @productversion FlexJS 0.0
           */
--        public function removeBead(value:IBead):IBead	
++        public function removeBead(value:IBead):IBead
          {
              var n:int = _beads.length;
              for (var i:int = 0; i < n; i++)

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as
index e919295,e919295..984fda9
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/NumericStepper.as
@@@ -37,6 -37,6 +37,7 @@@ package org.apache.flex.htm
  	 *  org.apache.flex.core.IBeadView: constructs the parts of the component.
  	 *  org.apache.flex.core.IBeadController: handles the input events.
  	 *
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -160,7 -160,7 +161,7 @@@
          {
              element = document.createElement('div') as WrappedHTMLElement;
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
  
              input = new TextInput();
              input.className = "NumericStepperInput";

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Panel.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Panel.as
index e9c5986,e9c5986..ab3b114
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Panel.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Panel.as
@@@ -19,6 -19,6 +19,9 @@@
  package org.apache.flex.html
  {
  	import org.apache.flex.core.IPanelModel;
++	import org.apache.flex.core.IChild;
++	import org.apache.flex.html.beads.PanelView;
++	import org.apache.flex.events.Event;
  
      COMPILE::JS
      {
@@@ -40,6 -40,6 +43,7 @@@
  	 *  org.apache.flex.core.IBorderBead: if present, draws a border around the Panel.
  	 *  org.apache.flex.core.IBackgroundBead: if present, provides a colored background for the Panel.
  	 *  
++     *  @toplevel
  	 *  @see PanelWithControlBar
  	 *  @see ControlBar
  	 *  @see TitleBar
@@@ -48,7 -48,7 +52,7 @@@
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class Panel extends Container
++	public class Panel extends Group
  	{
  		/**
  		 *  constructor.
@@@ -61,6 -61,6 +65,23 @@@
  		public function Panel()
  		{
  			super();
++			
++			className = "Panel";
++		}
++		
++		public function $addElement(c:IChild, dispatchEvent:Boolean = true):void
++		{
++			super.addElement(c, dispatchEvent);
++		}
++		
++		public function get $numElements():Number
++		{
++			return super.numElements;
++		}
++		
++		public function $getElementAt(index:Number):IChild
++		{
++			return super.getElementAt(index);
  		}
  		
  		/**
@@@ -109,13 -109,13 +130,67 @@@
  			IPanelModel(model).showCloseButton = value;
  		}
  		
--        COMPILE::JS
--        override protected function createElement():WrappedHTMLElement
--        {
--            super.createElement();
--            element.className = "Panel";
--            typeNames = "Panel";
--            return element;
--        }
++		
++		/**
++		 * @private
++		 * @flexjsignorecoercion org.apache.flex.html.beads.PanelView
++		 */
++		override public function addElement(c:IChild, dispatchEvent:Boolean = true):void
++		{
++			var panelView:PanelView = view as PanelView;
++			panelView.contentArea.addElement(c, dispatchEvent);
++			panelView.contentArea.dispatchEvent(new Event("layoutNeeded"));
++		}
++		
++		/**
++		 * @private
++		 * @flexjsignorecoercion org.apache.flex.html.beads.PanelView
++		 */
++		override public function addElementAt(c:IChild, index:int, dispatchEvent:Boolean = true):void
++		{
++			var panelView:PanelView = view as PanelView;
++			panelView.contentArea.addElementAt(c, index, dispatchEvent);
++			panelView.contentArea.dispatchEvent(new Event("layoutNeeded"));
++		}
++		
++		/**
++		 * @private
++		 * @flexjsignorecoercion org.apache.flex.html.beads.PanelView
++		 */
++		override public function getElementIndex(c:IChild):int
++		{
++			var panelView:PanelView = view as PanelView;
++			return panelView.contentArea.getElementIndex(c);
++		}
++		
++		/**
++		 * @private
++		 * @flexjsignorecoercion org.apache.flex.html.beads.PanelView
++		 */
++		override public function removeElement(c:IChild, dispatchEvent:Boolean = true):void
++		{
++			var panelView:PanelView = view as PanelView;
++			panelView.contentArea.removeElement(c, dispatchEvent);
++		}
++		
++		/**
++		 * @private
++		 * @flexjsignorecoercion org.apache.flex.html.beads.PanelView
++		 */
++		override public function get numElements():int
++		{
++			var panelView:PanelView = view as PanelView;
++			return panelView.contentArea.numElements;
++		}
++		
++		/**
++		 * @private
++		 * @flexjsignorecoercion org.apache.flex.html.beads.PanelView
++		 */
++		override public function getElementAt(index:int):IChild
++		{
++			var panelView:PanelView = view as PanelView;
++			return panelView.contentArea.getElementAt(index);
++		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/PanelWithControlBar.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/PanelWithControlBar.as
index 7659d9d,7659d9d..d5ff4b1
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/PanelWithControlBar.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/PanelWithControlBar.as
@@@ -33,12 -33,12 +33,13 @@@ package org.apache.flex.htm
  	 *  org.apache.flex.core.IBorderBead: if present, draws a border around the Panel.
  	 *  org.apache.flex.core.IBackgroundBead: if present, provides a colored background for the Panel.
  	 *  
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class PanelWithControlBar extends Container
++	public class PanelWithControlBar extends Panel
  	{
  		/**
  		 *  constructor.
@@@ -54,52 -54,52 +55,6 @@@
  		}
  		
  		/**
--		 *  The string to display in the org.apache.flex.html.TitleBar.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get title():String
--		{
--			return IPanelModel(model).title;
--		}
--		public function set title(value:String):void
--		{
--			IPanelModel(model).title = value;
--		}
--		
--		/**
--		 *  The HTML string to display in the org.apache.flex.html.TitleBar.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get htmlTitle():String
--		{
--			return IPanelModel(model).htmlTitle;
--		}
--		public function set htmlTitle(value:String):void
--		{
--			IPanelModel(model).htmlTitle = value;
--		}
--		
--		/**
--		 * Whether or not to show a Close button in the org.apache.flex.html.TitleBar.
--		 */
--		public function get showCloseButton():Boolean
--		{
--			return IPanelModel(model).showCloseButton;
--		}
--		public function set showCloseButton(value:Boolean):void
--		{
--			IPanelModel(model).showCloseButton = value;
--		}
--		
--		/**
  		 *  The items in the org.apache.flex.html.ControlBar. Setting this property automatically
  		 *  causes the ControlBar to display.
  		 *

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/RadioButton.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/RadioButton.as
index 282a9b7,9aa2254..a7dd387
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/RadioButton.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/RadioButton.as
@@@ -51,6 -51,6 +51,7 @@@ package org.apache.flex.htm
  	 *  org.apache.flex.core.IBeadModel: the data model, which includes the groupName.
  	 *  org.apache.flex.core.IBeadView:  the bead that constructs the visual parts of the RadioButton..
  	 *
++	 *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -252,7 -250,7 +253,7 @@@
              element = labelFor as WrappedHTMLElement;
  
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
  
              (element as WrappedHTMLElement).flexjs_wrapper = this;
              (textNode as WrappedHTMLElement).flexjs_wrapper = this;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/SimpleList.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/SimpleList.as
index 9dcb348,9dcb348..0d254e5
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/SimpleList.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/SimpleList.as
@@@ -21,14 -21,14 +21,15 @@@ package org.apache.flex.htm
      COMPILE::JS
      {
          import goog.events;
--        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
      }
--        
++
  	/**
  	 *  The SimpleList class is a component that displays data in a vertical column. This
--	 *  component differs from org.apache.flex.html.List in that it displays 
++	 *  component differs from org.apache.flex.html.List in that it displays
  	 *  only string values and maps to the &lt;select&gt; HTML element.
--	 *  
++	 *
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -48,7 -48,7 +49,7 @@@
  		{
  			super();
  		}
--        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           * @flexjsignorecoercion HTMLSelectElement
@@@ -61,12 -61,12 +62,12 @@@
              goog.events.listen(element, 'change',
                  changeHandler);
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              className = 'SimpleList';
--            
++
              return element;
--        }   
--        
++        }
++
          /**
           * @flexjsignorecoercion HTMLSelectElement
           */

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Slider.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Slider.as
index 151587c,d10891c..fc2889b
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Slider.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Slider.as
@@@ -23,22 -23,24 +23,23 @@@ package org.apache.flex.htm
  
      COMPILE::JS
      {
 -        import org.apache.flex.html.beads.SliderTrackView;
 -        import org.apache.flex.html.beads.SliderThumbView;
          import org.apache.flex.html.beads.controllers.SliderMouseController;
--        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
      }
  
  	[Event(name="valueChange", type="org.apache.flex.events.Event")]
--	
++
  	/**
  	 *  The Slider class is a component that displays a range of values using a
  	 *  track and a thumb control. The Slider uses the following bead types:
--	 * 
++	 *
  	 *  org.apache.flex.core.IBeadModel: the data model, typically an IRangeModel, that holds the Slider values.
  	 *  org.apache.flex.core.IBeadView:  the bead that constructs the visual parts of the Slider.
  	 *  org.apache.flex.core.IBeadController: the bead that handles input.
  	 *  org.apache.flex.core.IThumbValue: the bead responsible for the display of the thumb control.
  	 *  org.apache.flex.core.ITrackView: the bead responsible for the display of the track.
--	 *  
++	 *
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -57,16 -59,16 +58,16 @@@
  		public function Slider()
  		{
  			super();
--			
++
  			className = "Slider";
--			
++
  			IRangeModel(model).value = 0;
  			IRangeModel(model).minimum = 0;
  			IRangeModel(model).maximum = 100;
  			IRangeModel(model).stepSize = 1;
  			IRangeModel(model).snapInterval = 1;
  		}
--		
++
  		/**
  		 *  The current value of the Slider.
  		 *
@@@ -83,7 -85,7 +84,7 @@@
  		{
  			IRangeModel(model).value = newValue;
  		}
--		
++
  		/**
  		 *  The minimum value of the Slider.
  		 *
@@@ -100,7 -102,7 +101,7 @@@
  		{
  			IRangeModel(model).minimum = value;
  		}
--		
++
  		/**
  		 *  The maximum value of the Slider.
  		 *
@@@ -117,7 -119,7 +118,7 @@@
  		{
  			IRangeModel(model).maximum = value;
  		}
--		
++
  		/**
  		 *  The modulus of the Slider value. The thumb will be positioned
  		 *  at the nearest multiple of this value.
@@@ -135,7 -137,7 +136,7 @@@
  		{
  			IRangeModel(model).snapInterval = value;
  		}
--        
++
  		/**
  		 *  The amount to move the thumb when the track is selected. This value is
  		 *  adjusted to fit the nearest snapInterval.
@@@ -161,19 -172,28 +162,22 @@@
          override protected function createElement():WrappedHTMLElement
          {
              element = document.createElement('div') as WrappedHTMLElement;
 -            element.style.width = '200px';
++
++			// just to give it some default values
 +            element.style.width = '100px';
              element.style.height = '30px';
 -            
 -            track = new SliderTrackView();
 -            addBead(track);
 -            
 -            thumb = new SliderThumbView();
 -            addBead(thumb);
 -            
 -            controller = new SliderMouseController();
 -            addBead(controller);
--            
++
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
--            
++
              className = 'Slider';
--            
++
              return element;
--        } 
--        
++        }
++
          /**
++		 * @private
           */
          COMPILE::JS
          public function snap(value:Number):Number
@@@ -191,6 -211,23 +195,5 @@@
                  return n + si;
              return n;
          }
 -        
 -        
 -        /**
 -         * @param {number} value The value used to calculate new position of the thumb.
 -         * @return {void} Moves the thumb to the corresponding position.
 -         */
 -        COMPILE::JS
 -        public function setThumbFromValue(value:Number):void
 -        {
 -            var min:Number = model.minimum;
 -            var max:Number = model.maximum;
 -            var p:Number = (value - min) / (max - min);
 -            var xloc:Number = p * (parseInt(track.element.style.width, 10) -
 -                parseInt(thumb.element.style.width, 10));
 -            
 -            thumb.element.style.left = "" + xloc + 'px';
 -        }        
--
      }
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Spinner.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Spinner.as
index 65b5290,65b5290..2cc160e
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Spinner.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Spinner.as
@@@ -37,6 -37,6 +37,7 @@@ package org.apache.flex.htm
  	 *  org.apache.flex.core.IBeadView:  the bead that constructs the visual parts of the Spinner.
  	 *  org.apache.flex.core.IBeadController: a bead that handles the input events.
  	 *
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -155,7 -155,7 +156,7 @@@
          {
              element = document.createElement('div') as WrappedHTMLElement;
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
  
              element.style.verticalAlign = 'middle';
              element.flexjs_wrapper = this;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/SubAppLoader.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/SubAppLoader.as
index 0000000,0000000..6fc5d67
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/SubAppLoader.as
@@@ -1,0 -1,0 +1,137 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html
++{
++	import org.apache.flex.core.IUIBase;
++	import org.apache.flex.core.UIBase;
++	import org.apache.flex.utils.PointUtils;
++	import org.apache.flex.geom.Point;
++	import org.apache.flex.events.Event;
++	
++	COMPILE::SWF
++	{
++		import flash.display.Loader;
++		import flash.display.DisplayObjectContainer;
++		import flash.system.LoaderContext;
++		import flash.system.ApplicationDomain;
++		import flash.net.URLRequest;
++		import flash.events.Event;
++	}
++	
++    COMPILE::JS
++    {
++        import org.apache.flex.core.WrappedHTMLElement;            
++    }
++    
++    /**
++     *  The SubAppLoader class can load Flash or HTML content into a space within an application. 
++	 *  Use SubAppLoader to identify where the application should appear, then use its loadApplication() 
++	 *  function to load the application dynamically.
++	 * 
++     *  @toplevel
++     *  @see org.apache.flex.html.beads.layout
++     *  @see org.apache.flex.html.supportClasses.ScrollingViewport
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */    
++	public class SubAppLoader extends UIBase
++	{
++        /**
++         *  Constructor.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function SubAppLoader()
++		{
++			super();
++		}
++		
++		COMPILE::SWF
++		private var swfLoader:Loader;
++		
++		COMPILE::JS
++		private var htmlLoader:WrappedHTMLElement;
++		
++		/**
++		 * @private
++		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
++		 */
++		private function createLoader():void
++		{
++			COMPILE::SWF {				
++				if (swfLoader != null) {
++					removeChild(swfLoader);
++				}
++				
++				swfLoader = new Loader();
++				swfLoader.x = 0;
++				swfLoader.y = 0;
++			}
++				
++			COMPILE::JS {
++				var origin:Point = new Point(0,0);
++				var xlated:Point = PointUtils.localToGlobal(origin, parent);
++				
++				if (htmlLoader == null) {
++					htmlLoader = document.createElement('iframe') as WrappedHTMLElement;
++					htmlLoader["width"] = String(this.width);
++					htmlLoader["height"] = String(this.height);
++					htmlLoader.style.position = "absolute";
++					htmlLoader.style.left = String(xlated.x) + "px";
++					htmlLoader.style.top = String(xlated.y) + "px";
++					htmlLoader.style.backgroundColor = String("white");
++					htmlLoader.style.border = "none";
++					document.body.appendChild(htmlLoader);
++				}
++			}
++		}
++		
++		/**
++		 * Specifies the URL to load, depending on the runtime platform. Pass null for
++		 * whichever URL is not being used.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++		 */
++		public function loadApplication(swfURL:String, htmlURL:String):void
++		{
++			createLoader();
++			
++			COMPILE::SWF {
++				var url:URLRequest = new URLRequest(swfURL);
++				var loaderContext:LoaderContext = new LoaderContext(false, ApplicationDomain.currentDomain, null);
++				swfLoader.load(url, loaderContext);
++				if (swfLoader.parent == null) {
++					addChild(swfLoader);
++				}
++			}
++				
++			COMPILE::JS {
++				htmlLoader.setAttribute("src", htmlURL);
++			}
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TextArea.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TextArea.as
index 10b7555,c912dd4..2eb9c72
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TextArea.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TextArea.as
@@@ -20,25 -20,39 +20,39 @@@ package org.apache.flex.htm
  {
  	import org.apache.flex.core.ITextModel;
  	import org.apache.flex.core.UIBase;
+     import org.apache.flex.events.Event;
+ 
      COMPILE::JS
      {
-         import org.apache.flex.core.WrappedHTMLElement;            
+         import goog.events;
 -        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
      }
- 	
+ 
+     /**
+      *  Dispatched when the user changes the text.
+      *
+      *  @langversion 3.0
+      *  @playerversion Flash 10.2
+      *  @playerversion AIR 2.6
+      *  @productversion FlexJS 0.8.0
+      */
+     [Event(name="change", type="org.apache.flex.events.Event")]
+ 
      /**
       *  The TextArea class implements the basic control for
       *  multi-line text input.
--     *  
++     *
+      *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
--     */    
++     */
  	public class TextArea extends UIBase
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -47,11 -61,16 +61,16 @@@
  		public function TextArea()
  		{
  			super();
+ 
+             COMPILE::SWF
+             {
+                 model.addEventListener("textChange", textChangeHandler);
+             }
  		}
--		
++
          /**
           *  @copy org.apache.flex.html.Label#text
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -62,7 -82,7 +82,7 @@@
  		{
              COMPILE::SWF
              {
--                return ITextModel(model).text;                    
++                return ITextModel(model).text;
              }
              COMPILE::JS
              {
@@@ -83,12 -105,13 +105,13 @@@
              COMPILE::JS
              {
                  (element as HTMLInputElement).value = value;
+                 dispatchEvent(new Event('textChange'));
              }
  		}
--		
++
          /**
           *  @copy org.apache.flex.html.Label#html
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -104,9 -135,17 +135,17 @@@
           */
  		public function set html(value:String):void
  		{
- 			ITextModel(model).html = value;
+             COMPILE::SWF
+             {
+                 ITextModel(model).html = value;
+             }
+             COMPILE::JS
+             {
+                 (element as HTMLInputElement).value = value;
+                 dispatchEvent(new Event('textChange'));
+             }
  		}
--		
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
@@@ -115,12 -154,33 +154,33 @@@
          {
              element = document.createElement('textarea') as WrappedHTMLElement;
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
+ 
+             goog.events.listen(element, 'input', textChangeHandler);
 -            
++
              element.flexjs_wrapper = this;
              element.className = 'TextArea';
              typeNames = 'TextArea';
--            
++
              return element;
-         }        
+         }
+ 
+         private var inSetter:Boolean;
+ 
+         /**
+          *  dispatch change event in response to a textChange event
+          *
+          *  @langversion 3.0
+          *  @playerversion Flash 10.2
+          *  @playerversion AIR 2.6
+          *  @productversion FlexJS 0.8.0
+          */
+         public function textChangeHandler(event:Event):void
+         {
+             if (!inSetter)
+             {
+                 dispatchEvent(new Event(Event.CHANGE));
+             }
+         }
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TextInput.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TextInput.as
index c8df45d,c8df45d..0a63c95
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TextInput.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TextInput.as
@@@ -23,7 -23,7 +23,7 @@@ package org.apache.flex.htm
      COMPILE::JS
      {
          import goog.events;
--        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
      }
  
  	/**
@@@ -39,17 -39,17 +39,18 @@@
      /**
       *  The TextInput class implements the basic control for
       *  single-line text input.
--     *  
++     *
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
--     */    
++     */
  	public class TextInput extends UIBase
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -61,13 -61,13 +62,13 @@@
  
              COMPILE::SWF
              {
--                model.addEventListener("textChange", textChangeHandler);                    
++                model.addEventListener("textChange", textChangeHandler);
              }
  		}
--		
++
          /**
           *  @copy org.apache.flex.html.Label#text
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -79,7 -79,7 +80,7 @@@
  		{
              COMPILE::SWF
              {
--                return ITextModel(model).text;                    
++                return ITextModel(model).text;
              }
              COMPILE::JS
              {
@@@ -97,7 -97,7 +98,7 @@@
              {
                  inSetter = true;
                  ITextModel(model).text = value;
--                inSetter = false;                    
++                inSetter = false;
              }
              COMPILE::JS
              {
@@@ -105,22 -105,22 +106,22 @@@
                  dispatchEvent(new Event('textChange'));
              }
  		}
--		
++
          /**
           *  @copy org.apache.flex.html.Label#html
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
           *  @productversion FlexJS 0.0
           *  @flexjsignorecoercion HTMLInputElement
           */
--		[Bindable(event="change")] 
++		[Bindable(event="change")]
  		public function get html():String
  		{
              COMPILE::SWF
              {
--                return ITextModel(model).html;                    
++                return ITextModel(model).html;
              }
              COMPILE::JS
              {
@@@ -136,7 -136,7 +137,7 @@@
  		{
              COMPILE::SWF
              {
--                ITextModel(model).html = value;                    
++                ITextModel(model).html = value;
              }
              COMPILE::JS
              {
@@@ -146,7 -146,7 +147,7 @@@
  		}
  
          private var inSetter:Boolean;
--        
++
  		/**
  		 *  dispatch change event in response to a textChange event
  		 *
@@@ -160,7 -160,7 +161,7 @@@
              if (!inSetter)
                  dispatchEvent(new Event(Event.CHANGE));
  		}
--        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
@@@ -168,20 -168,20 +169,20 @@@
          override protected function createElement():WrappedHTMLElement
          {
              element = document.createElement('input') as WrappedHTMLElement;
--            element.setAttribute('type', 'input');
++            element.setAttribute('type', 'text');
              element.className = 'TextInput';
              typeNames = 'TextInput';
--            
++
              //attach input handler to dispatch flexjs change event when user write in textinput
              //goog.events.listen(element, 'change', killChangeHandler);
              goog.events.listen(element, 'input', textChangeHandler);
--            
++
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
--            
++
              return element;
--        }        
--        
++        }
++
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TitleBar.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TitleBar.as
index 3902330,3902330..2764731
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TitleBar.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TitleBar.as
@@@ -41,12 -41,12 +41,13 @@@ package org.apache.flex.htm
  	 *  org.apache.flex.core.IMeasurementBead: a bead that helps determine the size of the 
  	 *  org.apache.flex.html.TitleBar for layout.
  	 * 
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class TitleBar extends Container implements IChrome
++	public class TitleBar extends Group implements IChrome
  	{
  		/**
  		 *  constructor.
@@@ -135,11 -135,11 +136,8 @@@
              element = document.createElement('div') as WrappedHTMLElement;
              
              positioner = element;
--            positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
              
--            className = 'TitleBar';
--            
              return element;
          }        
  	}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VContainer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VContainer.as
index 92ebdca,92ebdca..13df0e8
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VContainer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VContainer.as
@@@ -38,12 -38,12 +38,13 @@@ package org.apache.flex.htm
       *  </basic:Container>
       *  </code>
       *  
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */    
--	public class VContainer extends Container implements IContainer
++	public class VContainer extends Container
  	{
          /**
           *  Constructor.

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VRule.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VRule.as
index d727f2a,89e372d..bdf05eb
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VRule.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VRule.as
@@@ -27,6 -27,6 +27,7 @@@ package org.apache.flex.htm
      /**
       *  The VRule class displays a vertical line
       *
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
@@@ -60,9 -60,9 +61,9 @@@
              element.style.borderBottom = 'none';
              element.style.borderRight = 'none';
              positioner = element;
-             positioner.style.position = 'relative';
 -           // positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
              return element;
-         }        
+         }
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionItemRendererView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionItemRendererView.as
index 2656b3a,0000000..bc9f89d
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionItemRendererView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionItemRendererView.as
@@@ -1,64 -1,0 +1,66 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads
 +{		
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.html.supportClasses.ICollapsible;
 +    
 +	/**
 +	 * This class creates and manages the contents of an AccordionItemItemRenderer
 +     *  
 +	 *  @viewbead
 +     *  @langversion 3.0
 +     *  @playerversion Flash 10.2
 +     *  @playerversion AIR 2.6
 +     *  @productversion FlexJS 0.0
 +	 */
 +	public class AccordionItemRendererView extends PanelView
 +	{
 +		/**
 +     	 *  The AccordionItemRendererView class is the default view for
 +         *  the org.apache.flex.html.supportClasses.AccordionItemRenderer classes.
 +         *  It provides some layout optimizations that can be attained by assuming
 +		 *  the strand to be an org.apache.flex.html.supportClasses.ICollapsible.
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.0
 +         */
 +		public function AccordionItemRendererView()
 +		{
 +			super();
 +		}
 +		
 +		override protected function performLayout(event:Event):void
 +		{
 +			var collapsibleStrand:ICollapsible = _strand as ICollapsible;
 +			if (!collapsibleStrand.collapsed)
 +			{
 +				super.performLayout(event);
 +			} else // skip layout for viewport children
 +			{
- 				layoutViewBeforeContentLayout();
++				COMPILE::SWF {
++				// no longer needed layoutViewBeforeContentLayout();
 +				layoutViewAfterContentLayout();
++				}
 +			}
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionView.as
index 282eb67,0000000..947da98
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionView.as
@@@ -1,90 -1,0 +1,91 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads
 +{
 +	import org.apache.flex.core.ISelectionModel;
 +	import org.apache.flex.core.IStyleableObject;
 +	import org.apache.flex.core.ValuesManager;
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.html.beads.layouts.IOneFlexibleChildLayout;
 +	import org.apache.flex.html.supportClasses.ICollapsible;
 +	import org.apache.flex.utils.StrandUtils;
 +	
 +	public class AccordionView extends ListView
 +	{
 +		private var _layout:IOneFlexibleChildLayout;
 +		public function AccordionView()
 +		{
 +			super();
 +		}
 +		
 +		override protected function selectionChangeHandler(event:Event):void
 +		{
 +			super.selectionChangeHandler(event);
 +			var renderer:IStyleableObject = dataGroup.getItemRendererForIndex(listModel.selectedIndex) as IStyleableObject;
 +			layout.flexibleChild = renderer.id;
 +		}
 +		
 +		public function get layout():IOneFlexibleChildLayout
 +		{
 +			if (!_layout)
 +			{
 +				_layout = _strand.getBeadByType(IOneFlexibleChildLayout) as IOneFlexibleChildLayout;
 +				if (!_layout) {
 +					var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout");
 +					if (c) {
 +						_layout = new c() as IOneFlexibleChildLayout;
 +					}
 +				}
 +				if (_layout)
 +				{
 +					_strand.addBead(_layout);
 +				}
 +			}
 +			return _layout;
 +		}
 +		
 +		override protected function performLayout(event:Event):void
 +		{
 +			if (layout)
 +			{
 +				if (!layout.flexibleChild)
 +				{
 +					var model:ISelectionModel = StrandUtils.loadBead(ISelectionModel, "iBeadModel", host) as ISelectionModel;
 +					if (model.selectedIndex > -1)
 +					{
 +						layout.flexibleChild = (dataGroup.getItemRendererForIndex(model.selectedIndex) as IStyleableObject).id;
 +					}
 +				}
 +				super.performLayout(event);
 +			}
 +		}
 +		
++		COMPILE::SWF
 +		override protected function itemsCreatedHandler(event:Event):void
 +		{
 +			var n:int = dataGroup.numElements;
 +			for (var i:int = 0; i < n; i++)
 +			{
 +				var child:ICollapsible = dataGroup.getItemRendererForIndex(i) as ICollapsible;
 +				child.collapse();
 +			}
 +			super.itemsCreatedHandler(event);
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/CenterElement.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/CenterElement.as
index 0000000,0000000..163679b
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/CenterElement.as
@@@ -1,0 -1,0 +1,84 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	import org.apache.flex.core.IBead;
++	import org.apache.flex.core.IChild;
++	import org.apache.flex.core.ILayoutChild;
++	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.IParent;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.IEventDispatcher;
++	
++	/**
++	 *  The CenterElement bead breaks the normal layout flow and forces
++	 *  a particlular element to stay centered.
++	 * 	  
++	 *  @viewbead
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	
++	public class CenterElement implements IBead
++	{
++		private var _strand:IStrand;
++		public function CenterElement()
++		{
++		}
++		
++		public function set strand(value:IStrand):void
++		{
++			_strand = value;
++			var layoutParent:ILayoutParent = getLayoutParent((value as IChild).parent);
++			IEventDispatcher(layoutParent).addEventListener('layoutComplete', layoutCompleteHandler);
++		}
++		
++		private function layoutCompleteHandler(e:Event):void
++		{
++			var childWidth:Number = host.width;
++			var parentWidth:Number = (host.parent as ILayoutChild).width;
++			var childHeight:Number = host.height;
++			var parentHeight:Number = (host.parent as ILayoutChild).height;
++			host.x = (parentWidth - childWidth) / 2;
++			host.y = (parentHeight - childHeight) / 2;
++		}
++		
++		private function get host():ILayoutChild
++		{
++			return _strand as ILayoutChild;
++		}
++		
++		private function getLayoutParent(value:IParent):ILayoutParent
++		{
++			while (value)
++			{
++				if (value is ILayoutParent)
++				{
++					return value as ILayoutParent;
++				}
++				value = IChild(value).parent;
++			}
++			return null;
++		}
++
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ComboBoxView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ComboBoxView.as
index 990c3ab,83c261a..3adb9de
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ComboBoxView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ComboBoxView.as
@@@ -111,35 -116,82 +111,40 @@@ package org.apache.flex.html.bead
  		override public function set strand(value:IStrand):void
  		{
  			super.strand = value;
 -        
 -			selectionModel = value.getBeadByType(IComboBoxModel) as IComboBoxModel;
 -			selectionModel.addEventListener("selectedIndexChanged", selectionChangeHandler);
 -            
 -			textInput = new TextInput();
 -			IParent(strand).addElement(textInput);
 -			textInput.width = 100;
 -			textInput.height = 18;
  			
 -			upSprite = new Sprite();
 -			drawButton( upSprite, "up", 18, 18 );
 -			overSprite = new Sprite();
 -			drawButton( overSprite, "over", 18, 18 );
 -			downSprite = new Sprite();
 -			drawButton( downSprite, "down", 18, 18 );
++			var host:UIBase = value as UIBase;
+ 			
 -			button = new Button();
 -            button.upState = upSprite;
 -            button.overState = overSprite;
 -            button.downState = downSprite;
 -			DisplayObjectContainer(strand).addChild(button);
 -			button.width = 18;
 -			button.height = 18;
 -			button.x = textInput.width;
 -			button.y = textInput.y;
 +			input = new TextInput();
- 			input.className = "ComboBoxTextInput";
- 			UIBase(host).addElement(input);
++			input.className = "ComboBoxTextInput";			
  			
 -			// listen for events on the text input and modify the list and selection
 -			textInput.addEventListener("change", textChangeHandler,false,0,true);
 -		}
 -		
 -		private var upSprite:Sprite;
 -		private var overSprite:Sprite;
 -		private var downSprite:Sprite;
 -		
 -		/**
 -		 * @private
 -		 */
 -		private function drawButton( sprite:Sprite, mode:String, width:Number, height:Number ) : void
 -		{
 -			sprite.graphics.clear();
 -			sprite.graphics.lineStyle(1,0xFFFFFF);
 -			sprite.graphics.drawRect(0, 0, width-1, height-1);
 -			sprite.graphics.lineStyle(-1);
 +			button = new TextButton();
 +			button.className = "ComboBoxButton";
 +			button.text = '\u25BC';
- 			UIBase(host).addElement(button);
+ 			
 -			if( mode == "over" ) sprite.graphics.beginFill(0xCCCCCC);
 -			else if( mode == "down" ) sprite.graphics.beginFill(0x888888);
 -			sprite.graphics.drawRect(0, 0, width-1, height-1);
 -			sprite.graphics.endFill();
++			if (isNaN(host.width)) input.width = 100;
+ 			
 -			sprite.graphics.beginFill(0x333333);
 -			sprite.graphics.moveTo(4,4);
 -			sprite.graphics.lineTo(width-4,4);
 -			sprite.graphics.lineTo(int(width/2),height-4);
 -			sprite.graphics.lineTo(4,4);
 -			sprite.graphics.endFill();
 -		}
 -		
 -		private var _popUp:IStrand;
 -		
 -		/**
 -		 *  The pop-up component that holds the selection list.
 -		 *
 -		 *  @langversion 3.0
 -		 *  @playerversion Flash 10.2
 -		 *  @playerversion AIR 2.6
 -		 *  @productversion FlexJS 0.0
 -		 */
 -		public function get popUp():IStrand
 -		{
 -			return _popUp;
++			host.addElement(input);
++			host.addElement(button);
 +			
 +			var popUpClass:Class = ValuesManager.valuesImpl.getValue(_strand, "iPopUp") as Class;
 +			list = new popUpClass() as UIBase;
 +			list.visible = false;
 +			
 +			var model:IComboBoxModel = _strand.getBeadByType(IComboBoxModel) as IComboBoxModel;
 +			model.addEventListener("selectedIndexChanged", handleItemChange);
 +			model.addEventListener("selectedItemChanged", handleItemChange);
 +			
 +			IEventDispatcher(_strand).addEventListener("sizeChanged", handleSizeChange);
 +			
 +			// set initial value and positions using default sizes
 +			handleItemChange(null);
 +			handleSizeChange(null);
  		}
  		
 -		private var _popUpVisible:Boolean;
 -		
  		/**
 -		 *  This property is true if the pop-up selection list is currently visible.
 +		 *  Returns whether or not the pop-up is visible.
 +		 * 
 +		 *  @copy org.apache.flex.html.beads.IComboBoxView#text
  		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
@@@ -153,46 -204,36 +158,61 @@@
  		}
  		public function set popUpVisible(value:Boolean):void
  		{
 -			if (value != _popUpVisible)
 -			{
 -				_popUpVisible = value;
 -				if (value)
 -				{
 -					if (!_popUp)
 -					{
 -						var popUpClass:Class = ValuesManager.valuesImpl.getValue(_strand, "iPopUp") as Class;
 -						_popUp = new popUpClass() as IStrand;
 -					}
 -					var root:Object = DisplayObject(_strand).root;
 -					var host:DisplayObjectContainer = DisplayObject(_strand).parent;
 -					while (host && !(host is IPopUpHost))
 -						host = host.parent;
 -                    if (host)
 -    					IPopUpHost(host).addElement(popUp as IChild);
 -				}
 -				else
 -				{
 -					DisplayObject(_popUp).parent.removeChild(_popUp as DisplayObject);                    
 +			if (value && !list.visible) {
 +				var model:IComboBoxModel = _strand.getBeadByType(IComboBoxModel) as IComboBoxModel;
 +				list.model = model;
 +				list.width = input.width;
++				list.height = 200;
 +				list.visible = true;
 +				
 +				var origin:Point = new Point(0, button.y+button.height);
 +				var relocated:Point = PointUtils.localToGlobal(origin,_strand);
 +				list.x = relocated.x
 +				list.y = relocated.y;
++				COMPILE::JS {
++					list.element.style.position = "absolute";
+ 				}
 +				
 +				var popupHost:IPopUpHost = UIUtils.findPopUpHost(_strand as IUIBase);
 +				popupHost.addElement(list);
 +			}
 +			else if (list.visible) {
 +				UIUtils.removePopUp(list);
 +				list.visible = false;
  			}
  		}
  		
  		/**
  		 * @private
  		 */
 -		private function selectionChangeHandler(event:Event):void
 +		private function handleSizeChange(event:Event):void
  		{
 -			text = selectionModel.selectedItem.toString();
++			var host:UIBase = UIBase(_strand);
++			
 +			input.x = 0;
 +			input.y = 0;
- 			input.width = host.width - 20;
++			if (host.isWidthSizedToContent()) {
++				input.width = 100;
++			} else {
++				input.width = host.width - 20;
++			}
 +			
 +			button.x = input.width;
 +			button.y = 0;
 +			button.width = 20;
 +			button.height = input.height;
 +			
 +			COMPILE::JS {
- 				// because the strand is a <div> it does not have a size so one is
- 				// assigned here based on the max height of the two components.
- 				var element:Object = UIBase(_strand).element;
- 				element["style"]["height"] = String(Math.max(input.height,button.height)) + "px";
++				input.element.style.position = "absolute";
++				button.element.style.position = "absolute";
++			}
++				
++			if (host.isHeightSizedToContent()) {
++				host.height = input.height;
++			}
++			if (host.isWidthSizedToContent()) {
++				host.width = input.width + button.width;
 +			}
  		}
  		
  		/**


[49/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - - Fix issue with styling in MDLExample - excluding defaults.css from Basic module

Posted by ah...@apache.org.
- Fix issue with styling in MDLExample - excluding defaults.css from Basic module


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/e0878223
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/e0878223
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/e0878223

Branch: refs/heads/develop
Commit: e0878223640105de220ec1a33ac5be70db235be9
Parents: ee1b633
Author: piotrz <pi...@apache.org>
Authored: Sun Apr 30 17:11:48 2017 +0200
Committer: piotrz <pi...@apache.org>
Committed: Sun Apr 30 17:11:48 2017 +0200

----------------------------------------------------------------------
 examples/flexjs/MDLExample/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/e0878223/examples/flexjs/MDLExample/pom.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/MDLExample/pom.xml b/examples/flexjs/MDLExample/pom.xml
index 74cfd29..c91c98a 100644
--- a/examples/flexjs/MDLExample/pom.xml
+++ b/examples/flexjs/MDLExample/pom.xml
@@ -56,7 +56,7 @@
         <configuration>
           <mainClass>App.mxml</mainClass>
           <htmlTemplate>${basedir}/target/javascript/bin/js-debug/mdl-js-index-template.html</htmlTemplate>
-          <additionalCompilerOptions>-compiler.exclude-defaults-css-files=HTML-0.8.0-SNAPSHOT.swc:defaults.css</additionalCompilerOptions>
+          <additionalCompilerOptions>-compiler.exclude-defaults-css-files=Basic-0.8.0-SNAPSHOT-js.swc:defaults.css</additionalCompilerOptions>
         </configuration>
       </plugin>
     </plugins>


[45/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - these are needed for 8377006

Posted by ah...@apache.org.
these are needed for 8377006


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/eaba9616
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/eaba9616
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/eaba9616

Branch: refs/heads/develop
Commit: eaba961619d93e045bb561da5419afe7792b93b5
Parents: e981c3d
Author: Alex Harui <ah...@apache.org>
Authored: Fri Apr 28 00:01:35 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Apr 28 00:01:35 2017 -0700

----------------------------------------------------------------------
 .../src/main/flex/org/apache/flex/core/ILayoutChild.as   |  2 ++
 .../main/flex/org/apache/flex/utils/MockLayoutChild.as   | 11 ++++++++++-
 .../main/flex/org/apache/flex/utils/MockLayoutParent.as  |  8 ++++++++
 3 files changed, 20 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/eaba9616/frameworks/projects/Core/src/main/flex/org/apache/flex/core/ILayoutChild.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/ILayoutChild.as b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/ILayoutChild.as
index da0918f..97e4561 100755
--- a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/ILayoutChild.as
+++ b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/ILayoutChild.as
@@ -68,6 +68,7 @@ package org.apache.flex.core
          *  @productversion FlexJS 0.0
          */
         function get explicitWidth():Number;
+        function set explicitWidth(value:Number):void;
         
         /**
          *  The height of this component 
@@ -79,6 +80,7 @@ package org.apache.flex.core
          *  @productversion FlexJS 0.0
          */
         function get explicitHeight():Number;
+        function set explicitHeight(value:Number):void;
         
         /**
          * Sets the height of the component without

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/eaba9616/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutChild.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutChild.as b/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutChild.as
index a8a719d..0dc4f98 100644
--- a/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutChild.as
+++ b/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutChild.as
@@ -74,6 +74,11 @@ package org.apache.flex.utils
 			return _explicitHeight;
 		}
 		
+		public function set explicitHeight(value:Number):void
+		{
+			_explicitHeight = value;
+		}
+		
 		public function isHeightSizedToContent():Boolean
 		{
 			return _isHeightSizedToContent;
@@ -129,7 +134,11 @@ package org.apache.flex.utils
 		{
 			return _explicitWidth;
 		}
-		
+		public function set explicitWidth(value:Number):void
+		{
+			_explicitWidth = value;
+		}
+
 		public function isWidthSizedToContent():Boolean
 		{
 			return _isWidthSizedToContent;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/eaba9616/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutParent.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutParent.as b/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutParent.as
index 1da2b5a..a07a1d4 100644
--- a/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutParent.as
+++ b/frameworks/projects/Effects/src/main/flex/org/apache/flex/utils/MockLayoutParent.as
@@ -182,12 +182,20 @@ package org.apache.flex.utils
 			// TODO Auto Generated method stub
 			return 0;
 		}
+		public function set explicitHeight(value:Number):void
+		{
+			// TODO Auto Generated method stub
+		}
 
 		public function get explicitWidth():Number
 		{
 			// TODO Auto Generated method stub
 			return 0;
 		}
+		public function set explicitWidth(value:Number):void
+		{
+			// TODO Auto Generated method stub
+		}
 
 		public function isHeightSizedToContent():Boolean
 		{


[16/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual

Posted by ah...@apache.org.
Merge branch 'develop' into dual

Conflicts:
	examples/flexjs/MobileTrader/build.xml
	frameworks/projects/HTML/src/main/flex/HTMLClasses.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/DataGrid.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/DateField.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/ContainerView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataGridView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
	frameworks/projects/HTML/src/main/resources/basic-manifest.xml


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/1691921e
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/1691921e
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/1691921e

Branch: refs/heads/develop
Commit: 1691921e7caa62fbfd7985bd1206462d1df976c5
Parents: 358a06f b1ba88e
Author: Alex Harui <ah...@apache.org>
Authored: Tue Apr 18 23:20:18 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Tue Apr 18 23:20:18 2017 -0700

----------------------------------------------------------------------
 examples/flexjs/MobileTrader/build.xml          |   35 +-
 .../src/main/flex/MobileTrader.mxml             |    3 +
 .../src/main/flex/MyInitialView.mxml            |  135 ++-
 .../flex/controller/DataModelChangeNotifier.as  |   71 ++
 .../src/main/flex/views/AlertsView.mxml         |   23 +-
 .../src/main/flex/views/AssetsView.mxml         |   21 +-
 .../src/main/flex/views/WatchListView.mxml      |   24 +-
 .../Basic/src/main/flex/BasicClasses.as         |    2 +-
 .../main/flex/org/apache/flex/core/GroupBase.as |   16 +
 .../flex/org/apache/flex/core/LayoutBase.as     |  118 ++
 .../main/flex/org/apache/flex/html/DataGrid.as  |   24 +-
 .../main/flex/org/apache/flex/html/DateField.as |   23 +
 .../html/beads/AccordionItemRendererView.as     |    2 +-
 .../org/apache/flex/html/beads/ContainerView.as |   46 +-
 .../apache/flex/html/beads/DataContainerView.as |   25 +-
 .../org/apache/flex/html/beads/DataGridView.as  |    2 +-
 .../org/apache/flex/html/beads/GroupView.as     |  135 +--
 .../flex/html/beads/layouts/ButtonBarLayout.as  |   65 +-
 .../html/beads/layouts/HorizontalFlexLayout.as  |    1 +
 .../html/beads/layouts/VerticalFlexLayout.as    |    1 +
 .../html/supportClasses/MXMLItemRenderer.as     |   10 +
 .../supportClasses/TextButtonItemRenderer.as    |  244 +++++
 .../Basic/src/main/resources/basic-manifest.xml |    2 +-
 .../Basic/src/main/resources/defaults.css       | 1035 ++++++++++--------
 .../org/apache/flex/charts/beads/ChartView.as   |   28 +-
 .../flex/charts/beads/layouts/BarChartLayout.as |    6 +-
 .../beads/layouts/BarChartLayoutForArrayList.as |    8 +-
 .../charts/beads/layouts/ChartBaseLayout.as     |   25 +-
 .../charts/beads/layouts/ColumnChartLayout.as   |    6 +-
 .../layouts/ColumnChartLayoutForArrayList.as    |    6 +-
 .../layouts/LineChartCategoryVsLinearLayout.as  |    6 +-
 .../layouts/LineChartLinearVsLinearLayout.as    |    6 +-
 .../flex/charts/beads/layouts/PieChartLayout.as |    6 +-
 .../beads/layouts/PieChartLayoutForArrayList.as |    6 +-
 .../beads/layouts/StackedBarChartLayout.as      |    6 +-
 .../StackedBarChartLayoutForArrayList.as        |    6 +-
 .../beads/layouts/StackedColumnChartLayout.as   |    6 +-
 .../StackedColumnChartLayoutForArrayList.as     |    6 +-
 .../flex/org/apache/flex/core/ILayoutHost.as    |   20 +
 .../org/apache/flex/utils/MockLayoutHost.as     |   10 +
 .../org/apache/flex/utils/MockLayoutParent.as   |   10 +
 .../Express/src/main/resources/defaults.css     |    9 +-
 .../src/main/resources/express-manifest.xml     |    1 +
 .../Flat/src/main/resources/defaults.css        |    2 +-
 .../src/main/flex/FormattersClasses.as          |    3 +
 .../html/accessories/DateFormatDDMMYYYYBead.as  |   46 +
 .../html/accessories/DateFormatMMDDYYYYBead.as  |  129 +--
 .../html/accessories/DateFormatYYYYMMDDBead.as  |   46 +
 .../html/accessories/SimpleDateFormatBead.as    |  222 ++++
 .../HTML/src/main/resources/basic-manifest.xml  |    2 -
 .../HTML/src/main/resources/defaults.css        |   15 +-
 .../apache/flex/mobile/StackedViewManager.as    |   29 +-
 .../org/apache/flex/mobile/TabbedViewManager.as |   10 +
 .../flex/org/apache/flex/mobile/TitleView.as    |    4 -
 .../org/apache/flex/mobile/ViewManagerBase.as   |   56 +-
 .../flex/mobile/beads/StackedViewManagerView.as |  147 ++-
 .../flex/mobile/beads/TabbedViewManagerView.as  |  127 ++-
 .../flex/mobile/beads/ViewManagerViewBase.as    |  139 +--
 .../Mobile/src/main/resources/defaults.css      |   30 +
 .../Network/src/main/flex/NetworkClasses.as     |    4 +-
 .../flex/org/apache/flex/net/BinaryUploader.as  |   16 +-
 .../flex/org/apache/flex/net/HTTPConstants.as   |   30 +-
 .../main/flex/org/apache/flex/net/HTTPHeader.as |   23 +-
 .../flex/org/apache/flex/net/HTTPService.as     |    9 +-
 .../main/flex/org/apache/flex/net/HTTPUtils.as  |   19 +-
 .../flex/org/apache/flex/net/URLBinaryLoader.as |    8 +-
 .../main/flex/org/apache/flex/net/URLRequest.as |   32 +-
 .../org/apache/flex/net/URLRequestHeader.as     |    9 +-
 .../main/flex/org/apache/flex/net/URLStream.as  |  137 ++-
 .../flex/net/beads/CORSCredentialsBead.as       |   96 ++
 .../src/main/resources/basic-manifest.xml       |    1 +
 71 files changed, 2369 insertions(+), 1262 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/examples/flexjs/MobileTrader/build.xml
----------------------------------------------------------------------
diff --cc examples/flexjs/MobileTrader/build.xml
index e331b36,81fd570..c34f553
--- a/examples/flexjs/MobileTrader/build.xml
+++ b/examples/flexjs/MobileTrader/build.xml
@@@ -29,7 -29,41 +29,40 @@@
      
      <include file="${basedir}/../../build_example.xml" />
  
-     <target name="main" depends="clean,build_example.compile" description="Clean build of ${example}">
+     <condition property="extlib_arg" value="-external-library-path=${FLEXJS_HOME}/js/libs/js.swc" >
+         <and>
+             <not>
+                 <isset property="extlib_arg" />
+             </not>
+             <available file="${FLEXJS_HOME}/js/libs/js.swc" type="file" />
+         </and>
+     </condition>
+     <condition property="extlib_arg" value="-external-library-path=${FALCONJX_HOME}/../js/libs/js.swc" >
+         <and>
+             <not>
+                 <isset property="extlib_arg" />
+             </not>
+             <available file="${FALCONJX_HOME}/../js/libs/js.swc" type="file" />
+         </and>
+     </condition>
+     <property name="extlib_arg" value="-external-library-path=${FALCONJX_HOME}/../externs/js/out/bin/js.swc"/>
+ 
 -    <target name="main" depends="clean,build_example.compile,build_example.compilejs,copyassets" description="Clean build of ${example}">
++    <target name="main" depends="clean,build_example.compile,copyassets" description="Clean build of ${example}">
+     </target>
+     
+     <target name="copyassets">
+     	<mkdir dir="${basedir}/bin/js-debug/assets" />
+     	<copy todir="${basedir}/bin/js-debug/assets" >
+             <fileset dir="${basedir}/src/main/resources/assets">
+                 <include name="**" />
+             </fileset>
+         </copy>
+         <mkdir dir="${basedir}/bin/js-release/assets" />
+         <copy todir="${basedir}/bin/js-release/assets" >
+             <fileset dir="${basedir}/src/main/resources/assets">
+                 <include name="**" />
+             </fileset>
+         </copy>
      </target>
      
      <target name="clean">

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/BasicClasses.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/BasicClasses.as
index d709608,a81838b..07bb731
--- a/frameworks/projects/Basic/src/main/flex/BasicClasses.as
+++ b/frameworks/projects/Basic/src/main/flex/BasicClasses.as
@@@ -161,7 -152,7 +161,7 @@@ internal class BasicClasse
  	import org.apache.flex.html.supportClasses.DataGroup; DataGroup;
  	import org.apache.flex.html.supportClasses.Viewport; Viewport;
  	import org.apache.flex.html.supportClasses.ScrollingViewport; ScrollingViewport;
--	import org.apache.flex.html.supportClasses.DataGridButtonBarButtonItemRenderer; DataGridButtonBarButtonItemRenderer;
++	import org.apache.flex.html.supportClasses.TextButtonItemRenderer; TextButtonItemRenderer;
  
  	import org.apache.flex.html.DataGridButtonBarTextButton; DataGridButtonBarTextButton;
  	import org.apache.flex.html.DataGridButtonBar; DataGridButtonBar;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/GroupBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/GroupBase.as
index e4dfb1f,0000000..07859a1
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/GroupBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/GroupBase.as
@@@ -1,280 -1,0 +1,296 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.core
 +{
 +	import org.apache.flex.core.IContentViewHost;
 +	import org.apache.flex.core.ILayoutParent;
 +	import org.apache.flex.core.ILayoutHost;
 +	import org.apache.flex.core.ILayoutView;
 +	import org.apache.flex.core.ValuesManager;
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.events.ValueChangeEvent;
 +	import org.apache.flex.states.State;
 +	import org.apache.flex.utils.MXMLDataInterpreter;
 +
 +    /**
 +     *  Indicates that the state change has completed.  All properties
 +     *  that need to change have been changed, and all transitinos
 +     *  that need to run have completed.  However, any deferred work
 +     *  may not be completed, and the screen may not be updated until
 +     *  code stops executing.
 +     *  
 +     *  @langversion 3.0
 +     *  @playerversion Flash 10.2
 +     *  @playerversion AIR 2.6
 +     *  @productversion FlexJS 0.8
 +     */
 +    [Event(name="stateChangeComplete", type="org.apache.flex.events.Event")]
 +    
 +    /**
 +     *  Indicates that the initialization of the container is complete.
 +     *  
 +     *  @langversion 3.0
 +     *  @playerversion Flash 10.2
 +     *  @playerversion AIR 2.6
 +     *  @productversion FlexJS 0.8
 +     */
 +    [Event(name="initComplete", type="org.apache.flex.events.Event")]
 +    
 +    /**
 +     *  Indicates that the children of the container is have been added.
 +     *  
 +     *  @langversion 3.0
 +     *  @playerversion Flash 10.2
 +     *  @playerversion AIR 2.6
 +     *  @productversion FlexJS 0.8
 +     */
 +    [Event(name="childrenAdded", type="org.apache.flex.events.Event")]
 +    
 +    /**
 +     *  The GroupBase class is the base class for most simple containers
 +     *  in FlexJS.  It is usable as the root tag of MXML
 +     *  documents and UI controls and containers are added to it.
 +     *  
 +     *  @langversion 3.0
 +     *  @playerversion Flash 10.2
 +     *  @playerversion AIR 2.6
 +     *  @productversion FlexJS 0.8
 +     */
 +	public class GroupBase extends UIBase implements IStatesObject, IContainer, ILayoutParent, ILayoutView, IContentViewHost
 +	{
 +        /**
 +         *  Constructor.
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +         */
 +		public function GroupBase()
 +		{
 +			super();            
 +		}
 +		
 +		/**
 +		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
 +		 */
 +		COMPILE::JS
 +		override protected function createElement():WrappedHTMLElement
 +		{
 +			element = document.createElement('div') as WrappedHTMLElement;
 +			element.flexjs_wrapper = this;
 +			
 +			positioner = element;
 +			
 +			return element;
 +		}
 +		
++		override public function addedToParent():void
++		{
++			super.addedToParent();
++			
++			// Load the layout bead if it hasn't already been loaded.
++			var layout:IBeadLayout = getBeadByType(IBeadLayout) as IBeadLayout;
++			if (!layout)
++			{
++				var c:Class = ValuesManager.valuesImpl.getValue(this, "iBeadLayout") as Class;
++				if (c) {
++					layout = new c() as IBeadLayout;
++					addBead(layout);
++				}
++			}
++		}
++		
 +		/*
 +		 * IContainer
 +		 */
 +        
 +        /**
 +         *  @private
 +         */
 +        public function childrenAdded():void
 +        {
 +            dispatchEvent(new Event("childrenAdded"));
 +        }
 +		
 +		/*
 +		 * Utility
 +		 */
 +		
 +		/**
 +		 * Dispatches a "layoutNeeded" event
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +		 */
 +		public function layoutNeeded():void
 +		{
 +			dispatchEvent( new Event("layoutNeeded") );
 +		}
 +		
 +		/*
 +		 * ILayoutParent
 +		 */
 +		
 +		/**
 +		 * Returns the ILayoutHost which is its view. From ILayoutParent.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function getLayoutHost():ILayoutHost
 +		{
 +			return view as ILayoutHost;
 +		}
 +		
 +		/**
 +		 * @copy org.apache.flex.core.IContentViewHost#strandChildren
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +		 */
 +		public function get strandChildren():IParent
 +		{
 +			return this;
 +		}
 +		
 +        private var _states:Array;
 +        
 +        /**
 +         *  The array of view states. These should
 +         *  be instances of org.apache.flex.states.State.
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +         */
 +        public function get states():Array
 +        {
 +            return _states;
 +        }
 +
 +        /**
 +         *  @private
 +         *  @flexjsignorecoercion Class
 +         *  @flexjsignorecoercion org.apache.flex.core.IBead
 +         */
 +        public function set states(value:Array):void
 +        {
 +            _states = value;
 +            _currentState = _states[0].name;
 +            
 +			try{
 +				if (getBeadByType(IStatesImpl) == null)
 +                {
 +                    var c:Class = ValuesManager.valuesImpl.getValue(this, "iStatesImpl") as Class;
 +                    var b:Object = new c();
 +					addBead(b as IBead);
 +                }
 +			}
 +			//TODO:  Need to handle this case more gracefully
 +			catch(e:Error)
 +			{
 +                COMPILE::SWF
 +                {
 +                    trace(e.message);                        
 +                }
 +			}
 +            
 +        }
 +        
 +        /**
 +         *  <code>true</code> if the array of states
 +         *  contains a state with this name.
 +         * 
 +         *  @param state The state namem.
 +         *  @return True if state in state array
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +         */
 +        public function hasState(state:String):Boolean
 +        {
 +            for each (var s:State in _states)
 +            {
 +                if (s.name == state)
 +                    return true;
 +            }
 +            return false;
 +        }
 +        
 +        private var _currentState:String;
 +        
 +        [Bindable("currentStateChange")]
 +        /**
 +         *  The name of the current state.
 +         * 
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +         */
 +        public function get currentState():String
 +        {
 +            return _currentState;   
 +        }
 +
 +        /**
 +         *  @private
 +         */
 +        public function set currentState(value:String):void
 +        {
 +            var event:ValueChangeEvent = new ValueChangeEvent("currentStateChange", false, false, _currentState, value)
 +            _currentState = value;
 +            dispatchEvent(event);
 +        }
 +        
 +        private var _transitions:Array;
 +        
 +        /**
 +         *  The array of transitions.
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +         */
 +        public function get transitions():Array
 +        {
 +            return _transitions;   
 +        }
 +        
 +        /**
 +         *  @private
 +         */
 +        public function set transitions(value:Array):void
 +        {
 +            _transitions = value;   
 +        }
 +
 +    }
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
index dde6448,0000000..f23f035
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
@@@ -1,166 -1,0 +1,284 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.core
 +{
 +
 +	import org.apache.flex.core.IBeadLayout;
 +	import org.apache.flex.core.ILayoutChild;
 +	import org.apache.flex.core.ILayoutHost;
 +	import org.apache.flex.core.ILayoutParent;
 +	import org.apache.flex.core.ILayoutView;
 +	import org.apache.flex.core.IParent;
 +	import org.apache.flex.core.IStrand;
 +	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.events.Event;
 +    import org.apache.flex.utils.CSSUtils;
 +
 +    /**
 +     *  This class is the base class for most, if not all, layouts. 
 +     *
 +     *  @langversion 3.0
 +     *  @playerversion Flash 10.2
 +     *  @playerversion AIR 2.6
 +     *  @productversion FlexJS 0.8
 +     */
 +	public class LayoutBase implements IBeadLayout
 +	{
 +        /**
 +         *  Constructor.
 +         *
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +         */
 +		public function LayoutBase()
 +		{
 +		}
 +
 +        /**
 +		 * The strand/host container is also an ILayoutChild because
 +         * it can have its size dictated by the host's parent which is
 +         * important to know for layout optimization.
 +         *
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +		 */
 +        protected var host:ILayoutChild;
 +
 +        /**
 +         *  @copy org.apache.flex.core.IBead#strand
 +         *
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +		 * 
 +		 * @flexjsignorecoercion org.apache.flex.core.ILayoutChild
 +         */
 +		public function set strand(value:IStrand):void
 +		{
 +            host = value as ILayoutChild;
++			
++			IEventDispatcher(host).addEventListener("widthChanged", handleSizeChange);
++			IEventDispatcher(host).addEventListener("heightChanged", handleSizeChange);
++			IEventDispatcher(host).addEventListener("sizeChanged", handleSizeChange);
++			
++			IEventDispatcher(host).addEventListener("childrenAdded", handleChildrenAdded);
++			IEventDispatcher(host).addEventListener("initComplete", handleInitComplete);
++			
++			IEventDispatcher(host).addEventListener("layoutNeeded", handleLayoutNeeded);
++		}
++		
++		/**
++		 * Changes in size to the host strand are handled (by default) by running the
++		 * layout sequence. Subclasses can override this function and use event.type
++		 * to handle specific changes in dimension.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		protected function handleSizeChange(event:Event):void
++		{
++			performLayout();
++		}
++		
++		/**
++		 * Handles the addition of children to the host's layoutView by listening for
++		 * size changes in the children.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		protected function handleChildrenAdded(event:Event):void
++		{
++			COMPILE::SWF {
++				var n:Number = layoutView.numElements;
++				for(var i:int=0; i < n; i++) {
++					var child:IEventDispatcher = layoutView.getElementAt(i) as IEventDispatcher;
++					child.addEventListener("widthChanged", childResizeHandler);
++					child.addEventListener("heightChanged", childResizeHandler);
++					child.addEventListener("sizeChanged", childResizeHandler);
++				}
++			}
++		}
++		
++		/**
++		 * If changes happen to a layoutView's child, this function will perform the
++		 * layout again.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		protected function childResizeHandler(event:Event):void
++		{
++			performLayout();
++		}
++		
++		/**
++		 * Called whenever "layoutNeeded" event is dispatched against the host strand.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		protected function handleLayoutNeeded(event:Event):void
++		{
++			performLayout();
++		}
++		
++		/**
++		 * Handles the final start-up condition by running the layout an initial time.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		protected function handleInitComplete(event:Event):void
++		{
++			performLayout();
 +		}
 +		
 +		/**
 +		 * Returns an object of margins for the given child.
 +		 * 
 +		 * @param child Object The element whose margins are required.
 +		 * @param hostWidth Number The usable width dimension of the host.
 +		 * @param hostHeight Number The usable height dimension of the host.
 +		 * 
 +		 * @return Object A structure of {top:Number, left:Number, bottom:Number, right:Number}
 +         *
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +		 */
 +		protected function childMargins(child:Object, hostWidth:Number, hostHeight:Number):Object
 +		{
 +			var margin:Object = ValuesManager.valuesImpl.getValue(child, "margin");
 +			var marginLeft:Object = ValuesManager.valuesImpl.getValue(child, "margin-left");
 +			var marginTop:Object = ValuesManager.valuesImpl.getValue(child, "margin-top");
 +			var marginRight:Object = ValuesManager.valuesImpl.getValue(child, "margin-right");
 +			var marginBottom:Object = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
 +			var ml:Number = CSSUtils.getLeftValue(marginLeft, margin, hostWidth);
 +			var mr:Number = CSSUtils.getRightValue(marginRight, margin, hostWidth);
 +			var mt:Number = CSSUtils.getTopValue(marginTop, margin, hostHeight);
 +			var mb:Number = CSSUtils.getBottomValue(marginBottom, margin, hostHeight);
 +			if (marginLeft == "auto")
 +				ml = 0;
 +			if (marginRight == "auto")
 +				mr = 0;
 +			
 +			return {left:ml, top:mt, right:mr, bottom:mb};
 +		}
 +		
 +		/**
 +		 * Returns an object containing the child's positioning values.
 +		 * 
 +		 * @param child Object The element whose positions are required.
 +		 * 
 +		 * @return Object A structure of {top:Number, left:Number, bottom:Number, right:Number}
 +         *
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +		 */
 +		protected function childPositions(child:Object):Object
 +		{
 +			var left:Number = ValuesManager.valuesImpl.getValue(child, "left");
 +			var right:Number = ValuesManager.valuesImpl.getValue(child, "right");
 +			var top:Number = ValuesManager.valuesImpl.getValue(child, "top");
 +			var bottom:Number = ValuesManager.valuesImpl.getValue(child, "bottom");
 +			
 +			return {top:top, left:left, bottom:bottom, right:right};
 +		}
 +		
 +		/**
 +		 * Returns the ILayoutView for the host.
 +         *
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +		 * 
 +		 * @flexjsignorecoercion org.apache.flex.core.ILayoutParent
 +		 */
 +		protected function get layoutView():ILayoutView
 +		{
 +			var viewBead:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 +			return viewBead.contentView;
 +		}
++		
++		private var isLayoutRunning:Boolean = false;
++		
++		/**
++		 * Performs the layout in three parts: before, layout, after.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		public function performLayout():void
++		{
++			// avoid running this layout instance recursively.
++			if (isLayoutRunning) return;
++			
++			isLayoutRunning = true;
++			
++			var viewBead:ILayoutHost = (host as ILayoutParent).getLayoutHost();
++			
++			viewBead.beforeLayout();
++			
++			if (layout()) {
++				viewBead.afterLayout();
++			}
++			
++			isLayoutRunning = false;
++			
++			IEventDispatcher(host).dispatchEvent(new Event("layoutComplete"));
++		}
 +
 +        /**
 +         * @copy org.apache.flex.core.IBeadLayout#layout
 +         *
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +         */
 +		public function layout():Boolean
 +		{
 +            // override in subclass
 +			return false;
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataGrid.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataGrid.as
index fda1b46,c271134..5a17c4a
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataGrid.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataGrid.as
@@@ -22,8 -22,7 +22,10 @@@ package org.apache.flex.htm
  	import org.apache.flex.core.IDataGridModel;
  	import org.apache.flex.core.IDataGridPresentationModel;
  	import org.apache.flex.core.UIBase;
++	import org.apache.flex.core.GroupBase;
 +	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.html.beads.models.DataGridPresentationModel;
++	import org.apache.flex.events.Event;
  	
  	[Event(name="change", type="org.apache.flex.events.Event")]
  	
@@@ -41,7 -39,7 +43,7 @@@
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
- 	public class DataGrid extends Group
 -	public class DataGrid extends UIBase
++	public class DataGrid extends GroupBase
  	{
  		/**
  		 *  constructor.
@@@ -160,24 -143,24 +162,10 @@@
  			presentationModel.rowHeight = value;
  		}
  		
--		/**
--		 * @private
--		 * The DataGrid needs to know whenever its size is being changed so the columns can be
--		 * be aligned properly, so the noEvent value must always be false.
--		 */
--		override public function setWidth(value:Number, noEvent:Boolean=false):void
--		{
--			super.setWidth(value,false);
--		}
--		
--		/**
--		 * @private
--		 * The DataGrid needs to know whenever its size is being changed so the columns can be
--		 * be aligned properly, so the noEvent value must always be false.
--		 */
--		override public function setHeight(value:Number, noEvent:Boolean=false):void
++		override public function addedToParent():void
  		{
--			super.setHeight(value,false);
++			super.addedToParent();
++			dispatchEvent(new Event("initComplete"));
  		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateField.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateField.as
index f46e453,ca142ba..5b73db0
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateField.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateField.as
@@@ -33,6 -34,6 +34,7 @@@ package org.apache.flex.htm
  	 * and a pop-up calendar control for picking a date as an alternative to
  	 * the text field.
  	 *  
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionItemRendererView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionItemRendererView.as
index bc9f89d,0000000..85e2b79
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionItemRendererView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/AccordionItemRendererView.as
@@@ -1,66 -1,0 +1,66 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads
 +{		
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.html.supportClasses.ICollapsible;
 +    
 +	/**
 +	 * This class creates and manages the contents of an AccordionItemItemRenderer
 +     *  
 +	 *  @viewbead
 +     *  @langversion 3.0
 +     *  @playerversion Flash 10.2
 +     *  @playerversion AIR 2.6
 +     *  @productversion FlexJS 0.0
 +	 */
 +	public class AccordionItemRendererView extends PanelView
 +	{
 +		/**
 +     	 *  The AccordionItemRendererView class is the default view for
 +         *  the org.apache.flex.html.supportClasses.AccordionItemRenderer classes.
 +         *  It provides some layout optimizations that can be attained by assuming
 +		 *  the strand to be an org.apache.flex.html.supportClasses.ICollapsible.
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.0
 +         */
 +		public function AccordionItemRendererView()
 +		{
 +			super();
 +		}
 +		
 +		override protected function performLayout(event:Event):void
 +		{
 +			var collapsibleStrand:ICollapsible = _strand as ICollapsible;
 +			if (!collapsibleStrand.collapsed)
 +			{
 +				super.performLayout(event);
 +			} else // skip layout for viewport children
 +			{
 +				COMPILE::SWF {
 +				// no longer needed layoutViewBeforeContentLayout();
- 				layoutViewAfterContentLayout();
++				afterLayout();
 +				}
 +			}
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ContainerView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ContainerView.as
index 4de5634,d62e799..ac723a9
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ContainerView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ContainerView.as
@@@ -160,15 -274,49 +160,15 @@@ package org.apache.flex.html.bead
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
 -		protected function completeSetup():void
 +		override protected function completeSetup():void
  		{
 +			super.completeSetup();
 +
  			// when the first layout is complete, set up listeners for changes
  			// to the childrens' sizes.
--			host.addEventListener("layoutComplete", childrenChangedHandler);
 -			
 -			host.addEventListener("childrenAdded", performLayout);
 -			host.addEventListener("layoutNeeded", performLayout);
 -			host.addEventListener("widthChanged", resizeHandler);
 -			host.addEventListener("heightChanged", resizeHandler);
 -			host.addEventListener("sizeChanged", resizeHandler);
 -			host.addEventListener("viewCreated", viewCreatedHandler);
 -		}
 -		
 -		/**
 -		 * Handles the viewCreated event by performing the first layout if
 -		 * there are children already present (ie, from MXML).
 -		 *  
 -		 *  @langversion 3.0
 -		 *  @playerversion Flash 10.2
 -		 *  @playerversion AIR 2.6
 -		 *  @productversion FlexJS 0.0
 -		 */
 -		protected function viewCreatedHandler(event:Event):void
 -		{			
 -			if ((host as UIBase).numElements > 0) {
 -				performLayout(null);
 -			}
++//			host.addEventListener("layoutComplete", childrenChangedHandler);
  		}
 -		
 -        /**
 -         * Calculate the space taken up by non-content children like a TItleBar in a Panel.
 -         *  
 -         *  @langversion 3.0
 -         *  @playerversion Flash 10.2
 -         *  @playerversion AIR 2.6
 -         *  @productversion FlexJS 0.0
 -         */
 -        protected function getChromeMetrics():Rectangle
 -        {
 -            return new Rectangle(0, 0, 0, 0);
 -        }
 -        
 +
  		/**
  		 * Creates the Viewport (or ScrollableViewport) through which the content
  		 * area is presented.
@@@ -229,22 -391,32 +229,22 @@@
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
- 		override protected function layoutViewBeforeContentLayout():void
 -		protected function performLayout(event:Event):void
++		override public function beforeLayout():void
  		{
 -			layoutRunning = true;
 -			
 -			layoutViewBeforeContentLayout();
 -			
 -			var host:UIBase = _strand as UIBase;
 -			
 -			var layout:IBeadLayout = _strand.getBeadByType(IBeadLayout) as IBeadLayout;
 -			if (layout == null) {
 -				var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout");
 -				if (c) {
 -					layout = new c() as IBeadLayout;
 -					_strand.addBead(layout);
 -				}
 -			}
 -			
 -			if (layout) {
 -				layout.layout();
 -			}
 -			
 -			layoutViewAfterContentLayout();
 -			
 -			layoutRunning = false;
 +            var host:ILayoutChild = this.host as ILayoutChild;
 +            var vm:IViewportModel = viewportModel;
 +			var hostWidth:Number = host.width;
 +			var hostHeight:Number = host.height;
 +
 +            vm.borderMetrics = CSSContainerUtils.getBorderMetrics(host);
 +
 +            viewport.setPosition(vm.borderMetrics.left, vm.borderMetrics.top);
 +
 +			viewport.layoutViewportBeforeContentLayout(
 +				host.isWidthSizedToContent() ? NaN : hostWidth - vm.borderMetrics.left - vm.borderMetrics.right,
 +				host.isHeightSizedToContent() ? NaN : hostHeight - vm.borderMetrics.top - vm.borderMetrics.bottom);
  		}
 -		
 +
  		/**
  		 * @private
  		 */
@@@ -259,20 -431,35 +259,20 @@@
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
- 		override protected function layoutViewAfterContentLayout():void
 -		protected function layoutViewAfterContentLayout():void
++		override public function afterLayout():void
  		{
 -			var host:UIBase = _strand as UIBase;
 -            var vm:IViewportModel = viewportModel;
 -            
 +			if (adjusting) return;
 +
  			adjusting = true;
 -			
 -            var viewportSize:Size = viewport.layoutViewportAfterContentLayout();
 -            
 -			if (host.isWidthSizedToContent() && host.isHeightSizedToContent()) {					
 -				host.setWidthAndHeight(viewportSize.width + vm.borderMetrics.left + vm.borderMetrics.right +
 -                                           vm.chromeMetrics.left + vm.chromeMetrics.right, 
 -					                   viewportSize.height + vm.borderMetrics.top + vm.borderMetrics.bottom +
 -                                           vm.chromeMetrics.top + vm.chromeMetrics.bottom,
 -                                       false);
 -			}
 -			else if (!host.isWidthSizedToContent() && host.isHeightSizedToContent())
 -			{
 -				host.setHeight(viewportSize.height + vm.borderMetrics.top + vm.borderMetrics.bottom +
 -                    vm.chromeMetrics.top + vm.chromeMetrics.bottom, false);
 -			}
 -			else if (host.isWidthSizedToContent() && !host.isHeightSizedToContent())
 -			{
 -				host.setWidth(viewportSize.width + vm.borderMetrics.left + vm.borderMetrics.right +
 -                    vm.chromeMetrics.left + vm.chromeMetrics.right, false);
 -			}			
 +
- 			super.layoutViewAfterContentLayout();
++			super.afterLayout();
 +
 +			var contentSize:Size = calculateContentSize();
 +			viewport.layoutViewportAfterContentLayout(contentSize);
 +
  			adjusting = false;
  		}
 -		
 +
  		/**
  		 * Handles dynamic changes to the host's size by running the layout once
  		 * the viewport has been adjusted.
@@@ -282,54 -469,11 +282,54 @@@
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
- 		override protected function resizeHandler(event:Event):void
- 		{
- 			if (!adjusting) {
- 				performLayout(event);
- 			}
- 		}
 -		protected function resizeHandler(event:Event):void
++//		override protected function resizeHandler(event:Event):void
++//		{
++//			if (!adjusting) {
++//				performLayout(event);
++//			}
++//		}
 +
 +		/**
 +		 * Whenever children are added, listeners are added to detect changes
 +		 * in their size.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
- 		protected function childrenChangedHandler(event:Event):void
- 		{
- 			var host:UIBase = _strand as UIBase;
- 			host.removeEventListener(event.type, childrenChangedHandler);
- 
- 			var n:Number = contentView.numElements;
- 			for (var i:int=0; i < n; i++) {
- 				var child:IUIBase = contentView.getElementAt(i) as IUIBase;
- 				child.addEventListener("widthChanged", childResizeHandler);
- 				child.addEventListener("heightChanged", childResizeHandler);
- 				child.addEventListener("sizeChanged", childResizeHandler);
- 			}
- 		}
++//		protected function childrenChangedHandler(event:Event):void
++//		{
++//			var host:UIBase = _strand as UIBase;
++//			host.removeEventListener(event.type, childrenChangedHandler);
++//
++//			var n:Number = contentView.numElements;
++//			for (var i:int=0; i < n; i++) {
++//				var child:IUIBase = contentView.getElementAt(i) as IUIBase;
++//				child.addEventListener("widthChanged", childResizeHandler);
++//				child.addEventListener("heightChanged", childResizeHandler);
++//				child.addEventListener("sizeChanged", childResizeHandler);
++//			}
++//		}
 +	}
 +
 +	COMPILE::JS
 +	public class ContainerView extends GroupView //??implements IParent
 +	{
 +		private var _viewport:IViewport;
 +
 +		/**
 +		 * The viewport used to present the content and may display
 +		 * scroll bars (depending on the actual type of viewport).
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		protected function get viewport():IViewport
  		{
 -			if (!adjusting) {
 -				performLayout(event);
 -			}
 +			return _viewport;
  		}
  		
  		/**

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataContainerView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataContainerView.as
index 36ed489,0000000..fc5f3a2
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataContainerView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataContainerView.as
@@@ -1,230 -1,0 +1,233 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads
 +{	
 +	import org.apache.flex.core.BeadViewBase;
 +	import org.apache.flex.core.ContainerBase;
 +	import org.apache.flex.core.IBead;
 +	import org.apache.flex.core.IBeadLayout;
 +	import org.apache.flex.core.IBeadModel;
 +	import org.apache.flex.core.IBeadView;
- 	import org.apache.flex.core.IList;
- 	import org.apache.flex.core.ISelectableItemRenderer;
++	import org.apache.flex.core.IDataProviderModel;
 +	import org.apache.flex.core.IItemRenderer;
 +	import org.apache.flex.core.IItemRendererParent;
++	import org.apache.flex.core.IList;
 +	import org.apache.flex.core.IParent;
-     import org.apache.flex.core.IParentIUIBase;
- 	import org.apache.flex.core.IDataProviderModel;
++	import org.apache.flex.core.IParentIUIBase;
++	import org.apache.flex.core.ISelectableItemRenderer;
 +	import org.apache.flex.core.ISelectionModel;
 +	import org.apache.flex.core.IStrand;
-     import org.apache.flex.core.IUIBase;
++	import org.apache.flex.core.IUIBase;
++	import org.apache.flex.core.LayoutBase;
 +	import org.apache.flex.core.Strand;
 +	import org.apache.flex.core.UIBase;
 +	import org.apache.flex.core.ValuesManager;
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.events.IEventDispatcher;
 +	import org.apache.flex.html.beads.models.ScrollBarModel;
 +	import org.apache.flex.html.beads.models.SingleLineBorderModel;
 +	import org.apache.flex.html.supportClasses.Border;
 +	import org.apache.flex.html.supportClasses.DataGroup;
 +	import org.apache.flex.html.supportClasses.ScrollBar;
 +
 +	/**
 +	 *  The DataContainerView provides the visual elements for the DataContainer.
 +	 *  
 +	 *  @viewbead
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
 +	 *  @productversion FlexJS 0.8
 +	 */
 +	COMPILE::JS
 +	public class DataContainerView extends ContainerView implements IListView
 +	{
 +		public function DataContainerView()
 +		{
 +			super();
 +		}
 +		
 +		/**
 +		 *  @copy org.apache.flex.core.IBead#strand
 +		 *  
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		override public function set strand(value:IStrand):void
 +		{
 +			_strand = value;
 +			super.strand = value;
 +			
 +			host.addEventListener("beadsAdded", beadsAddedHandler);
 +		}
 +		
 +		protected var dataModel:IDataProviderModel;
 +		
 +		/**
 +		 * @flexjsignorecoercion org.apache.flex.core.IItemRendererParent
 +		 */
 +		public function get dataGroup():IItemRendererParent
 +		{
 +			return super.contentView as IItemRendererParent;
 +		}
 +		
 +		protected function beadsAddedHandler(event:Event):void
 +		{
 +			dataModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
 +			host.addEventListener("itemsCreated", itemsCreatedHandler);
 +			dataModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
 +		}
 +		
 +		/**
 +		 * @private
 +		 */
 +		override protected function handleInitComplete(event:Event):void
 +		{
 +			super.handleInitComplete(event);
 +		}
 +		
 +		/**
 +		 * @private
 +		 */
 +		protected function itemsCreatedHandler(event:Event):void
 +		{
- 			performLayout(event);
++			trace("DataContainerView: itemsCreatedHandler");
++			host.dispatchEvent(new Event("layoutNeeded"));
 +		}
 +		
 +		/**
 +		 * @private
 +		 */
 +		protected function dataProviderChangeHandler(event:Event):void
 +		{
++			trace("DataContainerView: dataProviderChangeHandler");
 +			performLayout(event);
 +		}
 +	}
 +	
 +	COMPILE::SWF
 +	public class DataContainerView extends ContainerView implements IListView
 +	{
 +		public function DataContainerView()
 +		{
 +			super();
 +		}
 +						
 +		protected var dataModel:IDataProviderModel;
 +		
 +		/**
 +		 * @private
 +		 */
 +		override public function get host():IUIBase
 +		{
 +			return _strand as IUIBase;
 +		}
 +		
 +		/**
 +		 *  @copy org.apache.flex.core.IBead#strand
 +		 *  
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		override public function set strand(value:IStrand):void
 +		{
 +			_strand = value;
 +			super.strand = value;
 +			
 +			host.addEventListener("beadsAdded", beadsAddedHandler);
++			host.addEventListener("itemsCreated", itemsCreatedHandler);
 +		}
 +		
 +		override protected function completeSetup():void
 +		{
 +			super.completeSetup();
 +			
 +			// list is not interested in UI children, it wants to know when new items
 +			// have been added or the dataProvider has changed.
- 			host.removeEventListener("childrenAdded", childrenChangedHandler);
- 			host.removeEventListener("childrenAdded", performLayout);
- 			host.addEventListener("itemsCreated", itemsCreatedHandler);
++//			host.removeEventListener("childrenAdded", childrenChangedHandler);
++//			host.removeEventListener("childrenAdded", performLayout);
 +		}
 +		
 +		protected function beadsAddedHandler(event:Event):void
 +		{
 +			dataModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
 +			dataModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
 +		}
 +		
 +		override protected function handleInitComplete(event:Event):void
 +		{
 +			super.handleInitComplete(event);
 +		}
 +		
 +		/**
 +		 *  The area holding the itemRenderers.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function get dataGroup():IItemRendererParent
 +		{
 +			return super.contentView as IItemRendererParent;
 +		}
 +				
 +		/**
 +		 * @private
 +		 */
 +		override public function get resizableView():IUIBase
 +		{
 +			return _strand as IUIBase;
 +		}
 +		
 +		/**
 +		 * @private
 +		 */
 +		protected function itemsCreatedHandler(event:Event):void
 +		{
- 			performLayout(event);
++			host.dispatchEvent(new Event("layoutNeeded"));
 +		}
 +		
 +		/**
 +		 * @private
 +		 */
 +		protected function dataProviderChangeHandler(event:Event):void
 +		{
- 			performLayout(event);
++			host.dispatchEvent(new Event("layoutNeeded"));
 +		}
 +		        
 +        /**
 +         *  respond to a change in size or request to re-layout everything
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.0
 +         */
 +		override protected function resizeHandler(event:Event):void
 +		{
 +			// might need to do something here, not sure yet.
 +			super.resizeHandler(event);
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridView.as
index 68e5d95,8393057..3b387d9
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridView.as
@@@ -52,249 -115,152 +52,249 @@@ package org.apache.flex.html.bead
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
 -		public function set strand(value:IStrand):void
 +		public class DataGridView extends GroupView implements IBeadView
  		{
 -			_strand = value;
 -
 -			var host:UIBase = value as UIBase;
 -
 -			_header = new DataGridButtonBar();
 -			_header.id = "dataGridHeader";
 -
 -			var scrollPort:ScrollingViewport = new ScrollingViewport();
 -
 -			_listArea = new Container();
 -			_listArea.id = "dataGridListArea";
 -			_listArea.className = "DataGridListArea";
 -			_listArea.addBead(scrollPort);
 +			/**
 +			 *  constructor.
 +			 *
 +			 *  @langversion 3.0
 +			 *  @playerversion Flash 10.2
 +			 *  @playerversion AIR 2.6
 +			 *  @productversion FlexJS 0.0
 +			 */
 +			public function DataGridView()
 +			{
 +				super();
 +			}
  			
 -			if (_strand.getBeadByType(IBeadLayout) == null) {
 -				var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout");
 -				if (c)
 -				{
 -					var layout:IBeadLayout = new c() as IBeadLayout;
 -					_strand.addBead(layout);
 +			private var _strand:IStrand;
 +			private var _header:DataGridButtonBar;
 +			private var _listArea:Container;
 +			
 +			private var _lists:Array;
 +			
 +			/**
 +			 * An array of List objects the comprise the columns of the DataGrid.
 +			 */
 +			public function get columnLists():Array
 +			{
 +				return _lists;
 +			}
 +			
 +			/**
 +			 * The area used to hold the columns
 +			 *
 +			 */
 +			public function get listArea():Container
 +			{
 +				return _listArea;
 +			}
 +			
 +			/**
 +			 * Returns the component used as the header for the DataGrid.
 +			 */
 +			public function get header():IUIBase
 +			{
 +				return _header;
 +			}
 +			
 +			/**
 +			 *  @copy org.apache.flex.core.IBead#strand
 +			 *
 +			 *  @langversion 3.0
 +			 *  @playerversion Flash 10.2
 +			 *  @playerversion AIR 2.6
 +			 *  @productversion FlexJS 0.0
 +			 */
 +			override public function set strand(value:IStrand):void
 +			{
 +				super.strand = value;
 +				_strand = value;
 +				
 +				var host:DataGrid = value as DataGrid;
 +				
 +				_header = new DataGridButtonBar();
 +				_header.height = 30;
 +				_header.percentWidth = 100;
 +				
 +				_listArea = new Container();
 +				_listArea.percentWidth = 100;
 +				_listArea.className = "DataGridListArea";
 +				
 +				COMPILE::SWF {
 +					_header.style = new SimpleCSSStyles();
 +					_header.style.flexGrow = 0;
 +					
 +					_listArea.style = new SimpleCSSStyles();
 +					_listArea.style.flexGrow = 1;
  				}
 +				COMPILE::JS {
 +					_header.element.style["flex-grow"] = "0";
 +					_header.element.style["min-height"] = "30px";
 +					_listArea.element.style["flex-grow"] = "1";
 +				}
 +				
- 				IEventDispatcher(_strand).addEventListener("initComplete", finishSetup);
++				IEventDispatcher(_strand).addEventListener("beadsAdded", finishSetup);
  			}
 -
 -			finishSetup(null);
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function finishSetup(event:Event):void
 -		{
 -			var host:UIBase = _strand as UIBase;
 -
 -			// see if there is a presentation model already in place. if not, add one.
 -			var presentationModel:DataGridPresentationModel = _strand.getBeadByType(DataGridPresentationModel) as DataGridPresentationModel;
 -			if (presentationModel == null) {
 -				presentationModel = new DataGridPresentationModel();
 -				_strand.addBead(presentationModel);
 +			
 +			/**
 +			 * @private
 +			 */
 +			private function finishSetup(event:Event):void
 +			{
 +				var host:DataGrid = _strand as DataGrid;
 +				
 +				if (_lists == null || _lists.length == 0) {
 +					createLists();
 +				}
 +				
 +				// see if there is a presentation model already in place. if not, add one.
 +				var presentationModel:IDataGridPresentationModel = host.presentationModel;
 +				var sharedModel:IDataGridModel = host.model as IDataGridModel;
 +				IEventDispatcher(sharedModel).addEventListener("dataProviderChanged",handleDataProviderChanged);
 +				IEventDispatcher(sharedModel).addEventListener("selectedIndexChanged", handleSelectedIndexChanged);
 +				
 +				var columnLabels:Array = new Array();
 +				var buttonWidths:Array = new Array();
 +				
 +				var marginBorderOffset:int = 0;
 +				COMPILE::SWF {
 +					marginBorderOffset = 1;
 +				}
 +					
 +				for(var i:int=0; i < sharedModel.columns.length; i++) {
 +					var dgc:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
 +					columnLabels.push(dgc.label);
 +					var colWidth:Number = dgc.columnWidth - marginBorderOffset;
 +					buttonWidths.push(colWidth);
 +					
 +					var list:DataGridColumnList = _lists[i] as DataGridColumnList;
 +					if (!isNaN(colWidth)) {
 +						list.width = Number(colWidth - marginBorderOffset);
 +					} else {
 +						COMPILE::SWF {
 +							list.style = new SimpleCSSStyles();
 +							list.style.flexGrow = 1;
 +						}
 +							COMPILE::JS {
 +								list.element.style["flex-grow"] = "1";
 +							}
 +					}
 +				}
 +					
 +				var bblayout:ButtonBarLayout = new ButtonBarLayout();
 +				_header.buttonWidths = buttonWidths
 +				_header.widthType = ButtonBarModel.PIXEL_WIDTHS;
 +				_header.dataProvider = columnLabels;
 +				_header.addBead(bblayout);
 +				_header.addBead(new Viewport());
 +				host.addElement(_header);
 +				
 +				host.addElement(_listArea);
 +				
 +				handleDataProviderChanged(event);
 +				
 +				host.addEventListener("widthChanged", handleSizeChanges);
 +				host.addEventListener("heightChanged", handleSizeChanges);
  			}
 -
 -			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 -			IEventDispatcher(sharedModel).addEventListener("dataProviderChanged",handleDataProviderChanged);
 -
 -			var columnLabels:Array = new Array();
 -
 -			for(var i:int=0; i < sharedModel.columns.length; i++) {
 -				var dgc:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
 -				columnLabels.push(dgc.label);
 +			
 +			/**
 +			 * @private
 +			 */
 +			private function handleSizeChanges(event:Event):void
 +			{	
 +				_header.dispatchEvent(new Event("layoutChanged"));
 +				_listArea.dispatchEvent(new Event("layoutChanged"));
  			}
 -
 -			var bblayout:ButtonBarLayout = new ButtonBarLayout();
 -			var buttonBarModel:ArraySelectionModel = new ArraySelectionModel();
 -			buttonBarModel.dataProvider = columnLabels;
 -
 -			_header.addBead(buttonBarModel);
 -			_header.addBead(bblayout);
 -			_header.addBead(new Viewport());
 -			host.addElement(_header);
 -
 -			host.addElement(_listArea);
 -
 -			handleDataProviderChanged(event);
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function handleSizeChanges(event:Event):void
 -		{	
 -			var layoutBead:IDataGridLayout = _strand.getBeadByType(IBeadLayout) as IDataGridLayout;
 -			layoutBead.header = _header;
 -			layoutBead.columns = _lists;
 -			layoutBead.listArea = _listArea;
 -			layoutBead.layout();
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function handleDataProviderChanged(event:Event):void
 -		{
 -			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 -
 -			if (_lists == null || _lists.length == 0) {
 -				createLists();
 +			
 +			/**
 +			 * @private
 +			 */
 +			private function handleDataProviderChanged(event:Event):void
 +			{
 +				var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 +				
 +				for (var i:int=0; i < _lists.length; i++)
 +				{
 +					var list:DataGridColumnList = _lists[i] as DataGridColumnList;
 +					var listModel:ISelectionModel = list.getBeadByType(IBeadModel) as ISelectionModel;
 +					listModel.dataProvider = sharedModel.dataProvider;
 +				}
 +				
 +				host.dispatchEvent(new Event("layoutNeeded"));
  			}
 -
 -			for (var i:int=0; i < _lists.length; i++)
 +			
 +			/**
 +			 * @private
 +			 */
 +			private function handleSelectedIndexChanged(event:Event):void
  			{
 -				var list:DataGridColumnList = _lists[i] as DataGridColumnList;
 -				var listModel:ISelectionModel = list.getBeadByType(IBeadModel) as ISelectionModel;
 -				listModel.dataProvider = sharedModel.dataProvider;
 +				var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 +				var newIndex:int = sharedModel.selectedIndex;
 +				
 +				for (var i:int=0; i < _lists.length; i++)
 +				{
 +					var list:DataGridColumnList = _lists[i] as DataGridColumnList;
 +					list.selectedIndex = newIndex;
 +				}
  			}
 -
 -			host.dispatchEvent(new Event("layoutNeeded"));
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function handleColumnListChange(event:Event):void
 -		{
 -			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 -			var list:DataGridColumnList = event.target as DataGridColumnList;
 -			sharedModel.selectedIndex = list.selectedIndex;
 -
 -			for(var i:int=0; i < _lists.length; i++) {
 -				if (list != _lists[i]) {
 -					var otherList:DataGridColumnList = _lists[i] as DataGridColumnList;
 -					otherList.selectedIndex = list.selectedIndex;
 +			
 +			/**
 +			 * @private
 +			 */
 +			private function handleColumnListChange(event:Event):void
 +			{
 +				var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 +				var list:DataGridColumnList = event.target as DataGridColumnList;
 +				sharedModel.selectedIndex = list.selectedIndex;
 +				
 +				for(var i:int=0; i < _lists.length; i++) {
 +					if (list != _lists[i]) {
 +						var otherList:DataGridColumnList = _lists[i] as DataGridColumnList;
 +						otherList.selectedIndex = list.selectedIndex;
 +					}
  				}
 +				
 +				host.dispatchEvent(new Event('change'));
  			}
 -
 -			host.dispatchEvent(new Event('change'));
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function createLists():void
 -		{
 -			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 -			var presentationModel:DataGridPresentationModel = _strand.getBeadByType(DataGridPresentationModel) as DataGridPresentationModel;
 -			var listWidth:Number = host.width / sharedModel.columns.length;
 -
 -			_lists = new Array();
 -
 -			for (var i:int=0; i < sharedModel.columns.length; i++) {
 -				var dataGridColumn:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
 -
 -				var list:DataGridColumnList = new DataGridColumnList();
 -				list.id = "dataGridColumn"+String(i);
 -				list.addBead(sharedModel);
 -				list.itemRenderer = dataGridColumn.itemRenderer;
 -				list.labelField = dataGridColumn.dataField;
 -				list.addEventListener('change',handleColumnListChange);
 -				list.addBead(presentationModel);
 -
 -				_listArea.addElement(list);
 -				_lists.push(list);
 +			
 +			/**
 +			 * @private
 +			 */
 +			private function createLists():void
 +			{
 +				var host:DataGrid = _strand as DataGrid;
 +				
 +				var sharedModel:IDataGridModel = host.model as IDataGridModel;
 +				var presentationModel:IDataGridPresentationModel = host.presentationModel;
 +				
 +				_lists = new Array();
 +				
 +				for (var i:int=0; i < sharedModel.columns.length; i++) {
 +					var dataGridColumn:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
 +					
 +					var list:DataGridColumnList = new DataGridColumnList();
 +					list.id = "dataGridColumn"+String(i);
 +					list.addBead(sharedModel);
 +					list.itemRenderer = dataGridColumn.itemRenderer;
 +					list.labelField = dataGridColumn.dataField;
 +					list.addEventListener('change',handleColumnListChange);
 +					list.addBead(presentationModel);
 +					
 +					if (i == 0) {
 +						list.className = "first";
 +					} else if (i == sharedModel.columns.length-1) {
 +						list.className = "last";
 +					} else {
 +						list.className = "middle";
 +					}
 +					
 +					_listArea.addElement(list);
 +					_lists.push(list);
 +				}
 +				
 +				host.dispatchEvent(new Event("layoutNeeded"));
  			}
 -
 -			host.dispatchEvent(new Event("layoutNeeded"));
  		}
 -	}
  }
  

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
index c3351a5,0000000..2a982c2
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
@@@ -1,429 -1,0 +1,344 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads
 +{
 +	import org.apache.flex.core.BeadViewBase;
 +	import org.apache.flex.core.IBead;
 +	import org.apache.flex.core.IBeadLayout;
 +	import org.apache.flex.core.IBeadView;
 +	import org.apache.flex.core.ILayoutChild;
 +	import org.apache.flex.core.ILayoutHost;
 +	import org.apache.flex.core.ILayoutView;
 +	import org.apache.flex.core.IStrand;
 +	import org.apache.flex.core.IUIBase;
 +	import org.apache.flex.core.UIBase;
 +	import org.apache.flex.core.ValuesManager;
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.events.IEventDispatcher;
 +
 +	COMPILE::SWF {
 +		import org.apache.flex.geom.Size;
 +		import org.apache.flex.geom.Rectangle;
 +		import org.apache.flex.utils.CSSContainerUtils;
 +	}
 +
 +	/**
 +	 *  The GroupView is a bead that manages the layout bead (if any) attached to a Group. This class
 +	 *  also provides support for background and border styles for a Group on the SWF platform.
 +     *
 +	 *  @viewbead
 +     *  @langversion 3.0
 +     *  @playerversion Flash 10.2
 +     *  @playerversion AIR 2.6
 +     *  @productversion FlexJS 0.8
 +	 */
 +	public class GroupView extends BeadViewBase implements IBeadView, ILayoutHost
 +	{
 +		/**
 +     	 *  The GroupView class is the default view for
 +         *  the org.apache.flex.html.Group class.
 +         *  It lets you use some CSS styles to manage the border, background
 +         *  and padding around the content area.
 +         *
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.8
 +         */
 +		public function GroupView()
 +		{
 +			super();
 +
 +			layoutRunning = false;
 +		}
 +
 +		/**
 +		 * The sub-element used as the parent of the container's elements. This does not
 +		 * include the chrome elements.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function get contentView():ILayoutView
 +		{
 +			return host as ILayoutView;
 +		}
 +
 +		/**
 +		 * The view that can be resized.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		public function get resizableView():IUIBase
 +		{
 +			return host;
 +		}
 +
 +
 +		private var layoutRunning:Boolean;
 +
 +		/**
 +		 * Strand setter.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		override public function set strand(value:IStrand):void
 +		{
 +			_strand = value;
 +			super.strand = value;
 +
 +			COMPILE::SWF {
 +				displayBackgroundAndBorder(host as UIBase);
 +			}
 +
 +			// listen for initComplete to signal that the strand has been initialized
 +			// with its beads and children.
 +			host.addEventListener("initComplete", handleInitComplete);
- 			
- 			// listen for when children have been added so additional event listeners
- 			// can be placed upon them.
- 			host.addEventListener("childrenAdded", handleChildrenAdded);
- 			
- 			// listen for requests to run the layout.
- 			host.addEventListener("layoutNeeded", performLayout);
 +		}
 +
 +		/**
 +		 * Handles the initComplete event by completing the setup and kicking off the
 +		 * presentation of the contents.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		protected function handleInitComplete(event:Event):void
 +		{
 +            var ilc:ILayoutChild = host as ILayoutChild;
 +			// Complete the setup if the height is sized to content or has been explicitly set
 +            // and the width is sized to content or has been explicitly set
 +			if ((ilc.isHeightSizedToContent() || !isNaN(ilc.explicitHeight) || !isNaN(ilc.percentHeight)) &&
 +                (ilc.isWidthSizedToContent() || !isNaN(ilc.explicitWidth) || !isNaN(ilc.percentWidth))) {
 +				completeSetup();
 +			}
 +			else {
 +				// otherwise, wait until the unknown sizes have been set and then finish
 +				host.addEventListener("sizeChanged", deferredSizeHandler);
 +                host.addEventListener("widthChanged", deferredSizeHandler);
 +                host.addEventListener("heightChanged", deferredSizeHandler);
 +			}
 +		}
 +
 +		/**
 +		 * Handles the case where the size of the host is not immediately known, usually do
 +		 * to one of its dimensions being indicated as a percent size.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		protected function deferredSizeHandler(event:Event):void
 +		{
 +            host.removeEventListener("sizeChanged", deferredSizeHandler);
 +            host.removeEventListener("widthChanged", deferredSizeHandler);
 +            host.removeEventListener("heightChanged", deferredSizeHandler);
 +			
 +			completeSetup();
- 
- 			var num:Number = contentView.numElements;
- 			if (num > 0)
-             {
-                 performLayout(event);
-             }
 +		}
 +
 +		/**
 +		 * Called when the host is ready to complete its setup (usually after its size has been
 +		 * determined).
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		protected function completeSetup():void
 +		{
 +			// listen for changes to strand's size and rerun the layout
 +			host.addEventListener("sizeChanged", resizeHandler);
 +			host.addEventListener("widthChanged", resizeHandler);
 +			host.addEventListener("heightChanged", resizeHandler);
 +		}
- 
- 		/**
- 		 * Handles the viewCreated event by performing the first layout if
- 		 * there are children already present (ie, from MXML).
- 		 *
- 		 *  @langversion 3.0
- 		 *  @playerversion Flash 10.2
- 		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.8
- 		 */
- 		protected function viewCreatedHandler(event:Event):void
- 		{
- 			var num:Number = contentView.numElements;
- 			if (num > 0)
- 			{
- 				performLayout(event);
- 			}
- 		}
- 
- 		/**
- 		 * @private
- 		 */
- 		protected function handleChildrenAdded(event:Event):void
- 		{
- 			COMPILE::SWF {
- 				var n:Number = contentView.numElements;
- 				for(var i:int=0; i < n; i++) {
- 					var child:IEventDispatcher = contentView.getElementAt(i) as IEventDispatcher;
- 					child.addEventListener("widthChanged", childResizeHandler);
- 					child.addEventListener("heightChanged", childResizeHandler);
- 					child.addEventListener("sizeChanged", childResizeHandler);
- 				}
- 			}
- 
- 			performLayout(event);
- 		}
 +		
 +		/**
 +		 * Invoked in response to the strand being resized.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		protected function resizeHandler(event:Event):void
 +		{
- 			performLayout(event);
- 		}
- 		
- 		/**
- 		 * Invoked in response to any child being resized.
- 		 *
- 		 *  @langversion 3.0
- 		 *  @playerversion Flash 10.2
- 		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.8
- 		 */
- 		protected function childResizeHandler(event:Event):void
- 		{
- 			performLayout(event);
++			// override in subclasses in case there is something besides running
++			// the layout (which is handled automatically by the layout itself).
 +		}
 +		
 +		/**
 +		 * Provides a place for pre-layout actions.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
- 		protected function layoutViewBeforeContentLayout():void
++		public function beforeLayout():void
 +		{
 +			// This has no use for Group but is here so a subclass can override it.
 +		}
 +
 +		/**
 +		 * Executes the layout associated with this container. Once the layout has been
 +		 * run, it may affect the size of the host or may cause the host to present scroll
 +		 * bars view its viewport.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.8
 +		 */
 +		protected function performLayout(event:Event):void
 +		{
- 			if (layoutRunning) return;
- 
- 			layoutRunning = true;
- 			
- 			// pre-process before layout
- 			layoutViewBeforeContentLayout();
- 
- 			var host:UIBase = _strand as UIBase;
- 
- 			var layout:IBeadLayout = _strand.getBeadByType(IBeadLayout) as IBeadLayout;
- 			if (layout == null) {
- 				var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout");
- 				if (c) {
- 					layout = new c() as IBeadLayout;
- 					_strand.addBead(layout);
- 				}
- 			}
- 
- 			if (layout) {
- 				layout.layout();
- 			}
- 
- 			// cleanup or adjust after layout
- 			layoutViewAfterContentLayout();
- 
- 			layoutRunning = false;
- 			
- 			host.dispatchEvent(new Event("layoutComplete"));
++			trace("CALLING performLayout !!!!");
 +		}
 +
 +		/**
 +		 * Returns the size of the content area including the padding.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		COMPILE::SWF
 +		protected function calculateContentSize():Size
 +		{
 +			var maxWidth:Number = 0;
 +			var maxHeight:Number = 0;
 +			var num:Number = contentView.numElements;
 +
 +			for (var i:int=0; i < num; i++) {
 +				var child:IUIBase = contentView.getElementAt(i) as IUIBase;
 +				if (child == null || !child.visible) continue;
 +				var childXMax:Number = child.x + child.width;
 +				var childYMax:Number = child.y + child.height;
 +				maxWidth = Math.max(maxWidth, childXMax);
 +				maxHeight = Math.max(maxHeight, childYMax);
 +			}
 +
 +			var padding:org.apache.flex.geom.Rectangle = CSSContainerUtils.getPaddingMetrics(this._strand);
 +			var border:org.apache.flex.geom.Rectangle = CSSContainerUtils.getBorderMetrics(this._strand);
 +
 +			// return the content size as the max plus right/bottom padding. the x,y position of
 +			// each child is already offset by the left/top padding by the layout algorithm.
 +			return new Size(maxWidth + padding.right - (border.left+border.right), maxHeight + padding.bottom - (border.top+border.bottom));
 +		}
 +
 +		/**
- 		 * @private
- 		 */
- 		private var adjusting:Boolean = false;
- 
- 		/**
 +		 * Adjusts the size of the host after the layout has been run.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		COMPILE::SWF
- 		protected function layoutViewAfterContentLayout():void
++		public function afterLayout():void
 +		{
- 			if (adjusting) return;
- 
 +			var host:UIBase = _strand as UIBase;
- 
- 			adjusting = true;
- 
 +			var contentSize:Size = calculateContentSize();
 +
 +			if (host.isWidthSizedToContent() && host.isHeightSizedToContent()) {
 +				host.setWidthAndHeight(contentSize.width, contentSize.height, true);
 +			}
 +			else if (!host.isWidthSizedToContent() && host.isHeightSizedToContent())
 +			{
 +				host.setHeight(contentSize.height, true);
 +			}
 +			else if (host.isWidthSizedToContent() && !host.isHeightSizedToContent())
 +			{
 +				host.setWidth(contentSize.width, true);
 +			}
- 
- 			adjusting = false;
 +		}
 +		
 +		COMPILE::JS
- 		protected function layoutViewAfterContentLayout():void
++		public function afterLayout():void
 +		{
 +			// maybe useful in a subclass on the JS side.
 +		}
 +
 +		/**
 +		 * @private
 +		 */
 +		COMPILE::SWF
 +		protected function displayBackgroundAndBorder(host:UIBase) : void
 +		{
 +			var backgroundColor:Object = ValuesManager.valuesImpl.getValue(host, "background-color");
 +			var backgroundImage:Object = ValuesManager.valuesImpl.getValue(host, "background-image");
 +			if (backgroundColor != null || backgroundImage != null)
 +			{
 +				if (host.getBeadByType(IBackgroundBead) == null)
 +					var c:Class = ValuesManager.valuesImpl.getValue(host, "iBackgroundBead");
 +				if (c) {
 +					host.addBead( new c() as IBead );
 +				}
 +			}
- 
++			
++			if (setupForBorder(host, "border")) return;
++			if (setupForBorder(host, "border-top")) return;
++			if (setupForBorder(host, "border-bottom")) return;
++			if (setupForBorder(host, "border-left")) return;
++			if (setupForBorder(host, "border-right")) return;
++		}
++		
++		COMPILE::SWF
++		protected function setupForBorder(host:UIBase, borderType:String):Boolean
++		{
++			var result:Boolean = false;
++			
 +			var borderStyle:String;
- 			var borderStyles:Object = ValuesManager.valuesImpl.getValue(host, "border");
++			var borderStyles:Object = ValuesManager.valuesImpl.getValue(host, borderType);
 +			if (borderStyles is Array)
 +			{
 +				borderStyle = borderStyles[1];
 +			}
 +			if (borderStyle == null)
 +			{
- 				borderStyle = ValuesManager.valuesImpl.getValue(host, "border-style") as String;
++				borderStyle = ValuesManager.valuesImpl.getValue(host, borderType+"-style") as String;
 +			}
 +			if (borderStyle != null && borderStyle != "none")
 +			{
 +				if (host.getBeadByType(IBorderBead) == null) {
- 					c = ValuesManager.valuesImpl.getValue(host, "iBorderBead");
++					var c:Class = ValuesManager.valuesImpl.getValue(host, "iBorderBead");
 +					if (c) {
 +						host.addBead( new c() as IBead );
++						result = true;
 +					}
 +				}
 +			}
++			
++			return result;
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
index 761e1c7,5bd1159..51d0c4c
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
@@@ -17,36 -17,30 +17,21 @@@
  //
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
 -{	
 +{
  	import org.apache.flex.core.IBeadLayout;
 -	import org.apache.flex.core.IItemRendererClassFactory;
 -	import org.apache.flex.core.IItemRendererParent;
--	import org.apache.flex.core.ILayoutHost;
- 	import org.apache.flex.core.ILayoutParent;
 -	import org.apache.flex.core.IParentIUIBase;
 -	import org.apache.flex.core.ISelectableItemRenderer;
 -	import org.apache.flex.core.ISelectionModel;
++	import org.apache.flex.core.ILayoutChild;
 +	import org.apache.flex.core.ILayoutView;
- 	import org.apache.flex.core.IParentIUIBase;
- 	import org.apache.flex.core.ISelectableItemRenderer;
- 	import org.apache.flex.core.ISelectionModel;
++	import org.apache.flex.core.IStyleableObject;
  	import org.apache.flex.core.IStrand;
--	import org.apache.flex.core.IUIBase;
--	import org.apache.flex.core.IViewportModel;
- 	import org.apache.flex.core.LayoutBase;
- 	import org.apache.flex.core.SimpleCSSStyles;
--	import org.apache.flex.core.UIBase;
--	import org.apache.flex.core.ValuesManager;
--	import org.apache.flex.events.Event;
--	import org.apache.flex.events.IEventDispatcher;
--	import org.apache.flex.html.List;
--	import org.apache.flex.html.beads.ButtonBarView;
 -	
 +	import org.apache.flex.html.beads.models.ButtonBarModel;
- 	import org.apache.flex.geom.Rectangle;
- 	import org.apache.flex.utils.CSSUtils;
- 	import org.apache.flex.utils.CSSContainerUtils;
++	import org.apache.flex.html.supportClasses.UIItemRendererBase;
 +
  	/**
- 	 *  The ButtonBarLayout class bead sizes and positions the org.apache.flex.html.Button
 -	 *  The ButtonBarLayout class bead sizes and positions the org.apache.flex.html.Button 
 -	 *  elements that make up a org.apache.flex.html.ButtonBar. This bead arranges the Buttons 
++	 *  The ButtonBarLayout class bead sizes and positions the button
 +	 *  elements that make up a org.apache.flex.html.ButtonBar. This bead arranges the Buttons
  	 *  horizontally and makes them all the same width unless the buttonWidths property has been set in which case
  	 *  the values stored in that array are used.
 -	 *  
 +	 *
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -91,81 -98,46 +76,71 @@@
  		/**
  		 * @copy org.apache.flex.core.IBeadLayout#layout
  		 */
 -		public function layout():Boolean
 +		override public function layout():Boolean
  		{
 -			var layoutParent:ILayoutHost = _strand.getBeadByType(ILayoutHost) as ILayoutHost;
 -			var contentView:IParentIUIBase = layoutParent.contentView as IParentIUIBase;
 -			var itemRendererParent:IItemRendererParent = contentView as IItemRendererParent;
 -			var viewportModel:IViewportModel = (layoutParent as ButtonBarView).viewportModel;
 -			
 -			var n:int = contentView.numElements;
 -			var realN:int = n;
 -			
 -			for (var j:int=0; j < n; j++)
 -			{
 -				var child:IUIBase = itemRendererParent.getElementAt(j) as IUIBase;
 -				if (child == null || !child.visible) realN--;
 +			var contentView:ILayoutView = layoutView;
 +
 +			var model:ButtonBarModel = (host as IStrand).getBeadByType(ButtonBarModel) as ButtonBarModel;
 +			if (model) {
 +				buttonWidths = model.buttonWidths;
 +				_widthType = model.widthType;
  			}
 -			
 -			var xpos:Number = 0;
 -			var useWidth:Number = contentView.width / realN;
 -			var useHeight:Number = contentView.height;
 -			
 +
 +			var n:int = contentView.numElements;
++			if (n <= 0) return false;
 +
  			for (var i:int=0; i < n; i++)
--			{
- 				var ir:ISelectableItemRenderer = contentView.getElementAt(i) as ISelectableItemRenderer;
 -				var ir:ISelectableItemRenderer = itemRendererParent.getElementAt(i) as ISelectableItemRenderer;
--				if (ir == null || !UIBase(ir).visible) continue;
 -				UIBase(ir).y = 0;
 -				UIBase(ir).x = xpos;
 -				if (!isNaN(useHeight) && useHeight > 0) {
 -					UIBase(ir).height = useHeight;
 -				}
++			{	
++				var ilc:ILayoutChild = contentView.getElementAt(i) as ILayoutChild;
++				if (ilc == null || !ilc.visible) continue;
++				if (!(ilc is IStyleableObject)) continue;
  				
 -				if (buttonWidths) UIBase(ir).width = Number(buttonWidths[i]);
 -				else if (!isNaN(useWidth) && useWidth > 0) {
 -					UIBase(ir).width = useWidth;
 +				COMPILE::SWF {
 +					if (buttonWidths) {
 +						var widthValue:* = buttonWidths[i];
 +
 +						if (_widthType == ButtonBarModel.PIXEL_WIDTHS) {
- 							if (widthValue != null) UIBase(ir).width = Number(widthValue);
- 							if (UIBase(ir).style == null) {
- 								UIBase(ir).style = new SimpleCSSStyles();
- 							}
- 							UIBase(ir).style.flexGrow = 0;
++							if (widthValue != null) ilc.width = Number(widthValue);
++							IStyleableObject(ilc).style.flexGrow = 0;
 +						}
 +						else if (_widthType == ButtonBarModel.PROPORTIONAL_WIDTHS) {
 +							if (widthValue != null) {
- 								if (UIBase(ir).style == null) {
- 									UIBase(ir).style = new SimpleCSSStyles();
- 								}
- 								UIBase(ir).style.flexGrow = Number(widthValue);
++								IStyleableObject(ilc).style.flexGrow = Number(widthValue);
 +							}
 +						}
 +						else if (_widthType == ButtonBarModel.PERCENT_WIDTHS) {
- 							if (widthValue != null) UIBase(ir).percentWidth = Number(widthValue);
- 							if (UIBase(ir).style == null) {
- 								UIBase(ir).style = new SimpleCSSStyles();
- 							}
- 							UIBase(ir).style.flexGrow = 0;
++							if (widthValue != null) ilc.percentWidth = Number(widthValue);
++							IStyleableObject(ilc).style.flexGrow = 0;
 +						}
 +					} else {
- 						if (UIBase(ir).style == null) {
- 							UIBase(ir).style = new SimpleCSSStyles();
- 						}
- 						UIBase(ir).style.flexGrow = 1;
++						IStyleableObject(ilc).style.flexGrow = 1;
 +					}
 +				}
 +
 +				COMPILE::JS {
 +					// otherwise let the flexbox layout handle matters on its own.
 +					if (buttonWidths) {
 +						var widthValue:* = buttonWidths[i];
 +
 +						if (_widthType == ButtonBarModel.PIXEL_WIDTHS) {
- 							if (widthValue != null) UIBase(ir).width = Number(widthValue);
++							if (widthValue != null) ilc.width = Number(widthValue);
 +						}
 +						else if (_widthType == ButtonBarModel.PROPORTIONAL_WIDTHS) {
- 							if (widthValue != null) UIBase(ir).element.style["flex-grow"] = String(widthValue);
++							if (widthValue != null) ilc.element.style["flex-grow"] = String(widthValue);
 +						}
 +						else if (_widthType == ButtonBarModel.PERCENT_WIDTHS) {
- 							if (widthValue != null) UIBase(ir).percentWidth = Number(widthValue);
++							if (widthValue != null) ilc.percentWidth = Number(widthValue);
 +						}
 +					} else {
- 						UIBase(ir).element.style["flex-grow"] = "1";
++						ilc.element.style["flex-grow"] = "1";
 +					}
 +					
- 					UIBase(ir).height = contentView.height;
++					ilc.height = contentView.height;
  				}
 -				xpos += UIBase(ir).width;
  			}
 -			
 -			IEventDispatcher(_strand).dispatchEvent( new Event("layoutComplete") );
 -			
 -            return true;
 +
 +			// now let the horizontal layout take care of things.
 +			return super.layout();
  		}
  	}
  }


[03/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - add cordova plugin annotations

Posted by ah...@apache.org.
add cordova plugin annotations


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/d205ffb7
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/d205ffb7
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/d205ffb7

Branch: refs/heads/develop
Commit: d205ffb7d38d1b9ed08d836c3ad2d51b70600742
Parents: 9f03753
Author: Alex Harui <ah...@apache.org>
Authored: Fri Mar 10 11:28:40 2017 -0800
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 13 10:44:08 2017 -0700

----------------------------------------------------------------------
 .../src/main/flex/org/apache/cordova/camera/Camera.as  | 13 +++++++++++++
 .../flex/org/apache/cordova/geolocation/Geolocation.as | 13 +++++++++++++
 .../providers/AndroidExternalStorageProvider.as        |  1 +
 3 files changed, 27 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d205ffb7/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/camera/Camera.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/camera/Camera.as b/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/camera/Camera.as
index 69d2fa1..8adf787 100644
--- a/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/camera/Camera.as
+++ b/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/camera/Camera.as
@@ -40,6 +40,19 @@ package org.apache.cordova.camera
     }
     
 	[Mixin]
+	/**
+	 * The Camera class implements the Cordova Camera
+	 * 
+	 * @langversion 3.0
+	 * @playerversion Flash 10.2
+	 * @playerversion AIR 2.6
+	 * @productversion FlexJS 0.0
+	 * @flexjscordovaplugin cordova-plugin-camera
+	 * @flexjsignorecoercion FileEntry
+	 * @flexjsignorecoercion FileWriter
+	 * @flexjsignorecoercion window
+     * @flexjsignorecoercion Blob
+	 */
 	public class Camera
 	{
 		public static var DestinationType:Object = {

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d205ffb7/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/geolocation/Geolocation.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/geolocation/Geolocation.as b/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/geolocation/Geolocation.as
index c193413..97e99eb 100644
--- a/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/geolocation/Geolocation.as
+++ b/frameworks/projects/Mobile/src/main/flex/org/apache/cordova/geolocation/Geolocation.as
@@ -23,6 +23,19 @@ package org.apache.cordova.geolocation
 	 */
 
 	[Mixin]
+	/**
+	 * The Geolocation class implements Cordova geolocation plugin
+	 * 
+	 * @langversion 3.0
+	 * @playerversion Flash 10.2
+	 * @playerversion AIR 2.6
+	 * @productversion FlexJS 0.0
+	 * @flexjscordovaplugin cordova-plugin-geolocation
+	 * @flexjsignorecoercion FileEntry
+	 * @flexjsignorecoercion FileWriter
+	 * @flexjsignorecoercion window
+     * @flexjsignorecoercion Blob
+	 */
 	public class Geolocation
 	{
 		/**

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d205ffb7/frameworks/projects/Storage/src/main/flex/org/apache/flex/storage/providers/AndroidExternalStorageProvider.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Storage/src/main/flex/org/apache/flex/storage/providers/AndroidExternalStorageProvider.as b/frameworks/projects/Storage/src/main/flex/org/apache/flex/storage/providers/AndroidExternalStorageProvider.as
index 00244fa..99234de 100644
--- a/frameworks/projects/Storage/src/main/flex/org/apache/flex/storage/providers/AndroidExternalStorageProvider.as
+++ b/frameworks/projects/Storage/src/main/flex/org/apache/flex/storage/providers/AndroidExternalStorageProvider.as
@@ -34,6 +34,7 @@ package org.apache.flex.storage.providers
 	 * @playerversion Flash 10.2
 	 * @playerversion AIR 2.6
 	 * @productversion FlexJS 0.0
+	 * @flexjscordovaplugin cordova-plugin-file
 	 * @flexjsignorecoercion FileEntry
 	 * @flexjsignorecoercion FileWriter
 	 * @flexjsignorecoercion window


[12/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
Merge branch 'develop' into dual.  Clean build.  Now to get it to run

Conflicts:
	examples/examples-integrationtests/pom.xml
	examples/flexjs/ListExample/pom.xml
	examples/native/ButtonExample/build.xml
	examples/native/USStatesMap/build.xml
	examples/native/USStatesMap/pom.xml
	examples/native/pom.xml
	frameworks/build.xml
	frameworks/projects/Basic/src/main/flex/BasicClasses.as
	frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Image.as
	frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ClippingViewport.as
	frameworks/projects/Basic/src/main/resources/defaults.css
	frameworks/projects/Express/src/main/flex/org/apache/flex/express/TextButton.as
	frameworks/projects/Graphics/build.xml
	frameworks/projects/Graphics/pom.xml
	frameworks/projects/HTML/src/main/flex/HTMLClasses.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/core/ContainerBase.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/core/ContainerBaseStrandChildren.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/core/ImageBase.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/core/ListBase.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/core/UIBase.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/core/UIButtonBase.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/core/View.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/core/ViewBase.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/ButtonBar.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/ButtonBase.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/CheckBox.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Container.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/ControlBar.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/DataGrid.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/DateChooser.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/DropDownList.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Form.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/HContainer.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/HRule.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Image.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/ImageAndTextButton.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/ImageButton.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Label.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/List.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/MXMLBeadView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/NumericStepper.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Panel.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/PanelWithControlBar.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/RadioButton.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/SimpleList.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Slider.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Spinner.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/TextArea.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/TextInput.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/TitleBar.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/VContainer.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/VRule.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/ComboBoxView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/ContainerView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataGridView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayData.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayList.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForColumnData.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataProviderChangeNotifier.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DateChooserView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DateFieldView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DropDownListView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/HScrollBarTrackView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/ImageButtonView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/ListView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/PanelView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/PanelWithControlBarView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/RangeStepperView.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForStringVectorData.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/TitleBarView.mxml
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/UnselectableElementBead.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/controllers/ComboBoxController.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/FlexibleFirstChildHorizontalLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/HScrollBarLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/TileLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/VerticalColumnLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/models/TextModel.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/ButtonBarButtonItemRenderer.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/CheckBoxIcon.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/ContainerContentArea.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/DataGridButtonBarButtonItemRenderer.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/DataGridColumnList.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/DataGroup.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/DataItemRenderer.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/RadioButtonIcon.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/ScrollingViewport.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/StringItemRenderer.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/Viewport.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/Circle.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/DOMWrapper.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/Ellipse.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/GraphicContainer.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/GraphicShape.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/Image.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/Path.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/Rect.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/svg/Text.as
	frameworks/projects/HTML/src/main/resources/basic-manifest.xml
	frameworks/projects/HTML/src/main/resources/defaults.css


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/9fd9b78b
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/9fd9b78b
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/9fd9b78b

Branch: refs/heads/develop
Commit: 9fd9b78b75fe8f0377a8e9733be64e5cabbb3412
Parents: d205ffb ae5cb4e
Author: Alex Harui <ah...@apache.org>
Authored: Mon Apr 17 23:15:48 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Mon Apr 17 23:15:48 2017 -0700

----------------------------------------------------------------------
 RELEASE_NOTES                                   |   20 +
 .../main/resources/archetype-resources/pom.xml  |   40 -
 .../main/resources/archetype-resources/pom.xml  |   40 -
 .../flexjs-simple-library-archetype/pom.xml     |   31 +-
 .../META-INF/maven/archetype-metadata.xml       |   37 +
 .../main/resources/META-INF/maven/archetype.xml |   30 -
 .../main/resources/archetype-resources/pom.xml  |   60 +-
 .../src/main/flex/MylibClasses.as               |   44 +
 .../flex/org/example/flexjs/mylib/FlashClass.as |   30 +
 .../org/example/flexjs/mylib/JavaScriptClass.as |   30 +
 .../org/example/flexjs/mylib/UniversalClass.as  |   43 +
 .../src/main/resources/mylib-manifest.xml       |   27 +
 .../flexjs-simple-typedef-archetype/pom.xml     |   55 +
 .../META-INF/maven/archetype-metadata.xml       |   43 +
 .../main/resources/archetype-resources/pom.xml  |   80 ++
 .../src/main/javascript/myscripts.js            |   58 +
 archetypes/pom.xml                              |    1 +
 examples/.gitignore                             |    1 +
 examples/examples-integrationtests/pom.xml      |   10 +-
 examples/examples-tests/pom.xml                 |    4 +-
 .../flexjs/examples/tests/ExampleBuildTest.java |    6 -
 examples/express/DataBindingExample/pom.xml     |   14 +-
 .../src/main/flex/MyInitialView.mxml            |    3 +-
 examples/express/pom.xml                        |   95 ++
 examples/flexjs/ASDoc/pom.xml                   |    8 -
 .../ASDoc/src/main/config/asdoc-config.xml      |    2 -
 examples/flexjs/ChartExample/pom.xml            |    8 -
 .../src/main/flex/MyInitialView.mxml            |   27 +-
 .../src/main/flex/SpeedTestView.mxml            |    5 +-
 .../src/main/flex/models/ProductsModel.as       |    4 +-
 examples/flexjs/CordovaCameraExample/pom.xml    |    4 -
 .../src/main/flex/MyInitialView.mxml            |    2 +-
 examples/flexjs/CreateJSExample/pom.xml         |    8 -
 examples/flexjs/DataBindingExample/pom.xml      |    8 -
 .../src/main/flex/MyInitialView.mxml            |  100 +-
 examples/flexjs/DataBindingExample_Flat/pom.xml |   55 +-
 examples/flexjs/DataBindingExample_as/pom.xml   |    8 -
 .../src/main/flex/MyInitialView.as              |   52 +-
 examples/flexjs/DataGridExample/pom.xml         |    8 -
 .../src/main/flex/MyInitialView.mxml            |   46 +-
 .../src/main/flex/models/ProductsModel.as       |   37 +-
 .../main/flex/products/ProductItemRenderer.as   |   22 +-
 examples/flexjs/DateControlsExample/pom.xml     |    8 -
 .../src/main/flex/MyInitialView.mxml            |   13 +-
 examples/flexjs/DesktopMap/pom.xml              |    8 -
 examples/flexjs/FlexJSStore/pom.xml             |    8 -
 .../FlexJSStore/src/main/flex/FlexJSStore.mxml  |    6 +-
 .../FlexJSStore/src/main/flex/HomeView.mxml     |  134 +-
 .../FlexJSStore/src/main/flex/SupportView.mxml  |    6 +-
 .../src/main/flex/productsView/Grip.mxml        |    4 +-
 .../productsView/ProductCatalogThumbnail.mxml   |    8 +-
 .../main/flex/productsView/ProductDetails.mxml  |    8 +-
 .../main/flex/productsView/ProductListItem.mxml |    4 +-
 examples/flexjs/FlexJSStore_jquery/pom.xml      |    8 -
 .../src/main/flex/FlexJSStore.mxml              |    2 +-
 .../src/main/flex/HomeView.mxml                 |    8 +-
 .../src/main/flex/SupportView.mxml              |    6 +-
 .../src/main/flex/productsView/Grip.mxml        |    4 +-
 .../productsView/ProductCatalogThumbnail.mxml   |    8 +-
 .../main/flex/productsView/ProductDetails.mxml  |    8 +-
 .../main/flex/productsView/ProductListItem.mxml |    4 +-
 examples/flexjs/FlexTeamPage_MDL/pom.xml        |    8 -
 .../src/main/flex/MainView.mxml                 |   25 +-
 .../flex/itemRenderers/MemberItemRenderer.mxml  |   62 +-
 .../MaterialIconWithFontAwesomeIcon.as          |   28 +
 .../src/main/flex/models/MembersModel.as        |   92 +-
 .../src/main/flex/vos/MemberVO.as               |   19 +-
 examples/flexjs/FlexWebsiteStatsViewer/pom.xml  |    8 -
 examples/flexjs/HelloWorld/pom.xml              |    8 -
 examples/flexjs/ListExample/pom.xml             |   26 -
 .../src/main/flex/MyInitialView.mxml            |    7 +-
 .../src/main/flex/models/ProductsModel.as       |    8 +-
 .../src/main/flex/simple/GenericList.as         |   66 +-
 .../src/main/flex/simple/GenericListView.as     |   38 +-
 .../main/flex/simple/IRFactoryForArrayData.as   |    2 +-
 .../flexjs/MDLBlogExample/.vscode/launch.json   |   21 +
 .../flexjs/MDLBlogExample/.vscode/tasks.json    |    9 +
 examples/flexjs/MDLBlogExample/asconfig.json    |   14 +
 examples/flexjs/MDLBlogExample/build.xml        |   63 +
 examples/flexjs/MDLBlogExample/pom.xml          |   83 ++
 .../MDLBlogExample/src/main/flex/App.mxml       |   34 +
 .../src/main/flex/BlogTemplate.mxml             |  257 ++++
 .../itemRenderers/CustomMenuItemRenderer.mxml   |   37 +
 .../src/main/flex/models/MenuModel.as           |   40 +
 .../src/main/flex/vos/MenuItemVO.as             |   37 +
 .../main/resources/images/android-desktop.png   |  Bin 0 -> 8325 bytes
 .../src/main/resources/images/avatar.png        |  Bin 0 -> 246 bytes
 .../src/main/resources/images/bg_1024.jpg       |  Bin 0 -> 64530 bytes
 .../src/main/resources/images/bg_2048.jpg       |  Bin 0 -> 262772 bytes
 .../src/main/resources/images/bg_2880.jpg       |  Bin 0 -> 514925 bytes
 .../src/main/resources/images/co1.jpg           |  Bin 0 -> 4839 bytes
 .../src/main/resources/images/co2.jpg           |  Bin 0 -> 12778 bytes
 .../src/main/resources/images/coffee.jpg        |  Bin 0 -> 66602 bytes
 .../src/main/resources/images/favicon.png       |  Bin 0 -> 905 bytes
 .../src/main/resources/images/ios-desktop.png   |  Bin 0 -> 1489 bytes
 .../src/main/resources/images/logo.png          |  Bin 0 -> 1220 bytes
 .../src/main/resources/images/road.jpg          |  Bin 0 -> 76091 bytes
 .../src/main/resources/images/road_big.jpg      |  Bin 0 -> 232489 bytes
 .../src/main/resources/images/shopping.jpg      |  Bin 0 -> 94041 bytes
 .../main/resources/mdl-js-index-template.html   |   33 +
 .../src/main/resources/mdl-styles.css           |  504 ++++++++
 examples/flexjs/MDLDynamicTabsExample/pom.xml   |   78 ++
 .../src/main/flex/TabsExample.mxml              |   36 +
 .../CustomTabBarPanelItemRenderer.mxml          |   36 +
 .../src/main/flex/models/TabsModel.as           |   38 +
 .../src/main/flex/views/InitialView.mxml        |   52 +
 .../src/main/flex/vos/TabVO.as                  |   33 +
 .../main/resources/mdl-js-index-template.html   |   33 +
 .../src/main/resources/mdl-styles.css           |   31 +
 examples/flexjs/MDLExample/pom.xml              |    8 -
 .../flexjs/MDLExample/src/main/flex/App.mxml    |    4 +-
 .../src/main/flex/models/FooterModel.as         |    5 +-
 .../src/main/flex/models/ListsModel.as          |    6 +-
 .../src/main/flex/models/MainNavigationModel.as |   11 +-
 .../src/main/flex/models/MenuModel.as           |    5 +-
 .../src/main/flex/models/TablesModel.as         |    5 +-
 .../src/main/flex/models/TabsModel.as           |   17 +-
 .../MDLExample/src/main/flex/vos/MenuItemVO.as  |    4 +-
 .../src/main/flex/vos/NavigationLinkVO.as       |    3 +-
 .../MDLExample/src/main/flex/vos/ProductVO.as   |    1 -
 .../MDLExample/src/main/flex/vos/TabVO.as       |    3 +-
 examples/flexjs/MapSearch/pom.xml               |    8 -
 examples/flexjs/MobileMap/pom.xml               |    8 -
 examples/flexjs/MobileStocks/pom.xml            |    8 -
 .../src/main/flex/MyInitialView.mxml            |    2 +-
 .../src/main/flex/views/LaunchView.mxml         |    2 +-
 .../src/main/flex/views/WatchListView.mxml      |    2 +-
 examples/flexjs/MobileTrader/pom.xml            |    8 -
 .../src/main/flex/MyInitialView.mxml            |    2 +-
 examples/flexjs/StorageExample/pom.xml          |    8 -
 examples/flexjs/StyleExample/pom.xml            |    8 -
 examples/flexjs/TeamPage/pom.xml                |    8 -
 .../src/main/flex/MemberItemRenderer.mxml       |    4 +-
 examples/flexjs/TodoListSampleApp/pom.xml       |    8 -
 .../sample/todo/renderers/TodoItemRenderer.as   |   90 --
 .../sample/todo/renderers/TodoItemRenderer.mxml |   58 +
 .../flex/sample/todo/views/TodoListView.mxml    |   57 +-
 examples/flexjs/TreeExample/pom.xml             |    8 -
 examples/flexjs/pom.xml                         |    2 +
 examples/native/ButtonExample/build.xml         |   34 +
 examples/native/ButtonExample/pom.xml           |   24 +-
 examples/native/USStatesMap/build.xml           |   55 +
 examples/native/USStatesMap/pom.xml             |   10 +
 examples/native/pom.xml                         |    5 +-
 examples/pom.xml                                |   59 +-
 frameworks/asdoc-config.xml                     |    2 +
 frameworks/downloads.xml                        |   78 +-
 frameworks/js/.jshintrc                         |   14 -
 frameworks/js/FlexJS/projects/TextJS/build.xml  |  172 +++
 .../src/main/config/compile-js-config.xml       |   96 ++
 frameworks/js/jshint.properties                 |   14 -
 .../Basic/src/main/flex/BasicClasses.as         |   19 +-
 .../flex/org/apache/flex/core/ContainerBase.as  |  385 ++----
 .../flex/core/ContainerBaseStrandChildren.as    |    4 +-
 .../org/apache/flex/core/DataContainerBase.as   |  278 +++++
 .../main/flex/org/apache/flex/core/GroupBase.as |  280 +++++
 .../src/main/flex/org/apache/flex/core/IList.as |   48 +
 .../main/flex/org/apache/flex/core/ImageBase.as |    4 +-
 .../flex/org/apache/flex/core/LayoutBase.as     |  166 +++
 .../main/flex/org/apache/flex/core/ListBase.as  |  101 +-
 .../main/flex/org/apache/flex/core/UIBase.as    |   15 +-
 .../flex/org/apache/flex/core/UIButtonBase.as   |   30 +-
 .../src/main/flex/org/apache/flex/core/View.as  |   93 +-
 .../main/flex/org/apache/flex/core/ViewBase.as  |   40 +-
 .../main/flex/org/apache/flex/html/ButtonBar.as |   39 +-
 .../flex/org/apache/flex/html/ButtonBase.as     |    1 -
 .../flex/org/apache/flex/html/CSSCheckBox.as    |  219 ++++
 .../main/flex/org/apache/flex/html/CheckBox.as  |   18 +-
 .../main/flex/org/apache/flex/html/Container.as |  126 +-
 .../flex/org/apache/flex/html/ControlBar.as     |   38 +-
 .../flex/org/apache/flex/html/DataContainer.as  |  146 +--
 .../main/flex/org/apache/flex/html/DataGrid.as  |   56 +-
 .../flex/org/apache/flex/html/DateChooser.as    |   16 +-
 .../flex/org/apache/flex/html/DropDownList.as   |   55 +-
 .../src/main/flex/org/apache/flex/html/Form.as  |   29 +-
 .../src/main/flex/org/apache/flex/html/Group.as |  145 +++
 .../flex/org/apache/flex/html/HContainer.as     |    3 +-
 .../src/main/flex/org/apache/flex/html/HRule.as |   17 +-
 .../src/main/flex/org/apache/flex/html/Image.as |   61 +-
 .../org/apache/flex/html/ImageAndTextButton.as  |   35 +-
 .../flex/org/apache/flex/html/ImageButton.as    |   53 +-
 .../src/main/flex/org/apache/flex/html/Label.as |   41 +-
 .../src/main/flex/org/apache/flex/html/List.as  |  194 +--
 .../flex/org/apache/flex/html/MXMLBeadView.as   |  108 +-
 .../flex/org/apache/flex/html/MultilineLabel.as |   12 +-
 .../flex/org/apache/flex/html/NumericStepper.as |    3 +-
 .../src/main/flex/org/apache/flex/html/Panel.as |   93 +-
 .../org/apache/flex/html/PanelWithControlBar.as |   49 +-
 .../flex/org/apache/flex/html/RadioButton.as    |    3 +-
 .../flex/org/apache/flex/html/SimpleList.as     |   19 +-
 .../main/flex/org/apache/flex/html/Slider.as    |   39 +-
 .../main/flex/org/apache/flex/html/Spinner.as   |    3 +-
 .../flex/org/apache/flex/html/SubAppLoader.as   |  137 +++
 .../main/flex/org/apache/flex/html/TextArea.as  |   96 +-
 .../main/flex/org/apache/flex/html/TextInput.as |   47 +-
 .../main/flex/org/apache/flex/html/TitleBar.as  |    6 +-
 .../flex/org/apache/flex/html/VContainer.as     |    3 +-
 .../src/main/flex/org/apache/flex/html/VRule.as |   15 +-
 .../html/beads/AccordionItemRendererView.as     |    4 +-
 .../org/apache/flex/html/beads/AccordionView.as |    1 +
 .../org/apache/flex/html/beads/CenterElement.as |   84 ++
 .../org/apache/flex/html/beads/ComboBoxView.as  |   36 +-
 .../org/apache/flex/html/beads/ContainerView.as |  441 +++----
 .../apache/flex/html/beads/DataContainerView.as |  140 ++-
 .../flex/html/beads/DataGridPercentageView.as   |  293 +++++
 .../org/apache/flex/html/beads/DataGridView.as  |  466 +++----
 .../DataItemRendererFactoryForArrayData.as      |   56 +-
 .../DataItemRendererFactoryForArrayList.as      |   55 +-
 .../DataItemRendererFactoryForColumnData.as     |   28 +-
 .../html/beads/DataProviderChangeNotifier.as    |  163 +--
 .../DataProviderCollectionChangeNotifier.as     |   71 ++
 .../beads/DataProviderItemsChangeNotifier.as    |   95 ++
 .../apache/flex/html/beads/DateChooserView.as   |  223 ++--
 .../org/apache/flex/html/beads/DateFieldView.as |   15 +-
 .../html/beads/DispatchInputFinishedBead.as     |  140 +++
 .../html/beads/DispatchKeyboardEventBead.as     |  148 +++
 .../apache/flex/html/beads/DropDownListView.as  |   38 +-
 .../org/apache/flex/html/beads/GroupView.as     |  429 +++++++
 .../flex/html/beads/HScrollBarTrackView.as      |    1 +
 .../apache/flex/html/beads/ImageButtonView.as   |   40 +-
 .../flex/org/apache/flex/html/beads/ListView.as |  163 ++-
 .../org/apache/flex/html/beads/PanelView.as     |  228 +++-
 .../flex/html/beads/PanelWithControlBarView.as  |  160 +--
 .../apache/flex/html/beads/RangeStepperView.as  |    5 +-
 .../flex/html/beads/SingleLineBorderBead.as     |   10 +-
 .../SingleLineBorderWithChangeListenerBead.as   |   89 ++
 .../flex/html/beads/SolidBackgroundBead.as      |   42 +-
 .../SolidBackgroundWithChangeListenerBead.as    |   71 ++
 .../TextItemRendererFactoryForArrayData.as      |   30 +-
 ...extItemRendererFactoryForStringVectorData.as |   28 +-
 .../apache/flex/html/beads/TitleBarView.mxml    |    8 +-
 .../flex/html/beads/UnselectableElementBead.as  |   69 ++
 .../beads/controllers/ComboBoxController.as     |    2 +-
 .../flex/html/beads/layouts/BasicLayout.as      |  466 ++-----
 .../flex/html/beads/layouts/ButtonBarLayout.as  |  148 ++-
 .../FlexibleFirstChildHorizontalLayout.as       |  249 ++--
 .../flex/html/beads/layouts/HScrollBarLayout.as |   34 +-
 .../html/beads/layouts/HorizontalFlexLayout.as  |  264 ++++
 .../html/beads/layouts/HorizontalFlowLayout.as  |   76 +-
 .../flex/html/beads/layouts/HorizontalLayout.as |  349 ++----
 .../layouts/OneFlexibleChildHorizontalLayout.as |  442 ++++---
 .../layouts/OneFlexibleChildVerticalLayout.as   |  608 ++++-----
 .../flex/html/beads/layouts/TileLayout.as       |   72 +-
 .../html/beads/layouts/VerticalColumnLayout.as  |  105 +-
 .../html/beads/layouts/VerticalFlexLayout.as    |  260 ++++
 .../flex/html/beads/layouts/VerticalLayout.as   |  336 ++---
 .../flex/html/beads/models/ButtonBarModel.as    |  102 ++
 .../flex/html/beads/models/NonNullTextModel.as  |  125 ++
 .../ButtonBarButtonItemRenderer.as              |   19 +
 .../flex/html/supportClasses/CheckBoxIcon.as    |    2 +-
 .../html/supportClasses/ClippingViewport.as     |   11 +-
 .../html/supportClasses/ContainerContentArea.as |   54 +-
 .../DataGridButtonBarButtonItemRenderer.as      |   10 +
 .../html/supportClasses/DataGridColumnList.as   |    1 +
 .../flex/html/supportClasses/DataGroup.as       |   92 +-
 .../html/supportClasses/DataItemRenderer.as     |    2 +-
 .../supportClasses/DataProviderNotifierBase.as  |  154 +++
 .../html/supportClasses/DateChooserHeader.as    |   10 +-
 .../html/supportClasses/MXMLItemRenderer.as     |   15 +-
 .../html/supportClasses/PanelLayoutProxy.as     |  132 ++
 .../flex/html/supportClasses/RadioButtonIcon.as |    2 +-
 .../html/supportClasses/ScrollingViewport.as    |  329 +++--
 .../html/supportClasses/StringItemRenderer.as   |   54 +-
 .../apache/flex/html/supportClasses/Viewport.as |   74 +-
 .../src/main/flex/org/apache/flex/svg/Circle.as |   15 +-
 .../main/flex/org/apache/flex/svg/DOMWrapper.as |    2 +-
 .../main/flex/org/apache/flex/svg/Ellipse.as    |   23 +-
 .../org/apache/flex/svg/GraphicContainer.as     |   96 +-
 .../flex/org/apache/flex/svg/GraphicShape.as    |   47 +-
 .../src/main/flex/org/apache/flex/svg/Image.as  |    2 +-
 .../src/main/flex/org/apache/flex/svg/Path.as   |   10 +-
 .../src/main/flex/org/apache/flex/svg/Rect.as   |   24 +-
 .../src/main/flex/org/apache/flex/svg/Text.as   |   48 +-
 .../Basic/src/main/resources/basic-manifest.xml |   41 +-
 .../Basic/src/main/resources/defaults.css       |    9 +
 .../Charts/src/main/flex/ChartsClasses.as       |   22 +-
 .../apache/flex/charts/beads/AxisBaseBead.as    |    8 +
 .../charts/beads/ChartItemRendererFactory.as    |   29 +-
 .../org/apache/flex/charts/beads/ChartView.as   |  117 +-
 ...ItemRendererFactoryForSeriesArrayListData.as |    4 +-
 .../DataItemRendererFactoryForSeriesData.as     |    4 +-
 .../controllers/ChartSeriesMouseController.as   |   40 +-
 .../flex/charts/beads/layouts/BarChartLayout.as |    8 +-
 .../beads/layouts/BarChartLayoutForArrayList.as |    8 +-
 .../charts/beads/layouts/ChartBaseLayout.as     |    6 +-
 .../charts/beads/layouts/ColumnChartLayout.as   |    8 +-
 .../layouts/ColumnChartLayoutForArrayList.as    |    8 +-
 .../layouts/LineChartCategoryVsLinearLayout.as  |    8 +-
 .../layouts/LineChartLinearVsLinearLayout.as    |    8 +-
 .../flex/charts/beads/layouts/PieChartLayout.as |    4 +-
 .../beads/layouts/PieChartLayoutForArrayList.as |    4 +-
 .../beads/layouts/StackedBarChartLayout.as      |    8 +-
 .../StackedBarChartLayoutForArrayList.as        |    8 +-
 .../beads/layouts/StackedColumnChartLayout.as   |    8 +-
 .../StackedColumnChartLayoutForArrayList.as     |    8 +-
 .../org/apache/flex/charts/core/ChartBase.as    |   16 +-
 .../apache/flex/charts/core/IChartDataGroup.as  |    3 +-
 .../flex/charts/optimized/SVGChartDataGroup.as  |   30 +-
 .../charts/supportClasses/ChartDataGroup.as     |   11 +-
 .../org/apache/flex/collections/ArrayList.as    |   57 +-
 .../projects/Core/src/main/flex/CoreClasses.as  |   24 +-
 .../projects/Core/src/main/flex/Promise.as      |  277 +++++
 .../flex/org/apache/flex/core/AllCSSStyles.as   |  652 ++++++++++
 .../org/apache/flex/core/BindableCSSStyles.as   |   32 +-
 .../flex/org/apache/flex/core/ByteArrayAsset.as |   49 +
 .../flex/org/apache/flex/core/IContainer.as     |   10 +
 .../main/flex/org/apache/flex/core/IImage.as    |    5 +-
 .../org/apache/flex/core/IItemRendererParent.as |    4 +-
 .../flex/org/apache/flex/core/ILayoutHost.as    |    6 +-
 .../flex/org/apache/flex/core/ILayoutView.as    |   86 ++
 .../org/apache/flex/core/ISelectionModel.as     |    2 -
 .../flex/org/apache/flex/core/IStrandPrivate.as |   39 +
 .../main/flex/org/apache/flex/core/IViewport.as |    2 +-
 .../org/apache/flex/core/SimpleCSSStyles.as     |    8 +-
 .../org/apache/flex/core/SimpleCSSValuesImpl.as |   13 +-
 .../org/apache/flex/core/StyleChangeNotifier.as |   82 ++
 .../org/apache/flex/events/CollectionEvent.as   |   88 ++
 .../org/apache/flex/events/IEventDispatcher.as  |    2 +-
 .../org/apache/flex/events/KeyboardEvent.as     |  120 ++
 .../flex/org/apache/flex/events/MouseEvent.as   |    2 +
 .../org/apache/flex/events/StyleChangeEvent.as  |   79 ++
 .../org/apache/flex/events/utils/EditingKeys.as |   95 ++
 .../apache/flex/events/utils/KeyConverter.as    |  205 ++++
 .../flex/events/utils/KeyboardEventConverter.as |   82 ++
 .../apache/flex/events/utils/ModifierKeys.as    |   97 ++
 .../apache/flex/events/utils/NavigationKeys.as  |   66 +
 .../org/apache/flex/events/utils/SpecialKeys.as |   40 +
 .../flex/org/apache/flex/events/utils/UIKeys.as |  115 ++
 .../apache/flex/events/utils/WhitespaceKeys.as  |   49 +
 .../apache/flex/promises/enums/PromiseState.as  |   71 ++
 .../flex/promises/interfaces/IThenable.as       |   31 +
 .../flex/org/apache/flex/promises/vo/Handler.as |   68 ++
 .../flex/org/apache/flex/utils/AnimationUtil.as |  116 ++
 .../main/flex/org/apache/flex/utils/CSSUtils.as |   18 +-
 .../org/apache/flex/utils/CompressionUtils.as   |   69 ++
 .../main/flex/org/apache/flex/utils/IntUtil.as  |   82 ++
 .../src/main/flex/org/apache/flex/utils/MD5.as  |  257 ++++
 .../apache/flex/utils/MXMLDataInterpreter.as    |    6 +-
 .../main/flex/org/apache/flex/utils/OSUtils.as  |   87 ++
 .../flex/org/apache/flex/utils/ObjectMap.as     |  185 +++
 .../main/flex/org/apache/flex/utils/URLUtils.as |   28 +-
 .../org/apache/flex/utils/undo/IOperation.as    |   54 +
 .../org/apache/flex/utils/undo/IUndoManager.as  |  187 +++
 .../org/apache/flex/utils/undo/UndoManager.as   |  265 ++++
 .../Core/src/main/resources/basic-manifest.xml  |    3 +
 .../flex/org/apache/flex/createjs/Container.as  |    6 +
 .../flex/org/apache/flex/createjs/core/View.as  |    6 +
 .../flex/org/apache/flex/utils/LayoutTweener.as |   31 +-
 .../org/apache/flex/utils/MockContentView.as    |  101 +-
 .../org/apache/flex/utils/MockLayoutChild.as    |    1 -
 .../org/apache/flex/utils/MockLayoutHost.as     |   12 +-
 .../org/apache/flex/utils/MockLayoutParent.as   |  131 +-
 .../Express/src/main/flex/ExpressClasses.as     |    2 +
 .../flex/org/apache/flex/express/Container.as   |   18 +
 .../apache/flex/express/ImageAndTextButton.as   |   64 +
 .../flex/org/apache/flex/express/ImageButton.as |   64 +
 .../flex/org/apache/flex/express/TextButton.as  |   33 +-
 .../Express/src/main/resources/defaults.css     |    2 +
 .../src/main/resources/express-manifest.xml     |    4 +-
 frameworks/projects/Graphics/build.xml          |    1 +
 frameworks/projects/Graphics/pom.xml            |   56 +
 .../src/main/config/compile-swf-config.xml      |    1 +
 .../Graphics/src/main/flex/GraphicsClasses.as   |    1 +
 .../flex/org/apache/flex/graphics/ICircle.as    |   20 +-
 .../apache/flex/graphics/ICompoundGraphic.as    |   16 +-
 .../flex/org/apache/flex/graphics/IDrawable.as  |   30 +
 .../flex/org/apache/flex/graphics/IEllipse.as   |   32 +
 .../org/apache/flex/graphics/IGraphicShape.as   |   23 +-
 .../main/flex/org/apache/flex/graphics/IRect.as |   32 +-
 .../main/flex/org/apache/flex/graphics/IText.as |   23 +-
 .../org/apache/flex/graphics/PathBuilder.as     |   90 +-
 .../org/apache/flex/graphics/beads/BlendBead.as |  142 +++
 .../flex/graphics/utils/shaderClasses/Color.pbk |  101 ++
 .../graphics/utils/shaderClasses/ColorBurn.pbk  |  149 +++
 .../utils/shaderClasses/ColorBurnShader.as      |   60 +
 .../graphics/utils/shaderClasses/ColorDodge.pbk |  151 +++
 .../utils/shaderClasses/ColorDodgeShader.as     |   60 +
 .../graphics/utils/shaderClasses/ColorShader.as |   60 +
 .../graphics/utils/shaderClasses/Exclusion.pbk  |  105 ++
 .../utils/shaderClasses/ExclusionShader.as      |   60 +
 .../flex/graphics/utils/shaderClasses/Hue.pbk   |  216 ++++
 .../graphics/utils/shaderClasses/HueShader.as   |   60 +
 .../graphics/utils/shaderClasses/Luminosity.pbk |  103 ++
 .../shaderClasses/LuminosityMaskFilter.pbk      |  133 ++
 .../utils/shaderClasses/LuminosityMaskShader.as |   96 ++
 .../utils/shaderClasses/LuminosityShader.as     |   59 +
 .../graphics/utils/shaderClasses/Saturation.pbk |  222 ++++
 .../utils/shaderClasses/SaturationShader.as     |   59 +
 .../graphics/utils/shaderClasses/SoftLight.pbk  |  199 +++
 .../utils/shaderClasses/SoftLightShader.as      |   59 +
 .../src/main/resources/basic-manifest.xml       |    1 +
 .../projects/HTML/.actionScriptProperties       |    1 -
 .../projects/HTML/src/main/flex/HTMLClasses.as  |    2 +-
 .../src/main/flex/org/apache/flex/html/A.as     |    4 +-
 .../src/main/flex/org/apache/flex/html/Div.as   |    4 +-
 .../src/main/flex/org/apache/flex/html/Li.as    |    4 +-
 .../main/flex/org/apache/flex/html/Module.as    |  137 ---
 .../src/main/flex/org/apache/flex/html/P.as     |    4 +-
 .../src/main/flex/org/apache/flex/html/Span.as  |    4 +-
 .../src/main/flex/org/apache/flex/html/Td.as    |    4 +-
 .../src/main/flex/org/apache/flex/html/Th.as    |    4 +-
 .../src/main/flex/org/apache/flex/html/Ul.as    |    4 +-
 .../org/apache/flex/html/beads/InnerHTML.as     |   13 +-
 .../HTML/src/main/resources/basic-manifest.xml  |    1 +
 .../HTML/src/main/resources/defaults.css        |  231 +++-
 .../flex/org/apache/flex/html5/TransformBead.as |    2 +
 .../src/main/config/compile-swf-config.xml      |    1 +
 .../src/main/flex/MDLClasses.as                 |    7 +-
 .../src/main/flex/org/apache/flex/mdl/Button.as |   19 +-
 .../src/main/flex/org/apache/flex/mdl/Card.as   |   32 +-
 .../main/flex/org/apache/flex/mdl/CheckBox.as   |   11 +-
 .../src/main/flex/org/apache/flex/mdl/Dialog.as |   29 +-
 .../flex/org/apache/flex/mdl/DialogActions.as   |   12 +-
 .../flex/org/apache/flex/mdl/DialogContent.as   |   16 +-
 .../src/main/flex/org/apache/flex/mdl/Drawer.as |   12 +-
 .../src/main/flex/org/apache/flex/mdl/Footer.as |   16 +-
 .../org/apache/flex/mdl/FooterBottomSection.as  |   20 +-
 .../apache/flex/mdl/FooterDropDownSection.as    |   24 +-
 .../org/apache/flex/mdl/FooterLeftSection.as    |   22 +-
 .../org/apache/flex/mdl/FooterMiddleSection.as  |   22 +-
 .../org/apache/flex/mdl/FooterRightSection.as   |   22 +-
 .../org/apache/flex/mdl/FooterTopSection.as     |   20 +-
 .../src/main/flex/org/apache/flex/mdl/Grid.as   |   18 +-
 .../main/flex/org/apache/flex/mdl/GridCell.as   |   72 +-
 .../src/main/flex/org/apache/flex/mdl/Header.as |   14 +-
 .../main/flex/org/apache/flex/mdl/HeaderRow.as  |   12 +-
 .../main/flex/org/apache/flex/mdl/IconToggle.as |   24 +-
 .../src/main/flex/org/apache/flex/mdl/List.as   |  409 ++++---
 .../src/main/flex/org/apache/flex/mdl/Menu.as   |  119 +-
 .../main/flex/org/apache/flex/mdl/Navigation.as |   16 +-
 .../org/apache/flex/mdl/NavigationLayout.as     |   16 +-
 .../apache/flex/mdl/NavigationLayoutContent.as  |   14 +-
 .../flex/org/apache/flex/mdl/RadioButton.as     |   65 +-
 .../src/main/flex/org/apache/flex/mdl/Slider.as |   66 +-
 .../main/flex/org/apache/flex/mdl/Spinner.as    |    3 +
 .../src/main/flex/org/apache/flex/mdl/Switch.as |   31 +-
 .../src/main/flex/org/apache/flex/mdl/THead.as  |   14 +-
 .../src/main/flex/org/apache/flex/mdl/TabBar.as |   54 +-
 .../flex/org/apache/flex/mdl/TabBarPanel.as     |   26 +-
 .../main/flex/org/apache/flex/mdl/TableCell.as  |   24 +-
 .../flex/org/apache/flex/mdl/TableColumn.as     |   26 +-
 .../src/main/flex/org/apache/flex/mdl/Tabs.as   |   93 +-
 .../main/flex/org/apache/flex/mdl/TextArea.as   |    5 +-
 .../main/flex/org/apache/flex/mdl/TextField.as  |   13 +-
 .../org/apache/flex/mdl/beads/DeletableChip.as  |    4 +-
 .../apache/flex/mdl/beads/DeletableLinkChip.as  |    4 +-
 .../TabsItemRendererFactoryForArrayData.as      |   26 +-
 .../TabsItemRendererFactoryForArrayListData.as  |  206 ++++
 .../flex/org/apache/flex/mdl/beads/Tooltip.as   |   72 +-
 .../apache/flex/mdl/beads/UpgradeChildren.as    |  127 ++
 .../org/apache/flex/mdl/beads/UpgradeElement.as |  122 ++
 .../flex/mdl/beads/models/SliderRangeModel.as   |  198 +++
 .../flex/mdl/beads/models/TabArrayListModel.as  |   59 +
 .../flex/mdl/beads/models/TabArrayModel.as      |   59 +
 .../apache/flex/mdl/beads/models/TabModel.as    |   59 -
 .../org/apache/flex/mdl/beads/views/ListView.as |   91 +-
 .../apache/flex/mdl/beads/views/SliderView.as   |   77 +-
 .../apache/flex/mdl/beads/views/TabBarView.as   |   49 +-
 .../org/apache/flex/mdl/beads/views/TabsView.as |   78 +-
 .../flex/mdl/materialIcons/IMaterialIcon.as     |    9 +-
 .../flex/mdl/materialIcons/MaterialIconType.as  | 1156 +++++++++---------
 .../apache/flex/mdl/supportClasses/CardInner.as |   16 +-
 .../mdl/supportClasses/IMaterialIconProvider.as |   36 +
 .../flex/mdl/supportClasses/MaterialIconBase.as |    3 +-
 .../src/main/resources/defaults.css             |   10 +-
 .../src/main/resources/mdl-manifest.xml         |    3 +-
 .../flex/org/apache/flex/mobile/TitleView.as    |    4 +-
 .../flex/org/apache/flex/net/HTTPService.as     |   41 +-
 .../apache/flex/reflection/TypeDefinition.as    |    9 +-
 frameworks/projects/Text/.vscode/tasks.json     |   16 +
 frameworks/projects/Text/asconfig.json          |   21 +
 frameworks/projects/Text/build.xml              |  169 +++
 .../Text/src/main/config/compile-as-config.xml  |   88 ++
 .../projects/Text/src/main/flex/TextClasses.as  |   77 ++
 .../apache/flex/text/engine/BreakOpportunity.as |   32 +
 .../org/apache/flex/text/engine/CFFHinting.as   |   29 +
 .../org/apache/flex/text/engine/Constants.as    |   25 +
 .../apache/flex/text/engine/ContentElement.as   |   71 ++
 .../org/apache/flex/text/engine/DigitCase.as    |   30 +
 .../org/apache/flex/text/engine/DigitWidth.as   |   30 +
 .../flex/text/engine/EastAsianJustifier.as      |   39 +
 .../apache/flex/text/engine/ElementFormat.as    |   77 ++
 .../apache/flex/text/engine/FontDescription.as  |   61 +
 .../org/apache/flex/text/engine/FontLookup.as   |   31 +
 .../org/apache/flex/text/engine/FontMetrics.as  |   91 ++
 .../org/apache/flex/text/engine/FontPosture.as  |   30 +
 .../org/apache/flex/text/engine/FontWeight.as   |   30 +
 .../flex/org/apache/flex/text/engine/Fonts.as   |   37 +
 .../org/apache/flex/text/engine/GlyphMetrics.as |   33 +
 .../apache/flex/text/engine/GraphicElement.as   |   37 +
 .../org/apache/flex/text/engine/GroupElement.as |   73 ++
 .../flex/org/apache/flex/text/engine/IFont.as   |   38 +
 .../org/apache/flex/text/engine/IFontLoader.as  |   35 +
 .../org/apache/flex/text/engine/ITextBlock.as   |   68 ++
 .../org/apache/flex/text/engine/ITextFactory.as |   29 +
 .../org/apache/flex/text/engine/ITextLine.as    |   71 ++
 .../flex/text/engine/JustificationStyle.as      |   31 +
 .../flex/org/apache/flex/text/engine/Kerning.as |   31 +
 .../apache/flex/text/engine/LigatureLevel.as    |   32 +
 .../flex/text/engine/LineJustification.as       |   31 +
 .../apache/flex/text/engine/RenderingMode.as    |   30 +
 .../apache/flex/text/engine/SpaceJustifier.as   |   46 +
 .../org/apache/flex/text/engine/TabAlignment.as |   31 +
 .../flex/org/apache/flex/text/engine/TabStop.as |   34 +
 .../org/apache/flex/text/engine/TextBaseline.as |   34 +
 .../org/apache/flex/text/engine/TextElement.as  |   94 ++
 .../org/apache/flex/text/engine/TextEngine.as   |   27 +
 .../apache/flex/text/engine/TextJustifier.as    |   45 +
 .../flex/text/engine/TextLineCreationResult.as  |   31 +
 .../flex/text/engine/TextLineMirrorRegion.as    |   55 +
 .../apache/flex/text/engine/TextLineValidity.as |   28 +
 .../org/apache/flex/text/engine/TextRotation.as |   32 +
 .../apache/flex/text/engine/TypographicCase.as  |   34 +
 .../org/apache/flex/text/events/IMEEvent.as     |   50 +
 .../org/apache/flex/text/events/TextEvent.as    |   62 +
 .../flex/org/apache/flex/text/html/TextBlock.as |  220 ++++
 .../flex/org/apache/flex/text/html/TextLine.as  |  273 +++++
 .../flex/text/ime/CompositionAttributeRange.as  |  121 ++
 .../flex/org/apache/flex/text/ime/IIMEClient.as |  186 +++
 .../org/apache/flex/text/ime/IIMESupport.as     |   86 ++
 .../main/flex/org/apache/flex/text/ime/IME.as   |   49 +
 .../apache/flex/text/ime/IMEConversionMode.as   |   37 +
 .../src/main/resources/basic-as-manifest.xml    |   24 +
 .../Text/src/main/resources/basic-manifest.xml  |   24 +
 .../Text/src/main/resources/defaults.css        |   21 +
 frameworks/projects/pom.xml                     |    4 +-
 .../observedbugs/ObservedBugTests.as            |    4 +-
 pom.xml                                         |   37 +-
 testsuite/pom.xml                               |    2 +-
 .../custom-html-template/pom.xml                |   40 -
 530 files changed, 23124 insertions(+), 8101 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/ASDoc/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/ASDoc/src/main/config/asdoc-config.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/ChartExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/CordovaCameraExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/CreateJSExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/DataBindingExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/DataBindingExample_Flat/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/DataBindingExample_as/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/DateControlsExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/DesktopMap/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/FlexJSStore/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/FlexJSStore/src/main/flex/productsView/ProductCatalogThumbnail.mxml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/FlexJSStore_jquery/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/FlexJSStore_jquery/src/main/flex/productsView/ProductCatalogThumbnail.mxml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/FlexTeamPage_MDL/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/FlexWebsiteStatsViewer/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/ListExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/MDLExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/MapSearch/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/MobileMap/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/MobileStocks/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/MobileTrader/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/StorageExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/StyleExample/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/TeamPage/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/flexjs/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/native/ButtonExample/build.xml
----------------------------------------------------------------------
diff --cc examples/native/ButtonExample/build.xml
index 5e0f408,79d3a49..a427dd8
--- a/examples/native/ButtonExample/build.xml
+++ b/examples/native/ButtonExample/build.xml
@@@ -30,10 -30,71 +30,44 @@@
  
      <include file="${basedir}/../../build_example.xml" />
  
 -    <condition property="JS.SWC" value="${FLEXJS_HOME}/js/libs/js.swc" >
 -        <and>
 -            <not>
 -                <isset property="JS.SWC" />
 -            </not>
 -            <available file="${FLEXJS_HOME}/js/libs/js.swc" type="file" />
 -        </and>
 -    </condition>
 -
 -    <condition property="JS.SWC" value="${FALCONJX_HOME}/../externs/js/out/bin/js.swc" >
 -        <and>
 -            <not>
 -                <isset property="JS.SWC" />
 -            </not>
 -            <available file="${FALCONJX_HOME}/../externs/js/out/bin/js.swc" type="file" />
 -        </and>
 -    </condition>
 -        
 -    <condition property="JS.SWC" value="${FALCONJX_HOME}/libs/js.swc" >
 -        <and>
 -            <not>
 -                <isset property="JS.SWC" />
 -            </not>
 -            <available file="${FALCONJX_HOME}/libs/js.swc" type="file" />
 -        </and>
 -    </condition>
 -        
 -    <path id="lib.path">
 -        <fileset dir="${FALCON_HOME}/lib" includes="falcon-flexTasks.jar"/>
 -    </path>
 -
 -    <target name="main" depends="clean,build" description="Clean build of ${example}">
 -    </target>
 +    <property name="config_arg" value="js" />
 +    <property name="file_suffix" value="as" />
      
++<<<<<<< HEAD
 +    <target name="main" depends="clean,build_example.compile" description="Clean build of ${example}">
++=======
+     <target name="build">
+         <java jar="${FALCONJX_HOME}/lib/mxmlc.jar" resultProperty="errorCode"
+             fork="true">
+             <jvmarg line="${mxmlc.jvm.args}"/>
+             <jvmarg line="-Dflexlib=${FLEXJS_HOME}/frameworks}"/>
+             <arg value="+flexlib=${FLEXJS_HOME}/frameworks" />
+             <arg value="-debug" />
+             <arg value="-define=CONFIG::as_only,false" />
+             <arg value="-define=CONFIG::js_only,true" />
+             <arg value="-external-library-path=${JS.SWC}" />
+             <arg value="-compiler.mxml.children-as-data" />
+             <arg value="-compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent" />
+             <arg value="-compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent" />
+             <arg value="-compiler.binding-value-change-event-type=valueChange" />
+             <arg value="+playerglobal.version=${playerglobal.version}" />
+             <arg value="+env.PLAYERGLOBAL_HOME=${env.PLAYERGLOBAL_HOME}" />
+             <arg value="-js-output-type=FLEXJS" />
+             <arg value="-closure-lib=${GOOG_HOME}" />
+             <arg value="-sdk-js-lib=${FLEXJS_HOME}/frameworks/js/FlexJS/libs" />
+             <arg value="${basedir}/src/main/flex/${example}.as" />
+         </java>
+         <fail>
+             <condition>
+                 <not>
+                     <or>
+                         <equals arg1="${errorCode}" arg2="0" />
+                         <equals arg1="${errorCode}" arg2="2" />
+                     </or>
+                 </not>
+             </condition>
+         </fail>        
++>>>>>>> develop
      </target>
      
      <target name="clean">

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/native/ButtonExample/pom.xml
----------------------------------------------------------------------
diff --cc examples/native/ButtonExample/pom.xml
index 0cc09a6,aacf74f..b81d238
--- a/examples/native/ButtonExample/pom.xml
+++ b/examples/native/ButtonExample/pom.xml
@@@ -39,21 -39,12 +39,21 @@@
        <plugin>
          <groupId>org.apache.flex.flexjs.compiler</groupId>
          <artifactId>flexjs-maven-plugin</artifactId>
-         <version>${flexjs.compiler.version}</version>
          <extensions>true</extensions>
          <configuration>
+           <outputJavaScript>true</outputJavaScript>
            <mainClass>ButtonExample.as</mainClass>
 +          <targets>JS</targets>
          </configuration>
        </plugin>
 +      <plugin>
 +        <groupId>org.apache.maven.plugins</groupId>
 +        <artifactId>maven-war-plugin</artifactId>
 +      </plugin>
 +      <plugin>
 +        <groupId>org.codehaus.mojo</groupId>
 +        <artifactId>build-helper-maven-plugin</artifactId>
 +      </plugin>
      </plugins>
    </build>
  

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/native/USStatesMap/build.xml
----------------------------------------------------------------------
diff --cc examples/native/USStatesMap/build.xml
index 5a0d580,ebb9478..2a62d4a
--- a/examples/native/USStatesMap/build.xml
+++ b/examples/native/USStatesMap/build.xml
@@@ -30,12 -30,73 +30,67 @@@
  
      <include file="${basedir}/../../build_example.xml" />
  
 -    <condition property="JS.SWC" value="${FLEXJS_HOME}/js/libs/js.swc" >
 -        <and>
 -            <not>
 -                <isset property="JS.SWC" />
 -            </not>
 -            <available file="${FLEXJS_HOME}/js/libs/js.swc" type="file" />
 -        </and>
 -    </condition>
 +    <property name="config_arg" value="js" />
 +    <property name="file_suffix" value="as" />
  
+     <condition property="JS.SWC" value="${FALCONJX_HOME}/../externs/js/out/bin/js.swc" >
+         <and>
+             <not>
+                 <isset property="JS.SWC" />
+             </not>
+             <available file="${FALCONJX_HOME}/../externs/js/out/bin/js.swc" type="file" />
+         </and>
+     </condition>
+ 
+     <condition property="JS.SWC" value="${FALCONJX_HOME}/libs/js.swc" >
+         <and>
+             <not>
+                 <isset property="JS.SWC" />
+             </not>
+             <available file="${FALCONJX_HOME}/libs/js.swc" type="file" />
+         </and>
+     </condition>
+ 
+     <path id="lib.path">
+         <fileset dir="${FALCON_HOME}/lib" includes="falcon-flexTasks.jar"/>
+     </path>
+ 
 -    <target name="main" depends="clean,build" description="Clean build of ${example}">
 +    <target name="main" depends="clean,build_example.compile" description="Clean build of ${example}">
      </target>
      
+     <target name="build">
+         <java jar="${FALCONJX_HOME}/lib/mxmlc.jar" resultProperty="errorCode"
+             fork="true">
+             <jvmarg line="${mxmlc.jvm.args}"/>
+             <jvmarg line="-Dflexlib=${FLEXJS_HOME}/frameworks}"/>
+             <arg value="+flexlib=${FLEXJS_HOME}/frameworks" />
+             <arg value="-debug" />
+             <arg value="-define=CONFIG::as_only,false" />
+             <arg value="-define=CONFIG::js_only,true" />
+             <arg value="-external-library-path=${JS.SWC}" />
+             <arg value="-compiler.mxml.children-as-data" />
+             <arg value="-compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent" />
+             <arg value="-compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent" />
+             <arg value="-compiler.binding-value-change-event-type=valueChange" />
+             <arg value="+playerglobal.version=${playerglobal.version}" />
+             <arg value="+env.PLAYERGLOBAL_HOME=${env.PLAYERGLOBAL_HOME}" />
+             <arg value="-js-output-type=FLEXJS" />
+             <arg value="-closure-lib=${GOOG_HOME}" />
+             <arg value="-sdk-js-lib=${FLEXJS_HOME}/frameworks/js/FlexJS/libs" />
+             <arg value="${basedir}/src/main/flex/${example}.as" />
+         </java>
+         <fail>
+             <condition>
+                 <not>
+                     <or>
+                         <equals arg1="${errorCode}" arg2="0" />
+                         <equals arg1="${errorCode}" arg2="2" />
+                     </or>
+                 </not>
+             </condition>
+         </fail>        
+     </target>
+     
      <target name="clean">
          <delete dir="${basedir}/bin" failonerror="false" />
          <delete dir="${basedir}/bin-debug" failonerror="false" />

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/native/USStatesMap/pom.xml
----------------------------------------------------------------------
diff --cc examples/native/USStatesMap/pom.xml
index 2dac85b,13755b8..936866d
--- a/examples/native/USStatesMap/pom.xml
+++ b/examples/native/USStatesMap/pom.xml
@@@ -42,18 -42,10 +42,19 @@@
          <version>${flexjs.compiler.version}</version>
          <extensions>true</extensions>
          <configuration>
+           <outputJavaScript>true</outputJavaScript>
            <mainClass>USStatesMap.as</mainClass>
 +          <targets>JS</targets>
          </configuration>
        </plugin>
 +      <plugin>
 +        <groupId>org.apache.maven.plugins</groupId>
 +        <artifactId>maven-war-plugin</artifactId>
 +      </plugin>
 +      <plugin>
 +        <groupId>org.codehaus.mojo</groupId>
 +        <artifactId>build-helper-maven-plugin</artifactId>
 +      </plugin>
      </plugins>
    </build>
  

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/native/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/examples/pom.xml
----------------------------------------------------------------------
diff --cc examples/pom.xml
index 2ebcc32,412ce1a..9499b80
--- a/examples/pom.xml
+++ b/examples/pom.xml
@@@ -70,53 -71,21 +71,8 @@@
            <artifactId>flexjs-maven-plugin</artifactId>
            <version>${flexjs.compiler.version}</version>
            <extensions>true</extensions>
 -          <executions>
 -            <!-- Add a second execution with output set to JavaScript (Flash is the default) -->
 -            <execution>
 -              <id>compile-javascript</id>
 -              <phase>compile</phase>
 -              <goals>
 -                <goal>compile-app</goal>
 -              </goals>
 -              <configuration>
 -                <outputJavaScript>true</outputJavaScript>
 -              </configuration>
 -            </execution>
 -          </executions>
          </plugin>
          <plugin>
-           <groupId>org.apache.maven.plugins</groupId>
-           <artifactId>maven-war-plugin</artifactId>
-           <version>2.6</version>
-           <executions>
-             <execution>
-               <id>package-javascript</id>
-               <phase>package</phase>
-               <goals>
-                 <goal>war</goal>
-               </goals>
-             </execution>
-           </executions>
-           <configuration>
-             <warSourceDirectory>${compiler.output-dir}</warSourceDirectory>
-             <failOnMissingWebXml>false</failOnMissingWebXml>
-             <!--webResources>
-               <resource>
-                 <directory>${compiler.output-dir}</directory>
-               </resource>
-             </webResources-->
-           </configuration>
-         </plugin>
-         <plugin>
-           <groupId>org.codehaus.mojo</groupId>
-           <artifactId>build-helper-maven-plugin</artifactId>
-           <version>1.11</version>
-           <executions>
-             <execution>
-               <id>attach-war</id>
-               <phase>package</phase>
-               <goals>
-                 <goal>attach-artifact</goal>
-               </goals>
-             </execution>
-           </executions>
-           <configuration>
-             <artifacts>
-               <artifact>
-                 <file>${basedir}/target/${project.artifactId}-${project.version}.war</file>
-                 <type>war</type>
-               </artifact>
-             </artifacts>
-           </configuration>
-         </plugin>
-         <plugin>
            <groupId>org.jboss.errai</groupId>
            <artifactId>cordova-maven-plugin</artifactId>
            <version>4.0.0.Beta2</version>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/asdoc-config.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/BasicClasses.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/BasicClasses.as
index f43c962,a81838b..d709608
--- a/frameworks/projects/Basic/src/main/flex/BasicClasses.as
+++ b/frameworks/projects/Basic/src/main/flex/BasicClasses.as
@@@ -27,9 -27,9 +27,9 @@@ packag
   */
  internal class BasicClasses
  {
--
      import org.apache.flex.html.ToolTip; ToolTip;
  	import org.apache.flex.html.accessories.NumericOnlyTextInputBead; NumericOnlyTextInputBead;
++    import org.apache.flex.html.beads.DispatchInputFinishedBead; DispatchInputFinishedBead;
  	import org.apache.flex.html.accessories.PasswordInputBead; PasswordInputBead;
  	import org.apache.flex.html.accessories.TextPromptBead; TextPromptBead;
      import org.apache.flex.html.beads.AlertView; AlertView;
@@@ -42,9 -41,9 +42,10 @@@
  	COMPILE::SWF
  	{
  		import org.apache.flex.html.beads.CheckBoxView; CheckBoxView;
 -	    import org.apache.flex.html.beads.ComboBoxView; ComboBoxView;
  	}
 +    import org.apache.flex.html.beads.ComboBoxView; ComboBoxView;
      import org.apache.flex.html.beads.ContainerView; ContainerView;
++	import org.apache.flex.html.beads.GroupView; GroupView;
  	COMPILE::SWF
  	{
  	    import org.apache.flex.html.beads.ControlBarMeasurementBead; ControlBarMeasurementBead;
@@@ -66,23 -63,23 +67,27 @@@
  	    import org.apache.flex.html.beads.NumericStepperView; NumericStepperView;
  	}
      import org.apache.flex.html.beads.PanelView; PanelView;
++	import org.apache.flex.html.supportClasses.PanelLayoutProxy; PanelLayoutProxy;
 +    import org.apache.flex.html.beads.SliderView; SliderView;
+     import org.apache.flex.html.beads.PanelWithControlBarView; PanelWithControlBarView;
++    import org.apache.flex.html.beads.AccordionItemRendererView; AccordionItemRendererView;
  	COMPILE::SWF
  	{
- 	    import org.apache.flex.html.beads.PanelWithControlBarView; PanelWithControlBarView;
  		import org.apache.flex.html.beads.RadioButtonView; RadioButtonView;
  		import org.apache.flex.html.beads.VScrollBarView; VScrollBarView;
  		import org.apache.flex.html.beads.HScrollBarView; HScrollBarView;
      	import org.apache.flex.html.beads.ScrollBarView; ScrollBarView;
  		import org.apache.flex.html.beads.SimpleAlertView; SimpleAlertView;
      	import org.apache.flex.html.beads.SingleLineBorderBead; SingleLineBorderBead;
 -		import org.apache.flex.html.beads.SliderView; SliderView;
 +        import org.apache.flex.html.beads.SliderThumbView; SliderThumbView;
 +        import org.apache.flex.html.beads.SliderTrackView; SliderTrackView;
++		import org.apache.flex.html.beads.SingleLineBorderWithChangeListenerBead; SingleLineBorderWithChangeListenerBead;
  	}
 -	import org.apache.flex.html.beads.SliderThumbView; SliderThumbView;
 -	import org.apache.flex.html.beads.SliderTrackView; SliderTrackView;
  	import org.apache.flex.html.beads.SpinnerView; SpinnerView;
  	COMPILE::SWF
  	{
  		import org.apache.flex.html.beads.SolidBackgroundBead; SolidBackgroundBead;
++		import org.apache.flex.html.beads.SolidBackgroundWithChangeListenerBead; SolidBackgroundWithChangeListenerBead;
      	import org.apache.flex.html.beads.TextButtonMeasurementBead; TextButtonMeasurementBead;
  		import org.apache.flex.html.beads.TextFieldLabelMeasurementBead; TextFieldLabelMeasurementBead;
      	import org.apache.flex.html.beads.TextAreaView; TextAreaView;
@@@ -90,8 -87,8 +95,8 @@@
      	import org.apache.flex.html.beads.TextFieldView; TextFieldView;
      	import org.apache.flex.html.beads.TextInputView; TextInputView;
  	    import org.apache.flex.html.beads.TextInputWithBorderView; TextInputWithBorderView;
--	    import org.apache.flex.html.beads.models.AlertModel; AlertModel;
  	}
++	import org.apache.flex.html.beads.models.AlertModel; AlertModel
  	import org.apache.flex.html.beads.models.ArraySelectionModel; ArraySelectionModel;
  	import org.apache.flex.html.beads.models.ArrayListSelectionModel; ArrayListSelectionModel;
      import org.apache.flex.html.beads.models.RangeModel; RangeModel;
@@@ -135,7 -134,7 +140,9 @@@
  	}
  	import org.apache.flex.html.beads.layouts.ButtonBarLayout; ButtonBarLayout;
      import org.apache.flex.html.beads.layouts.VerticalLayout; VerticalLayout;
++	import org.apache.flex.html.beads.layouts.VerticalFlexLayout; VerticalFlexLayout;
  	import org.apache.flex.html.beads.layouts.HorizontalLayout; HorizontalLayout;
++	import org.apache.flex.html.beads.layouts.HorizontalFlexLayout; HorizontalFlexLayout;
      import org.apache.flex.html.beads.layouts.BasicLayout; BasicLayout;
  	import org.apache.flex.html.beads.layouts.OneFlexibleChildHorizontalLayout; OneFlexibleChildHorizontalLayout;
  	import org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout; OneFlexibleChildVerticalLayout;
@@@ -144,6 -143,6 +151,7 @@@
  	{
  		import org.apache.flex.html.beads.layouts.HScrollBarLayout; HScrollBarLayout;
      	import org.apache.flex.html.beads.layouts.VScrollBarLayout; VScrollBarLayout;
++		import org.apache.flex.html.supportClasses.ContainerContentArea; ContainerContentArea;
  	}
  	import org.apache.flex.html.beads.layouts.TileLayout; TileLayout;
      import org.apache.flex.html.beads.TextItemRendererFactoryForArrayData; TextItemRendererFactoryForArrayData;
@@@ -159,7 -158,7 +167,7 @@@
  	import org.apache.flex.html.DataGridButtonBar; DataGridButtonBar;
  	import org.apache.flex.html.beads.DataGridColumnView; DataGridColumnView;
  	import org.apache.flex.html.beads.DataGridView; DataGridView;
--	import org.apache.flex.html.beads.layouts.DataGridLayout; DataGridLayout;
++	import org.apache.flex.html.beads.DataGridPercentageView; DataGridPercentageView;
  	import org.apache.flex.html.beads.DateChooserView; DateChooserView;
  	import org.apache.flex.html.beads.DateFieldView; DateFieldView;
  	import org.apache.flex.html.beads.DecrementButtonView; DecrementButtonView;
@@@ -186,7 -183,7 +194,6 @@@
  	import org.apache.flex.html.beads.models.WebBrowserModel; WebBrowserModel;
  	
  	import org.apache.flex.core.ListBase; ListBase;
--	import org.apache.flex.core.ListBaseStrandChildren; ListBaseStrandChildren;
  	import org.apache.flex.core.FilledRectangle; FilledRectangle;
      import org.apache.flex.core.UIBase; UIBase;
      import org.apache.flex.core.SimpleApplication; SimpleApplication;
@@@ -213,6 -208,6 +220,8 @@@
  		import org.apache.flex.html.beads.VRuleView; VRuleView;
  		import org.apache.flex.html.beads.MultilineTextFieldView; MultilineTextFieldView;
  	}
++	
++	import org.apache.flex.html.SubAppLoader; SubAppLoader;
  }
  
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ContainerBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ContainerBase.as
index a5cb094,0dd0b53..0dcb0e3
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ContainerBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ContainerBase.as
@@@ -18,12 -18,12 +18,9 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.core
  {
--	import org.apache.flex.core.IMXMLDocument;
  	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.ValueChangeEvent;
--	import org.apache.flex.states.State;
--	import org.apache.flex.utils.MXMLDataInterpreter;
  
      /**
       *  Indicates that the state change has completed.  All properties
@@@ -59,8 -59,8 +56,6 @@@
       */
      [Event(name="childrenAdded", type="org.apache.flex.events.Event")]
      
--	[DefaultProperty("mxmlContent")]
--    
      /**
       *  The ContainerBase class is the base class for most containers
       *  in FlexJS.  It is usable as the root tag of MXML
@@@ -71,7 -71,7 +66,7 @@@
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class ContainerBase extends UIBase implements IMXMLDocument, IStatesObject, IContainer, IContentViewHost
++	public class ContainerBase extends GroupBase implements IStrandPrivate
  	{
          /**
           *  Constructor.
@@@ -84,8 -84,8 +79,6 @@@
  		public function ContainerBase()
  		{
  			super();
--            
--			_strandChildren = new ContainerBaseStrandChildren(this);
  		}
  		
  		private var _strandChildren:ContainerBaseStrandChildren;
@@@ -93,144 -93,135 +86,105 @@@
  		/**
  		 * @private
  		 */
--		public function get strandChildren():IParent
++		override public function get strandChildren():IParent
  		{
++			if (_strandChildren == null) {
++				_strandChildren = new ContainerBaseStrandChildren(this);
++			}
  			return _strandChildren;
  		}
--        
--        /**
--         *  @copy org.apache.flex.core.IParent#getElementAt()
--         * 
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        override public function getElementAt(index:int):IChild
--        {
--            var contentView:IParent = view as IParent;
--            if (contentView != null) {
--                return contentView.getElementAt(index);
--            } else {
--                return super.getElementAt(index);
--            }
--        }        
--        
--        /**
--         *  @private
--         */
--        override public function getElementIndex(c:IChild):int
--        {
--			var contentView:IParent = view as IParent;
--			if (contentView != null) {
--				return contentView.getElementIndex(c);
--			} else {
--				return super.getElementIndex(c);
--			}
--        }
--        
--        /**
--         *  @private
--         */
--        override public function addElement(c:IChild, dispatchEvent:Boolean = true):void
--        {
--			var contentView:IParent = view as IParent;
--			if (contentView != null) {
--				contentView.addElement(c, dispatchEvent);
--                if (dispatchEvent)
--                    this.dispatchEvent(new Event("childrenAdded"));
--			}
--			else {
--				super.addElement(c);
--			}
--        }
--        
--        /**
--         *  @private
--         */
--        override public function addElementAt(c:IChild, index:int, dispatchEvent:Boolean = true):void
--        {
--			var contentView:IParent = view as IParent;
--			if (contentView != null) {
--				contentView.addElementAt(c, index, dispatchEvent);
--                if (dispatchEvent)
--                    this.dispatchEvent(new Event("childrenAdded"));
--			}
--			else {
--				super.addElementAt(c, index);
--			}
--        }
--        
--        /**
--         *  @private
--         */
--        override public function removeElement(c:IChild, dispatchEvent:Boolean = true):void
--        {
--			var contentView:IParent = view as IParent;
--			if (contentView != null) {
--				contentView.removeElement(c, dispatchEvent);
--                if (dispatchEvent)
--                    this.dispatchEvent(new Event("childrenRemoved"));
--			}
--			else {
--				super.removeElement(c);
--			}
--        }
--        
--        /**
--         *  @private
--         */
--        public function childrenAdded():void
--        {
--            dispatchEvent(new Event("childrenAdded"));
--        }
--        
--        /**
--         *  A ContainerBase doesn't create its children until it is added to
--         *  a parent.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		override public function addedToParent():void
++		
++		/*
++		 * The following functions are for the SWF-side only and re-direct element functions
++		 * to the content area, enabling scrolling and clipping which are provided automatically
++		 * in the JS-side.
++		 */
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		override public function addElement(c:IChild, dispatchEvent:Boolean = true):void
 +		{
-             if (!_initialized)
-             {
-     			// each MXML file can also have styles in fx:Style block
-     			ValuesManager.valuesImpl.init(this);
-             }
-             
- 			super.addedToParent();
- 			
-             if (!_initialized)
-             {
-     			MXMLDataInterpreter.generateMXMLInstances(_mxmlDocument, this, MXMLDescriptor);
- 			
-                 dispatchEvent(new Event("initBindings"));
-     			dispatchEvent(new Event("initComplete"));
-                 _initialized = true;
-             }
++			var layoutHost:ILayoutHost = view as ILayoutHost;
++			var contentView:IParent = layoutHost.contentView as IParent;
++			contentView.addElement(c, dispatchEvent);
++		}
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		override public function addElementAt(c:IChild, index:int, dispatchEvent:Boolean = true):void
+ 		{
 -            if (!_initialized)
 -            {
 -    			// each MXML file can also have styles in fx:Style block
 -    			ValuesManager.valuesImpl.init(this);
 -            }
 -            
 -			super.addedToParent();
 -			
 -            if (!_initialized)
 -            {
 -    			MXMLDataInterpreter.generateMXMLInstances(_mxmlDocument, this, MXMLDescriptor);
 -			
 -                dispatchEvent(new Event("initBindings"));
 -    			dispatchEvent(new Event("initComplete"));
 -                _initialized = true;
 -            }
++			var layoutHost:ILayoutHost = view as ILayoutHost;
++			var contentView:IParent = layoutHost.contentView as IParent;
++			contentView.addElementAt(c, index, dispatchEvent);
  		}
  		
-         /**
-          *  @private
-          */
-         override public function get numElements():int
-         {
-             var contentView:IParent = view as IParent;
-             return contentView != null ? contentView.numElements : super.numElements;
-         }
-                 
+ 		/**
+ 		 * @private
++		 */
++		COMPILE::SWF
++		override public function getElementIndex(c:IChild):int
++		{
++			var layoutHost:ILayoutHost = view as ILayoutHost;
++			var contentView:IParent = layoutHost.contentView as IParent;
++			return contentView.getElementIndex(c);
++		}
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		override public function removeElement(c:IChild, dispatchEvent:Boolean = true):void
++		{
++			var layoutHost:ILayoutHost = view as ILayoutHost;
++			var contentView:IParent = layoutHost.contentView as IParent;
++			contentView.removeElement(c, dispatchEvent);
++		}
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		override public function get numElements():int
++		{
++			var layoutHost:ILayoutHost = view as ILayoutHost;
++			var contentView:IParent = layoutHost.contentView as IParent;
++			return contentView.numElements;
++		}
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		override public function getElementAt(index:int):IChild
++		{
++			var layoutHost:ILayoutHost = view as ILayoutHost;
++			var contentView:IParent = layoutHost.contentView as IParent;
++			return contentView.getElementAt(index);
++		}
++
++		/*
++		 * IStrandPrivate
++		 *
++		 * These "internal" function provide a backdoor way for proxy classes to
++		 * operate directly at strand level. While these function are available on
++		 * both SWF and JS platforms, they really only have meaning on the SWF-side. 
++		 * Other subclasses may provide use on the JS-side.
++		 *
++		 * @see org.apache.flex.core.IContainer#strandChildren
++		 */
++		
 +		/**
 +		 * @private
           * @suppress {undefinedNames}
  		 * Support strandChildren.
  		 */
  		public function $numElements():int
  		{
--			return super.numElements();
++			return super.numElements;
  		}
  		
  		/**
@@@ -283,170 -274,170 +237,5 @@@
  			return super.getElementAt(index);
  		}
  
--        private var _mxmlDescriptor:Array;
--        private var _mxmlDocument:Object = this;
--        private var _initialized:Boolean;
--        
--        /**
--         *  @copy org.apache.flex.core.Application#MXMLDescriptor
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		public function get MXMLDescriptor():Array
--		{
--			return _mxmlDescriptor;
--		}
--
--        /**
--         *  @private
--         */
--        public function setMXMLDescriptor(document:Object, value:Array):void
--        {
--            _mxmlDocument = document;
--            _mxmlDescriptor = value;
--        }
--
--        /**
--         *  @copy org.apache.flex.core.Application#generateMXMLAttributes()
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		public function generateMXMLAttributes(data:Array):void
--		{
--            MXMLDataInterpreter.generateMXMLProperties(this, data);
--		}
--		
--        /**
--         *  @copy org.apache.flex.core.ItemRendererClassFactory#mxmlContent
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		public var mxmlContent:Array;
--		
--        private var _states:Array;
--        
--        /**
--         *  The array of view states. These should
--         *  be instances of org.apache.flex.states.State.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        public function get states():Array
--        {
--            return _states;
--        }
--
--        /**
--         *  @private
--         *  @flexjsignorecoercion Class
--         *  @flexjsignorecoercion org.apache.flex.core.IBead
--         */
--        public function set states(value:Array):void
--        {
--            _states = value;
--            _currentState = _states[0].name;
--            
--			try{
--				if (getBeadByType(IStatesImpl) == null)
--                {
--                    var c:Class = ValuesManager.valuesImpl.getValue(this, "iStatesImpl") as Class;
--                    var b:Object = new c();
--					addBead(b as IBead);
--                }
--			}
--			//TODO:  Need to handle this case more gracefully
--			catch(e:Error)
--			{
--                COMPILE::SWF
--                {
--                    trace(e.message);                        
--                }
--			}
--            
--        }
--        
--        /**
--         *  <code>true</code> if the array of states
--         *  contains a state with this name.
--         * 
--         *  @param state The state namem.
--         *  @return True if state in state array
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        public function hasState(state:String):Boolean
--        {
--            for each (var s:State in _states)
--            {
--                if (s.name == state)
--                    return true;
--            }
--            return false;
--        }
--        
--        private var _currentState:String;
--        
--        [Bindable("currentStateChange")]
--        /**
--         *  The name of the current state.
--         * 
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        public function get currentState():String
--        {
--            return _currentState;   
--        }
--
--        /**
--         *  @private
--         */
--        public function set currentState(value:String):void
--        {
--            var event:ValueChangeEvent = new ValueChangeEvent("currentStateChange", false, false, _currentState, value)
--            _currentState = value;
--            dispatchEvent(event);
--        }
--        
--        private var _transitions:Array;
--        
--        /**
--         *  The array of transitions.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        public function get transitions():Array
--        {
--            return _transitions;   
--        }
--        
--        /**
--         *  @private
--         */
--        public function set transitions(value:Array):void
--        {
--            _transitions = value;   
--        }
--
      }
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ContainerBaseStrandChildren.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ContainerBaseStrandChildren.as
index e961c1f,e961c1f..d831004
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ContainerBaseStrandChildren.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ContainerBaseStrandChildren.as
@@@ -43,10 -43,10 +43,10 @@@ package org.apache.flex.cor
  		{
  			super();
  			
--			this.owner = owner as ContainerBase;
++			this.owner = owner as IStrandPrivate;
  		}
  		
--		public var owner:ContainerBase;
++		public var owner:IStrandPrivate;
  		
  		/**
  		 *  @private

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/DataContainerBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/DataContainerBase.as
index 0000000,0000000..0f03f67
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/DataContainerBase.as
@@@ -1,0 -1,0 +1,278 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.core
++{
++	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.html.beads.IListView;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.ItemAddedEvent;
++	import org.apache.flex.events.ItemClickedEvent;
++	import org.apache.flex.events.ItemRemovedEvent;
++	import org.apache.flex.events.ValueChangeEvent;
++	import org.apache.flex.states.State;
++	import org.apache.flex.html.supportClasses.DataItemRenderer;
++	
++	/**
++	 *  Indicates that the initialization of the list is complete.
++	 *
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	[Event(name="initComplete", type="org.apache.flex.events.Event")]
++    
++    /**
++     *  The DataContainerBase class is the base class for components that
++	 *  that have generated content, like lists.
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public class DataContainerBase extends ContainerBase implements IItemRendererParent, IList
++	{
++        /**
++         *  Constructor.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function DataContainerBase()
++		{
++			super();
++		}
++		
++		/*
++		* UIBase
++		*/
++		
++		/**
++		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
++		 */
++		COMPILE::JS
++		override protected function createElement():WrappedHTMLElement
++		{
++			super.createElement();
++			className = 'DataContainer';
++			
++			return element;
++		}
++		
++		private var _DCinitialized:Boolean;
++		
++		/**
++		 * @private
++		 */
++		override public function addedToParent():void
++		{
++			if (!_DCinitialized)
++			{
++				ValuesManager.valuesImpl.init(this);
++				_DCinitialized = true;
++			}
++			
++			super.addedToParent();
++			
++			// Even though super.addedToParent dispatched "beadsAdded", DataContainer still needs its data mapper
++			// and item factory beads. These beads are added after super.addedToParent is called in case substitutions
++			// were made; these are just defaults extracted from CSS.
++			
++			if (getBeadByType(IDataProviderItemRendererMapper) == null)
++			{
++				var mapper:IDataProviderItemRendererMapper = new (ValuesManager.valuesImpl.getValue(this, "iDataProviderItemRendererMapper")) as IDataProviderItemRendererMapper;
++				addBead(mapper);
++			}
++			var itemRendererFactory:IItemRendererClassFactory = getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
++			if (!itemRendererFactory)
++			{
++				itemRendererFactory = new (ValuesManager.valuesImpl.getValue(this, "iItemRendererClassFactory")) as IItemRendererClassFactory;
++				addBead(itemRendererFactory);
++			}
++			
++			dispatchEvent(new Event("initComplete"));
++		}
++		
++		/*
++		 * IList
++		 */
++		
++		/**
++		 * Returns the sub-component that parents all of the item renderers.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get dataGroup():IItemRendererParent
++		{
++			// The JS-side's view.dataGroup is actually this instance of DataContainerBase
++			return (view as IListView).dataGroup;
++		}
++		
++		/*
++		* IItemRendererProvider
++		*/
++		
++		private var _itemRenderer:IFactory;
++		
++		/**
++		 *  The class or factory used to display each item.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get itemRenderer():IFactory
++		{
++			return _itemRenderer;
++		}
++		public function set itemRenderer(value:IFactory):void
++		{
++			_itemRenderer = value;
++		}
++		
++		/**
++		 * Returns whether or not the itemRenderer property has been set.
++		 *
++		 *  @see org.apache.flex.core.IItemRendererProvider
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get hasItemRenderer():Boolean
++		{
++			var result:Boolean = false;
++			
++			COMPILE::SWF {
++				result = _itemRenderer != null;
++			}
++				
++				COMPILE::JS {
++					var test:* = _itemRenderer;
++					result = _itemRenderer !== null && test !== undefined;
++				}
++				
++				return result;
++		}
++		
++		/*
++		* IItemRendererParent
++		*/
++		
++		/**
++		 * @copy org.apache.flex.core.IItemRendererParent#addItemRenderer()
++		 * @private
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function addItemRenderer(renderer:IItemRenderer):void
++		{
++			addElement(renderer, true);
++			
++			var newEvent:ItemAddedEvent = new ItemAddedEvent("itemAdded");
++			newEvent.item = renderer;
++			
++			dispatchEvent(newEvent);
++		}
++		
++		/**
++		 * @copy org.apache.flex.core.IItemRendererParent#removeItemRenderer()
++		 * @private
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function removeItemRenderer(renderer:IItemRenderer):void
++		{
++			removeElement(renderer, true);
++			
++			var newEvent:ItemRemovedEvent = new ItemRemovedEvent("itemRemoved");
++			newEvent.item = renderer;
++			
++			dispatchEvent(newEvent);
++		}
++		
++		/**
++		 * @copy org.apache.flex.core.IItemRendererParent#removeAllItemRenderers()
++		 * @private
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function removeAllItemRenderers():void
++		{
++			while (numElements > 0) {
++				var child:IChild = getElementAt(0);
++				removeElement(child);
++			}
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.IItemRendererParent#getItemRendererForIndex()
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function getItemRendererForIndex(index:int):IItemRenderer
++		{
++			if (index < 0 || index >= numElements) return null;
++			return getElementAt(index) as IItemRenderer;
++		}
++		
++		/**
++		 *  Refreshes the itemRenderers. Useful after a size change by the data group.
++		 *
++		 *  @copy org.apache.flex.core.IItemRendererParent#updateAllItemRenderers()
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function updateAllItemRenderers():void
++		{
++			var n:Number = numElements;
++			for (var i:Number = 0; i < n; i++)
++			{
++				var renderer:DataItemRenderer = getItemRendererForIndex(i) as DataItemRenderer;
++				if (renderer) {
++					renderer.setWidth(this.width,true);
++					renderer.adjustSize();
++				}
++			}
++		}
++
++    }
++}


[13/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - lost this event metadata in the merge

Posted by ah...@apache.org.
lost this event metadata in the merge


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/358a06f1
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/358a06f1
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/358a06f1

Branch: refs/heads/develop
Commit: 358a06f1a6720958ea85c487a2dddf396ade66e7
Parents: 9fd9b78
Author: Alex Harui <ah...@apache.org>
Authored: Tue Apr 18 08:47:42 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Tue Apr 18 08:47:42 2017 -0700

----------------------------------------------------------------------
 .../Basic/src/main/flex/org/apache/flex/html/CheckBox.as  | 10 ++++++++++
 1 file changed, 10 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/358a06f1/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as
index ef78a05..d8e8568 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as
@@ -132,6 +132,16 @@ package org.apache.flex.html
 		}
 	}
 
+    /**
+     *  Dispatched when the user checks or un-checks the CheckBox.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10.2
+     *  @playerversion AIR 2.6
+     *  @productversion FlexJS 0.0
+     */
+	[Event(name="change", type="org.apache.flex.events.Event")]
+
     COMPILE::JS
     public class CheckBox extends UIBase
     {


[18/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - get stock quotes to work again

Posted by ah...@apache.org.
get stock quotes to work again


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/31e3c55b
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/31e3c55b
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/31e3c55b

Branch: refs/heads/develop
Commit: 31e3c55be37020b1e0afed2e86490872624156cc
Parents: 4941e12
Author: Alex Harui <ah...@apache.org>
Authored: Fri Apr 21 09:31:26 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Apr 21 09:31:26 2017 -0700

----------------------------------------------------------------------
 .../DataBindingExample/src/main/flex/controllers/MyController.as | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/31e3c55b/examples/flexjs/DataBindingExample/src/main/flex/controllers/MyController.as
----------------------------------------------------------------------
diff --git a/examples/flexjs/DataBindingExample/src/main/flex/controllers/MyController.as b/examples/flexjs/DataBindingExample/src/main/flex/controllers/MyController.as
index b7d52bd..6487908 100644
--- a/examples/flexjs/DataBindingExample/src/main/flex/controllers/MyController.as
+++ b/examples/flexjs/DataBindingExample/src/main/flex/controllers/MyController.as
@@ -42,8 +42,8 @@ package controllers
 		private var service:HTTPService;
 		private var collection:LazyCollection;
 
-        private var queryBegin:String = "http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20yahoo.finance.quotes%20where%20symbol%20in%20(%22";
-        private var queryEnd:String = "%22)%0A%09%09&env=http%3A%2F%2Fdatatables.org%2Falltables.env&format=json";
+        private var queryBegin:String = "https://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20yahoo.finance.quotes%20where%20symbol%20in%20(%22";
+        private var queryEnd:String = "%22)%0A%09%09&env=store%3A%2F%2Fdatatables.org%2Falltableswithkeys&format=json";
 
 		private function viewChangeHandler(event:Event):void
 		{


[26/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'dual' of https://git-wip-us.apache.org/repos/asf/flex-asjs into dual

Posted by ah...@apache.org.
Merge branch 'dual' of https://git-wip-us.apache.org/repos/asf/flex-asjs into dual

# By Alex Harui
# Via Alex Harui
* 'dual' of https://git-wip-us.apache.org/repos/asf/flex-asjs:
  switch TextArea width back to 300
  in the browser, %width is applied even if parent is sizedToContent, so make SWF do the samething


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/08650525
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/08650525
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/08650525

Branch: refs/heads/develop
Commit: 086505252013a0e5de594455ab429b73a33deace
Parents: a168d45 8256ea5
Author: Peter Ent <pe...@apache.org>
Authored: Mon Apr 24 15:25:32 2017 -0400
Committer: Peter Ent <pe...@apache.org>
Committed: Mon Apr 24 15:25:32 2017 -0400

----------------------------------------------------------------------
 .../DataBindingExample/src/main/flex/MyInitialView.mxml   |  2 +-
 .../apache/flex/html/beads/layouts/VerticalFlexLayout.as  | 10 +++++-----
 2 files changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------



[40/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - another scenario that needs drawing

Posted by ah...@apache.org.
another scenario that needs drawing


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/7de620af
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/7de620af
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/7de620af

Branch: refs/heads/develop
Commit: 7de620afad5ce05dedb10762eaa2272b1d35b11f
Parents: 5734ef1
Author: Alex Harui <ah...@apache.org>
Authored: Wed Apr 26 22:49:08 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 14:15:18 2017 -0700

----------------------------------------------------------------------
 .../flex/org/apache/flex/html/beads/TextInputWithBorderView.as  | 5 +++++
 1 file changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/7de620af/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputWithBorderView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputWithBorderView.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputWithBorderView.as
index fbab13e..5db680c 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputWithBorderView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputWithBorderView.as
@@ -61,6 +61,11 @@ package org.apache.flex.html.beads
 			
             value.addBead(new (ValuesManager.valuesImpl.getValue(value, "iBackgroundBead")) as IBead);
 			value.addBead(new (ValuesManager.valuesImpl.getValue(value, "iBorderBead")) as IBead);
+			
+			// if we aren't going to get resized, draw the border now
+            var ilc:ILayoutChild = host as ILayoutChild;
+            if (ilc.isWidthSizedToContent() && !isNaN(ilc.explicitHeight))
+				ilc.dispatchEvent(new Event("initComplete"));
 		}
 
         /**


[23/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - in the browser, %width is applied even if parent is sizedToContent, so make SWF do the samething

Posted by ah...@apache.org.
in the browser, %width is applied even if parent is sizedToContent, so make SWF do the samething


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/925a08d3
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/925a08d3
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/925a08d3

Branch: refs/heads/develop
Commit: 925a08d3b3aa84a07ca3d29dde9f429233c3e9fb
Parents: 9ae73e0
Author: Alex Harui <ah...@apache.org>
Authored: Mon Apr 24 10:47:31 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Mon Apr 24 10:47:31 2017 -0700

----------------------------------------------------------------------
 .../apache/flex/html/beads/layouts/VerticalFlexLayout.as  | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/925a08d3/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
index c543425..bdc080d 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
@@ -159,11 +159,11 @@ package org.apache.flex.html.beads.layouts
 					}
 
 					var useWidth:Number = -1;
-					if (!hostWidthSizedToContent) {
-						if (ilc) {
-							if (!isNaN(ilc.percentWidth)) useWidth = hostWidth * (ilc.percentWidth/100.0);
-							else if (!isNaN(ilc.explicitWidth)) useWidth = ilc.explicitWidth;
-							else useWidth = hostWidth;
+					if (ilc) {
+						if (!isNaN(ilc.percentWidth)) useWidth = hostWidth * (ilc.percentWidth/100.0);
+						else if (!isNaN(ilc.explicitWidth)) useWidth = ilc.explicitWidth;
+						else if (!hostWidthSizedToContent) {
+							useWidth = hostWidth;
 						}
 					}
 


[47/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Added a default height to TextInput just like default width.

Posted by ah...@apache.org.
Added a default height to TextInput just like default width.


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/bfb15c88
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/bfb15c88
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/bfb15c88

Branch: refs/heads/develop
Commit: bfb15c881850a87f48607ded6e8bcd1e878cc679
Parents: 90764bc
Author: Peter Ent <pe...@apache.org>
Authored: Sun Apr 30 07:54:29 2017 -0400
Committer: Peter Ent <pe...@apache.org>
Committed: Sun Apr 30 07:54:29 2017 -0400

----------------------------------------------------------------------
 .../src/main/flex/org/apache/flex/html/beads/TextInputView.as      | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/bfb15c88/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as
index be59056..9d27974 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as
@@ -99,6 +99,8 @@ package org.apache.flex.html.beads
                     textField.text = s;                    
                 }
                 ilc.setHeight(h + uiMetrics.top + uiMetrics.bottom, true);
+				// TextInput doesn't stretch if no height like divs do
+				ilc.explicitHeight = ilc.height;
             }
 			
 			heightChangeHandler(null);


[28/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Adding VGroup and HGroup classes to dual branch.

Posted by ah...@apache.org.
Adding VGroup and HGroup classes to dual branch.


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/f22668ba
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/f22668ba
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/f22668ba

Branch: refs/heads/develop
Commit: f22668baa44a9b6aca68493bde9cfd9b2a3c1a17
Parents: 8d8ba2f
Author: Peter Ent <pe...@apache.org>
Authored: Tue Apr 25 09:19:30 2017 -0400
Committer: Peter Ent <pe...@apache.org>
Committed: Tue Apr 25 09:19:30 2017 -0400

----------------------------------------------------------------------
 .../main/flex/org/apache/flex/html/HGroup.as    | 46 ++++++++++++++++++++
 .../main/flex/org/apache/flex/html/VGroup.as    | 46 ++++++++++++++++++++
 .../Basic/src/main/resources/basic-manifest.xml |  2 +
 .../Basic/src/main/resources/defaults.css       | 10 +++++
 4 files changed, 104 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f22668ba/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HGroup.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HGroup.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HGroup.as
new file mode 100644
index 0000000..c228d26
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HGroup.as
@@ -0,0 +1,46 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.html
+{
+    /**
+     *  This Group subclass uses HorizontalLayout as its default layout.
+     *
+     *  @toplevel
+     *  @see org.apache.flex.html.beads.layout
+     *  @langversion 3.0
+     *  @playerversion Flash 10.2
+     *  @playerversion AIR 2.6
+     *  @productversion FlexJS 0.8
+     */
+	public class HGroup extends Group
+	{
+        /**
+         *  Constructor.
+         *
+         *  @langversion 3.0
+         *  @playerversion Flash 10.2
+         *  @playerversion AIR 2.6
+         *  @productversion FlexJS 0.8
+         */
+		public function HGroup()
+		{
+			super();
+		}
+	}
+}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f22668ba/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VGroup.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VGroup.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VGroup.as
new file mode 100644
index 0000000..03d3e4f
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/VGroup.as
@@ -0,0 +1,46 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.html
+{
+    /**
+     *  This Group subclass uses VerticalLayout as its default layout.
+     *
+     *  @toplevel
+     *  @see org.apache.flex.html.beads.layout
+     *  @langversion 3.0
+     *  @playerversion Flash 10.2
+     *  @playerversion AIR 2.6
+     *  @productversion FlexJS 0.8
+     */
+	public class VGroup extends Group
+	{
+        /**
+         *  Constructor.
+         *
+         *  @langversion 3.0
+         *  @playerversion Flash 10.2
+         *  @playerversion AIR 2.6
+         *  @productversion FlexJS 0.8
+         */
+		public function VGroup()
+		{
+			super();
+		}
+	}
+}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f22668ba/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml b/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
index 4e3d261..c9b49b8 100644
--- a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
@@ -47,6 +47,8 @@
     <component id="ComboBoxList" class="org.apache.flex.html.supportClasses.ComboBoxList"/>
     <component id="Container" class="org.apache.flex.html.Container"/>
     <component id="Group" class="org.apache.flex.html.Group"/>
+    <component id="HGroup" class="org.apache.flex.html.HGroup"/>
+    <component id="VGroup" class="org.apache.flex.html.VGroup"/>
     <component id="Accordion" class="org.apache.flex.html.Accordion"/>
     <component id="Form" class="org.apache.flex.html.Form"/>
     <component id="HContainer" class="org.apache.flex.html.HContainer"/>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f22668ba/frameworks/projects/Basic/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/resources/defaults.css b/frameworks/projects/Basic/src/main/resources/defaults.css
index 1a944dd..f2893ce 100644
--- a/frameworks/projects/Basic/src/main/resources/defaults.css
+++ b/frameworks/projects/Basic/src/main/resources/defaults.css
@@ -267,6 +267,16 @@ DateField {
 	IFormatBead: ClassReference("org.apache.flex.html.accessories.DateFormatYYYYMMDDBead");
 }
 
+/* Groups */
+
+HGroup {
+	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalLayout");
+}
+
+VGroup {
+	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
+}
+
 /* RangeStepper */
 
 RangeStepper {


[20/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - make sure Basic is in maven build

Posted by ah...@apache.org.
make sure Basic is in maven build


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/c07b2b3b
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/c07b2b3b
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/c07b2b3b

Branch: refs/heads/develop
Commit: c07b2b3bf2da762324c5cda70a38c913f9015b95
Parents: 6af0a47
Author: Alex Harui <ah...@apache.org>
Authored: Fri Apr 21 10:15:11 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Apr 21 10:15:11 2017 -0700

----------------------------------------------------------------------
 frameworks/projects/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/c07b2b3b/frameworks/projects/pom.xml
----------------------------------------------------------------------
diff --git a/frameworks/projects/pom.xml b/frameworks/projects/pom.xml
index 66e9019..2d4e6b4 100644
--- a/frameworks/projects/pom.xml
+++ b/frameworks/projects/pom.xml
@@ -37,6 +37,7 @@
     <module>Charts</module>
     <module>Collections</module>
     <module>Core</module>
+    <module>Basic</module>
     <module>CreateJS</module>
     <module>DragDrop</module>
     <module>Effects</module>
@@ -46,7 +47,6 @@
     <module>FontAwesome</module>
     <module>GoogleMaps</module>
     <module>Graphics</module>
-    <!--<module>Basic</module>-->
     <module>HTML</module>
     <module>HTML5</module>
     <module>JQuery</module>


[14/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/HTML/src/main/resources/basic-manifest.xml
index 3d60024,4778ae8..4a47ba4
--- a/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
@@@ -21,8 -21,140 +21,6 @@@
  
  <componentPackage>
  
 -    <component id="Application" class="org.apache.flex.core.Application"/>
 -    <component id="View" class="org.apache.flex.core.View"/>
 -    <component id="Button" class="org.apache.flex.html.Button"/>
 -    <component id="CloseButton" class="org.apache.flex.html.CloseButton"/>
 -    <component id="ButtonBar" class="org.apache.flex.html.ButtonBar"/>
 -    <component id="DropDownList" class="org.apache.flex.html.DropDownList"/>
 -    <component id="DropDownListList" class="org.apache.flex.html.supportClasses.DropDownListList"/>
 -    <component id="Image" class="org.apache.flex.html.Image"/>
 -    <component id="BinaryImage" class="org.apache.flex.html.BinaryImage"/>
 -    <component id="Label" class="org.apache.flex.html.Label"/>
--	<component id="HTMLText" class="org.apache.flex.html.HTMLText"/>
 -    <component id="MultilineLabel" class="org.apache.flex.html.MultilineLabel"/>
 -    <component id="ImageAndTextButton" class="org.apache.flex.html.ImageAndTextButton"/>
 -    <component id="TextButton" class="org.apache.flex.html.TextButton"/>
 -    <component id="ToggleTextButton" class="org.apache.flex.html.ToggleTextButton"/>
 -    <component id="TextInput" class="org.apache.flex.html.TextInput"/>
 -    <component id="TextArea" class="org.apache.flex.html.TextArea"/>
 -    <component id="DataContainer" class="org.apache.flex.html.DataContainer"/>
 -    <component id="List" class="org.apache.flex.html.List"/>
 -    <component id="SimpleList" class="org.apache.flex.html.SimpleList"/>
 -    <component id="CheckBox" class="org.apache.flex.html.CheckBox"/>
 -    <component id="CSSCheckBox" class="org.apache.flex.html.CSSCheckBox"/>
 -    <component id="RadioButton" class="org.apache.flex.html.RadioButton"/>
 -    <component id="ComboBox" class="org.apache.flex.html.ComboBox"/>
 -    <component id="ComboBoxList" class="org.apache.flex.html.supportClasses.ComboBoxList"/>
 -    <component id="Container" class="org.apache.flex.html.Container"/>
 -    <component id="Group" class="org.apache.flex.html.Group"/>
 -    <component id="Accordion" class="org.apache.flex.html.Accordion"/>
 -    <component id="Form" class="org.apache.flex.html.Form"/>
 -    <component id="HContainer" class="org.apache.flex.html.HContainer"/>
 -    <component id="VContainer" class="org.apache.flex.html.VContainer"/>
 -    <component id="Panel" class="org.apache.flex.html.Panel"/>
 -    <component id="PanelView" class="org.apache.flex.html.beads.PanelView"/>
 -    <component id="ImageView" class="org.apache.flex.html.beads.ImageView"/>
 -    <component id="PanelWithControlBar" class="org.apache.flex.html.PanelWithControlBar"/>
 -    <component id="PanelWithControlBarView" class="org.apache.flex.html.beads.PanelWithControlBarView"/>
 -    <component id="ControlBar" class="org.apache.flex.html.ControlBar"/>
 -    <component id="RangeStepper" class="org.apache.flex.html.RangeStepper" />
 -    <component id="TitleBar" class="org.apache.flex.html.TitleBar"/>
 -    <component id="ImageModel" class="org.apache.flex.html.beads.models.ImageModel"/>
 -    <component id="TitleBarModel" class="org.apache.flex.html.beads.models.TitleBarModel"/>
 -    <component id="ToolTip" class="org.apache.flex.html.ToolTip"/>
 -    <component id="Tree" class="org.apache.flex.html.Tree"/>
 -    <component id="BasicLayout" class="org.apache.flex.html.beads.layouts.BasicLayout"/>
 -    <component id="VerticalLayout" class="org.apache.flex.html.beads.layouts.VerticalLayout"/>
 -    <component id="VerticalFlexLayout" class="org.apache.flex.html.beads.layouts.VerticalFlexLayout"/>
 -    <component id="HorizontalLayout" class="org.apache.flex.html.beads.layouts.HorizontalLayout"/>
 -    <component id="HorizontalFlexLayout" class="org.apache.flex.html.beads.layouts.HorizontalFlexLayout"/>
 -    <component id="HorizontalFlowLayout" class="org.apache.flex.html.beads.layouts.HorizontalFlowLayout" />
 -    <component id="TileLayout" class="org.apache.flex.html.beads.layouts.TileLayout"/>
 -    <component id="ListView" class="org.apache.flex.html.beads.ListView"/>
 -    <component id="AccordionView" class="org.apache.flex.html.beads.AccordionView"/>
 -    <component id="CenterElement" class="org.apache.flex.html.beads.CenterElement"/>
 -    <!--<component id="MultilineTextFieldView" class="org.apache.flex.html.beads.MultilineTextFieldView"/>-->
 -    
 -    <component id="SimpleAlert" class="org.apache.flex.html.SimpleAlert"/>
 -    <component id="Alert" class="org.apache.flex.html.Alert"/>
 -    <component id="Spinner" class="org.apache.flex.html.Spinner"/>
 -    <component id="Slider" class="org.apache.flex.html.Slider"/>
 -    <component id="NumericStepper" class="org.apache.flex.html.NumericStepper" />
 -    <component id="StringItemRenderer" class="org.apache.flex.html.supportClasses.StringItemRenderer"/>
 -    <component id="AccordionItemRenderer" class="org.apache.flex.html.supportClasses.AccordionItemRenderer"/>
 -    <component id="AccordionCollapseBead" class="org.apache.flex.html.beads.AccordionCollapseBead"/>
 -    <component id="DispatchInputFinishedBead" class="org.apache.flex.html.beads.DispatchInputFinishedBead"/>
 -    <component id="DispatchKeyboardEventBead" class="org.apache.flex.html.beads.DispatchKeyboardEventBead"/>
 -    <component id="TreeItemRenderer" class="org.apache.flex.html.supportClasses.TreeItemRenderer"/>
 -    <component id="DataItemRenderer" class="org.apache.flex.html.supportClasses.DataItemRenderer"/>
 -    <component id="MXMLItemRenderer" class="org.apache.flex.html.supportClasses.MXMLItemRenderer"/>
 -    <component id="DateItemRenderer" class="org.apache.flex.html.supportClasses.DateItemRenderer"/>
 -    <component id="DayNameItemRenderer" class="org.apache.flex.html.supportClasses.DayNameItemRenderer"/>
 -    <component id="TextButtonItemRenderer" class="org.apache.flex.html.supportClasses.TextButtonItemRenderer"/>
 -    <!--
 -     <component id="TextFieldItemRenderer" class="org.apache.flex.html.supportClasses.TextFieldItemRenderer"/>
 -    <component id="HScrollBar" class="org.apache.flex.html.supportClasses.HScrollBar"/>
 -    <component id="VScrollBar" class="org.apache.flex.html.supportClasses.VScrollBar"/>
 -     <component id="HRuleView" class="org.apache.flex.html.beads.HRuleView" />
 -     <component id="VRuleView" class="org.apache.flex.html.beads.VRuleView" />
 -     -->
 -    <component id="UnselectableElementBead" class="org.apache.flex.html.beads.UnselectableElementBead"/>
 -    <component id="DisableBead" class="org.apache.flex.html.beads.DisableBead" />
 -    <component id="NumericOnlyTextInputBead" class="org.apache.flex.html.accessories.NumericOnlyTextInputBead" />
 -    <component id="PasswordInputBead" class="org.apache.flex.html.accessories.PasswordInputBead" />
 -    <component id="TextPromptBead" class="org.apache.flex.html.accessories.TextPromptBead" />
 -    <component id="HRule" class="org.apache.flex.html.HRule" />
 -    <component id="VRule" class="org.apache.flex.html.VRule" />
 -    <component id="Spacer" class="org.apache.flex.html.Spacer" />
 -    <!--
 -    <component id="ImageAndTextButtonView" class="org.apache.flex.html.beads.ImageAndTextButtonView" />
 -     -->
 -    <component id="ScrollingViewport" class="org.apache.flex.html.supportClasses.ScrollingViewport" />
 -    <component id="ClippingViewport" class="org.apache.flex.html.supportClasses.ClippingViewport" />
 -    
 -    <component id="ArraySelectionModel" class="org.apache.flex.html.beads.models.ArraySelectionModel" />
 -    <component id="ArrayListSelectionModel" class="org.apache.flex.html.beads.models.ArrayListSelectionModel" />
 -
 -    <component id="DataGrid" class="org.apache.flex.html.DataGrid"/>
 -    <component id="DataProviderChangeNotifier" class="org.apache.flex.html.beads.DataProviderChangeNotifier"/>
 -    <component id="DataProviderCollectionChangeNotifier" class="org.apache.flex.html.beads.DataProviderCollectionChangeNotifier"/>
 -    <component id="DataProviderItemsChangeNotifier" class="org.apache.flex.html.beads.DataProviderItemsChangeNotifier"/>
 -    <component id="DataGridButtonBar" class="org.apache.flex.html.DataGridButtonBar"/>
 -    <component id="DataGridButtonBarTextButton" class="org.apache.flex.html.DataGridButtonBarTextButton"/>
 -    <component id="DataGridColumn" class="org.apache.flex.html.supportClasses.DataGridColumn"/>
 -    <component id="DataGridLinesBead" class="org.apache.flex.html.beads.DataGridLinesBead"/>
 -    <component id="DataGridColumnList" class="org.apache.flex.html.supportClasses.DataGridColumnList"/>
 -    <component id="DataGridPercentageView" class="org.apache.flex.html.beads.DataGridPercentageView" />
 -    
 -    <component id="DataItemRendererFactoryForArrayData" class="org.apache.flex.html.beads.DataItemRendererFactoryForArrayData" />
 -    <component id="DataItemRendererFactoryForArrayList" class="org.apache.flex.html.beads.DataItemRendererFactoryForArrayList" />
 -    <component id="DataItemRendererFactoryForHierarchicalData" class="org.apache.flex.html.beads.DataItemRendererFactoryForHierarchicalData" />
 -    <component id="TextItemRendererFactoryForArrayData" class="org.apache.flex.html.beads.TextItemRendererFactoryForArrayData" />
 -    <component id="TextItemRendererFactoryForStringVectorData" class="org.apache.flex.html.beads.TextItemRendererFactoryForStringVectorData" />
 -
 -    <component id="DateChooser" class="org.apache.flex.html.DateChooser"/>
 -    <component id="DateChooserList" class="org.apache.flex.html.supportClasses.DateChooserList" />
 -    <component id="DateChooserHeader" class="org.apache.flex.html.supportClasses.DateChooserHeader" />
 -    <component id="DateField" class="org.apache.flex.html.DateField"/>
 -    <component id="VerticalColumnLayout" class="org.apache.flex.html.beads.layouts.VerticalColumnLayout" />
 -
 -    <component id="ToolTipBead" class="org.apache.flex.html.accessories.ToolTipBead" />
 -
 -    <component id="LayoutChangeNotifier" class="org.apache.flex.html.beads.layouts.LayoutChangeNotifier"/>
 -    <component id="LayoutOnShow" class="org.apache.flex.html.beads.layouts.LayoutOnShow"/>
 -    <component id="ImageButton" class="org.apache.flex.html.ImageButton"/>
 -    <component id="FlexibleFirstChildHorizontalLayout" class="org.apache.flex.html.beads.layouts.FlexibleFirstChildHorizontalLayout"/>
 -    <component id="OneFlexibleChildVerticalLayout" class="org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout"/>
 -    <component id="OneFlexibleChildHorizontalLayout" class="org.apache.flex.html.beads.layouts.OneFlexibleChildHorizontalLayout"/>
 -    <component id="MXMLBeadView" class="org.apache.flex.html.MXMLBeadView"/>
 -    
 -    <component id="SubAppLoader" class="org.apache.flex.html.SubAppLoader" />
 -
 -    <component id="Border" class="org.apache.flex.html.supportClasses.Border"/>
 -    
 -    <component id="WebBrowser" class="org.apache.flex.html.WebBrowser" />
--
      <component id="A" class="org.apache.flex.html.A" />
      <component id="H1" class="org.apache.flex.html.H1" />
      <component id="H2" class="org.apache.flex.html.H2" />

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Mobile/src/main/flex/org/apache/flex/mobile/TitleView.as
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/1691921e/frameworks/projects/Mobile/src/main/flex/org/apache/flex/mobile/ViewManagerBase.as
----------------------------------------------------------------------


[21/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - get examples to build

Posted by ah...@apache.org.
get examples to build


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/544e2de4
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/544e2de4
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/544e2de4

Branch: refs/heads/develop
Commit: 544e2de47944f56e0bbf837e3a3334e17cd370ac
Parents: c07b2b3
Author: Alex Harui <ah...@apache.org>
Authored: Fri Apr 21 14:19:24 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Apr 21 14:25:47 2017 -0700

----------------------------------------------------------------------
 .../src/main/config/compile-app-config.xml      |  4 +-
 .../src/main/config/compile-app-config.xml      |  4 +-
 .../src/main/config/compile-app-config.xml      |  4 +-
 .../src/main/config/compile-app-config.xml      |  4 +-
 .../src/main/config/compile-app-config.xml      |  4 +-
 .../src/main/config/compile-app-config.xml      |  4 +-
 examples/native/USStatesMap/build.xml           | 55 --------------------
 7 files changed, 12 insertions(+), 67 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/544e2de4/examples/flexjs/CreateJSExample/src/main/config/compile-app-config.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/CreateJSExample/src/main/config/compile-app-config.xml b/examples/flexjs/CreateJSExample/src/main/config/compile-app-config.xml
index 51e4b0d..d5e7156 100644
--- a/examples/flexjs/CreateJSExample/src/main/config/compile-app-config.xml
+++ b/examples/flexjs/CreateJSExample/src/main/config/compile-app-config.xml
@@ -21,8 +21,8 @@
         <optimization>skipFunctionCoercions</optimization>
     </js-output-optimization>
     <compiler>
-        <js-external-library-path append="true">
+        <external-library-path append="true">
             <path-element>../../../../../../js/libs/createjs.swc</path-element>
-        </js-external-library-path>
+        </external-library-path>
     </compiler>
 </flex-config>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/544e2de4/examples/flexjs/DesktopMap/src/main/config/compile-app-config.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/DesktopMap/src/main/config/compile-app-config.xml b/examples/flexjs/DesktopMap/src/main/config/compile-app-config.xml
index 0d2aeef..d542757 100644
--- a/examples/flexjs/DesktopMap/src/main/config/compile-app-config.xml
+++ b/examples/flexjs/DesktopMap/src/main/config/compile-app-config.xml
@@ -19,8 +19,8 @@
 <flex-config>
     <remove-circulars>true</remove-circulars>
     <compiler>
-        <js-external-library-path append="true">
+        <external-library-path append="true">
             <path-element>../../../../../../js/libs/google_maps.swc</path-element>
-        </js-external-library-path>
+        </external-library-path>
     </compiler>
 </flex-config>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/544e2de4/examples/flexjs/FlexJSStore_jquery/src/main/config/compile-app-config.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/FlexJSStore_jquery/src/main/config/compile-app-config.xml b/examples/flexjs/FlexJSStore_jquery/src/main/config/compile-app-config.xml
index 6036129..0e2b391 100644
--- a/examples/flexjs/FlexJSStore_jquery/src/main/config/compile-app-config.xml
+++ b/examples/flexjs/FlexJSStore_jquery/src/main/config/compile-app-config.xml
@@ -21,8 +21,8 @@
         <optimization>skipFunctionCoercions</optimization>
     </js-output-optimization>
     <compiler>
-        <js-external-library-path append="true">
+        <external-library-path append="true">
             <path-element>../../../../../../js/libs/jquery.swc</path-element>
-        </js-external-library-path>
+        </external-library-path>
     </compiler>
 </flex-config>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/544e2de4/examples/flexjs/MapSearch/src/main/config/compile-app-config.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/MapSearch/src/main/config/compile-app-config.xml b/examples/flexjs/MapSearch/src/main/config/compile-app-config.xml
index 0d2aeef..d542757 100644
--- a/examples/flexjs/MapSearch/src/main/config/compile-app-config.xml
+++ b/examples/flexjs/MapSearch/src/main/config/compile-app-config.xml
@@ -19,8 +19,8 @@
 <flex-config>
     <remove-circulars>true</remove-circulars>
     <compiler>
-        <js-external-library-path append="true">
+        <external-library-path append="true">
             <path-element>../../../../../../js/libs/google_maps.swc</path-element>
-        </js-external-library-path>
+        </external-library-path>
     </compiler>
 </flex-config>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/544e2de4/examples/flexjs/MobileMap/src/main/config/compile-app-config.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/MobileMap/src/main/config/compile-app-config.xml b/examples/flexjs/MobileMap/src/main/config/compile-app-config.xml
index 0d2aeef..d542757 100644
--- a/examples/flexjs/MobileMap/src/main/config/compile-app-config.xml
+++ b/examples/flexjs/MobileMap/src/main/config/compile-app-config.xml
@@ -19,8 +19,8 @@
 <flex-config>
     <remove-circulars>true</remove-circulars>
     <compiler>
-        <js-external-library-path append="true">
+        <external-library-path append="true">
             <path-element>../../../../../../js/libs/google_maps.swc</path-element>
-        </js-external-library-path>
+        </external-library-path>
     </compiler>
 </flex-config>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/544e2de4/examples/flexjs/StorageExample/src/main/config/compile-app-config.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/StorageExample/src/main/config/compile-app-config.xml b/examples/flexjs/StorageExample/src/main/config/compile-app-config.xml
index a165dee..cc47563 100644
--- a/examples/flexjs/StorageExample/src/main/config/compile-app-config.xml
+++ b/examples/flexjs/StorageExample/src/main/config/compile-app-config.xml
@@ -19,8 +19,8 @@
 <flex-config>
     <remove-circulars>true</remove-circulars>
     <compiler>
-        <js-external-library-path append="true">
+        <external-library-path append="true">
             <path-element>../../../../../../js/libs/cordova.swc</path-element>
-        </js-external-library-path>
+        </external-library-path>
     </compiler>
 </flex-config>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/544e2de4/examples/native/USStatesMap/build.xml
----------------------------------------------------------------------
diff --git a/examples/native/USStatesMap/build.xml b/examples/native/USStatesMap/build.xml
index 2a62d4a..5a0d580 100644
--- a/examples/native/USStatesMap/build.xml
+++ b/examples/native/USStatesMap/build.xml
@@ -33,64 +33,9 @@
     <property name="config_arg" value="js" />
     <property name="file_suffix" value="as" />
 
-    <condition property="JS.SWC" value="${FALCONJX_HOME}/../externs/js/out/bin/js.swc" >
-        <and>
-            <not>
-                <isset property="JS.SWC" />
-            </not>
-            <available file="${FALCONJX_HOME}/../externs/js/out/bin/js.swc" type="file" />
-        </and>
-    </condition>
-
-    <condition property="JS.SWC" value="${FALCONJX_HOME}/libs/js.swc" >
-        <and>
-            <not>
-                <isset property="JS.SWC" />
-            </not>
-            <available file="${FALCONJX_HOME}/libs/js.swc" type="file" />
-        </and>
-    </condition>
-
-    <path id="lib.path">
-        <fileset dir="${FALCON_HOME}/lib" includes="falcon-flexTasks.jar"/>
-    </path>
-
     <target name="main" depends="clean,build_example.compile" description="Clean build of ${example}">
     </target>
     
-    <target name="build">
-        <java jar="${FALCONJX_HOME}/lib/mxmlc.jar" resultProperty="errorCode"
-            fork="true">
-            <jvmarg line="${mxmlc.jvm.args}"/>
-            <jvmarg line="-Dflexlib=${FLEXJS_HOME}/frameworks}"/>
-            <arg value="+flexlib=${FLEXJS_HOME}/frameworks" />
-            <arg value="-debug" />
-            <arg value="-define=CONFIG::as_only,false" />
-            <arg value="-define=CONFIG::js_only,true" />
-            <arg value="-external-library-path=${JS.SWC}" />
-            <arg value="-compiler.mxml.children-as-data" />
-            <arg value="-compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent" />
-            <arg value="-compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent" />
-            <arg value="-compiler.binding-value-change-event-type=valueChange" />
-            <arg value="+playerglobal.version=${playerglobal.version}" />
-            <arg value="+env.PLAYERGLOBAL_HOME=${env.PLAYERGLOBAL_HOME}" />
-            <arg value="-js-output-type=FLEXJS" />
-            <arg value="-closure-lib=${GOOG_HOME}" />
-            <arg value="-sdk-js-lib=${FLEXJS_HOME}/frameworks/js/FlexJS/libs" />
-            <arg value="${basedir}/src/main/flex/${example}.as" />
-        </java>
-        <fail>
-            <condition>
-                <not>
-                    <or>
-                        <equals arg1="${errorCode}" arg2="0" />
-                        <equals arg1="${errorCode}" arg2="2" />
-                    </or>
-                </not>
-            </condition>
-        </fail>        
-    </target>
-    
     <target name="clean">
         <delete dir="${basedir}/bin" failonerror="false" />
         <delete dir="${basedir}/bin-debug" failonerror="false" />


[42/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - make sure we know autosize settings before setting text

Posted by ah...@apache.org.
make sure we know autosize settings before setting text


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/9ab3b569
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/9ab3b569
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/9ab3b569

Branch: refs/heads/develop
Commit: 9ab3b569208393549565dbf352f8f65348b6abcf
Parents: 8f3c9a0
Author: Alex Harui <ah...@apache.org>
Authored: Thu Apr 27 23:57:19 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 23:57:19 2017 -0700

----------------------------------------------------------------------
 .../org/apache/flex/html/beads/TextFieldViewBase.as     | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9ab3b569/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextFieldViewBase.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextFieldViewBase.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextFieldViewBase.as
index 75cafb1..8176f53 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextFieldViewBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextFieldViewBase.as
@@ -96,14 +96,16 @@ package org.apache.flex.html.beads
             IEventDispatcher(_strand).addEventListener("heightChanged", heightChangeHandler);
             IEventDispatcher(_strand).addEventListener("sizeChanged", sizeChangeHandler);
 			DisplayObjectContainer(value).addChild(_textField);
-			if (_textModel.text !== null)
-				text = _textModel.text;
-			if (_textModel.html !== null)
-				html = _textModel.html;
-            
+
             var ilc:ILayoutChild = host as ILayoutChild;
             autoHeight = ilc.isHeightSizedToContent();
             autoWidth = ilc.isWidthSizedToContent();
+			
+			if (_textModel.text !== null)
+				text = _textModel.text;
+			if (_textModel.html !== null)
+				html = _textModel.html;            
+			
             if (!autoWidth && !isNaN(ilc.explicitWidth))
             {
                 widthChangeHandler(null);


[36/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - get SWF version working by injection more BasicLayouts

Posted by ah...@apache.org.
get SWF version working by injection more BasicLayouts


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/e828d177
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/e828d177
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/e828d177

Branch: refs/heads/develop
Commit: e828d177b86c09752ee26bb96209323de2d98bee
Parents: df6f560
Author: Alex Harui <ah...@apache.org>
Authored: Wed Apr 26 22:46:36 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 14:15:17 2017 -0700

----------------------------------------------------------------------
 .../FlexJSStore/src/main/flex/FlexJSStore.mxml  |  3 +
 .../FlexJSStore/src/main/flex/HomeView.mxml     | 60 +++++++++++++-------
 .../FlexJSStore/src/main/flex/ProductsView.mxml |  1 -
 .../FlexJSStore/src/main/flex/SupportView.mxml  |  2 +-
 4 files changed, 43 insertions(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/e828d177/examples/flexjs/FlexJSStore/src/main/flex/FlexJSStore.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/FlexJSStore/src/main/flex/FlexJSStore.mxml b/examples/flexjs/FlexJSStore/src/main/flex/FlexJSStore.mxml
index 37d41cb..17b8632 100755
--- a/examples/flexjs/FlexJSStore/src/main/flex/FlexJSStore.mxml
+++ b/examples/flexjs/FlexJSStore/src/main/flex/FlexJSStore.mxml
@@ -250,6 +250,9 @@ limitations under the License.
                                 click="headToSupport()"/>            
             </js:ControlBar>
             <js:Group width="990" id="viewholder">
+			    <js:beads>
+					<js:BasicLayout />
+			    </js:beads>
                 <js:style>
                     <js:SimpleCSSStyles paddingLeft="0" paddingRight="0"/>
                 </js:style>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/e828d177/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml b/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml
index 484b970..3a93319 100755
--- a/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml
+++ b/examples/flexjs/FlexJSStore/src/main/flex/HomeView.mxml
@@ -32,7 +32,7 @@ Width and height are hard-coded in the root tag to help the Design view.
 -->
 <js:Group xmlns:fx="http://ns.adobe.com/mxml/2009"
          xmlns:js="library://ns.apache.org/flexjs/basic" 
-           xmlns="*" width="990" height="550"
+           xmlns="*"
            initComplete="updateMapImage()">
 	<fx:Script>
 		<![CDATA[
@@ -47,6 +47,7 @@ Width and height are hard-coded in the root tag to help the Design view.
 	</fx:Script>
     <js:beads>
         <js:ContainerDataBinding />
+		<js:BasicLayout />
     </js:beads>
 	<js:Group width="100%" height="100%" y="0" x="0" className="colorPanel">
 		<js:beads>
@@ -57,8 +58,13 @@ Width and height are hard-coded in the root tag to help the Design view.
 				<js:VerticalLayout />
 			</js:beads>
 			<js:Group width="100%" height="100%">
-			
+			    <js:beads>
+					<js:BasicLayout />
+			    </js:beads>
 				<js:Group height="60" className="homeSection">
+				    <js:beads>
+						<js:BasicLayout />
+				    </js:beads>
                     <js:style>
                         <js:SimpleCSSStyles backgroundColor="#ebebe9" left="10" top="10" right="10"/>
                     </js:style>
@@ -68,6 +74,9 @@ Width and height are hard-coded in the root tag to help the Design view.
 				</js:Group>
 				
 				<js:Group height="280" className="homeSection">
+				    <js:beads>
+						<js:BasicLayout />
+				    </js:beads>
                     <js:style>
                         <js:SimpleCSSStyles backgroundColor="#ffffff" left="10" top="78" right="10" />                        
                     </js:style>
@@ -97,12 +106,15 @@ Width and height are hard-coded in the root tag to help the Design view.
 				
 				<js:Group height="174" className="homeSection">
 					<js:beads>
-						<js:VerticalLayout />
+						<js:BasicLayout />
 					</js:beads>
                     <js:style>
                         <js:SimpleCSSStyles backgroundColor="#ebebe9" left="10" top="366" right="10" />
                     </js:style>
 					<js:Group width="100%" height="100%">
+					    <js:beads>
+							<js:VerticalLayout />
+					    </js:beads>
                         <js:style>
                             <js:SimpleCSSStyles left="10" top="10" />
                         </js:style>
@@ -114,21 +126,18 @@ Width and height are hard-coded in the root tag to help the Design view.
 							<js:beads>
 								<js:HorizontalLayout />
 							</js:beads>
-                            <js:style>
-                                <js:SimpleCSSStyles verticalAlign="middle" />
-                            </js:style>
 							<js:TextInput height="20" width="40">
 								<js:beads>
 									<js:NumericOnlyTextInputBead/>
 								</js:beads>
 							</js:TextInput>
-							<js:HRule width="8" height="2"/>
+							<js:HRule width="8" height="2" style="verticalAlign:'middle'"/>
 							<js:TextInput height="20" width="40">
 								<js:beads>
 									<js:NumericOnlyTextInputBead/>
 								</js:beads>
 							</js:TextInput>
-							<js:HRule width="8" height="2"/>
+							<js:HRule width="8" height="2" style="verticalAlign:'middle'"/>
 							<js:TextInput height="20" width="40">
 								<js:beads>
 									<js:NumericOnlyTextInputBead/>
@@ -137,7 +146,7 @@ Width and height are hard-coded in the root tag to help the Design view.
 						</js:Group>
 						
 						<js:Label text="Password"/>
-						<js:TextInput height="20">
+						<js:TextInput id="password" height="20">
 							<js:beads>
 								<js:PasswordInputBead/>
 							</js:beads>
@@ -161,9 +170,15 @@ Width and height are hard-coded in the root tag to help the Design view.
 				<js:VerticalLayout />
 			</js:beads>
 			<js:Group width="100%" height="100%">
+			    <js:beads>
+					<js:BasicLayout />
+			    </js:beads>
 			
 			    <!-- can't use binding to set the mapImage source because the style isn't available early enough -->
 				<js:Group id="mapCanvas" height="35%" className="homeMap">
+				    <js:beads>
+						<js:BasicLayout />
+				    </js:beads>
                     <js:style>
                         <js:SimpleCSSStyles left="0" right="10" top="10" />
                     </js:style>
@@ -175,6 +190,9 @@ Width and height are hard-coded in the root tag to help the Design view.
 				</js:Group>
 				
 				<js:Group height="330" >
+				    <js:beads>
+						<js:BasicLayout />
+				    </js:beads>
                     <js:style>
                         <js:SimpleCSSStyles backgroundColor="#ffffff" borderStyle="solid" bottom="10" right="10" left="0" /> <!-- cornerRadius="4" -->
                     </js:style>
@@ -189,11 +207,11 @@ Width and height are hard-coded in the root tag to help the Design view.
 							<js:beads>
 								<js:VerticalLayout />
 							</js:beads>
+ 							<js:Image id="image1" src="assets/akotter.jpg" style="margin:auto;"/>							
 							<js:Group width="100%">
-								<js:Image id="image1" src="assets/akotter.jpg" style="margin:auto;verticalCenter:0"/>
-							</js:Group>
-							
-							<js:Group width="100%">
+							    <js:beads>
+									<js:BasicLayout />
+							    </js:beads>
 								<js:Label text="Annette Kotter" id="feat_prod_1" style="margin:auto;fontWeight:'bold';fontSize:12"/>
 							</js:Group>
 							
@@ -203,11 +221,11 @@ Width and height are hard-coded in the root tag to help the Design view.
 							<js:beads>
 								<js:VerticalLayout />
 							</js:beads>
+							<js:Image id="image2" style="margin:auto;" src="assets/bcrater.jpg"/>
 							<js:Group width="100%">
-								<js:Image id="image2" style="margin:auto;verticalCenter:0" src="assets/bcrater.jpg"/>
-							</js:Group>
-							
-							<js:Group width="100%">
+							    <js:beads>
+									<js:BasicLayout />
+							    </js:beads>
 								<js:Label text="Ben Crater" id="feat_prod_2" style="margin:auto;fontWeight:'bold';fontSize:12"/>
 							</js:Group>
 							
@@ -217,11 +235,11 @@ Width and height are hard-coded in the root tag to help the Design view.
 							<js:beads>
 								<js:VerticalLayout />
 							</js:beads>
+							<js:Image id="image3" style="margin:auto;" src="assets/jproctor.jpg"/>
 							<js:Group width="100%">
-								<js:Image id="image3" style="margin:auto;verticalCenter:0" src="assets/jproctor.jpg"/>
-							</js:Group>
-							
-							<js:Group width="100%">
+							    <js:beads>
+									<js:BasicLayout />
+							    </js:beads>
 								<js:Label text="Jane Proctor" id="feat_prod_3" style="margin:auto;fontWeight:'bold';fontSize:12"/>
 							</js:Group>
 							

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/e828d177/examples/flexjs/FlexJSStore/src/main/flex/ProductsView.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/FlexJSStore/src/main/flex/ProductsView.mxml b/examples/flexjs/FlexJSStore/src/main/flex/ProductsView.mxml
index 579de46..0a38b28 100755
--- a/examples/flexjs/FlexJSStore/src/main/flex/ProductsView.mxml
+++ b/examples/flexjs/FlexJSStore/src/main/flex/ProductsView.mxml
@@ -23,7 +23,6 @@ limitations under the License.
 <js:Container xmlns:fx="http://ns.adobe.com/mxml/2009"
          xmlns:js="library://ns.apache.org/flexjs/basic" 
     xmlns:productsView="productsView.*"
-    width="990" height="550"
     currentState="showFilter"
     >
 

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/e828d177/examples/flexjs/FlexJSStore/src/main/flex/SupportView.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/FlexJSStore/src/main/flex/SupportView.mxml b/examples/flexjs/FlexJSStore/src/main/flex/SupportView.mxml
index 3d02179..439c153 100755
--- a/examples/flexjs/FlexJSStore/src/main/flex/SupportView.mxml
+++ b/examples/flexjs/FlexJSStore/src/main/flex/SupportView.mxml
@@ -32,7 +32,7 @@ The width and height are hard-coded in the root tag to help the Design view.
 <js:Container xmlns:fx="http://ns.adobe.com/mxml/2009"
                  xmlns:js="library://ns.apache.org/flexjs/basic" 
                  xmlns="*" alpha="1.0"
-    width="990" height="550">
+    >
 	
 	<fx:Script>
 	    <![CDATA[


[02/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - - Adjust the Tomcat download url

Posted by ah...@apache.org.
- Adjust the Tomcat download url


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/9f037533
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/9f037533
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/9f037533

Branch: refs/heads/develop
Commit: 9f037533c3ec527a5f6fd65b42cdd5c47c3cca55
Parents: 3b95eca
Author: Christofer Dutz <ch...@codecentric.de>
Authored: Fri Mar 10 16:14:51 2017 +0100
Committer: Christofer Dutz <ch...@codecentric.de>
Committed: Fri Mar 10 16:14:51 2017 +0100

----------------------------------------------------------------------
 examples/examples-integrationtests/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9f037533/examples/examples-integrationtests/pom.xml
----------------------------------------------------------------------
diff --git a/examples/examples-integrationtests/pom.xml b/examples/examples-integrationtests/pom.xml
index c4a62d8..9be2dee 100644
--- a/examples/examples-integrationtests/pom.xml
+++ b/examples/examples-integrationtests/pom.xml
@@ -89,7 +89,7 @@
                 <containerId>tomcat8x</containerId>
                 <log>${project.build.directory}/tomcat8x/container.log</log>
                 <zipUrlInstaller>
-                  <url>http://ftp.fau.de/apache/tomcat/tomcat-8/v8.5.9/bin/apache-tomcat-8.5.9.zip</url>
+                  <url>http://ftp.fau.de/apache/tomcat/tomcat-8/v8.5.11/bin/apache-tomcat-8.5.11.zip</url>
                   <extractDir>${java.io.tmpdir}/cargo/installs</extractDir>
                 </zipUrlInstaller>
                 <!-- 3 Minutes -->


[48/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - defaults.css in HTML module do not need styles related to Basic

Posted by ah...@apache.org.
defaults.css in HTML module do not need styles related to Basic


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/ee1b6339
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/ee1b6339
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/ee1b6339

Branch: refs/heads/develop
Commit: ee1b6339aafbd71591d99fd4b3c0a4348d247abb
Parents: bfb15c8
Author: piotrz <pi...@apache.org>
Authored: Sun Apr 30 17:10:56 2017 +0200
Committer: piotrz <pi...@apache.org>
Committed: Sun Apr 30 17:10:56 2017 +0200

----------------------------------------------------------------------
 .../HTML/src/main/resources/defaults.css        | 853 +------------------
 1 file changed, 1 insertion(+), 852 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/ee1b6339/frameworks/projects/HTML/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/resources/defaults.css b/frameworks/projects/HTML/src/main/resources/defaults.css
index ffd48e2..8cf8313 100644
--- a/frameworks/projects/HTML/src/main/resources/defaults.css
+++ b/frameworks/projects/HTML/src/main/resources/defaults.css
@@ -18,855 +18,4 @@
 */
 
 @namespace "library://ns.apache.org/flexjs/basic";
-@namespace svg "library://ns.apache.org/flexjs/svg";
-
-/* Global style declaration */
-*
-{
-	font-family: "Arial";
-	font-size: 12px;
-	border-width: 1px;
-}
-
-.flexjs *, . flexjs *:before, . flexjs *:after {
-	-moz-box-sizing: border-box;
-	-webkit-box-sizing: border-box;
-	box-sizing: border-box;
-}
-
-.unselectable
-{
-	-moz-user-select: -moz-none;
-	-khtml-user-select: none;
-	-webkit-user-select: none;
-	-o-user-select: none;
-	user-select: none;
-}
-
-Alert
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.AlertModel");
-	
-	background-color: #FFFFFF;
-	border-style: solid;
-	border-color: #000000;
-	border-width: 1px;
-}
-
-
-Application
-{
-	padding: 0px;
-	margin: 0px;
-}
-
-Button
-{
-	background-color: #f8f8f8;
-	border: 1px solid #808080;
-	border-radius: 2px;
-	padding: 4px;
-	margin: 0px;
-}
-
-Button:hover
-{
-	background-color: #e8e8e8;
-	border: 1px solid #808080;
-	padding: 4px;
-}
-
-Button:active
-{
-	background-color: #d8d8d8;
-	border: 1px solid #808080;
-	padding: 4px;
-}
-
-ButtonBar
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ButtonBarModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ButtonBarView");			
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.ButtonBarLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.TextButtonItemRenderer");
-	
-	border-style: none;
-}
-
-ComboBox
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ComboBoxModel");
-	IBeadView: ClassReference("org.apache.flex.html.beads.ComboBoxView");
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ComboBoxController");
-	IPopUp: ClassReference("org.apache.flex.html.supportClasses.ComboBoxList");
-}
-
-ComboBoxList
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.ScrollingViewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-	border-style: solid;
-	border-radius: 4px;
-	border-color: #000000;
-	border-width: 1px;
-	background-color: #FFFFFF;
-}
-
-.ComboBoxButton {
-	padding: 0px;
-	margin: 0px;
-}
-
-Container
-{
-	IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.BasicLayout");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.Viewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-}
-
-ControlBar
-{
-	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalFlexLayout");
-	
-	padding: 2px;
-	background-color: #E2E2E2;
-	border-top: solid 1px #333333;
-	height: 30px;
-}
-
-DataContainer
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.DataProviderModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.DataContainerView");			
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.Viewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-	border-style: solid;
-	border-color: #222222;
-}
-
-/* ASJS */
-DataGrid
-{
-	IDataGridPresentationModel: ClassReference("org.apache.flex.html.beads.models.DataGridPresentationModel");
-	IBeadView: ClassReference("org.apache.flex.html.beads.DataGridView");
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.DataGridModel");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");
-	
-	background-color: #FFFFFF;
-	border-style: solid;
-	border-color: #222222;
-	border-width: 1px;
-}
-
-DataGridButtonBar
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ButtonBarModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ButtonBarView");			
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.ButtonBarLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.TextButtonItemRenderer");
-	
-	border-style: none;
-}
-
-DataGridColumnList {
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.DataGridModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayList");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.Viewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-	border-style: none;
-	background-color: #FFFFFF;
-}
-
-.DataGridListArea {
-	background-color: #FFFFFF;
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalLayout");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.ScrollingViewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-}
-
-/* DateChooser */
-
-DateChooser {
-	IBeadView:   ClassReference("org.apache.flex.html.beads.DateChooserView");
-	IBeadModel:  ClassReference("org.apache.flex.html.beads.models.DateChooserModel");			
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");	
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DateChooserMouseController");
-	width:  280px;
-	height: 240px;
-}
-
-DateChooserList {
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.DateItemRenderer");		
-	border-style: solid;
-	border-color: #000000;
-	border-width: 1px;
-	background-color: #FFFFFF;
-}
-
-DateChooserHeader {	
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.DayNameItemRenderer");
-	height: 20px;
-	border-style: solid;
-	border-color: #000000;
-	border-width: 1px;
-	background-color: #FFFFFF;
-}
-
-.DateChooserMonthButtons {				
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalFlexLayout");	
-	height: 20px;
-}
-
-DateItemRenderer
-{
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
-	text-align: center;
-	flex-shrink: 0;
-	flex-grow: 1;
-}
-
-DayNameItemRenderer
-{
-	text-align: center;
-	flex-shrink: 0;
-	flex-grow: 1;
-}
-
-/* DateField */
-
-DateField {
-	IBeadView:   ClassReference("org.apache.flex.html.beads.DateFieldView");
-	IBeadModel:  ClassReference("org.apache.flex.html.beads.models.DateChooserModel");
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DateFieldMouseController");
-	IFormatBead: ClassReference("org.apache.flex.html.accessories.DateFormatYYYYMMDDBead");
-}
-
-/* RangeStepper */
-
-RangeStepper {
-	IBeadView: ClassReference("org.apache.flex.html.beads.RangeStepperView");
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModelExtended");
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.RangeStepperMouseController");
-}
-
-Form {
-	
-}
-
-Group {
-	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
-}
-
-HContainer
-{
-	IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalLayout");
-	white-space: nowrap;
-}
-
-Image
-{
-	vertical-align: top;
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ImageModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ImageView");
-}
-
-BinaryImage
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.BinaryImageModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ImageView");
-	IBinaryImageLoader:  ClassReference("org.apache.flex.html.beads.BinaryImageLoader");
-}
-
-ImageAndTextButton
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ImageAndTextModel");
-}
-
-ImageButton
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ImageModel");
-	border-style: none;
-}
-
-ImageButton:hover
-{
-	border-style: none;
-}
-
-ImageButton:active
-{
-	border-style: none;
-}
-
-VContainer
-{
-	IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
-}
-
-List
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.Viewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-	border-style: solid;
-	border-color: #222222;
-	background-color: #FFFFFF;
-}
-
-Accordion
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.AccordionView");			
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.AccordionItemRenderer");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.ClippingViewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-	IAccordionCollapseBead: ClassReference("org.apache.flex.html.beads.AccordionCollapseBead");
-	border-style: solid;
-	border-color: #222222;
-}
-
-Tree
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArrayListSelectionModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.TreeSingleSelectionMouseController");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForHierarchicalData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.TreeItemRenderer");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.ScrollingViewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-	border-style: solid;
-	border-color: #222222;
-}
-
-NumericStepper
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
-}
-
-Panel
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.PanelModel");
-	IBeadView: ClassReference("org.apache.flex.html.beads.PanelView");
-	IPanelLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");
-	
-	background-color: #FFFFFF;
-	border: solid 1px #333333
-}
-
-PanelWithControlBar
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.PanelModel");
-	IBeadView: ClassReference("org.apache.flex.html.beads.PanelWithControlBarView");
-	IPanelLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");
-	
-	background-color: #FFFFFF;
-	border: solid 1px #333333;
-}
-
-Panel .TitleBar
-{
-	border-bottom: solid 1px #333333;
-}
-
-SimpleList
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");
-	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
-	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
-	IViewport: ClassReference("org.apache.flex.html.supportClasses.ScrollingViewport");
-	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
-}
-
-Slider
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
-	iBeadView:  ClassReference("org.apache.flex.html.beads.SliderView");
-	iBeadController: ClassReference("org.apache.flex.html.beads.controllers.SliderMouseController");
-}
-
-Spinner
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.RangeModel");
-	IBeadView:  ClassReference("org.apache.flex.html.beads.SpinnerView");
-}
-
-
-StringItemRenderer
-{
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
-	height: 24;
-	flex-shrink: 0;
-	flex-grow: 1;
-}
-
-AccordionItemRenderer
-{
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AccordionItemRendererMouseController");
-	IBeadView: ClassReference("org.apache.flex.html.beads.AccordionItemRendererView");
-	flex-shrink: 0;
-	flex-grow: 1;
-}
-
-TreeItemRenderer
-{
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
-	height: 24;
-	flex-shrink: 0;
-	flex-grow: 1;
-}
-
-TextInput
-{
-	border: 1px solid #808080;
-	border-radius: 2px;
-	padding: 4px;
-	margin: 0px;
-}
-
-TextArea
-{
-	border: 1px solid #808080;
-	border-radius: 2px;
-	padding: 4px;
-	resize: none;
-}
-
-TitleBar
-{
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.TitleBarModel");
-	IBeadView: ClassReference("org.apache.flex.html.beads.TitleBarView");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.FlexibleFirstChildHorizontalLayout");
-	iMeasurementBead: ClassReference("org.apache.flex.html.beads.TitleBarMeasurementBead");
-	background-color: #E2E2E2;
-	padding: 2px;
-	height: 30px;
-	flex-grow: 0;
-	min-height: 30px;
-}
-
-TitleBar .TitleBarCloseButton {
-	width: 16px;
-	height: 16px;
-	margin: 0px;
-}
-
-TitleBar .TitleBarTitle {
-	font-weight: bold;
-	padding: 0;
-	margin: 0;
-}
-
-.toggleTextButton
-{
-	background-color: #f8f8f8;
-	border: 1px solid #808080;
-	padding: 4px;
-}
-
-.toggleTextButton:hover
-{
-	background-color: #e8e8e8;
-	border: 1px solid #808080;
-	padding: 4px;
-}
-
-.toggleTextButton_Selected
-{
-	background-color: #d8d8d8;
-	border: 1px solid #808080;
-	padding: 4px;
-}
-
-.toggleTextButton_Selected:hover
-{
-	background-color: #e8e8e8;
-	border: 1px solid #808080;
-	padding: 4px;
-}
-
-ToolTip
-{
-	background-color: #FFFFCC;
-}
-
-View
-{
-	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
-	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.BasicLayout");
-}
-
-WebBrowser
-{
-	IBeadView: ClassReference("org.apache.flex.html.beads.WebBrowserView");
-	IBeadModel: ClassReference("org.apache.flex.html.beads.models.WebBrowserModel");
-}
-
-
-/* Global Style Declaration */
-global
-{
-	IStatesImpl: ClassReference("org.apache.flex.core.SimpleStatesImpl");
-	IEffectTimer: ClassReference("org.apache.flex.utils.EffectTimer");
-	effectTimerInterval: 10;
-}
-
-@media -flex-flash
-{
-	Accordion {
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
-	}
-	
-	Alert
-	{
-		IBeadView:  ClassReference("org.apache.flex.html.beads.AlertView");
-		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AlertController");
-		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-	}
-	
-	Border
-	{
-		border-color: inherit;
-		border-style: inherit;
-		border-radius: inherit;
-		border-width: inherit;
-		border: inherit;
-	}
-	
-	Button
-	{
-		IBeadView: ClassReference("org.apache.flex.html.beads.CSSButtonView");
-	}
-	
-	ButtonBar
-	{
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
-	}
-	
-	CheckBox
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ToggleButtonModel");
-		IBeadView:  ClassReference("org.apache.flex.html.beads.CheckBoxView");			
-	}
-	
-	CSSCheckBox
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ToggleButtonModel");
-		IBeadView:  ClassReference("org.apache.flex.html.beads.CheckBoxView");			
-	}
-	
-	CloseButton
-	{
-		IBeadView: ClassReference("org.apache.flex.html.beads.CloseButtonView");
-	}
-	
-	Container
-	{
-		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.ContainerContentArea");
-	}
-	
-	ControlBar
-	{
-		IMeasurementBead: ClassReference("org.apache.flex.html.beads.ControlBarMeasurementBead");
-		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");  
-		border: solid 1px #333333;
-	}
-	
-	ComboBoxList {
-		IBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
-	}
-	
-	DataContainer {
-		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
-	}
-	
-	DataGridButtonBar {
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
-	}
-	
-	DateChooserList {
-		iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
-		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead"); 
-	}
-	
-	DateChooserHeader {
-		padding-top: 0px;
-		padding-bottom: 5px;
-		iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
-		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");   
-	}
-	
-	DateItemRenderer {
-		margin: 0px;
-		padding: 5px;
-	}
-	
-	DropDownList
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.DropDownListView");
-		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.DropDownListController");
-		IPopUp: ClassReference("org.apache.flex.html.supportClasses.DropDownListList");
-	}
-	
-	DropDownListList
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
-		IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.TextItemRendererFactoryForArrayData");
-		IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
-		IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.StringItemRenderer");
-		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
-		iBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
-		border-style: solid;
-		border-radius: 4px;
-		border-color: #333333;
-		border-width: 1px;
-		background-color: #FFFFFF;
-	}
-	
-	Group
-	{
-		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-		iBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
-	}
-	
-	HRule
-	{
-		IBeadView:  ClassReference("org.apache.flex.html.beads.HRuleView");
-	}
-	
-	ImageButton
-	{
-		IBeadView: ClassReference("org.apache.flex.html.beads.ImageButtonView");
-	}
-	
-	ImageAndTextButton
-	{
-		IBeadView: ClassReference("org.apache.flex.html.beads.CSSImageAndTextButtonView");
-	}
-	
-	Label
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.TextFieldView");
-		iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextFieldLabelMeasurementBead");
-	}
-	
-	List
-	{
-		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
-		iBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
-	}
-	
-	MultilineLabel
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.MultilineTextFieldView");
-	}
-	
-	NumericStepper
-	{
-		IBeadView: ClassReference("org.apache.flex.html.beads.NumericStepperView");
-		
-		padding: 0px;
-		border-style: solid;
-		border-color: #000000;
-		border-width: 1px;
-		background-color: #FFFFFF;
-		iBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
-		iBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
-	}
-	
-	Panel
-	{
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.ContainerContentArea");
-		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");    
-	}
-	
-	PanelWithControlBar
-	{
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.ContainerContentArea");
-		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-	}
-	
-	RadioButton
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ValueToggleButtonModel");
-		IBeadView:  ClassReference("org.apache.flex.html.beads.RadioButtonView");			
-	}
-	
-	VScrollBar
-	{
-		IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VScrollBarLayout");
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ScrollBarModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.VScrollBarView");
-		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.VScrollBarMouseController");
-	}
-	
-	HScrollBar
-	{
-		IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HScrollBarLayout");
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ScrollBarModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.HScrollBarView");
-		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.HScrollBarMouseController");
-	}
-	
-	SimpleAlert
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.AlertModel");
-		IBeadView:  ClassReference("org.apache.flex.html.beads.SimpleAlertView");
-		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AlertController");
-		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		
-		background-color: #FFFFFF;
-		border-style: solid;
-		border-color: #000000;
-		border-width: 1px;
-	}
-	
-	Slider
-	{
-		iThumbView: ClassReference("org.apache.flex.html.beads.SliderThumbView");
-		iTrackView: ClassReference("org.apache.flex.html.beads.SliderTrackView");
-	}
-	
-	Spinner
-	{
-		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.SpinnerMouseController");
-	}
-	
-	TextArea
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.TextAreaView");
-		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.EditableTextKeyboardController");
-		IBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
-		IBorderModel: ClassReference('org.apache.flex.html.beads.models.SingleLineBorderModel');
-		border-style: solid;
-		border-color: #000000;
-		border-width: 1px;
-		background-color: #FFFFFF;
-	}
-	
-	TextButton
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.CSSTextButtonView");
-		iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextButtonMeasurementBead");
-	}
-	
-	Tree {
-		IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
-	}
-	
-	/*
-	TextFieldItemRenderer
-	{
-	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ItemRendererMouseController");
-	height: 16;
-	}
-	*/
-	
-	TextInput
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.TextInputWithBorderView");
-		IBeadController: ClassReference("org.apache.flex.html.beads.controllers.EditableTextKeyboardController");
-		IBorderBead: ClassReference('org.apache.flex.html.beads.SingleLineBorderBead');
-		IBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
-		border-style: solid;
-		border-color: #000000;
-		border-width: 1px;
-		background-color: #FFFFFF;
-	}
-	
-	TitleBar
-	{
-		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		border: solid 1px #333333;
-	}
-	
-	ToggleTextButton
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.ToggleButtonModel");
-		IBeadView:  ClassReference("org.apache.flex.html.beads.CSSTextToggleButtonView");
-	}
-	
-	View
-	{
-		iBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
-		iBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
-	}
-	
-	VRule
-	{
-		IBeadView:  ClassReference("org.apache.flex.html.beads.VRuleView");
-	}
-	
-	/* SVG */
-	
-	svg|TextButton
-	{
-		IBeadModel: ClassReference("org.apache.flex.html.beads.models.TextModel");
-		IBeadView: ClassReference("org.apache.flex.html.beads.CSSTextButtonView");
-		iMeasurementBead: ClassReference("org.apache.flex.html.beads.TextButtonMeasurementBead");
-	}
-	
-}
+@namespace svg "library://ns.apache.org/flexjs/svg";
\ No newline at end of file


[25/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge commit 'b7dc23b30a0b712d97b27f4d0d0db6310405564b' into dual

Posted by ah...@apache.org.
Merge commit 'b7dc23b30a0b712d97b27f4d0d0db6310405564b' into dual

* commit 'b7dc23b30a0b712d97b27f4d0d0db6310405564b':
  - Remove unwanted quotation marks
  Added new Table component and pieces.
  Uses beadsAdded event instead of viewChanged.
  Map examples now working on JS platform.
  Updated MapSearch example.
  Updates for DesktopMap example.

Conflicts:
	frameworks/projects/HTML/src/main/flex/HTMLClasses.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/accessories/NumericOnlyTextInputBead.as
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/accessories/PasswordInputBead.as
	frameworks/projects/HTML/src/main/resources/basic-manifest.xml


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/a168d45a
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/a168d45a
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/a168d45a

Branch: refs/heads/develop
Commit: a168d45a26928e988c79aae09ef308e9c211588b
Parents: 9ae73e0 b7dc23b
Author: Peter Ent <pe...@apache.org>
Authored: Mon Apr 24 15:24:55 2017 -0400
Committer: Peter Ent <pe...@apache.org>
Committed: Mon Apr 24 15:24:55 2017 -0400

----------------------------------------------------------------------
 .../DesktopMap/src/main/flex/MyInitialView.mxml | 113 ++++++----
 .../flexjs/DesktopMap/src/main/flex/NoLayout.as |  35 +++
 .../DesktopMap/src/main/flex/models/MyModel.as  |   6 +-
 .../main/resources/mdl-js-index-template.html   |   2 +-
 .../MapSearch/src/main/flex/MyInitialView.mxml  |  93 +++++---
 .../flexjs/MapSearch/src/main/flex/NoLayout.as  |  26 +++
 .../src/main/flex/SearchResultItemRenderer.mxml |  53 +++++
 .../MapSearch/src/main/flex/models/MyModel.as   |   6 +-
 .../Basic/src/main/flex/BasicClasses.as         |   9 +
 .../src/main/flex/org/apache/flex/html/Table.as |  67 ++++++
 .../main/flex/org/apache/flex/html/TableCell.as |  68 ++++++
 .../flex/org/apache/flex/html/TableHeader.as    |  67 ++++++
 .../main/flex/org/apache/flex/html/TableRow.as  |  69 ++++++
 .../org/apache/flex/html/beads/TableCellView.as |  54 +++++
 .../html/beads/layouts/SimpleTableLayout.as     | 213 +++++++++++++++++++
 .../flex/html/beads/layouts/TableCellLayout.as  | 120 +++++++++++
 .../html/beads/layouts/TableHeaderLayout.as     | 124 +++++++++++
 .../Basic/src/main/resources/basic-manifest.xml |   5 +
 .../Basic/src/main/resources/defaults.css       |  16 ++
 .../flex/maps/google/beads/GoogleMapView.as     |   2 +-
 20 files changed, 1073 insertions(+), 75 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/BasicClasses.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/BasicClasses.as
index 07bb731,a81838b..70665e1
--- a/frameworks/projects/Basic/src/main/flex/BasicClasses.as
+++ b/frameworks/projects/Basic/src/main/flex/BasicClasses.as
@@@ -220,8 -208,6 +220,17 @@@ internal class BasicClasse
  		import org.apache.flex.html.beads.VRuleView; VRuleView;
  		import org.apache.flex.html.beads.MultilineTextFieldView; MultilineTextFieldView;
  	}
 +	
 +	import org.apache.flex.html.SubAppLoader; SubAppLoader;
++	
++	import org.apache.flex.html.Table; Table;
++	import org.apache.flex.html.TableRow; TableRow;
++	import org.apache.flex.html.TableCell; TableCell;
++	import org.apache.flex.html.TableHeader; TableHeader;
++	import org.apache.flex.html.beads.TableCellView; TableCellView;
++	import org.apache.flex.html.beads.layouts.SimpleTableLayout; SimpleTableLayout;
++	import org.apache.flex.html.beads.layouts.TableCellLayout; TableCellLayout;
++	import org.apache.flex.html.beads.layouts.TableHeaderLayout; TableHeaderLayout;
  }
  
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Table.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Table.as
index 0000000,0000000..2a572d4
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Table.as
@@@ -1,0 -1,0 +1,67 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html
++{
++    COMPILE::JS
++    {
++        import org.apache.flex.core.WrappedHTMLElement;            
++    }
++
++	/**
++	 *  The Table class represents an HTML <table> element
++     *  
++	 *  
++     *  @toplevel
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class Table extends Group
++	{
++		/**
++		 *  constructor.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function Table()
++		{
++			super();
++			
++			className = "Table";
++		}
++
++        /**
++         * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
++         */
++        COMPILE::JS
++        override protected function createElement():WrappedHTMLElement
++        {
++			element = document.createElement('table') as WrappedHTMLElement;
++
++            positioner = element;
++            element.flexjs_wrapper = this;
++            
++            return element;
++        }
++    }
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableCell.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableCell.as
index 0000000,0000000..863eeb7
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableCell.as
@@@ -1,0 -1,0 +1,68 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html
++{
++    COMPILE::JS
++    {
++        import org.apache.flex.core.WrappedHTMLElement;            
++    }
++	
++	/**
++	 *  The TableCell class defines a table data cell in the Table component. This element
++	 *  may have nearly any type of FlexJS component as children.
++     *  
++	 *  
++     *  @toplevel
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class TableCell extends Group
++	{
++		/**
++		 *  constructor.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function TableCell()
++		{
++			super();
++			
++			className = "TableCell";
++		}
++		
++		/**
++		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
++		 */
++		COMPILE::JS
++		override protected function createElement():WrappedHTMLElement
++		{
++			element = document.createElement('td') as WrappedHTMLElement;
++			
++			positioner = element;
++			element.flexjs_wrapper = this;
++			
++			return element;
++		}
++    }
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableHeader.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableHeader.as
index 0000000,0000000..9c6e043
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableHeader.as
@@@ -1,0 -1,0 +1,67 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html
++{
++    COMPILE::JS
++    {
++        import org.apache.flex.core.WrappedHTMLElement;            
++    }
++	
++	/**
++	 *  The TableHeader class defines a table header cell in the Table component. 
++     *  
++	 *  
++     *  @toplevel
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class TableHeader extends TableCell
++	{
++		/**
++		 *  constructor.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function TableHeader()
++		{
++			super();
++			
++			className = "TableHeader";
++		}
++		
++		/**
++		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
++		 */
++		COMPILE::JS
++		override protected function createElement():WrappedHTMLElement
++		{
++			element = document.createElement('th') as WrappedHTMLElement;
++			
++			positioner = element;
++			element.flexjs_wrapper = this;
++			
++			return element;
++		}
++    }
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableRow.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableRow.as
index 0000000,0000000..f5bc359
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/TableRow.as
@@@ -1,0 -1,0 +1,69 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html
++{
++	import org.apache.flex.core.UIBase;
++	
++	COMPILE::JS
++	{
++		import org.apache.flex.core.WrappedHTMLElement;            
++	}
++	
++	/**
++	 *  The TableRow class defines a row of a Table. This will translate to a <tr> elemement
++     *  
++	 *  
++     *  @toplevel
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class TableRow extends Group
++	{
++		/**
++		 *  constructor.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function TableRow()
++		{
++			super();
++			
++			className = "TableRow";
++		}
++		
++		/**
++		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
++		 */
++		COMPILE::JS
++		override protected function createElement():WrappedHTMLElement
++		{
++			element = document.createElement('tr') as WrappedHTMLElement;
++			
++			positioner = element;
++			element.flexjs_wrapper = this;
++			
++			return element;
++		}
++    }
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TableCellView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TableCellView.as
index 0000000,0000000..443b4c3
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TableCellView.as
@@@ -1,0 -1,0 +1,54 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++    
++	
++	/**
++	 *  The TableCellView class is the view bead for TableCell. It has no function
++	 *  on the JS platform, but with SWF, it prevents the cell from shrinking
++	 *  to fit its content.
++	 *  
++	 *  @viewbead
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class TableCellView extends GroupView
++	{
++		/**
++		 *  constructor.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function TableCellView()
++		{
++			super();
++		}
++		
++		override public function afterLayout():void
++		{
++			// do nothing for TableCell
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/SimpleTableLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/SimpleTableLayout.as
index 0000000,0000000..bf8b35a
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/SimpleTableLayout.as
@@@ -1,0 -1,0 +1,213 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads.layouts
++{
++	import org.apache.flex.core.LayoutBase;
++	
++	import org.apache.flex.core.IBeadLayout;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.html.TableCell;
++	import org.apache.flex.html.TableRow;
++	
++	COMPILE::SWF {
++		import org.apache.flex.geom.Rectangle;
++		import org.apache.flex.utils.CSSUtils;
++		import org.apache.flex.utils.CSSContainerUtils;
++	}
++
++    /**
++     *  The SimpleTableLayout is the layout for the Table component. On the SWF platform it mimics
++	 *  the HTML <table> element and makes sure all the columns and rows are even. It does not
++	 *  support column or row spanning.
++     *
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public class SimpleTableLayout extends LayoutBase implements IBeadLayout
++	{
++        /**
++         *  Constructor.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function SimpleTableLayout()
++		{
++			super();
++		}
++
++        /**
++         * @copy org.apache.flex.core.IBeadLayout#layout
++		 * @flexjsignorecoercion org.apache.flex.core.ILayoutHost
++		 * @flexjsignorecoercion org.apache.flex.core.UIBase
++         */
++		override public function layout():Boolean
++		{
++            COMPILE::SWF
++            {
++				var contentView:ILayoutView = layoutView;
++				
++				var n:int = contentView.numElements;
++				if (n == 0) return false;
++
++				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
++				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
++				var hostWidth:Number = hostWidthSizedToContent ? host.width : contentView.width;
++				var hostHeight:Number = hostHeightSizedToContent ? host.height : contentView.height;
++				
++				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
++				
++				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++				// resulting adjusted value may be less than zero.
++				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++				
++				var numRows:int = n;
++				var numCols:int = 0;
++
++				// pass 1: figure out the number of columns (numRows is already given)
++                for (var i:int = 0; i < n; i++)
++                {
++                    var row:TableRow = contentView.getElementAt(i) as TableRow;
++					if (row == null || !row.visible) {
++						numRows -= 1;
++						continue;
++					}
++					
++					numCols = Math.max(numCols,row.numElements);
++				}
++				
++				// these defaults may change once the next pass is complete.
++				var defaultColWidth:Number = hostWidth / numCols;
++				var defaultRowHeight:Number = hostHeight / numRows;
++				
++				var remainingWidth:Number = hostWidth;
++				var remainingHeight:Number = hostHeight;
++				
++				var colWidths:Array = new Array(numCols);
++				var colActuals:Array = new Array(numCols);
++				for(j=0; j < numCols; j++) { colWidths[j] = 0; colActuals[j] = 0; }
++				
++				var rowHeights:Array = new Array(numRows);
++				for(i=0; i < numRows; i++) rowHeights[i] = 0;
++				
++				// pass2: figure out the sizes things should be
++				for(i=0; i < n; i++)
++				{
++					row = contentView.getElementAt(i) as TableRow;
++					if (row == null || !row.visible) continue;
++					
++					for(var j:int=0; j < row.numElements; j++)
++					{
++						var cell:TableCell = row.getElementAt(j) as TableCell;
++						if (cell == null || !cell.visible) continue;
++						
++						if (cell.isWidthSizedToContent()) {
++							colWidths[j] = Math.max(colWidths[j],0);
++							colActuals[j] = Math.max(colActuals[j],cell.width);
++						} else {
++							if (isNaN(cell.percentWidth)) {
++								colWidths[j] = Math.max(colWidths[j],cell.width);
++							} else {
++								colWidths[j] = Math.max(colWidths[j],(hostWidth*cell.percentWidth/100.0));
++							}
++							colActuals[j] = Math.max(colActuals[j],colWidths[j]);
++						}
++						
++						if (cell.isHeightSizedToContent()) {
++							rowHeights[i] = Math.max(rowHeights[i],0);
++						} else {
++							if (isNaN(cell.percentHeight)) {
++								rowHeights[i] = Math.max(rowHeights[i],cell.height);
++							} else {
++								rowHeights[i] = Math.max(rowHeights[i],(hostHeight*cell.percentHeight/100.0));
++							}
++						}
++					}
++                }
++				
++				var needsDefaultColWidthCount:int = 0;
++				var needsDefaultRowHeightCount:int = 0;
++				
++				// pass3: determine default sizes for cells without size
++				for(i=0; i < rowHeights.length; i++) {
++					if (!isNaN(rowHeights[i]) && rowHeights[i] > 0) remainingHeight -= rowHeights[i];
++					else needsDefaultRowHeightCount++;
++				}
++				for(j=0; j < colWidths.length; j++) {
++					if (colWidths[j] == 0) {
++						if (colActuals[j] > defaultColWidth) {
++							colWidths[j] = colActuals[j];
++							remainingWidth -= colActuals[j];
++						}
++						else {
++							needsDefaultColWidthCount++;
++						}
++					} else {
++						remainingWidth -= colWidths[j];
++					}
++				}
++				
++				defaultColWidth = remainingWidth / needsDefaultColWidthCount;
++				defaultRowHeight = remainingHeight / needsDefaultRowHeightCount;
++				
++				var ypos:Number = paddingMetrics.top + borderMetrics.top;
++				
++				// pass4: size everything
++				for(i=0; i < n; i++)
++				{
++					row = contentView.getElementAt(i) as TableRow;
++					if (row == null || !row.visible) continue;
++					
++					var xpos:Number = paddingMetrics.left + borderMetrics.left;
++					
++					for(j=0; j < row.numElements; j++)
++					{
++						cell = row.getElementAt(j) as TableCell;
++						if (cell == null || !cell.visible) continue;
++						
++						var useWidth:Number = colWidths[j] > 0 ? colWidths[j] : defaultColWidth;
++						var useHeight:Number = rowHeights[i] > 0 ? rowHeights[i] : defaultRowHeight;
++						
++						cell.x = xpos;
++						cell.y = ypos;
++						cell.setWidthAndHeight(useWidth, useHeight);
++						
++						xpos += useWidth;
++					}
++					
++					ypos += rowHeights[i] > 0 ? rowHeights[i] : defaultRowHeight;
++				}
++
++                return true;
++
++            }
++
++            COMPILE::JS
++            {
++                return true;
++            }
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TableCellLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TableCellLayout.as
index 0000000,0000000..0dd9dc4
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TableCellLayout.as
@@@ -1,0 -1,0 +1,120 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads.layouts
++{
++	import org.apache.flex.core.LayoutBase;
++	
++	import org.apache.flex.core.IBeadLayout;
++	import org.apache.flex.core.ILayoutChild;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.html.TableCell;
++	import org.apache.flex.html.TableRow;
++	
++	COMPILE::SWF {
++		import org.apache.flex.geom.Rectangle;
++		import org.apache.flex.utils.CSSUtils;
++		import org.apache.flex.utils.CSSContainerUtils;
++	}
++
++    /**
++     *  The TableCellLayout is the default layout for TableCell items. It places the cell's contents
++	 *  vertically centered within the cell.
++     *
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public class TableCellLayout extends HorizontalLayout implements IBeadLayout
++	{
++        /**
++         *  Constructor.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function TableCellLayout()
++		{
++			super();
++		}
++
++        /**
++         * @copy org.apache.flex.core.IBeadLayout#layout
++		 * @flexjsignorecoercion org.apache.flex.core.ILayoutHost
++		 * @flexjsignorecoercion org.apache.flex.core.UIBase
++         */
++		override public function layout():Boolean
++		{
++            COMPILE::SWF
++            {
++				if (!super.layout()) return false;
++				
++				var contentView:ILayoutView = layoutView;
++				var n:int = contentView.numElements;
++				if (n == 0) return false;
++				
++				// find the overall size and position in the centervar contentView:ILayoutView = layoutView;
++				
++				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
++				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
++				var hostWidth:Number = hostWidthSizedToContent ? host.width : contentView.width;
++				var hostHeight:Number = hostHeightSizedToContent ? host.height : contentView.height;
++				
++				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
++				
++				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++				// resulting adjusted value may be less than zero.
++				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++				
++				var totalHeight:Number = 0;
++				
++				for(var i:int=0; i < n; i++)
++				{
++					var child:ILayoutChild = contentView.getElementAt(i) as ILayoutChild;
++					if (child == null || !child.visible) continue;
++					var positions:Object = childPositions(child);
++					var margins:Object = childMargins(child, hostWidth, hostHeight);
++					
++					totalHeight += margins.top + child.height + margins.bottom;
++				}
++				
++				var shiftBy:Number = (hostHeight - totalHeight)/2;
++				
++				for(i=0; i < n; i++)
++				{
++					child = contentView.getElementAt(i) as ILayoutChild;
++					if (child == null || !child.visible) continue;
++					child.y += shiftBy;
++				}
++
++                return true;
++
++            }
++
++            COMPILE::JS
++            {
++                return true;
++            }
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TableHeaderLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TableHeaderLayout.as
index 0000000,0000000..a955c83
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TableHeaderLayout.as
@@@ -1,0 -1,0 +1,124 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads.layouts
++{
++	import org.apache.flex.core.LayoutBase;
++	
++	import org.apache.flex.core.IBeadLayout;
++	import org.apache.flex.core.ILayoutChild;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.html.TableCell;
++	import org.apache.flex.html.TableRow;
++	
++	COMPILE::SWF {
++		import org.apache.flex.geom.Rectangle;
++		import org.apache.flex.utils.CSSUtils;
++		import org.apache.flex.utils.CSSContainerUtils;
++	}
++
++    /**
++     *  The TableHeaderLayout is the default layout for TableHeader items. It places the cell's contents
++	 *  vertically and horizontally centered within the cell.
++     *
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public class TableHeaderLayout extends HorizontalLayout implements IBeadLayout
++	{
++        /**
++         *  Constructor.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function TableHeaderLayout()
++		{
++			super();
++		}
++
++        /**
++         * @copy org.apache.flex.core.IBeadLayout#layout
++		 * @flexjsignorecoercion org.apache.flex.core.ILayoutHost
++		 * @flexjsignorecoercion org.apache.flex.core.UIBase
++         */
++		override public function layout():Boolean
++		{
++            COMPILE::SWF
++            {
++				if (!super.layout()) return false;
++				
++				var contentView:ILayoutView = layoutView;
++				var n:int = contentView.numElements;
++				if (n == 0) return false;
++				
++				// find the overall size and position in the centervar contentView:ILayoutView = layoutView;
++				
++				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
++				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
++				var hostWidth:Number = hostWidthSizedToContent ? host.width : contentView.width;
++				var hostHeight:Number = hostHeightSizedToContent ? host.height : contentView.height;
++				
++				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
++				
++				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++				// resulting adjusted value may be less than zero.
++				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++				
++				var totalHeight:Number = 0;
++				var totalWidth:Number = 0;
++				
++				for(var i:int=0; i < n; i++)
++				{
++					var child:ILayoutChild = contentView.getElementAt(i) as ILayoutChild;
++					if (child == null || !child.visible) continue;
++					var positions:Object = childPositions(child);
++					var margins:Object = childMargins(child, hostWidth, hostHeight);
++					
++					totalHeight += margins.top + child.height + margins.bottom;
++					totalWidth += margins.left + child.width + margins.right;
++				}
++				
++				var shiftYBy:Number = (hostHeight - totalHeight)/2;
++				var shiftXBy:Number = (hostWidth - totalWidth)/2;
++				
++				for(i=0; i < n; i++)
++				{
++					child = contentView.getElementAt(i) as ILayoutChild;
++					if (child == null || !child.visible) continue;
++					child.x += shiftXBy;
++					child.y += shiftYBy;
++				}
++
++                return true;
++
++            }
++
++            COMPILE::JS
++            {
++                return true;
++            }
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/resources/basic-manifest.xml
index d57c592,072aed9..4e3d261
--- a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
@@@ -148,10 -124,8 +148,15 @@@
      <component id="OneFlexibleChildHorizontalLayout" class="org.apache.flex.html.beads.layouts.OneFlexibleChildHorizontalLayout"/>
      <component id="MXMLBeadView" class="org.apache.flex.html.MXMLBeadView"/>
  
 +    <component id="SubAppLoader" class="org.apache.flex.html.SubAppLoader" />
 +
      <component id="Border" class="org.apache.flex.html.supportClasses.Border"/>
 -    
 +
      <component id="WebBrowser" class="org.apache.flex.html.WebBrowser" />
++    
++    <component id="Table" class="org.apache.flex.html.Table"/>
++    <component id="TableRow" class="org.apache.flex.html.TableRow"/>
++    <component id="TableCell" class="org.apache.flex.html.TableCell"/>
++    <component id="TableHeader" class="org.apache.flex.html.TableHeader"/>
  
  </componentPackage>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/Basic/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/resources/defaults.css
index 02a5bdb,5ce20fb..1a944dd
--- a/frameworks/projects/Basic/src/main/resources/defaults.css
+++ b/frameworks/projects/Basic/src/main/resources/defaults.css
@@@ -344,28 -240,11 +344,44 @@@ Lis
  	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
  	border-style: solid;
  	border-color: #222222;
 +	background-color: #FFFFFF;
  }
  
 -Tree
 +Accordion
  {
  	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
 +	IBeadView:  ClassReference("org.apache.flex.html.beads.AccordionView");			
 +	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
 +	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout");
 +	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
 +	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
 +	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.AccordionItemRenderer");
 +	IViewport: ClassReference("org.apache.flex.html.supportClasses.ClippingViewport");
 +	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
 +	IAccordionCollapseBead: ClassReference("org.apache.flex.html.beads.AccordionCollapseBead");
 +	border-style: solid;
 +	border-color: #222222;
 +}
 +
++Table
++{
++	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.SimpleTableLayout");
++}
++
++TableHeader
++{
++	font-weight: bold;
++	border: 1px solid #999999;
++}
++
++TableCell
++{
++	border: 1px solid #999999;
++}
++
 +Tree
 +{
 +	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArrayListSelectionModel");
  	IBeadView:  ClassReference("org.apache.flex.html.beads.ListView");			
  	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.TreeSingleSelectionMouseController");
  	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalLayout");

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a168d45a/frameworks/projects/GoogleMaps/src/main/flex/org/apache/flex/maps/google/beads/GoogleMapView.as
----------------------------------------------------------------------


[19/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - fix another merge issue

Posted by ah...@apache.org.
fix another merge issue


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/6af0a47d
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/6af0a47d
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/6af0a47d

Branch: refs/heads/develop
Commit: 6af0a47d04353cc4f429820e2e10a61b0ff67dd9
Parents: 31e3c55
Author: Alex Harui <ah...@apache.org>
Authored: Fri Apr 21 09:56:10 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Apr 21 09:56:10 2017 -0700

----------------------------------------------------------------------
 examples/native/ButtonExample/build.xml | 34 ----------------------------
 1 file changed, 34 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/6af0a47d/examples/native/ButtonExample/build.xml
----------------------------------------------------------------------
diff --git a/examples/native/ButtonExample/build.xml b/examples/native/ButtonExample/build.xml
index a427dd8..5e0f408 100644
--- a/examples/native/ButtonExample/build.xml
+++ b/examples/native/ButtonExample/build.xml
@@ -33,41 +33,7 @@
     <property name="config_arg" value="js" />
     <property name="file_suffix" value="as" />
     
-<<<<<<< HEAD
     <target name="main" depends="clean,build_example.compile" description="Clean build of ${example}">
-=======
-    <target name="build">
-        <java jar="${FALCONJX_HOME}/lib/mxmlc.jar" resultProperty="errorCode"
-            fork="true">
-            <jvmarg line="${mxmlc.jvm.args}"/>
-            <jvmarg line="-Dflexlib=${FLEXJS_HOME}/frameworks}"/>
-            <arg value="+flexlib=${FLEXJS_HOME}/frameworks" />
-            <arg value="-debug" />
-            <arg value="-define=CONFIG::as_only,false" />
-            <arg value="-define=CONFIG::js_only,true" />
-            <arg value="-external-library-path=${JS.SWC}" />
-            <arg value="-compiler.mxml.children-as-data" />
-            <arg value="-compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent" />
-            <arg value="-compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent" />
-            <arg value="-compiler.binding-value-change-event-type=valueChange" />
-            <arg value="+playerglobal.version=${playerglobal.version}" />
-            <arg value="+env.PLAYERGLOBAL_HOME=${env.PLAYERGLOBAL_HOME}" />
-            <arg value="-js-output-type=FLEXJS" />
-            <arg value="-closure-lib=${GOOG_HOME}" />
-            <arg value="-sdk-js-lib=${FLEXJS_HOME}/frameworks/js/FlexJS/libs" />
-            <arg value="${basedir}/src/main/flex/${example}.as" />
-        </java>
-        <fail>
-            <condition>
-                <not>
-                    <or>
-                        <equals arg1="${errorCode}" arg2="0" />
-                        <equals arg1="${errorCode}" arg2="2" />
-                    </or>
-                </not>
-            </condition>
-        </fail>        
->>>>>>> develop
     </target>
     
     <target name="clean">


[29/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Form missing view bead and should extend Group.

Posted by ah...@apache.org.
Form missing view bead and should extend Group.


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/b0d78b34
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/b0d78b34
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/b0d78b34

Branch: refs/heads/develop
Commit: b0d78b342862f5862cf9647471fb8f4ceddaae2e
Parents: f22668b
Author: Peter Ent <pe...@apache.org>
Authored: Tue Apr 25 11:55:53 2017 -0400
Committer: Peter Ent <pe...@apache.org>
Committed: Tue Apr 25 11:55:53 2017 -0400

----------------------------------------------------------------------
 .../src/main/flex/org/apache/flex/html/Form.as      |  4 +---
 .../projects/Basic/src/main/resources/defaults.css  | 16 ++++++++--------
 2 files changed, 9 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b0d78b34/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as
index 96fe42a..ef258c2 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as
@@ -18,8 +18,6 @@
 ////////////////////////////////////////////////////////////////////////////////
 package org.apache.flex.html
 {
-    import org.apache.flex.html.Container;
-
     COMPILE::JS
     {
         import org.apache.flex.core.WrappedHTMLElement;
@@ -36,7 +34,7 @@ package org.apache.flex.html
      *  @playerversion AIR 2.6
      *  @productversion FlexJS 0.0
      */
-    public class Form extends Container
+    public class Form extends Group
 	{
         /**
          *  Constructor.

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b0d78b34/frameworks/projects/Basic/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/resources/defaults.css b/frameworks/projects/Basic/src/main/resources/defaults.css
index f2893ce..20175fa 100644
--- a/frameworks/projects/Basic/src/main/resources/defaults.css
+++ b/frameworks/projects/Basic/src/main/resources/defaults.css
@@ -269,6 +269,14 @@ DateField {
 
 /* Groups */
 
+Form {
+	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
+}
+
+Group {
+	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
+}
+
 HGroup {
 	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.HorizontalLayout");
 }
@@ -285,14 +293,6 @@ RangeStepper {
 	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.RangeStepperMouseController");
 }
 
-Form {
-	
-}
-
-Group {
-	IBeadView: ClassReference("org.apache.flex.html.beads.GroupView");
-}
-
 HContainer
 {
 	IBeadView: ClassReference("org.apache.flex.html.beads.ContainerView");


[34/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - HorizontalLayoutWithPaddingAndGap, VerticalLayoutWithPaddingAndGap: versions of HorizontalLayout and VerticalLayout that have properties for padding and gap

Posted by ah...@apache.org.
HorizontalLayoutWithPaddingAndGap, VerticalLayoutWithPaddingAndGap: versions of HorizontalLayout and VerticalLayout that have properties for padding and gap


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/df6f560a
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/df6f560a
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/df6f560a

Branch: refs/heads/develop
Commit: df6f560aa381878b94d5862f720b4bf66929f8eb
Parents: 16c4fea
Author: Josh Tynjala <jo...@apache.org>
Authored: Thu Apr 27 12:20:18 2017 -0700
Committer: Josh Tynjala <jo...@apache.org>
Committed: Thu Apr 27 12:20:18 2017 -0700

----------------------------------------------------------------------
 .../Basic/src/main/flex/BasicClasses.as         |   2 +
 .../HorizontalLayoutWithPaddingAndGap.as        | 348 +++++++++++++++++++
 .../layouts/VerticalLayoutWithPaddingAndGap.as  | 329 ++++++++++++++++++
 .../Basic/src/main/resources/basic-manifest.xml |   2 +
 .../src/main/resources/express-manifest.xml     |   2 +
 5 files changed, 683 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/df6f560a/frameworks/projects/Basic/src/main/flex/BasicClasses.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/BasicClasses.as b/frameworks/projects/Basic/src/main/flex/BasicClasses.as
index 70665e1..4436e43 100644
--- a/frameworks/projects/Basic/src/main/flex/BasicClasses.as
+++ b/frameworks/projects/Basic/src/main/flex/BasicClasses.as
@@ -140,8 +140,10 @@ internal class BasicClasses
 	}
 	import org.apache.flex.html.beads.layouts.ButtonBarLayout; ButtonBarLayout;
     import org.apache.flex.html.beads.layouts.VerticalLayout; VerticalLayout;
+    import org.apache.flex.html.beads.layouts.VerticalLayoutWithPaddingAndGap; VerticalLayoutWithPaddingAndGap;
 	import org.apache.flex.html.beads.layouts.VerticalFlexLayout; VerticalFlexLayout;
 	import org.apache.flex.html.beads.layouts.HorizontalLayout; HorizontalLayout;
+    import org.apache.flex.html.beads.layouts.HorizontalLayoutWithPaddingAndGap; HorizontalLayoutWithPaddingAndGap;
 	import org.apache.flex.html.beads.layouts.HorizontalFlexLayout; HorizontalFlexLayout;
     import org.apache.flex.html.beads.layouts.BasicLayout; BasicLayout;
 	import org.apache.flex.html.beads.layouts.OneFlexibleChildHorizontalLayout; OneFlexibleChildHorizontalLayout;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/df6f560a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayoutWithPaddingAndGap.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayoutWithPaddingAndGap.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayoutWithPaddingAndGap.as
new file mode 100644
index 0000000..7aec7f3
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayoutWithPaddingAndGap.as
@@ -0,0 +1,348 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.html.beads.layouts
+{
+	import org.apache.flex.core.LayoutBase;
+	
+	import org.apache.flex.core.IBeadLayout;
+	import org.apache.flex.core.IBeadModel;
+	import org.apache.flex.core.ILayoutChild;
+	import org.apache.flex.core.ILayoutHost;
+	import org.apache.flex.core.ILayoutView;
+	import org.apache.flex.core.ILayoutParent;
+	import org.apache.flex.core.IParentIUIBase;
+	import org.apache.flex.core.IStrand;
+	import org.apache.flex.core.IUIBase;
+	import org.apache.flex.core.ValuesManager;
+	import org.apache.flex.events.Event;
+	import org.apache.flex.events.IEventDispatcher;
+	import org.apache.flex.geom.Rectangle;
+	import org.apache.flex.utils.CSSContainerUtils;
+	import org.apache.flex.utils.CSSUtils;
+	COMPILE::SWF {
+			import org.apache.flex.core.UIBase;
+	}
+    COMPILE::JS {
+        import org.apache.flex.core.WrappedHTMLElement;
+    }
+
+    /**
+	 *  The HorizontalLayoutWithPaddingAndGap class is a simple layout
+	 *  bead similar to HorizontalLayout, but it adds support for
+	 *  padding and gap values.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 10.2
+     *  @playerversion AIR 2.6
+     *  @productversion FlexJS 0.0
+     */
+	public class HorizontalLayoutWithPaddingAndGap extends LayoutBase implements IBeadLayout
+	{
+        /**
+         *  Constructor.
+         *
+         *  @langversion 3.0
+         *  @playerversion Flash 10.2
+         *  @playerversion AIR 2.6
+         *  @productversion FlexJS 0.0
+         */
+		public function HorizontalLayoutWithPaddingAndGap()
+		{
+			super();
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _paddingTop:Number = 0;
+
+		/**
+		 *  The top padding value.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get paddingTop():Number
+		{
+			return _paddingTop;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set paddingTop(value:Number):void
+		{
+			_paddingTop = value;
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _paddingRight:Number = 0;
+
+		/**
+		 *  The right padding value.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get paddingRight():Number
+		{
+			return _paddingRight;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set paddingRight(value:Number):void
+		{
+			_paddingRight = value;
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _paddingBottom:Number = 0;
+
+		/**
+		 *  The top padding value.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get paddingBottom():Number
+		{
+			return _paddingBottom;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set paddingBottom(value:Number):void
+		{
+			_paddingBottom = value;
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _paddingLeft:Number = 0;
+
+		/**
+		 *  The left padding value.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get paddingLeft():Number
+		{
+			return _paddingLeft;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set paddingLeft(value:Number):void
+		{
+			_paddingLeft = value;
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _gap:Number = 0;
+
+		/**
+		 *  The gap between items.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get gap():Number
+		{
+			return _gap;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set gap(value:Number):void
+		{
+			_gap = value;
+		}
+
+        /**
+         *  @copy org.apache.flex.core.IBead#strand
+         *
+         *  @langversion 3.0
+         *  @playerversion Flash 10.2
+         *  @playerversion AIR 2.6
+         *  @productversion FlexJS 0.0
+         *  @flexjsignorecoercion HTMLElement
+         *  @flexjsignorecoercion org.apache.flex.core.IUIBase
+         */
+		override public function set strand(value:IStrand):void
+		{
+			super.strand = value;
+			
+            COMPILE::JS
+            {
+				var base:IUIBase = value as IUIBase;
+				if (base.element.style.display !== "none") {
+					base.element.style.display = "block";
+				}
+            }
+		}
+
+        /**
+         * @copy org.apache.flex.core.IBeadLayout#layout
+         * @flexjsignorecoercion org.apache.flex.core.ILayoutHost
+         * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
+         */
+		override public function layout():Boolean
+		{
+            COMPILE::SWF
+            {
+				var contentView:ILayoutView = layoutView;
+
+				var n:Number = contentView.numElements;
+				if (n == 0) return false;
+
+				var maxWidth:Number = 0;
+				var maxHeight:Number = 0;
+				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
+				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
+				var hostWidth:Number = hostWidthSizedToContent ? 0 : contentView.width;
+				var hostHeight:Number = hostHeightSizedToContent ? 0 : contentView.height;
+
+				var ilc:ILayoutChild;
+				var data:Object;
+				var canAdjust:Boolean = false;
+
+				var paddingMetrics:Rectangle = new Rectangle(_paddingLeft, _paddingTop, _paddingRight - _paddingLeft, _paddingBottom - _paddingTop);
+				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
+				
+				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
+				// resulting adjusted value may be less than zero.
+				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
+				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
+
+				var xpos:Number = borderMetrics.left + paddingMetrics.left;
+				var ypos:Number = borderMetrics.top + paddingMetrics.left;
+
+				// First pass determines the data about the child.
+				for(var i:int=0; i < n; i++)
+				{
+					var child:IUIBase = contentView.getElementAt(i) as IUIBase;
+					if (child == null || !child.visible) continue;
+					var positions:Object = childPositions(child);
+
+					ilc = child as ILayoutChild;
+
+					var childYpos:Number = ypos; // default y position
+
+					if (!hostHeightSizedToContent) {
+						var childHeight:Number = child.height;
+						if (ilc != null && !isNaN(ilc.percentHeight)) {
+							childHeight = hostHeight * ilc.percentHeight/100.0;
+							ilc.setHeight(childHeight);
+						}
+						// the following code middle-aligns the child, but since HTML does not
+						// do this normally, this code is commented. (Use HorizontalFlexLayout for
+						// vertically centered elements in a horizontal row).
+//						childYpos = hostHeight/2 - (childHeight + mt + mb)/2;
+					}
+
+					if (ilc) {
+						ilc.setX(xpos);
+						ilc.setY(childYpos);
+
+						if (!hostWidthSizedToContent && !isNaN(ilc.percentWidth)) {
+							var newWidth:Number = hostWidth * ilc.percentWidth / 100;
+							ilc.setWidth(newWidth);
+						}
+
+					} else {
+						child.x = xpos;
+						child.y = childYpos;
+					}
+
+					xpos += child.width + _gap;
+				}
+
+				return true;
+
+            }
+            COMPILE::JS
+            {
+                var children:Array;
+                var i:int;
+                var n:int;
+				var contentView:IParentIUIBase = layoutView as IParentIUIBase;
+
+				contentView.element.style["white-space"] = "nowrap";
+
+                children = contentView.internalChildren();
+
+
+                n = children.length;
+                for (i = 0; i < n; i++)
+                {
+                    var child:WrappedHTMLElement = children[i] as WrappedHTMLElement;
+					if (child == null) continue;
+					child.style.marginTop = _paddingTop + 'px';
+					if(i === (n - 1))
+					{
+						child.style.marginRight = _paddingRight + 'px';
+					}
+					else
+					{
+						child.style.marginRight = '0px';
+					}
+					child.style.marginBottom = _paddingBottom + 'px';
+					if(i == 0)
+					{
+						child.style.marginLeft = _paddingLeft + 'px';
+					}
+					else
+					{
+						child.style.marginLeft = _gap + 'px';
+					}
+					child.flexjs_wrapper.setDisplayStyleForLayout('inline-block');
+					if (child.style.display !== 'none')
+					{
+						child.style.display = 'inline-block';
+					}
+				}
+
+                return true;
+            }
+		}
+	}
+}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/df6f560a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayoutWithPaddingAndGap.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayoutWithPaddingAndGap.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayoutWithPaddingAndGap.as
new file mode 100644
index 0000000..9a137b4
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayoutWithPaddingAndGap.as
@@ -0,0 +1,329 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.html.beads.layouts
+{
+	import org.apache.flex.core.LayoutBase;
+	
+	import org.apache.flex.core.IBeadLayout;
+	import org.apache.flex.core.IBeadModel;
+	import org.apache.flex.core.ILayoutChild;
+	import org.apache.flex.core.ILayoutHost;
+	import org.apache.flex.core.ILayoutView;
+	import org.apache.flex.core.ILayoutParent;
+	import org.apache.flex.core.IParentIUIBase;
+	import org.apache.flex.core.IStrand;
+	import org.apache.flex.core.IUIBase;
+	import org.apache.flex.core.ValuesManager;
+	COMPILE::JS
+	{
+		import org.apache.flex.core.WrappedHTMLElement;
+	}
+	import org.apache.flex.events.Event;
+	import org.apache.flex.events.IEventDispatcher;
+	import org.apache.flex.geom.Rectangle;
+	import org.apache.flex.utils.CSSContainerUtils;
+	import org.apache.flex.utils.CSSUtils;
+
+	/**
+	 *  The VerticalLayoutWithPaddingAndGap class is a simple layout
+	 *  bead similar to VerticalLayout, but it adds support for
+	 *  padding and gap values.
+	 *
+	 *  @langversion 3.0
+	 *  @playerversion Flash 10.2
+	 *  @playerversion AIR 2.6
+	 *  @productversion FlexJS 0.0
+	 */
+	public class VerticalLayoutWithPaddingAndGap extends LayoutBase implements IBeadLayout
+	{
+		/**
+		 *  Constructor.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function VerticalLayoutWithPaddingAndGap()
+		{
+			super();
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _paddingTop:Number = 0;
+
+		/**
+		 *  The top padding value.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get paddingTop():Number
+		{
+			return _paddingTop;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set paddingTop(value:Number):void
+		{
+			_paddingTop = value;
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _paddingRight:Number = 0;
+
+		/**
+		 *  The right padding value.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get paddingRight():Number
+		{
+			return _paddingRight;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set paddingRight(value:Number):void
+		{
+			_paddingRight = value;
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _paddingBottom:Number = 0;
+
+		/**
+		 *  The top padding value.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get paddingBottom():Number
+		{
+			return _paddingBottom;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set paddingBottom(value:Number):void
+		{
+			_paddingBottom = value;
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _paddingLeft:Number = 0;
+
+		/**
+		 *  The left padding value.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get paddingLeft():Number
+		{
+			return _paddingLeft;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set paddingLeft(value:Number):void
+		{
+			_paddingLeft = value;
+		}
+
+		/**
+		 *  @private
+		 */
+		private var _gap:Number = 0;
+
+		/**
+		 *  The gap between items.
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 */
+		public function get gap():Number
+		{
+			return _gap;
+		}
+
+		/**
+		 *  @private
+		 */
+		public function set gap(value:Number):void
+		{
+			_gap = value;
+		}
+
+		/**
+		 *  Layout children vertically
+		 *
+		 *  @langversion 3.0
+		 *  @playerversion Flash 10.2
+		 *  @playerversion AIR 2.6
+		 *  @productversion FlexJS 0.0
+		 *  @flexjsignorecoercion org.apache.flex.core.ILayoutHost
+		 */
+		override public function layout():Boolean
+		{
+			COMPILE::SWF
+			{
+				var contentView:ILayoutView = layoutView;
+
+				var n:Number = contentView.numElements;
+				if (n == 0) return false;
+
+				var maxWidth:Number = 0;
+				var maxHeight:Number = 0;
+				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
+				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
+				var hostWidth:Number = hostWidthSizedToContent ? 0 : contentView.width;
+				var hostHeight:Number = hostHeightSizedToContent ? 0 : contentView.height;
+
+				var ilc:ILayoutChild;
+				var data:Object;
+				var canAdjust:Boolean = false;
+
+				var paddingMetrics:Rectangle = new Rectangle(_paddingLeft, _paddingTop, _paddingRight - _paddingLeft, _paddingBottom - _paddingTop);
+				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
+				
+				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
+				// resulting adjusted value may be less than zero.
+				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
+				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
+
+				var xpos:Number = borderMetrics.left + paddingMetrics.left;
+				var ypos:Number = borderMetrics.top + paddingMetrics.left;
+
+				// First pass determines the data about the child.
+				for(var i:int=0; i < n; i++)
+				{
+					var child:IUIBase = contentView.getElementAt(i) as IUIBase;
+					if (child == null || !child.visible) continue;
+					var positions:Object = childPositions(child);
+
+					ilc = child as ILayoutChild;
+
+					var childXpos:Number = xpos; // default x position
+
+					if (!hostWidthSizedToContent) {
+						var childWidth:Number = child.width;
+						if (ilc != null && !isNaN(ilc.percentWidth)) {
+							childWidth = hostWidth * ilc.percentWidth/100.0;
+							ilc.setWidth(childWidth);
+						}
+						// the following code center-aligns the child, but since HTML does not
+						// do this normally, this code is commented. (Use VerticalFlexLayout for
+						// horizontally centered elements in a vertical column).
+						//					childXpos = hostWidth/2 - (childWidth + ml + mr)/2;
+					}
+
+					if (ilc) {
+						ilc.setX(childXpos);
+						ilc.setY(ypos);
+
+						if (!hostHeightSizedToContent && !isNaN(ilc.percentHeight)) {
+							var newHeight:Number = hostHeight * ilc.percentHeight / 100;
+							ilc.setHeight(newHeight);
+						}
+
+					} else {
+						child.x = childXpos;
+						child.y = ypos;
+					}
+
+					ypos += child.height + _gap;
+				}
+
+				return true;
+			}
+			COMPILE::JS
+			{
+				var children:Array;
+				var i:int;
+				var n:int;
+				var contentView:IParentIUIBase = layoutView as IParentIUIBase;
+				
+				children = contentView.internalChildren();
+				n = children.length;
+				for (i = 0; i < n; i++)
+				{
+					var child:WrappedHTMLElement = children[i];
+					if(i == 0)
+					{
+						child.style.marginTop = _paddingTop + 'px';
+					}
+					else
+					{
+						child.style.marginTop = _gap + 'px';
+					}
+					child.style.marginRight = _paddingRight + 'px';
+					if(i === (n - 1))
+					{
+						child.style.marginBottom = _paddingBottom + 'px';
+					}
+					else
+					{
+						child.style.marginBottom = '0px';
+					}
+					child.style.marginLeft = _paddingLeft + 'px';
+					child.flexjs_wrapper.setDisplayStyleForLayout('block');
+					if (child.style.display === 'none')
+					{
+						child.flexjs_wrapper.setDisplayStyleForLayout('block');
+					}
+					else
+					{
+						// block elements don't measure width correctly so set to inline for a second
+						child.style.display = 'inline-block';
+						child.style.display = 'block';
+					}
+					child.flexjs_wrapper.dispatchEvent('sizeChanged');
+				}
+
+				return true;
+			}
+		}
+
+	}
+}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/df6f560a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml b/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
index c9b49b8..204d10c 100644
--- a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
@@ -67,8 +67,10 @@
     <component id="Tree" class="org.apache.flex.html.Tree"/>
     <component id="BasicLayout" class="org.apache.flex.html.beads.layouts.BasicLayout"/>
     <component id="VerticalLayout" class="org.apache.flex.html.beads.layouts.VerticalLayout"/>
+    <component id="VerticalLayoutWithPaddingAndGap" class="org.apache.flex.html.beads.layouts.VerticalLayoutWithPaddingAndGap"/>
     <component id="VerticalFlexLayout" class="org.apache.flex.html.beads.layouts.VerticalFlexLayout"/>
     <component id="HorizontalLayout" class="org.apache.flex.html.beads.layouts.HorizontalLayout"/>
+    <component id="HorizontalLayoutWithPaddingAndGap" class="org.apache.flex.html.beads.layouts.HorizontalLayoutWithPaddingAndGap"/>
     <component id="HorizontalFlexLayout" class="org.apache.flex.html.beads.layouts.HorizontalFlexLayout"/>
     <component id="HorizontalFlowLayout" class="org.apache.flex.html.beads.layouts.HorizontalFlowLayout" />
     <component id="TileLayout" class="org.apache.flex.html.beads.layouts.TileLayout"/>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/df6f560a/frameworks/projects/Express/src/main/resources/express-manifest.xml
----------------------------------------------------------------------
diff --git a/frameworks/projects/Express/src/main/resources/express-manifest.xml b/frameworks/projects/Express/src/main/resources/express-manifest.xml
index 9ea226e..63551e2 100644
--- a/frameworks/projects/Express/src/main/resources/express-manifest.xml
+++ b/frameworks/projects/Express/src/main/resources/express-manifest.xml
@@ -61,7 +61,9 @@
     <component id="ToolTip" class="org.apache.flex.html.ToolTip"  lookupOnly="true" />
     <component id="BasicLayout" class="org.apache.flex.html.beads.layouts.BasicLayout"  lookupOnly="true" />
     <component id="VerticalLayout" class="org.apache.flex.html.beads.layouts.VerticalLayout"  lookupOnly="true" />
+    <component id="VerticalLayoutWithPaddingAndGap" class="org.apache.flex.html.beads.layouts.VerticalLayoutWithPaddingAndGap"  lookupOnly="true" />
     <component id="HorizontalLayout" class="org.apache.flex.html.beads.layouts.HorizontalLayout"  lookupOnly="true" />
+    <component id="HorizontalLayoutWithPaddingAndGap" class="org.apache.flex.html.beads.layouts.HorizontalLayoutWithPaddingAndGap"  lookupOnly="true" />
     <component id="TileLayout" class="org.apache.flex.html.beads.layouts.TileLayout"  lookupOnly="true" />
     <component id="ListView" class="org.apache.flex.html.beads.ListView" lookupOnly="true" />
     <component id="MultilineTextFieldView" class="org.apache.flex.html.beads.MultilineTextFieldView" lookupOnly="true" />


[37/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - force drawing in a few more scenarios

Posted by ah...@apache.org.
force drawing in a few more scenarios


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/5734ef16
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/5734ef16
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/5734ef16

Branch: refs/heads/develop
Commit: 5734ef16de2d0ec2ba8476cfaf37a9006b5ded87
Parents: b06d5a1
Author: Alex Harui <ah...@apache.org>
Authored: Wed Apr 26 22:48:19 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 14:15:17 2017 -0700

----------------------------------------------------------------------
 .../org/apache/flex/html/beads/SingleLineBorderBead.as    |  9 +++++++++
 .../org/apache/flex/html/beads/SolidBackgroundBead.as     | 10 ++++++++++
 2 files changed, 19 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/5734ef16/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
index 657beef..0dcc6fa 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
@@ -21,6 +21,7 @@ package org.apache.flex.html.beads
 	import flash.display.Graphics;
 
 	import org.apache.flex.core.IBead;
+	import org.apache.flex.core.ILayoutChild;
 	import org.apache.flex.core.IStatesObject;
 	import org.apache.flex.core.IStrand;
 	import org.apache.flex.core.UIBase;
@@ -70,6 +71,14 @@ package org.apache.flex.html.beads
 			IEventDispatcher(value).addEventListener("sizeChanged", changeHandler);
 			IEventDispatcher(value).addEventListener("initComplete", changeHandler);
 			IEventDispatcher(value).addEventListener("layoutComplete", changeHandler);
+			var ilc:ILayoutChild = value as ILayoutChild;
+			if (ilc)
+			{
+				if (!isNaN(ilc.explicitWidth) && !isNaN(ilc.explicitHeight))
+				{
+					changeHandler(null);
+				}
+			}
 		}
 		        
 		protected function changeHandler(event:Event):void

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/5734ef16/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
index 5833d52..22a7fc7 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
@@ -80,6 +80,16 @@ package org.apache.flex.html.beads
 			IEventDispatcher(host).addEventListener("layoutComplete", changeHandler);
 			
 			setupStyle();
+			
+			var ilc:ILayoutChild = value as ILayoutChild;
+			if (ilc)
+			{
+				if (!isNaN(ilc.explicitWidth) && !isNaN(ilc.explicitHeight))
+				{
+					changeHandler(null);
+				}
+			}
+
 		}
 		
 		protected function setupStyle():void


[43/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - TextInput without a width isn't stretchy. It seems to have a default width

Posted by ah...@apache.org.
TextInput without a width isn't stretchy.  It seems to have a default width


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/8377006c
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/8377006c
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/8377006c

Branch: refs/heads/develop
Commit: 8377006c39efc7e453693997a78d398f5ebaab5f
Parents: 9ab3b56
Author: Alex Harui <ah...@apache.org>
Authored: Thu Apr 27 23:58:03 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 23:58:03 2017 -0700

----------------------------------------------------------------------
 .../src/main/flex/org/apache/flex/html/beads/TextInputView.as      | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/8377006c/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as
index a6f1438..be59056 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as
@@ -84,6 +84,8 @@ package org.apache.flex.html.beads
                 h = textField.textHeight;
                 textField.text = s;
                 ilc.setWidth(w + uiMetrics.left + uiMetrics.right, true);
+				// TextInput doesn't stretch if no width like divs do
+				ilc.explicitWidth = ilc.width;
             }
             if (ilc.isHeightSizedToContent())
             {


[35/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - run layout in a few more scenarios

Posted by ah...@apache.org.
run layout in a few more scenarios


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/b06d5a1d
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/b06d5a1d
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/b06d5a1d

Branch: refs/heads/develop
Commit: b06d5a1d869fbe5f013cd4e83fed6b799bbdfd4b
Parents: e828d17
Author: Alex Harui <ah...@apache.org>
Authored: Wed Apr 26 22:47:37 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 14:15:17 2017 -0700

----------------------------------------------------------------------
 .../flex/org/apache/flex/core/LayoutBase.as     | 33 +++++++++++++++-----
 1 file changed, 25 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b06d5a1d/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
index f23f035..979ebc7 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
@@ -53,6 +53,8 @@ package org.apache.flex.core
 		{
 		}
 
+		private var sawInitComplete:Boolean;
+		
         /**
 		 * The strand/host container is also an ILayoutChild because
          * it can have its size dictated by the host's parent which is
@@ -116,12 +118,19 @@ package org.apache.flex.core
 		protected function handleChildrenAdded(event:Event):void
 		{
 			COMPILE::SWF {
-				var n:Number = layoutView.numElements;
-				for(var i:int=0; i < n; i++) {
-					var child:IEventDispatcher = layoutView.getElementAt(i) as IEventDispatcher;
-					child.addEventListener("widthChanged", childResizeHandler);
-					child.addEventListener("heightChanged", childResizeHandler);
-					child.addEventListener("sizeChanged", childResizeHandler);
+				if (sawInitComplete)
+				{
+					performLayout();
+				}
+				else
+				{
+					var n:Number = layoutView.numElements;
+					for(var i:int=0; i < n; i++) {
+						var child:IEventDispatcher = layoutView.getElementAt(i) as IEventDispatcher;
+						child.addEventListener("widthChanged", childResizeHandler);
+						child.addEventListener("heightChanged", childResizeHandler);
+						child.addEventListener("sizeChanged", childResizeHandler);
+					}
 				}
 			}
 		}
@@ -163,7 +172,13 @@ package org.apache.flex.core
 		 */
 		protected function handleInitComplete(event:Event):void
 		{
-			performLayout();
+			sawInitComplete = true;
+			
+			// Complete the setup if the height is sized to content or has been explicitly set
+            // and the width is sized to content or has been explicitly set
+			if ((host.isHeightSizedToContent() || !isNaN(host.explicitHeight)) &&
+                (host.isWidthSizedToContent() || !isNaN(host.explicitWidth)))
+	    		performLayout();
 		}
 		
 		/**
@@ -195,8 +210,10 @@ package org.apache.flex.core
 				ml = 0;
 			if (marginRight == "auto")
 				mr = 0;
+			if (margin == "auto")
+			    ml = mr = mt = mb = 0;
 			
-			return {left:ml, top:mt, right:mr, bottom:mb};
+			return {left:ml, top:mt, right:mr, bottom:mb, auto: (marginLeft == "auto" && marginRight == "auto") || margin == "auto"};
 		}
 		
 		/**


[24/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - switch TextArea width back to 300

Posted by ah...@apache.org.
switch TextArea width back to 300


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/8256ea58
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/8256ea58
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/8256ea58

Branch: refs/heads/develop
Commit: 8256ea5884e5831fa522f297ca40ee7fe9359870
Parents: 925a08d
Author: Alex Harui <ah...@apache.org>
Authored: Mon Apr 24 10:47:51 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Mon Apr 24 10:47:51 2017 -0700

----------------------------------------------------------------------
 .../flexjs/DataBindingExample/src/main/flex/MyInitialView.mxml     | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/8256ea58/examples/flexjs/DataBindingExample/src/main/flex/MyInitialView.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/DataBindingExample/src/main/flex/MyInitialView.mxml b/examples/flexjs/DataBindingExample/src/main/flex/MyInitialView.mxml
index c8d4b81..84f6f26 100644
--- a/examples/flexjs/DataBindingExample/src/main/flex/MyInitialView.mxml
+++ b/examples/flexjs/DataBindingExample/src/main/flex/MyInitialView.mxml
@@ -146,7 +146,7 @@ limitations under the License.
 	
 	<js:Label id="bindtest" text="{fieldText + ' expression binding'}" />
 	<js:Label width="300" text.showAll="110" includeIn="showAll" />
-	<js:TextArea id="ta" width="100%" height="100" height.showAll="110" 
+	<js:TextArea id="ta" width="300" height="100" height.showAll="110" 
 				 includeIn="showAll"
 				 text="{MyModel(applicationModel).allData}" />
 </js:View>


[09/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ContainerView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ContainerView.as
index 3bd2e94,d62e799..4de5634
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ContainerView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ContainerView.as
@@@ -17,18 -17,18 +17,20 @@@
  //
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads
--{		
++{
  	import org.apache.flex.core.BeadViewBase;
  	import org.apache.flex.core.ContainerBase;
  	import org.apache.flex.core.IBead;
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.IBeadView;
--    import org.apache.flex.core.IChild;
++	import org.apache.flex.core.IChild;
  	import org.apache.flex.core.IContainer;
  	import org.apache.flex.core.IContainerView;
  	import org.apache.flex.core.IContentViewHost;
  	import org.apache.flex.core.ILayoutChild;
  	import org.apache.flex.core.ILayoutHost;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.IParent;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
@@@ -39,37 -39,37 +41,40 @@@
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.geom.Rectangle;
--    import org.apache.flex.geom.Size;
++	import org.apache.flex.geom.Size;
++	import org.apache.flex.html.Container;
  	import org.apache.flex.html.beads.models.ViewportModel;
  	import org.apache.flex.html.supportClasses.Border;
  	import org.apache.flex.html.supportClasses.ContainerContentArea;
  	import org.apache.flex.html.supportClasses.Viewport;
  	import org.apache.flex.utils.CSSContainerUtils;
--    
++
  	/**
  	 * This class creates and manages the contents of a Container. On the ActionScript
  	 * side, a Container has a contentView into which the offical children can be
  	 * placed. When adding an element that implements IChrome, that element is not
  	 * placed into the contentView, but is made a child of the Container directly.
--	 * 
++	 *
  	 * Containers also have a layout associated with them which controls the size and
  	 * placement of the elements in the contentView. When a Container does not have an
  	 * explicit size (including a percent size), the content dictates the size of the
  	 * Container.
--     *  
++     *
++	 *  @viewbead
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
  	 */
--	public class ContainerView extends BeadViewBase implements IBeadView, IContainerView, ILayoutHost
++	COMPILE::SWF
++	public class ContainerView extends GroupView
  	{
  		/**
       	 *  The ContainerView class is the default view for
           *  the org.apache.flex.core.ContainerBase classes.
           *  It lets you use some CSS styles to manage the border, background
           *  and padding around the content area.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -78,41 -78,41 +83,26 @@@
  		public function ContainerView()
  		{
  			super();
--			
--			layoutRunning = false;
  		}
--		
++
  		/**
  		 * The sub-element used as the parent of the container's elements. This does not
  		 * include the chrome elements.
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get contentView():IParentIUIBase
--		{
--			return viewport.contentView as IParentIUIBase;
--		}
--		
--		/**
--		 * The view that can be resized.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		public function get resizableView():IUIBase
++		override public function get contentView():ILayoutView
  		{
--			return host;
++			return viewport.contentView as ILayoutView;
  		}
--		
++
  		/**
  		 * The viewport used to present the content and may display
  		 * scroll bars (depending on the actual type of viewport).
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -122,11 -122,11 +112,11 @@@
  		{
  			return _viewport;
  		}
--		
++
  		/**
  		 * The data model used by the viewport to determine how it should
  		 * present the content area.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -136,62 -136,62 +126,14 @@@
  		{
  			return _viewportModel;
  		}
--		
++
  		private var _viewportModel:IViewportModel;
  		private var _viewport:IViewport;
  		private var layoutRunning:Boolean;
--		
--		/**
--		 * @private
--		 */
--		public function addElement(c:IChild, dispatchEvent:Boolean = true):void
--		{
--			contentView.addElement(c, dispatchEvent);
--		}
--		
--		/**
--		 * @private
--		 */
--		public function addElementAt(c:IChild, index:int, dispatchEvent:Boolean = true):void
--		{
--			contentView.addElementAt(c, index, dispatchEvent);
--		}
--		
--		/**
--		 * @private
--		 */
--		public function getElementIndex(c:IChild):int
--		{
--			return contentView.getElementIndex(c);
--		}
--		
--		/**
--		 * @private
--		 */
--		public function removeElement(c:IChild, dispatchEvent:Boolean = true):void
--		{
--			contentView.removeElement(c, dispatchEvent);
--		}
--		
--		/**
--		 * @private
--		 */
--		public function get numElements():int
--		{
--			return contentView.numElements;
--		}
--		
--		/**
--		 * @private
--		 */
--		public function getElementAt(index:int):IChild
--		{
--			return contentView.getElementAt(index);
--		}
--		
++
  		/**
  		 * Strand setter.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -200,127 -200,127 +142,37 @@@
  		override public function set strand(value:IStrand):void
  		{
  			_strand = value;
--			super.strand = value;
--			
++
              createViewport();
--			
--			(host as IContentViewHost).strandChildren.addElement(viewport.contentView, false);
--			
--			displayBackgroundAndBorder(host as UIBase);
--			
--			// listen for initComplete to signal that the strand is set with its size
--			// and beads.
-             host.addEventListener("beadsAdded", beadsAddedHandler);
 -			host.addEventListener("initComplete", initCompleteHandler);
--		}
--		
--		/**
--		 * Handles the initComplete event by completing the setup and kicking off the
--		 * presentation of the Container.
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
- 		protected function beadsAddedHandler(event:Event):void
 -		protected function initCompleteHandler(event:Event):void
--		{
--            var ilc:ILayoutChild = host as ILayoutChild;
--			// Complete the setup if the height is sized to content or has been explicitly set
--            // and the width is sized to content or has been explicitly set
--			if ((ilc.isHeightSizedToContent() || !isNaN(ilc.explicitHeight)) &&
--                (ilc.isWidthSizedToContent() || !isNaN(ilc.explicitWidth))) {
--				completeSetup();
--				
--				var num:Number = contentView.numElements;
--				if (num > 0) performLayout(event);
--			}
--			else {
--				// otherwise, wait until the unknown sizes have been set and then finish
--				host.addEventListener("sizeChanged", deferredSizeHandler);
--                host.addEventListener("widthChanged", deferredSizeHandler);
--                host.addEventListener("heightChanged", deferredSizeHandler);
--			}
--		}
--		
--		/**
--		 * Handles the case where the size of the host is not immediately known, usually do
--		 * to one of its dimensions being indicated as a percent size.
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		private function deferredSizeHandler(event:Event):void
--		{
--            host.removeEventListener("sizeChanged", deferredSizeHandler);
--            host.removeEventListener("widthChanged", deferredSizeHandler);
--            host.removeEventListener("heightChanged", deferredSizeHandler);
--			completeSetup();
--			
--			var num:Number = contentView.numElements;
--			if (num > 0) 
--            {
--                performLayout(event);
--            }
++
++			var chost:IContainer = host as IContainer;
++			chost.strandChildren.addElement(viewport.contentView);
++
++			super.strand = value;
  		}
--		
++
  		/**
  		 * Called when the host is ready to complete its setup (usually after its size has been
  		 * determined).
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		protected function completeSetup():void
++		override protected function completeSetup():void
  		{
++			super.completeSetup();
++
  			// when the first layout is complete, set up listeners for changes
  			// to the childrens' sizes.
  			host.addEventListener("layoutComplete", childrenChangedHandler);
--			
--			host.addEventListener("childrenAdded", performLayout);
--			host.addEventListener("layoutNeeded", performLayout);
--			host.addEventListener("widthChanged", resizeHandler);
--			host.addEventListener("heightChanged", resizeHandler);
--			host.addEventListener("sizeChanged", resizeHandler);
--			host.addEventListener("viewCreated", viewCreatedHandler);
--		}
--		
--		/**
--		 * Handles the viewCreated event by performing the first layout if
--		 * there are children already present (ie, from MXML).
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		protected function viewCreatedHandler(event:Event):void
--		{			
--			if ((host as UIBase).numElements > 0) {
--				performLayout(null);
--			}
  		}
--		
--        /**
--         * Calculate the space taken up by non-content children like a TItleBar in a Panel.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        protected function getChromeMetrics():Rectangle
--        {
--            return new Rectangle(0, 0, 0, 0);
--        }
--        
++
  		/**
  		 * Creates the Viewport (or ScrollableViewport) through which the content
  		 * area is presented.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -340,7 -340,7 +192,7 @@@
                      }
                  }
  			}
--			
++
  			if (viewport == null) {
  				_viewport = _strand.getBeadByType(IViewport) as IViewport;
  				if (viewport == null) {
@@@ -351,72 -351,72 +203,48 @@@
  						_strand.addBead(viewport);
  					}
  				}
--			}			
++			}
  		}
--		
++
  		/**
--		 *  Positions the viewport, then sets any known sizes of the Viewport prior
--         *  to laying out its content.
--		 *  
++		 * Calculate the space taken up by non-content children like a TitleBar in a Panel.
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		protected function layoutViewBeforeContentLayout():void
++		protected function getChromeMetrics():Rectangle
  		{
--            var host:ILayoutChild = this.host as ILayoutChild;
--            var vm:IViewportModel = viewportModel;
--            vm.borderMetrics = CSSContainerUtils.getBorderMetrics(host);
--            vm.chromeMetrics = getChromeMetrics();
--            viewport.setPosition(vm.borderMetrics.left + vm.chromeMetrics.left,
--                                 vm.borderMetrics.top + vm.chromeMetrics.top)
--            viewport.layoutViewportBeforeContentLayout(
--                !host.isWidthSizedToContent() ? 
--			        host.width - vm.borderMetrics.left - vm.borderMetrics.right -
--                        vm.chromeMetrics.left - vm.chromeMetrics.right : NaN,
--                !host.isHeightSizedToContent() ? 
--                    host.height - vm.borderMetrics.top - vm.borderMetrics.bottom -
--                        vm.chromeMetrics.top - vm.chromeMetrics.bottom : NaN);
--			
++			var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++			return paddingMetrics;
  		}
  		
  		/**
--		 * Executes the layout associated with this container. Once the layout has been
--		 * run, it may affect the size of the host or may cause the host to present scroll
--		 * bars view its viewport.
--		 *  
++		 *  Positions the viewport, then sets any known sizes of the Viewport prior
++         *  to laying out its content.
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		protected function performLayout(event:Event):void
++		override protected function layoutViewBeforeContentLayout():void
  		{
--			layoutRunning = true;
--			
--			layoutViewBeforeContentLayout();
--			
--			var host:UIBase = _strand as UIBase;
--			
--			var layout:IBeadLayout = _strand.getBeadByType(IBeadLayout) as IBeadLayout;
--			if (layout == null) {
--				var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout");
--				if (c) {
--					layout = new c() as IBeadLayout;
--					_strand.addBead(layout);
--				}
--			}
--			
--			if (layout) {
--				layout.layout();
--			}
--			
--			layoutViewAfterContentLayout();
--			
--			layoutRunning = false;
++            var host:ILayoutChild = this.host as ILayoutChild;
++            var vm:IViewportModel = viewportModel;
++			var hostWidth:Number = host.width;
++			var hostHeight:Number = host.height;
++
++            vm.borderMetrics = CSSContainerUtils.getBorderMetrics(host);
++
++            viewport.setPosition(vm.borderMetrics.left, vm.borderMetrics.top);
++
++			viewport.layoutViewportBeforeContentLayout(
++				host.isWidthSizedToContent() ? NaN : hostWidth - vm.borderMetrics.left - vm.borderMetrics.right,
++				host.isHeightSizedToContent() ? NaN : hostHeight - vm.borderMetrics.top - vm.borderMetrics.bottom);
  		}
--		
++
  		/**
  		 * @private
  		 */
@@@ -425,61 -425,61 +253,46 @@@
  		/**
  		 * Adjusts the size of the host, or adds scrollbars to the viewport, after
  		 * the layout has been run.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		protected function layoutViewAfterContentLayout():void
++		override protected function layoutViewAfterContentLayout():void
  		{
--			var host:UIBase = _strand as UIBase;
--            var vm:IViewportModel = viewportModel;
--            
++			if (adjusting) return;
++
  			adjusting = true;
--			
--            var viewportSize:Size = viewport.layoutViewportAfterContentLayout();
--            
--			if (host.isWidthSizedToContent() && host.isHeightSizedToContent()) {					
--				host.setWidthAndHeight(viewportSize.width + vm.borderMetrics.left + vm.borderMetrics.right +
--                                           vm.chromeMetrics.left + vm.chromeMetrics.right, 
--					                   viewportSize.height + vm.borderMetrics.top + vm.borderMetrics.bottom +
--                                           vm.chromeMetrics.top + vm.chromeMetrics.bottom,
--                                       false);
--			}
--			else if (!host.isWidthSizedToContent() && host.isHeightSizedToContent())
--			{
--				host.setHeight(viewportSize.height + vm.borderMetrics.top + vm.borderMetrics.bottom +
--                    vm.chromeMetrics.top + vm.chromeMetrics.bottom, false);
--			}
--			else if (host.isWidthSizedToContent() && !host.isHeightSizedToContent())
--			{
--				host.setWidth(viewportSize.width + vm.borderMetrics.left + vm.borderMetrics.right +
--                    vm.chromeMetrics.left + vm.chromeMetrics.right, false);
--			}			
++
++			super.layoutViewAfterContentLayout();
++
++			var contentSize:Size = calculateContentSize();
++			viewport.layoutViewportAfterContentLayout(contentSize);
++
  			adjusting = false;
  		}
--		
++
  		/**
  		 * Handles dynamic changes to the host's size by running the layout once
  		 * the viewport has been adjusted.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		protected function resizeHandler(event:Event):void
++		override protected function resizeHandler(event:Event):void
  		{
  			if (!adjusting) {
  				performLayout(event);
  			}
  		}
--		
++
  		/**
  		 * Whenever children are added, listeners are added to detect changes
--		 * in their size. 
--		 *  
++		 * in their size.
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -489,7 -489,7 +302,7 @@@
  		{
  			var host:UIBase = _strand as UIBase;
  			host.removeEventListener(event.type, childrenChangedHandler);
--			
++
  			var n:Number = contentView.numElements;
  			for (var i:int=0; i < n; i++) {
  				var child:IUIBase = contentView.getElementAt(i) as IUIBase;
@@@ -498,55 -498,55 +311,79 @@@
  				child.addEventListener("sizeChanged", childResizeHandler);
  			}
  		}
--				
++	}
++
++	COMPILE::JS
++	public class ContainerView extends GroupView //??implements IParent
++	{
++		private var _viewport:IViewport;
++
  		/**
--		 * This event handles changes to the size of children of the container by running
--		 * the layout again and adjusting the size of the container or viewport as necessary. 
--		 *  
++		 * The viewport used to present the content and may display
++		 * scroll bars (depending on the actual type of viewport).
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		protected function childResizeHandler(event:Event):void
++		protected function get viewport():IViewport
  		{
--			// during this process we don't want the layout to trigger
--			// an endless event chain should any children get resized
--			// by the layout.
--			if (layoutRunning) return;			
--			performLayout(event);
++			return _viewport;
  		}
  		
--		protected function displayBackgroundAndBorder(host:UIBase) : void
++		/**
++		 * The sub-element used as the parent of the container's elements. This does not
++		 * include the chrome elements.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		override public function get contentView():ILayoutView
  		{
--			var backgroundColor:Object = ValuesManager.valuesImpl.getValue(host, "background-color");
--			var backgroundImage:Object = ValuesManager.valuesImpl.getValue(host, "background-image");
--			if (backgroundColor != null || backgroundImage != null)
--			{
--				if (host.getBeadByType(IBackgroundBead) == null)
--					var c:Class = ValuesManager.valuesImpl.getValue(host, "iBackgroundBead");
--				if (c) {
--					host.addBead( new c() as IBead );
++			if (viewport != null) {
++				return viewport.contentView as ILayoutView;
++			} else {
++				return host as ILayoutView;
++			}
++		}
++
++		/**
++		 * Strand setter.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		override public function set strand(value:IStrand):void
++		{
++			_strand = value;
++			super.strand = value;
++
++			var c:Class;
++
++			if (viewport == null) {
++				_viewport = _strand.getBeadByType(IViewport) as IViewport;
++				if (viewport == null) {
++					c = ValuesManager.valuesImpl.getValue(host, "iViewport");
++					if (c)
++					{
++						_viewport = new c() as IViewport;
++						_strand.addBead(viewport);
++					}
  				}
  			}
  			
--			var borderStyle:String;
--			var borderStyles:Object = ValuesManager.valuesImpl.getValue(host, "border");
--			if (borderStyles is Array)
--			{
--				borderStyle = borderStyles[1];
--			}
--			if (borderStyle == null)
--			{
--				borderStyle = ValuesManager.valuesImpl.getValue(host, "border-style") as String;
--			}
--			if (borderStyle != null && borderStyle != "none")
--			{
--				if (host.getBeadByType(IBorderBead) == null) {
--					c = ValuesManager.valuesImpl.getValue(host, "iBorderBead");
--					if (c) {
--						host.addBead( new c() as IBead );
--					}
++			if (viewport != null) {
++				var chost:IContainer = host as IContainer;
++				// add the viewport's contentView to this host ONLY if
++				// the contentView is not the host itself, which is likely
++				// most situations.
++				if (chost != viewport.contentView) {
++					chost.addElement(viewport.contentView);
  				}
  			}
  		}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataContainerView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataContainerView.as
index b32df59,0000000..36ed489
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataContainerView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataContainerView.as
@@@ -1,170 -1,0 +1,230 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads
 +{	
 +	import org.apache.flex.core.BeadViewBase;
 +	import org.apache.flex.core.ContainerBase;
 +	import org.apache.flex.core.IBead;
 +	import org.apache.flex.core.IBeadLayout;
 +	import org.apache.flex.core.IBeadModel;
 +	import org.apache.flex.core.IBeadView;
++	import org.apache.flex.core.IList;
 +	import org.apache.flex.core.ISelectableItemRenderer;
 +	import org.apache.flex.core.IItemRenderer;
 +	import org.apache.flex.core.IItemRendererParent;
 +	import org.apache.flex.core.IParent;
 +    import org.apache.flex.core.IParentIUIBase;
 +	import org.apache.flex.core.IDataProviderModel;
++	import org.apache.flex.core.ISelectionModel;
 +	import org.apache.flex.core.IStrand;
 +    import org.apache.flex.core.IUIBase;
 +	import org.apache.flex.core.Strand;
 +	import org.apache.flex.core.UIBase;
 +	import org.apache.flex.core.ValuesManager;
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.events.IEventDispatcher;
 +	import org.apache.flex.html.beads.models.ScrollBarModel;
 +	import org.apache.flex.html.beads.models.SingleLineBorderModel;
 +	import org.apache.flex.html.supportClasses.Border;
 +	import org.apache.flex.html.supportClasses.DataGroup;
 +	import org.apache.flex.html.supportClasses.ScrollBar;
 +
 +	/**
- 	 *  The List class creates the visual elements of the org.apache.flex.html.List 
- 	 *  component. A List consists of the area to display the data (in the dataGroup), any 
- 	 *  scrollbars, and so forth.
++	 *  The DataContainerView provides the visual elements for the DataContainer.
 +	 *  
 +	 *  @viewbead
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
- 	 *  @productversion FlexJS 0.0
++	 *  @productversion FlexJS 0.8
 +	 */
++	COMPILE::JS
 +	public class DataContainerView extends ContainerView implements IListView
 +	{
 +		public function DataContainerView()
 +		{
++			super();
 +		}
- 						
- 		protected var listModel:IDataProviderModel;
- 		
- 		private var _border:Border;
 +		
 +		/**
- 		 *  The border surrounding the org.apache.flex.html.List.
- 		 *
++		 *  @copy org.apache.flex.core.IBead#strand
++		 *  
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.0
++		 *  @productversion FlexJS 0.8
 +		 */
-         public function get border():Border
-         {
-             return _border;
-         }
++		override public function set strand(value:IStrand):void
++		{
++			_strand = value;
++			super.strand = value;
++			
++			host.addEventListener("beadsAdded", beadsAddedHandler);
++		}
++		
++		protected var dataModel:IDataProviderModel;
 +		
 +		/**
- 		 *  The area holding the itemRenderers.
- 		 *
- 		 *  @langversion 3.0
- 		 *  @playerversion Flash 10.2
- 		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.0
++		 * @flexjsignorecoercion org.apache.flex.core.IItemRendererParent
 +		 */
 +		public function get dataGroup():IItemRendererParent
 +		{
- 			(contentView as UIBase).className = "ListDataGroup";
- 			return contentView as IItemRendererParent;
++			return super.contentView as IItemRendererParent;
 +		}
- 				
++		
++		protected function beadsAddedHandler(event:Event):void
++		{
++			dataModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
++			host.addEventListener("itemsCreated", itemsCreatedHandler);
++			dataModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
++		}
++		
 +		/**
 +		 * @private
 +		 */
- 		override public function get resizableView():IUIBase
++		override protected function handleInitComplete(event:Event):void
++		{
++			super.handleInitComplete(event);
++		}
++		
++		/**
++		 * @private
++		 */
++		protected function itemsCreatedHandler(event:Event):void
++		{
++			performLayout(event);
++		}
++		
++		/**
++		 * @private
++		 */
++		protected function dataProviderChangeHandler(event:Event):void
++		{
++			performLayout(event);
++		}
++	}
++	
++	COMPILE::SWF
++	public class DataContainerView extends ContainerView implements IListView
++	{
++		public function DataContainerView()
++		{
++			super();
++		}
++						
++		protected var dataModel:IDataProviderModel;
++		
++		/**
++		 * @private
++		 */
++		override public function get host():IUIBase
 +		{
 +			return _strand as IUIBase;
 +		}
-         
-         /**
-          * @private
-          */
-         override public function get host():IUIBase
-         {
-             return _strand as IUIBase;
-         }
-         		
++		
 +		/**
 +		 *  @copy org.apache.flex.core.IBead#strand
 +		 *  
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.0
++		 *  @productversion FlexJS 0.8
 +		 */
 +		override public function set strand(value:IStrand):void
 +		{
 +			_strand = value;
 +			super.strand = value;
++			
++			host.addEventListener("beadsAdded", beadsAddedHandler);
 +		}
 +		
 +		override protected function completeSetup():void
 +		{
 +			super.completeSetup();
 +			
 +			// list is not interested in UI children, it wants to know when new items
 +			// have been added or the dataProvider has changed.
- 			
 +			host.removeEventListener("childrenAdded", childrenChangedHandler);
 +			host.removeEventListener("childrenAdded", performLayout);
 +			host.addEventListener("itemsCreated", itemsCreatedHandler);
- 			
- 			listModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
- 			listModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
 +		}
 +		
- 		protected var lastSelectedIndex:int = -1;
++		protected function beadsAddedHandler(event:Event):void
++		{
++			dataModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
++			dataModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
++		}
++		
++		override protected function handleInitComplete(event:Event):void
++		{
++			super.handleInitComplete(event);
++		}
++		
++		/**
++		 *  The area holding the itemRenderers.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get dataGroup():IItemRendererParent
++		{
++			return super.contentView as IItemRendererParent;
++		}
++				
++		/**
++		 * @private
++		 */
++		override public function get resizableView():IUIBase
++		{
++			return _strand as IUIBase;
++		}
 +		
 +		/**
 +		 * @private
 +		 */
 +		protected function itemsCreatedHandler(event:Event):void
 +		{
 +			performLayout(event);
 +		}
 +		
 +		/**
 +		 * @private
 +		 */
 +		protected function dataProviderChangeHandler(event:Event):void
 +		{
 +			performLayout(event);
 +		}
 +		        
 +        /**
 +         *  respond to a change in size or request to re-layout everything
 +         *  
 +         *  @langversion 3.0
 +         *  @playerversion Flash 10.2
 +         *  @playerversion AIR 2.6
 +         *  @productversion FlexJS 0.0
 +         */
 +		override protected function resizeHandler(event:Event):void
 +		{
++			// might need to do something here, not sure yet.
 +			super.resizeHandler(event);
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridPercentageView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridPercentageView.as
index 0000000,0000000..510e18d
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridPercentageView.as
@@@ -1,0 -1,0 +1,293 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	import org.apache.flex.core.IBeadModel;
++	import org.apache.flex.core.IBeadView;
++	import org.apache.flex.core.IDataGridModel;
++	import org.apache.flex.core.IDataGridPresentationModel;
++	import org.apache.flex.core.ISelectionModel;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.IUIBase;
++	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.html.DataGrid;
++	import org.apache.flex.html.DataGridButtonBar;
++	import org.apache.flex.html.Container;
++	import org.apache.flex.html.beads.layouts.ButtonBarLayout;
++	import org.apache.flex.html.beads.models.ButtonBarModel;
++	import org.apache.flex.html.supportClasses.DataGridColumn;
++	import org.apache.flex.html.supportClasses.DataGridColumnList;
++	import org.apache.flex.html.supportClasses.Viewport;
++	
++	COMPILE::SWF {
++		import org.apache.flex.core.SimpleCSSStyles;
++	}
++
++	/**
++	 *  The DataGridPercentageView class is the visual bead for the org.apache.flex.html.DataGrid.
++	 *  This class constructs the items that make the DataGrid: Lists for each column and a
++	 *  org.apache.flex.html.ButtonBar for the column headers. This class interprets the
++	 *  columnWidth value of each column to be a percentage rather than a pixel value.
++	 *
++	 *  @viewbead
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class DataGridPercentageView extends GroupView implements IBeadView
++	{
++		/**
++		 *  constructor.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function DataGridPercentageView()
++		{
++			super();
++		}
++
++		private var _strand:IStrand;
++		private var _header:DataGridButtonBar;
++		private var _listArea:Container;
++		
++		private var _lists:Array;
++		
++		/**
++		 * An array of List objects the comprise the columns of the DataGrid.
++		 */
++		public function get columnLists():Array
++		{
++			return _lists;
++		}
++		
++		/**
++		 * The area used to hold the columns
++		 *
++		 */
++		public function get listArea():Container
++		{
++			return _listArea;
++		}
++		
++		/**
++		 * Returns the component used as the header for the DataGrid.
++		 */
++		public function get header():IUIBase
++		{
++			return _header;
++		}
++
++		/**
++		 *  @copy org.apache.flex.core.IBead#strand
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		override public function set strand(value:IStrand):void
++		{
++			super.strand = value;
++			_strand = value;
++
++			var host:DataGrid = value as DataGrid;
++
++			_header = new DataGridButtonBar();
++			_header.height = 30;
++			_header.percentWidth = 100;
++
++			_listArea = new Container();
++			_listArea.percentWidth = 100;
++			_listArea.className = "DataGridListArea";
++			
++			COMPILE::SWF {
++				_header.style = new SimpleCSSStyles();
++				_header.style.flexGrow = 0;
++				
++				_listArea.style = new SimpleCSSStyles();
++				_listArea.style.flexGrow = 1;
++			}
++			COMPILE::JS {
++				_header.element.style["flex-grow"] = "0";
++				_header.element.style["min-height"] = "30px";
++				_listArea.element.style["flex-grow"] = "1";
++			}
++			
++			IEventDispatcher(_strand).addEventListener("initComplete", finishSetup);
++		}
++
++		/**
++		 * @private
++		 */
++		private function finishSetup(event:Event):void
++		{
++			var host:DataGrid = _strand as DataGrid;
++			
++			if (_lists == null || _lists.length == 0) {
++				createLists();
++			}
++
++			// see if there is a presentation model already in place. if not, add one.
++			var presentationModel:IDataGridPresentationModel = host.presentationModel;
++			var sharedModel:IDataGridModel = host.model as IDataGridModel;
++			IEventDispatcher(sharedModel).addEventListener("dataProviderChanged",handleDataProviderChanged);
++			IEventDispatcher(sharedModel).addEventListener("selectedIndexChanged", handleSelectedIndexChanged);
++
++			var columnLabels:Array = new Array();
++			var buttonWidths:Array = new Array();
++
++			for(var i:int=0; i < sharedModel.columns.length; i++) {
++				var dgc:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
++				columnLabels.push(dgc.label);
++				var colWidth:Number = dgc.columnWidth;
++				buttonWidths.push(colWidth);
++				
++				var list:DataGridColumnList = _lists[i] as DataGridColumnList;
++				if (!isNaN(colWidth)) {
++					list.percentWidth = Number(colWidth);
++				} else {
++					COMPILE::SWF {
++						list.style = new SimpleCSSStyles();
++						list.style.flexGrow = 1;
++					}
++						COMPILE::JS {
++							list.element.style["flex-grow"] = "1";
++						}
++				}
++			}
++
++			var bblayout:ButtonBarLayout = new ButtonBarLayout();
++			_header.buttonWidths = buttonWidths
++			_header.widthType = ButtonBarModel.PERCENT_WIDTHS;
++			_header.dataProvider = columnLabels;
++			_header.addBead(bblayout);
++			_header.addBead(new Viewport());
++			host.addElement(_header);
++
++			host.addElement(_listArea);
++
++			handleDataProviderChanged(event);
++		}
++
++		/**
++		 * @private
++		 */
++		private function handleSizeChanges(event:Event):void
++		{	
++			_header.dispatchEvent(new Event("layoutChanged"));
++			_listArea.dispatchEvent(new Event("layoutChanged"));
++		}
++
++		/**
++		 * @private
++		 */
++		private function handleDataProviderChanged(event:Event):void
++		{
++			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
++
++			for (var i:int=0; i < _lists.length; i++)
++			{
++				var list:DataGridColumnList = _lists[i] as DataGridColumnList;
++				var listModel:ISelectionModel = list.getBeadByType(IBeadModel) as ISelectionModel;
++				listModel.dataProvider = sharedModel.dataProvider;
++			}
++
++			host.dispatchEvent(new Event("layoutNeeded"));
++		}
++		
++		/**
++		 * @private
++		 */
++		private function handleSelectedIndexChanged(event:Event):void
++		{
++			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
++			var newIndex:int = sharedModel.selectedIndex;
++			
++			for (var i:int=0; i < _lists.length; i++)
++			{
++				var list:DataGridColumnList = _lists[i] as DataGridColumnList;
++				list.selectedIndex = newIndex;
++			}
++		}
++
++		/**
++		 * @private
++		 */
++		private function handleColumnListChange(event:Event):void
++		{
++			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
++			var list:DataGridColumnList = event.target as DataGridColumnList;
++			sharedModel.selectedIndex = list.selectedIndex;
++
++			for(var i:int=0; i < _lists.length; i++) {
++				if (list != _lists[i]) {
++					var otherList:DataGridColumnList = _lists[i] as DataGridColumnList;
++					otherList.selectedIndex = list.selectedIndex;
++				}
++			}
++
++			host.dispatchEvent(new Event('change'));
++		}
++
++		/**
++		 * @private
++		 */
++		private function createLists():void
++		{
++			var host:DataGrid = _strand as DataGrid;
++			
++			var sharedModel:IDataGridModel = host.model as IDataGridModel;
++			var presentationModel:IDataGridPresentationModel = host.presentationModel;
++
++			_lists = new Array();
++
++			for (var i:int=0; i < sharedModel.columns.length; i++) {
++				var dataGridColumn:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
++
++				var list:DataGridColumnList = new DataGridColumnList();
++				list.id = "dataGridColumn"+String(i);
++				list.addBead(sharedModel);
++				list.itemRenderer = dataGridColumn.itemRenderer;
++				list.labelField = dataGridColumn.dataField;
++				list.addEventListener('change',handleColumnListChange);
++				list.addBead(presentationModel);
++				
++				if (i == 0) {
++					list.className = "first";
++				} else if (i == sharedModel.columns.length-1) {
++					list.className = "last";
++				} else {
++					list.className = "middle";
++				}
++
++				_listArea.addElement(list);
++				_lists.push(list);
++			}
++
++			host.dispatchEvent(new Event("layoutNeeded"));
++		}
++	}
++}
++

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridView.as
index fe4b14f,8393057..68e5d95
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataGridView.as
@@@ -18,263 -18,249 +18,283 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads
  {
--	import org.apache.flex.core.IBead;
  	import org.apache.flex.core.IBeadModel;
--	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.IBeadView;
  	import org.apache.flex.core.IDataGridModel;
-     import org.apache.flex.core.IDataGridPresentationModel;
--	import org.apache.flex.core.ISelectableItemRenderer;
++	import org.apache.flex.core.IDataGridPresentationModel;
  	import org.apache.flex.core.ISelectionModel;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
--	import org.apache.flex.core.UIBase;
  	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
-     import org.apache.flex.html.DataGrid;
++	import org.apache.flex.html.DataGrid;
  	import org.apache.flex.html.DataGridButtonBar;
  	import org.apache.flex.html.Container;
  	import org.apache.flex.html.beads.layouts.ButtonBarLayout;
--	import org.apache.flex.html.beads.layouts.VerticalLayout;
--	import org.apache.flex.html.beads.layouts.HorizontalLayout;
--	import org.apache.flex.html.beads.layouts.IDataGridLayout;
--	import org.apache.flex.html.beads.models.ArraySelectionModel;
 -	import org.apache.flex.html.beads.models.DataGridPresentationModel;
++	import org.apache.flex.html.beads.models.ButtonBarModel;
  	import org.apache.flex.html.supportClasses.DataGridColumn;
  	import org.apache.flex.html.supportClasses.DataGridColumnList;
--	import org.apache.flex.html.supportClasses.ScrollingViewport;
  	import org.apache.flex.html.supportClasses.Viewport;
--
--	/**
--	 *  The DataGridView class is the visual bead for the org.apache.flex.html.DataGrid.
--	 *  This class constructs the items that make the DataGrid: Lists for each column and a
--	 *  org.apache.flex.html.ButtonBar for the column headers.
--	 *
--	 *  @langversion 3.0
--	 *  @playerversion Flash 10.2
--	 *  @playerversion AIR 2.6
--	 *  @productversion FlexJS 0.0
--	 */
--	public class DataGridView implements IBeadView
--	{
--		/**
--		 *  constructor.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function DataGridView()
--		{
--		}
--
--		private var _strand:IStrand;
--		private var _header:DataGridButtonBar;
--		private var _listArea:Container;
--		
--		private var _lists:Array;
--		
--		/**
--		 * An array of List objects the comprise the columns of the DataGrid.
--		 */
--		public function get columnLists():Array
--		{
--			return _lists;
--		}
--		
--		/**
--		 * The area used to hold the columns
--		 *
--		 */
--		public function get listArea():Container
--		{
--			return _listArea;
--		}
--
--		/**
--		 * @private
--		 */
--		public function get host():IUIBase
--		{
--			return _strand as IUIBase;
--		}
++	
++	COMPILE::SWF {
++		import org.apache.flex.core.SimpleCSSStyles;
++	}
  		
  		/**
--		 * Returns the component used as the header for the DataGrid.
--		 */
--		public function get header():IUIBase
--		{
--			return _header;
--		}
--
--		/**
--		 *  @copy org.apache.flex.core.IBead#strand
++		 *  The DataGridView class is the visual bead for the org.apache.flex.html.DataGrid.
++		 *  This class constructs the items that make the DataGrid: Lists for each column and a
++		 *  org.apache.flex.html.ButtonBar for the column headers.
  		 *
++		 *  @viewbead
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		public function set strand(value:IStrand):void
++		public class DataGridView extends GroupView implements IBeadView
  		{
--			_strand = value;
--
--			var host:UIBase = value as UIBase;
--
--			_header = new DataGridButtonBar();
--			_header.id = "dataGridHeader";
--
--			var scrollPort:ScrollingViewport = new ScrollingViewport();
--
--			_listArea = new Container();
--			_listArea.id = "dataGridListArea";
--			_listArea.className = "DataGridListArea";
--			_listArea.addBead(scrollPort);
++			/**
++			 *  constructor.
++			 *
++			 *  @langversion 3.0
++			 *  @playerversion Flash 10.2
++			 *  @playerversion AIR 2.6
++			 *  @productversion FlexJS 0.0
++			 */
++			public function DataGridView()
++			{
++				super();
++			}
  			
--			if (_strand.getBeadByType(IBeadLayout) == null) {
--				var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout");
--				if (c)
--				{
--					var layout:IBeadLayout = new c() as IBeadLayout;
--					_strand.addBead(layout);
++			private var _strand:IStrand;
++			private var _header:DataGridButtonBar;
++			private var _listArea:Container;
++			
++			private var _lists:Array;
++			
++			/**
++			 * An array of List objects the comprise the columns of the DataGrid.
++			 */
++			public function get columnLists():Array
++			{
++				return _lists;
++			}
++			
++			/**
++			 * The area used to hold the columns
++			 *
++			 */
++			public function get listArea():Container
++			{
++				return _listArea;
++			}
++			
++			/**
++			 * Returns the component used as the header for the DataGrid.
++			 */
++			public function get header():IUIBase
++			{
++				return _header;
++			}
++			
++			/**
++			 *  @copy org.apache.flex.core.IBead#strand
++			 *
++			 *  @langversion 3.0
++			 *  @playerversion Flash 10.2
++			 *  @playerversion AIR 2.6
++			 *  @productversion FlexJS 0.0
++			 */
++			override public function set strand(value:IStrand):void
++			{
++				super.strand = value;
++				_strand = value;
++				
++				var host:DataGrid = value as DataGrid;
++				
++				_header = new DataGridButtonBar();
++				_header.height = 30;
++				_header.percentWidth = 100;
++				
++				_listArea = new Container();
++				_listArea.percentWidth = 100;
++				_listArea.className = "DataGridListArea";
++				
++				COMPILE::SWF {
++					_header.style = new SimpleCSSStyles();
++					_header.style.flexGrow = 0;
++					
++					_listArea.style = new SimpleCSSStyles();
++					_listArea.style.flexGrow = 1;
  				}
++				COMPILE::JS {
++					_header.element.style["flex-grow"] = "0";
++					_header.element.style["min-height"] = "30px";
++					_listArea.element.style["flex-grow"] = "1";
++				}
++				
++				IEventDispatcher(_strand).addEventListener("initComplete", finishSetup);
  			}
--
--			finishSetup(null);
--		}
--
--		/**
--		 * @private
--		 */
--		private function finishSetup(event:Event):void
--		{
-             var host:DataGrid = _strand as DataGrid;
-             
- 			// see if there is a presentation model already in place. if not, add one.
-             var presentationModel:IDataGridPresentationModel = host.presentationModel;
-             var sharedModel:IDataGridModel = host.model as IDataGridModel;
- 			IEventDispatcher(sharedModel).addEventListener("dataProviderChanged",handleDataProviderChanged);
-             IEventDispatcher(sharedModel).addEventListener("selectedIndexChanged", handleSelectedIndexChanged);
- 
- 			var columnLabels:Array = new Array();
 -			var host:UIBase = _strand as UIBase;
--
- 			for(var i:int=0; i < sharedModel.columns.length; i++) {
- 				var dgc:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
- 				columnLabels.push(dgc.label);
 -			// see if there is a presentation model already in place. if not, add one.
 -			var presentationModel:DataGridPresentationModel = _strand.getBeadByType(DataGridPresentationModel) as DataGridPresentationModel;
 -			if (presentationModel == null) {
 -				presentationModel = new DataGridPresentationModel();
 -				_strand.addBead(presentationModel);
++			
++			/**
++			 * @private
++			 */
++			private function finishSetup(event:Event):void
++			{
++				var host:DataGrid = _strand as DataGrid;
++				
++				if (_lists == null || _lists.length == 0) {
++					createLists();
++				}
++				
++				// see if there is a presentation model already in place. if not, add one.
++				var presentationModel:IDataGridPresentationModel = host.presentationModel;
++				var sharedModel:IDataGridModel = host.model as IDataGridModel;
++				IEventDispatcher(sharedModel).addEventListener("dataProviderChanged",handleDataProviderChanged);
++				IEventDispatcher(sharedModel).addEventListener("selectedIndexChanged", handleSelectedIndexChanged);
++				
++				var columnLabels:Array = new Array();
++				var buttonWidths:Array = new Array();
++				
++				var marginBorderOffset:int = 0;
++				COMPILE::SWF {
++					marginBorderOffset = 1;
++				}
++					
++				for(var i:int=0; i < sharedModel.columns.length; i++) {
++					var dgc:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
++					columnLabels.push(dgc.label);
++					var colWidth:Number = dgc.columnWidth - marginBorderOffset;
++					buttonWidths.push(colWidth);
++					
++					var list:DataGridColumnList = _lists[i] as DataGridColumnList;
++					if (!isNaN(colWidth)) {
++						list.width = Number(colWidth - marginBorderOffset);
++					} else {
++						COMPILE::SWF {
++							list.style = new SimpleCSSStyles();
++							list.style.flexGrow = 1;
++						}
++							COMPILE::JS {
++								list.element.style["flex-grow"] = "1";
++							}
++					}
++				}
++					
++				var bblayout:ButtonBarLayout = new ButtonBarLayout();
++				_header.buttonWidths = buttonWidths
++				_header.widthType = ButtonBarModel.PIXEL_WIDTHS;
++				_header.dataProvider = columnLabels;
++				_header.addBead(bblayout);
++				_header.addBead(new Viewport());
++				host.addElement(_header);
++				
++				host.addElement(_listArea);
++				
++				handleDataProviderChanged(event);
++				
++				host.addEventListener("widthChanged", handleSizeChanges);
++				host.addEventListener("heightChanged", handleSizeChanges);
  			}
- 
- 			var bblayout:ButtonBarLayout = new ButtonBarLayout();
- 			var buttonBarModel:ArraySelectionModel = new ArraySelectionModel();
- 			buttonBarModel.dataProvider = columnLabels;
- 
- 			_header.addBead(buttonBarModel);
- 			_header.addBead(bblayout);
- 			_header.addBead(new Viewport());
- 			host.addElement(_header);
- 
- 			host.addElement(_listArea);
- 
- 			handleDataProviderChanged(event);
- 		}
- 
- 		/**
- 		 * @private
- 		 */
- 		private function handleSizeChanges(event:Event):void
- 		{	
- 			var layoutBead:IDataGridLayout = _strand.getBeadByType(IBeadLayout) as IDataGridLayout;
- 			layoutBead.header = _header;
- 			layoutBead.columns = _lists;
- 			layoutBead.listArea = _listArea;
- 			layoutBead.layout();
- 		}
--
- 		/**
- 		 * @private
- 		 */
- 		private function handleDataProviderChanged(event:Event):void
- 		{
--			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 -			IEventDispatcher(sharedModel).addEventListener("dataProviderChanged",handleDataProviderChanged);
--
- 			if (_lists == null || _lists.length == 0) {
- 				createLists();
 -			var columnLabels:Array = new Array();
 -
 -			for(var i:int=0; i < sharedModel.columns.length; i++) {
 -				var dgc:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
 -				columnLabels.push(dgc.label);
++			
++			/**
++			 * @private
++			 */
++			private function handleSizeChanges(event:Event):void
++			{	
++				_header.dispatchEvent(new Event("layoutChanged"));
++				_listArea.dispatchEvent(new Event("layoutChanged"));
  			}
--
- 			for (var i:int=0; i < _lists.length; i++)
 -			var bblayout:ButtonBarLayout = new ButtonBarLayout();
 -			var buttonBarModel:ArraySelectionModel = new ArraySelectionModel();
 -			buttonBarModel.dataProvider = columnLabels;
 -
 -			_header.addBead(buttonBarModel);
 -			_header.addBead(bblayout);
 -			_header.addBead(new Viewport());
 -			host.addElement(_header);
 -
 -			host.addElement(_listArea);
 -
 -			handleDataProviderChanged(event);
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function handleSizeChanges(event:Event):void
 -		{	
 -			var layoutBead:IDataGridLayout = _strand.getBeadByType(IBeadLayout) as IDataGridLayout;
 -			layoutBead.header = _header;
 -			layoutBead.columns = _lists;
 -			layoutBead.listArea = _listArea;
 -			layoutBead.layout();
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function handleDataProviderChanged(event:Event):void
 -		{
 -			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 -
 -			if (_lists == null || _lists.length == 0) {
 -				createLists();
++			
++			/**
++			 * @private
++			 */
++			private function handleDataProviderChanged(event:Event):void
 +			{
- 				var list:DataGridColumnList = _lists[i] as DataGridColumnList;
- 				var listModel:ISelectionModel = list.getBeadByType(IBeadModel) as ISelectionModel;
- 				listModel.dataProvider = sharedModel.dataProvider;
++				var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
++				
++				for (var i:int=0; i < _lists.length; i++)
++				{
++					var list:DataGridColumnList = _lists[i] as DataGridColumnList;
++					var listModel:ISelectionModel = list.getBeadByType(IBeadModel) as ISelectionModel;
++					listModel.dataProvider = sharedModel.dataProvider;
++				}
++				
++				host.dispatchEvent(new Event("layoutNeeded"));
  			}
- 
- 			host.dispatchEvent(new Event("layoutNeeded"));
- 		}
- 
-         /**
-          * @private
-          */
-         private function handleSelectedIndexChanged(event:Event):void
-         {
-             var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
-             var newIndex:int = sharedModel.selectedIndex;
-             
-             for (var i:int=0; i < _lists.length; i++)
-             {
-                 var list:DataGridColumnList = _lists[i] as DataGridColumnList;
-                 list.selectedIndex = newIndex;
-             }
-         }
- 
- 		/**
- 		 * @private
- 		 */
- 		private function handleColumnListChange(event:Event):void
- 		{
- 			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
- 			var list:DataGridColumnList = event.target as DataGridColumnList;
- 			sharedModel.selectedIndex = list.selectedIndex;
--
- 			for(var i:int=0; i < _lists.length; i++) {
- 				if (list != _lists[i]) {
- 					var otherList:DataGridColumnList = _lists[i] as DataGridColumnList;
- 					otherList.selectedIndex = list.selectedIndex;
 -			for (var i:int=0; i < _lists.length; i++)
++			
++			/**
++			 * @private
++			 */
++			private function handleSelectedIndexChanged(event:Event):void
+ 			{
 -				var list:DataGridColumnList = _lists[i] as DataGridColumnList;
 -				var listModel:ISelectionModel = list.getBeadByType(IBeadModel) as ISelectionModel;
 -				listModel.dataProvider = sharedModel.dataProvider;
++				var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
++				var newIndex:int = sharedModel.selectedIndex;
++				
++				for (var i:int=0; i < _lists.length; i++)
++				{
++					var list:DataGridColumnList = _lists[i] as DataGridColumnList;
++					list.selectedIndex = newIndex;
 +				}
  			}
--
- 			host.dispatchEvent(new Event('change'));
 -			host.dispatchEvent(new Event("layoutNeeded"));
--		}
--
--		/**
--		 * @private
--		 */
- 		private function createLists():void
 -		private function handleColumnListChange(event:Event):void
--		{
-             var host:DataGrid = _strand as DataGrid;
-             
-             var sharedModel:IDataGridModel = host.model as IDataGridModel;
-             var presentationModel:IDataGridPresentationModel = host.presentationModel;
- 			var listWidth:Number = host.width / sharedModel.columns.length;
- 
- 			_lists = new Array();
- 
- 			for (var i:int=0; i < sharedModel.columns.length; i++) {
- 				var dataGridColumn:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
- 
- 				var list:DataGridColumnList = new DataGridColumnList();
- 				list.id = "dataGridColumn"+String(i);
- 				list.addBead(sharedModel);
- 				list.itemRenderer = dataGridColumn.itemRenderer;
- 				list.labelField = dataGridColumn.dataField;
- 				list.addEventListener('change',handleColumnListChange);
- 				list.addBead(presentationModel);
 -			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 -			var list:DataGridColumnList = event.target as DataGridColumnList;
 -			sharedModel.selectedIndex = list.selectedIndex;
--
- 				_listArea.addElement(list);
- 				_lists.push(list);
 -			for(var i:int=0; i < _lists.length; i++) {
 -				if (list != _lists[i]) {
 -					var otherList:DataGridColumnList = _lists[i] as DataGridColumnList;
 -					otherList.selectedIndex = list.selectedIndex;
++			
++			/**
++			 * @private
++			 */
++			private function handleColumnListChange(event:Event):void
++			{
++				var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
++				var list:DataGridColumnList = event.target as DataGridColumnList;
++				sharedModel.selectedIndex = list.selectedIndex;
++				
++				for(var i:int=0; i < _lists.length; i++) {
++					if (list != _lists[i]) {
++						var otherList:DataGridColumnList = _lists[i] as DataGridColumnList;
++						otherList.selectedIndex = list.selectedIndex;
++					}
+ 				}
++				
++				host.dispatchEvent(new Event('change'));
+ 			}
 -
 -			host.dispatchEvent(new Event('change'));
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function createLists():void
 -		{
 -			var sharedModel:IDataGridModel = _strand.getBeadByType(IBeadModel) as IDataGridModel;
 -			var presentationModel:DataGridPresentationModel = _strand.getBeadByType(DataGridPresentationModel) as DataGridPresentationModel;
 -			var listWidth:Number = host.width / sharedModel.columns.length;
 -
 -			_lists = new Array();
 -
 -			for (var i:int=0; i < sharedModel.columns.length; i++) {
 -				var dataGridColumn:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
 -
 -				var list:DataGridColumnList = new DataGridColumnList();
 -				list.id = "dataGridColumn"+String(i);
 -				list.addBead(sharedModel);
 -				list.itemRenderer = dataGridColumn.itemRenderer;
 -				list.labelField = dataGridColumn.dataField;
 -				list.addEventListener('change',handleColumnListChange);
 -				list.addBead(presentationModel);
 -
 -				_listArea.addElement(list);
 -				_lists.push(list);
++			
++			/**
++			 * @private
++			 */
++			private function createLists():void
++			{
++				var host:DataGrid = _strand as DataGrid;
++				
++				var sharedModel:IDataGridModel = host.model as IDataGridModel;
++				var presentationModel:IDataGridPresentationModel = host.presentationModel;
++				
++				_lists = new Array();
++				
++				for (var i:int=0; i < sharedModel.columns.length; i++) {
++					var dataGridColumn:DataGridColumn = sharedModel.columns[i] as DataGridColumn;
++					
++					var list:DataGridColumnList = new DataGridColumnList();
++					list.id = "dataGridColumn"+String(i);
++					list.addBead(sharedModel);
++					list.itemRenderer = dataGridColumn.itemRenderer;
++					list.labelField = dataGridColumn.dataField;
++					list.addEventListener('change',handleColumnListChange);
++					list.addBead(presentationModel);
++					
++					if (i == 0) {
++						list.className = "first";
++					} else if (i == sharedModel.columns.length-1) {
++						list.className = "last";
++					} else {
++						list.className = "middle";
++					}
++					
++					_listArea.addElement(list);
++					_lists.push(list);
++				}
++				
++				host.dispatchEvent(new Event("layoutNeeded"));
  			}
--
--			host.dispatchEvent(new Event("layoutNeeded"));
  		}
--	}
  }
  

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayData.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayData.as
index 30024ec,fdfd9b3..bcd837b
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayData.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayData.as
@@@ -36,6 -36,6 +36,11 @@@ package org.apache.flex.html.bead
  	import org.apache.flex.events.ItemRendererEvent;
  	import org.apache.flex.html.List;
  	
++	import org.apache.flex.core.IList;
++	import org.apache.flex.core.IChild;
++	import org.apache.flex.core.ILayoutHost;
++	import org.apache.flex.core.IParentIUIBase;
++	
  	[Event(name="itemRendererCreated",type="org.apache.flex.events.ItemRendererEvent")]
  	
      /**
@@@ -64,11 -64,11 +69,11 @@@
  		{
  			super(target);
  		}
--		
-         protected var dataProviderModel:IDataProviderModel;
 -		private var selectionModel:ISelectionModel;
--		
-         protected var labelField:String;
 -		private var labelField:String;
--		
++
++		protected var dataProviderModel:IDataProviderModel;
++
++		protected var labelField:String;
++
  		private var _strand:IStrand;
  		
          /**
@@@ -82,21 -82,21 +87,22 @@@
  		public function set strand(value:IStrand):void
  		{
  			_strand = value;
--			IEventDispatcher(value).addEventListener("beadsAdded",finishSetup);
  			IEventDispatcher(value).addEventListener("initComplete",finishSetup);
  		}
  		
++		/**
++		 * @private
++		 */
  		private function finishSetup(event:Event):void
--		{
-             dataProviderModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
 -			selectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
--			var listView:IListView = _strand.getBeadByType(IListView) as IListView;
--			dataGroup = listView.dataGroup;
-             dataProviderModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
 -			selectionModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
++		{			
++			dataProviderModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
++			dataProviderModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
++			labelField = dataProviderModel.labelField;
  			
-             labelField = dataProviderModel.labelField;
 -			labelField = (listView.host as List).labelField;
--			
--			if (!itemRendererFactory)
--			{
++			// if the host component inherits from DataContainerBase, the itemRendererClassFactory will 
++			// already have been loaded by DataContainerBase.addedToParent function.
++			_itemRendererFactory = _strand.getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
++			if (itemRendererFactory == null) {
  				_itemRendererFactory = new (ValuesManager.valuesImpl.getValue(_strand, "iItemRendererClassFactory")) as IItemRendererClassFactory;
  				_strand.addBead(_itemRendererFactory);
  			}
@@@ -136,25 -136,24 +142,25 @@@
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
           *  @productversion FlexJS 0.0
--         */
--		protected var dataGroup:IItemRendererParent;
--		
-         protected function dataProviderChangeHandler(event:Event):void
 -		private function dataProviderChangeHandler(event:Event):void
++         */		
++		protected function dataProviderChangeHandler(event:Event):void
  		{
-             var dp:Array = dataProviderModel.dataProvider as Array;
 -			var dp:Array = selectionModel.dataProvider as Array;
++			var dp:Array = dataProviderModel.dataProvider as Array;
  			if (!dp)
  				return;
  			
--			dataGroup.removeAllElements();
++			var list:IList = _strand as IList;
++			var dataGroup:IItemRendererParent = list.dataGroup;
++			
++			dataGroup.removeAllItemRenderers();
  			
--			var listView:IListView = _strand.getBeadByType(IListView) as IListView;
  			var presentationModel:IListPresentationModel = _strand.getBeadByType(IListPresentationModel) as IListPresentationModel;
  			
  			var n:int = dp.length; 
  			for (var i:int = 0; i < n; i++)
  			{				
  				var ir:ISelectableItemRenderer = itemRendererFactory.createItemRenderer(dataGroup) as ISelectableItemRenderer;
-                 dataGroup.addElement(ir);
++				dataGroup.addItemRenderer(ir);
  				ir.index = i;
  				ir.labelField = labelField;
  				if (presentationModel) {
@@@ -162,8 -161,8 +168,8 @@@
  					style.marginBottom = presentationModel.separatorThickness;
  					UIBase(ir).style = style;
  					UIBase(ir).height = presentationModel.rowHeight;
-                     UIBase(ir).percentWidth = 100;
-                 }
++					UIBase(ir).percentWidth = 100;
+ 				}
 -				dataGroup.addElement(ir);
  				ir.data = dp[i];
  				
  				var newEvent:ItemRendererEvent = new ItemRendererEvent(ItemRendererEvent.CREATED);

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayList.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayList.as
index 3d8f1fc,42b159c..c35f07f
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayList.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForArrayList.as
@@@ -35,7 -35,7 +35,8 @@@ package org.apache.flex.html.bead
  	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.events.EventDispatcher;
  	import org.apache.flex.events.ItemRendererEvent;
--	import org.apache.flex.html.List;
++	//import org.apache.flex.html.List;
++	import org.apache.flex.core.IList;
  	
  	[Event(name="itemRendererCreated",type="org.apache.flex.events.ItemRendererEvent")]
  	
@@@ -66,7 -66,7 +67,7 @@@
  			super(target);
  		}
  		
-         protected var dataProviderModel:IDataProviderModel;
 -		protected var selectionModel:ISelectionModel;
++		protected var dataProviderModel:IDataProviderModel;
  		
  		protected var labelField:String;
  		
@@@ -83,26 -83,26 +84,21 @@@
  		public function set strand(value:IStrand):void
  		{
  			_strand = value;
--			IEventDispatcher(_strand).addEventListener("beadsAdded", finishSetup);
  			IEventDispatcher(_strand).addEventListener("initComplete", finishSetup);
  		}
  		
  		private function finishSetup(event:Event):void
--		{
-             dataProviderModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
 -			selectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
--			var listView:IListView = _strand.getBeadByType(IListView) as IListView;
--			dataGroup = listView.dataGroup;
-             dataProviderModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
 -			selectionModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
--			
 -			labelField = (listView.host as List).labelField;
++		{			
++			dataProviderModel = _strand.getBeadByType(IDataProviderModel) as IDataProviderModel;
++			dataProviderModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
 +			labelField = dataProviderModel.labelField;
  			
--			if (!itemRendererFactory)
--			{
--				_itemRendererFactory = _strand.getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
--				if (_itemRendererFactory == null) {
--					_itemRendererFactory = new (ValuesManager.valuesImpl.getValue(_strand, "iItemRendererClassFactory")) as IItemRendererClassFactory;
--					_strand.addBead(_itemRendererFactory);
--				}
++			// if the host component inherits from DataContainerBase, the itemRendererClassFactory will 
++			// already have been loaded by DataContainerBase.addedToParent function.
++			_itemRendererFactory = _strand.getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
++			if (itemRendererFactory == null) {
++				_itemRendererFactory = new (ValuesManager.valuesImpl.getValue(_strand, "iItemRendererClassFactory")) as IItemRendererClassFactory;
++				_strand.addBead(_itemRendererFactory);
  			}
  			
  			dataProviderChangeHandler(null);
@@@ -132,17 -132,17 +128,6 @@@
  			_itemRendererFactory = value;
  		}
  		
--        /**
--         *  The org.apache.flex.core.IItemRendererParent that will
--         *  parent the item renderers.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		protected var dataGroup:IItemRendererParent;
--		
  		/**
  		 * @private
  		 */
@@@ -162,25 -162,25 +147,25 @@@
  			if (!dp)
  				return;
  			
--			dataGroup.removeAllElements();
++			var list:IList = _strand as IList;
++			var dataGroup:IItemRendererParent = list.dataGroup;
++			
++			dataGroup.removeAllItemRenderers();
  			
--			var listView:IListView = _strand.getBeadByType(IListView) as IListView;
  			var presentationModel:IListPresentationModel = _strand.getBeadByType(IListPresentationModel) as IListPresentationModel;
  			
  			var n:int = dp.length; 
  			for (var i:int = 0; i < n; i++)
  			{				
  				var ir:ISelectableItemRenderer = itemRendererFactory.createItemRenderer(dataGroup) as ISelectableItemRenderer;
++				dataGroup.addItemRenderer(ir);
  				if (presentationModel) {
--					UIBase(ir).height = presentationModel.rowHeight;
--					
--					// ensure that the IR spans the width of its column
  					var style:SimpleCSSStyles = new SimpleCSSStyles();
--					style.right = 0;
--					style.left = 0;
++					style.marginBottom = presentationModel.separatorThickness;
  					UIBase(ir).style = style;
++					UIBase(ir).height = presentationModel.rowHeight;
++					UIBase(ir).percentWidth = 100;
  				}
--				dataGroup.addElement(ir);
  				setData(ir, dp.getItemAt(i), i);
  				
  				var newEvent:ItemRendererEvent = new ItemRendererEvent(ItemRendererEvent.CREATED);

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForColumnData.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForColumnData.as
index 4cd66ef,d399cfb..554a9c9
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForColumnData.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataItemRendererFactoryForColumnData.as
@@@ -24,6 -24,6 +24,7 @@@ package org.apache.flex.html.bead
  	import org.apache.flex.core.IDataProviderItemRendererMapper;
  	import org.apache.flex.core.IItemRendererClassFactory;
  	import org.apache.flex.core.IItemRendererParent;
++	import org.apache.flex.core.IList;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.events.Event;
@@@ -69,13 -69,13 +70,21 @@@
  		public function set strand(value:IStrand):void
  		{
  			_strand = value;
--			selectionModel = value.getBeadByType(IDataGridModel) as IDataGridModel;
--			var listView:IListView = value.getBeadByType(IListView) as IListView;
--			dataGroup = listView.dataGroup;
++			IEventDispatcher(value).addEventListener("initComplete",finishSetup);
++		}
++		
++		/**
++		 * @private
++		 */
++		private function finishSetup(event:Event):void
++		{			
++			selectionModel = _strand.getBeadByType(IDataGridModel) as IDataGridModel;
  			selectionModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
  			
--			if (!itemRendererFactory)
--			{
++			// if the host component inherits from DataContainerBase, the itemRendererClassFactory will 
++			// already have been loaded by DataContainerBase.addedToParent function.
++			_itemRendererFactory = _strand.getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
++			if (itemRendererFactory == null) {
  				_itemRendererFactory = new (ValuesManager.valuesImpl.getValue(_strand, "iItemRendererClassFactory")) as IItemRendererClassFactory;
  				_strand.addBead(_itemRendererFactory);
  			}
@@@ -110,7 -110,7 +119,7 @@@
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 */
--		protected var dataGroup:IItemRendererParent;
++//		protected var dataGroup:IItemRendererParent;
  		
  		/**
  		 * @private
@@@ -121,8 -121,8 +130,11 @@@
  			if (!dp)
  				return;
  			
--			dataGroup.removeAllElements();
++			var list:IList = _strand as IList;
++			var dataGroup:IItemRendererParent = list.dataGroup;
  			
++			dataGroup.removeAllItemRenderers();
++						
  			var view:DataGridColumnView = _strand.getBeadByType(IBeadView) as DataGridColumnView;
  			if (view == null) return;
  						
@@@ -130,9 -130,9 +142,9 @@@
  			for (var i:int = 0; i < n; i++)
  			{
  				var tf:DataItemRenderer = itemRendererFactory.createItemRenderer(dataGroup) as DataItemRenderer;
-                 dataGroup.addElement(tf);
++				dataGroup.addItemRenderer(tf);
  				tf.index = i;
  				tf.labelField = view.column.dataField;
 -				dataGroup.addElement(tf);
  				tf.data = dp[i];
  			}
  			

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderChangeNotifier.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderChangeNotifier.as
index a24810b,a24810b..e8c28bd
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderChangeNotifier.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderChangeNotifier.as
@@@ -18,17 -18,17 +18,13 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads
  {
--	import org.apache.flex.core.IBead;
--	import org.apache.flex.core.IBeadModel;
--	import org.apache.flex.core.IDocument;
  	import org.apache.flex.core.ISelectionModel;
--	import org.apache.flex.core.IStrand;
--	import org.apache.flex.core.UIBase;
  	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.collections.ArrayList;
--	
--	/**
++    import org.apache.flex.html.supportClasses.DataProviderNotifierBase;
++
++    /**
  	 *  The DataProviderChangeNotifier notifies listeners when a selection model's
  	 *  ArrayList dataProvider has changed.
  	 *  
@@@ -37,7 -37,7 +33,7 @@@
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class DataProviderChangeNotifier implements IBead, IDocument
++	public class DataProviderChangeNotifier extends DataProviderNotifierBase
  	{
  		/**
  		 *  constructor.
@@@ -51,144 -51,144 +47,31 @@@
  		{
  		}
  		
--		protected var _dataProvider:ArrayList;
--		
--		private var _strand:IStrand;
--		
--		/**
--		 *  @copy org.apache.flex.core.IBead#strand
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function set strand(value:IStrand):void
++		override protected function destinationChangedHandler(event:Event):void
  		{
--			_strand = value;
--			
--			if (_strand[destinationPropertyName] == null) {
--				var model:IBeadModel = UIBase(_strand).model as IBeadModel;
--				IEventDispatcher(model).addEventListener(changeEventName, destinationChangedHandler);
--			}
--			else {
--				destinationChangedHandler(null);
--			}
--		}
--		
--		private function destinationChangedHandler(event:Event):void
--		{
--			if (_dataProvider == null) {
++			if (dataProvider == null)
++			{
  				var object:Object = document[sourceID];
--				_dataProvider = object[propertyName] as ArrayList;
++				dataProvider = object[propertyName] as ArrayList;
  			}
--			else {
--				_dataProvider.removeEventListener("itemAdded", handleItemAdded);
--				_dataProvider.removeEventListener("itemRemoved", handleItemRemoved);
--				_dataProvider.removeEventListener("itemUpdated", handleItemUpdated);
++			else
++			{
++                dataProvider.removeEventListener("itemAdded", handleDataProviderChanges);
++                dataProvider.removeEventListener("itemRemoved", handleDataProviderChanges);
++                dataProvider.removeEventListener("itemUpdated", handleDataProviderChanges);
++                dataProvider.removeEventListener("collectionChanged", handleDataProviderChanges);
  			}
--			
--			_dataProvider.addEventListener("itemAdded", handleItemAdded);
--			_dataProvider.addEventListener("itemRemoved", handleItemRemoved);
--			_dataProvider.addEventListener("itemUpdated", handleItemUpdated);
--		}
--		
--		protected var document:Object;
--		
--		/**
--		 * @private
--		 */
--		public function setDocument(document:Object, id:String = null):void
--		{
--			this.document = document;
--		}
--		
--		private var _destinationPropertyName:String;
--		
--		public function get destinationPropertyName():String
--		{
--			return _destinationPropertyName;
--		}
--		public function set destinationPropertyName(value:String):void
--		{
--			_destinationPropertyName = value;
--		}
--		
--		private var _changeEventName:String;
--		
--		public function get changeEventName():String
--		{
--			return _changeEventName;
--		}
--		public function set changeEventName(value:String):void
--		{
--			_changeEventName = value;
--		}
--		
--		private var _sourceID:String;
--		
--		/**
--		 *  The ID of the object holding the ArrayList, usually a model.
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get sourceID():String
--		{
--			return _sourceID;
--		}
--		public function set sourceID(value:String):void
--		{
--			_sourceID = value;
--		}
--		
--		private var _propertyName:String;
--		
--		/**
--		 *  The property in the sourceID that is the ArrayList.
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get propertyName():String
--		{
--			return _propertyName;
--		}
--		
--		public function set propertyName(value:String):void
--		{
--			_propertyName = value;
--		}
--		
--		/**
--		 * @private
--		 */
--		private function handleItemAdded(event:Event):void
--		{
--			var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
--			selectionModel.dispatchEvent(new Event("dataProviderChanged"));
++
++            dataProvider.addEventListener("itemAdded", handleDataProviderChanges);
++            dataProvider.addEventListener("itemRemoved", handleDataProviderChanges);
++            dataProvider.addEventListener("itemUpdated", handleDataProviderChanges);
++            dataProvider.addEventListener("collectionChanged", handleDataProviderChanges);
  		}
--		
--		/**
--		 * @private
--		 */
--		private function handleItemRemoved(event:Event):void
--		{
--			var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
--			selectionModel.dispatchEvent(new Event("dataProviderChanged"));
--		}
--		
--		/**
--		 * @private
--		 */
--		private function handleItemUpdated(event:Event):void
++
++		private function handleDataProviderChanges(event:Event):void
  		{
--			var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
--			selectionModel.dispatchEvent(new Event("dataProviderChanged"));
++            var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
++            selectionModel.dispatchEvent(new Event("dataProviderChanged"));
  		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderCollectionChangeNotifier.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderCollectionChangeNotifier.as
index 0000000,0000000..2d58795
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderCollectionChangeNotifier.as
@@@ -1,0 -1,0 +1,71 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	import org.apache.flex.core.ISelectionModel;
++	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.collections.ArrayList;
++    import org.apache.flex.html.supportClasses.DataProviderNotifierBase;
++
++    /**
++	 *  The DataProviderCollectionChangeNotifier notifies listeners when a selection model's
++	 *  ArrayList dataProvider disptached collectionChanged event.
++	 *  
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class DataProviderCollectionChangeNotifier extends DataProviderNotifierBase
++	{
++		/**
++		 *  constructor.
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function DataProviderCollectionChangeNotifier()
++		{
++		}
++		
++		override protected function destinationChangedHandler(event:Event):void
++		{
++			if (dataProvider == null)
++			{
++				var object:Object = document[sourceID];
++				dataProvider = object[propertyName] as ArrayList;
++			}
++			else
++			{
++                dataProvider.removeEventListener("collectionChanged", handleCollectionChanged);
++			}
++
++            dataProvider.addEventListener("collectionChanged", handleCollectionChanged);
++		}
++
++		private function handleCollectionChanged(event:Event):void
++		{
++            var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
++            selectionModel.dispatchEvent(new Event("dataProviderChanged"));
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderItemsChangeNotifier.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderItemsChangeNotifier.as
index 0000000,0000000..eee1990
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DataProviderItemsChangeNotifier.as
@@@ -1,0 -1,0 +1,95 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	import org.apache.flex.core.ISelectionModel;
++	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.collections.ArrayList;
++	import org.apache.flex.events.CollectionEvent;
++    import org.apache.flex.html.supportClasses.DataProviderNotifierBase;
++
++    /**
++	 *  The DataProviderItemsChangeNotifier notifies listeners when to selection model's
++	 *  ArrayList dataProvider item has been added, removed or updated.
++	 *  
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class DataProviderItemsChangeNotifier extends DataProviderNotifierBase
++	{
++		/**
++		 *  constructor.
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function DataProviderItemsChangeNotifier()
++		{
++		}
++
++		private function destinationChangedHandler(event:Event):void
++		{
++			if (dataProvider == null) {
++				var object:Object = document[sourceID];
++				dataProvider = object[propertyName] as ArrayList;
++			}
++			else {
++				dataProvider.removeEventListener(CollectionEvent.ITEM_ADDED, handleItemAdded);
++				dataProvider.removeEventListener(CollectionEvent.ITEM_REMOVED, handleItemRemoved);
++				dataProvider.removeEventListener(CollectionEvent.ITEM_UPDATED, handleItemUpdated);
++			}
++			
++			dataProvider.addEventListener(CollectionEvent.ITEM_ADDED, handleItemAdded);
++			dataProvider.addEventListener(CollectionEvent.ITEM_REMOVED, handleItemRemoved);
++            dataProvider.addEventListener(CollectionEvent.ITEM_UPDATED, handleItemUpdated);
++		}
++
++		/**
++		 * @private
++		 */
++		private function handleItemAdded(event:CollectionEvent):void
++		{
++			var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
++			selectionModel.dispatchEvent(event.cloneEvent() as CollectionEvent);
++		}
++		
++		/**
++		 * @private
++		 */
++		private function handleItemRemoved(event:CollectionEvent):void
++		{
++			var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
++			selectionModel.dispatchEvent(event.cloneEvent() as CollectionEvent);
++		}
++
++        /**
++         * @private
++         */
++        private function handleItemUpdated(event:CollectionEvent):void
++        {
++            var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
++            selectionModel.dispatchEvent(event.cloneEvent() as CollectionEvent);
++        }
++	}
++}


[38/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - handle centering

Posted by ah...@apache.org.
handle centering


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/712a17e7
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/712a17e7
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/712a17e7

Branch: refs/heads/develop
Commit: 712a17e799fa8d53a352ece9022bbf9602f199b9
Parents: 7de620a
Author: Alex Harui <ah...@apache.org>
Authored: Wed Apr 26 22:49:27 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 14:15:18 2017 -0700

----------------------------------------------------------------------
 .../org/apache/flex/html/beads/layouts/BasicLayout.as   | 12 ++++++++++++
 .../apache/flex/html/beads/layouts/HorizontalLayout.as  |  9 +++++----
 .../apache/flex/html/beads/layouts/VerticalLayout.as    |  7 ++-----
 3 files changed, 19 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/712a17e7/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
index 72c42d8..a7a54ac 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
@@ -126,9 +126,13 @@ package org.apache.flex.html.beads.layouts
 							else
 							{
 								if (ilc)
+								{
 									ilc.setX( w - positions.right - margins.left - child.width - margins.right);
+								}
 								else
+								{
 									child.x = w - positions.right - margins.left - child.width - margins.right;
+								}
 							}
 						}
 					}
@@ -162,6 +166,14 @@ package org.apache.flex.html.beads.layouts
 					{
 						ilc.setHeight((hh - margins.top - margins.bottom) * ilc.percentHeight/100, false);
 					}
+					
+					if (margins.auto)
+					{
+						if (ilc)
+							ilc.setX( (w - child.width) / 2);
+						else
+							child.x = (w - child.width) / 2;
+					}
                 }
 
                 return true;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/712a17e7/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
index 148866b..89aab6e 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
@@ -147,10 +147,11 @@ package org.apache.flex.html.beads.layouts
 							childHeight = hostHeight * ilc.percentHeight/100.0;
 							ilc.setHeight(childHeight);
 						}
-						// the following code middle-aligns the child, but since HTML does not
-						// do this normally, this code is commented. (Use HorizontalFlexLayout for
-						// vertically centered elements in a horizontal row).
-//						childYpos = hostHeight/2 - (childHeight + mt + mb)/2;
+						var valign:Object = ValuesManager.valuesImpl.getValue(child, "vertical-align");
+						if (valign == "middle")
+						{
+							childYpos = hostHeight/2 - (childHeight + margins.top + margins.bottom)/2;
+						}
 					}
 
 					if (ilc) {

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/712a17e7/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
index a8b9774..6357e9f 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
@@ -126,12 +126,9 @@ package org.apache.flex.html.beads.layouts
 							childWidth = hostWidth * ilc.percentWidth/100.0;
 							ilc.setWidth(childWidth);
 						}
-						// the following code center-aligns the child, but since HTML does not
-						// do this normally, this code is commented. (Use VerticalFlexLayout for
-						// horizontally centered elements in a vertical column).
-						//					childXpos = hostWidth/2 - (childWidth + ml + mr)/2;
+						if (margins.auto)
+							childXpos = (hostWidth - childWidth) / 2;
 					}
-
 					if (ilc) {
 						ilc.setX(childXpos);
 						ilc.setY(ypos);


[08/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DateChooserView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DateChooserView.as
index 057661d,54b2550..ca1a0ee
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DateChooserView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DateChooserView.as
@@@ -23,27 -23,24 +23,31 @@@ package org.apache.flex.html.bead
  	import org.apache.flex.core.IBeadModel;
  	import org.apache.flex.core.IBeadView;
  	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.SimpleCSSStyles;
  	import org.apache.flex.core.UIBase;
  	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.html.Container;
-     import org.apache.flex.html.List;
++	import org.apache.flex.html.Group;
++	import org.apache.flex.html.List;
  	import org.apache.flex.html.TextButton;
-     import org.apache.flex.html.beads.layouts.HorizontalLayout;
++	import org.apache.flex.html.beads.GroupView;
++	import org.apache.flex.html.beads.layouts.HorizontalLayout;
  	import org.apache.flex.html.beads.layouts.TileLayout;
  	import org.apache.flex.html.beads.models.DateChooserModel;
 -	import org.apache.flex.html.supportClasses.DateChooserButton;
  	import org.apache.flex.html.supportClasses.DateHeaderButton;
-     import org.apache.flex.html.supportClasses.DateChooserHeader;
-     import org.apache.flex.html.supportClasses.DateChooserList;
-     
++	import org.apache.flex.html.supportClasses.DateChooserHeader;
++	import org.apache.flex.html.supportClasses.DateChooserList;
+ 
  	/**
  	 * The DateChooserView class is a view bead for the DateChooser. This class
  	 * creates the elements for the DateChooser: the buttons to move between
  	 * months, the labels for the days of the week, and the buttons for each day
  	 * of the month.
++	 *  @viewbead	 
  	 */
--	public class DateChooserView extends BeadViewBase implements IBeadView
++	public class DateChooserView extends GroupView implements IBeadView
  	{
  		/**
  		 *  constructor
@@@ -55,33 -52,45 +59,33 @@@
  		 */
  		public function DateChooserView()
  		{
++			super();
  		}
  		
 -		/**
 -		 *  @copy org.apache.flex.core.IBead#strand
 -		 *
 -		 *  @langversion 3.0
 -		 *  @playerversion Flash 10.2
 -		 *  @playerversion AIR 2.6
 -		 *  @productversion FlexJS 0.0
 -		 */
  		override public function set strand(value:IStrand):void
  		{
  			super.strand = value;
 -			_strand = value;
 -
 -			// make sure there is a model.
++			
  			model = _strand.getBeadByType(IBeadModel) as DateChooserModel;
  			if (model == null) {
  				model = new (ValuesManager.valuesImpl.getValue(_strand,"iBeadModel")) as DateChooserModel;
  			}
  			model.addEventListener("displayedMonthChanged",handleModelChange);
  			model.addEventListener("displayedYearChanged",handleModelChange);
--
--			var host:UIBase = value as UIBase;
--			host.addEventListener("widthChanged", handleSizeChange);
--			host.addEventListener("heightChanged", handleSizeChange);
--
++			
  			createChildren();
--			layoutContents();
++			updateDisplay();
  		}
--
-         private var model:DateChooserModel;
++		
++		private var model:DateChooserModel;
++		
  		private var _prevMonthButton:DateHeaderButton;
  		private var _nextMonthButton:DateHeaderButton;
 -		private var _dayButtons:Array;
  		private var monthLabel:DateHeaderButton;
-         private var dayNamesContainer:DateChooserHeader;
-         private var daysContainer:DateChooserList;
-         
 -		private var dayContainer:Container;
 -
 -		private var model:DateChooserModel;
 -
++		private var monthButtonsContainer:Group;
++		private var dayNamesContainer:DateChooserHeader;
++		private var daysContainer:DateChooserList;
++		
  		/**
  		 *  The button that causes the previous month to be displayed by the DateChooser.
  		 *
@@@ -94,7 -103,7 +98,7 @@@
  		{
  			return _prevMonthButton;
  		}
--
++		
  		/**
  		 *  The button that causes the next month to be displayed by the DateChooser.
  		 *
@@@ -107,103 -116,213 +111,136 @@@
  		{
  			return _nextMonthButton;
  		}
--
-         public function get dayList():List
-         {
-             return daysContainer;
-         }
-             
 -		/**
 -		 * The array of DateChooserButton instances that represent each day of the month.
 -		 */
 -		public function get dayButtons():Array
 -		{
 -			return _dayButtons;
 -		}
 -
--		private function handleSizeChange(event:Event):void
 -		{
 -			layoutContents();
 -		}
 -
 -		private function layoutContents():void
++		
++		public function get dayList():List
  		{
- 			layoutContents();
 -			var sw:Number = UIBase(_strand).width;
 -			var sh:Number = UIBase(_strand).height;
 -
 -			_prevMonthButton.x = 0;
 -			_prevMonthButton.y = 0;
 -
 -			_nextMonthButton.x = sw - _nextMonthButton.width;
 -			_nextMonthButton.y = 0;
 -
 -			monthLabel.x = (sw - monthLabel.width)/2;
 -			monthLabel.y = 0;
 -
 -			dayContainer.x = 0;
 -			dayContainer.y = monthLabel.y + monthLabel.height + 5;
 -			dayContainer.width = sw;
 -			dayContainer.height = sh - (monthLabel.height+5);
 -			
 -			COMPILE::SWF {
 -				displayBackgroundAndBorder(_strand as UIBase);
 -			}
 -
 -			IEventDispatcher(_strand).dispatchEvent( new Event("layoutNeeded") );
 -			IEventDispatcher(dayContainer).dispatchEvent( new Event("layoutNeeded") );
++			return daysContainer;
  		}
--
++		
++		private const controlHeight:int = 26;
++		private const commonButtonWidth:int = 40;
++		
  		/**
  		 * @private
  		 */
  		private function createChildren():void
  		{
++			// HEADER BUTTONS
++			
++			monthButtonsContainer = new Group();
++			monthButtonsContainer.height = controlHeight;
++			monthButtonsContainer.id = "dateChooserMonthButtons";
++			monthButtonsContainer.className = "DateChooserMonthButtons";
++			monthButtonsContainer.style = new SimpleCSSStyles();
++			monthButtonsContainer.style.flexGrow = 0;
++			COMPILE::JS {
++				monthButtonsContainer.element.style["flex-grow"] = "0";
++			}
++			
  			_prevMonthButton = new DateHeaderButton();
--			_prevMonthButton.width = 40;
--			_prevMonthButton.height = 20;
++			_prevMonthButton.width = commonButtonWidth;
  			_prevMonthButton.text = "<";
--			UIBase(_strand).addElement(_prevMonthButton);
--
--			_nextMonthButton = new DateHeaderButton();
--			_nextMonthButton.width = 40;
--			_nextMonthButton.height = 20;
--			_nextMonthButton.text = ">";
--			UIBase(_strand).addElement(_nextMonthButton);
--
++			if (_prevMonthButton.style == null) {
++				_prevMonthButton.style = new SimpleCSSStyles();
++			}
++			_prevMonthButton.style.flexGrow = 0;
++			COMPILE::JS {
++				_prevMonthButton.element.style["flex-grow"] = "0";
++			}
++			monthButtonsContainer.addElement(_prevMonthButton);
++			
  			monthLabel = new DateHeaderButton();
  			monthLabel.text = "Month Here";
--			monthLabel.width = 100;
--			monthLabel.height = 20;
--			UIBase(_strand).addElement(monthLabel);
--
-             dayNamesContainer = new DateChooserHeader();
-             UIBase(_strand).addElement(dayNamesContainer, false);
-             
-             daysContainer = new DateChooserList();
-             UIBase(_strand).addElement(daysContainer, false);
-             
 -			dayContainer = new Container();
 -			var tileLayout:TileLayout = new TileLayout();
 -			dayContainer.addBead(tileLayout);
 -            UIBase(_strand).addElement(dayContainer, false);
 -
 -			tileLayout.numColumns = 7;
 -
 -			// the calendar has 7 columns with 6 rows, the first row are the day names
 -			for(var i:int=0; i < 7; i++) {
 -				var dayName:DateChooserButton = new DateChooserButton();
 -				dayName.text = model.dayNames[i];
 -				dayName.dayOfMonth = 0;
 -				dayContainer.addElement(dayName, false);
++			if (monthLabel.style == null) {
++				monthLabel.style = new SimpleCSSStyles();
+ 			}
 -
 -			_dayButtons = new Array();
 -
 -			for(i=0; i < 42; i++) {
 -				var date:DateChooserButton = new DateChooserButton();
 -				date.text = String(i+1);
 -				dayContainer.addElement(date, false);
 -				dayButtons.push(date);
++			monthLabel.style.flexGrow = 1;
++			COMPILE::JS {
++				monthLabel.element.style["flex-grow"] = "1";
+ 			}
 -
 -			IEventDispatcher(dayContainer).dispatchEvent( new Event("itemsCreated") );
 -
 -			updateCalendar();
 -		}
 -
 -		/**
 -		 * @private
 -		 */
 -		private function updateCalendar():void
 -		{
 -			monthLabel.text = model.monthNames[model.displayedMonth] + " " +
 -				String(model.displayedYear);
 -
 -			var firstDay:Date = new Date(model.displayedYear,model.displayedMonth,1);
 -
 -			// blank out the labels for the first firstDay.day-1 entries.
 -			for(var i:int=0; i < firstDay.getDay(); i++) {
 -				var dateButton:DateChooserButton = dayButtons[i] as DateChooserButton;
 -				dateButton.dayOfMonth = -1;
 -				dateButton.text = "";
++			monthButtonsContainer.addElement(monthLabel);
++			
++			_nextMonthButton = new DateHeaderButton();
++			_nextMonthButton.width = commonButtonWidth;
++			_nextMonthButton.text = ">";
++			if (_nextMonthButton.style == null) {
++				_nextMonthButton.style = new SimpleCSSStyles();
+ 			}
 -
 -			// flag today
 -			var today:Date = new Date();
 -
 -			// renumber to the last day of the month
 -			var dayNumber:int = 1;
 -			var numDays:Number = numberOfDaysInMonth(model.displayedMonth, model.displayedYear);
 -
 -			for(; i < dayButtons.length && dayNumber <= numDays; i++) {
 -				dateButton = dayButtons[i] as DateChooserButton;
 -				dateButton.dayOfMonth = dayNumber;
 -				dateButton.text = String(dayNumber++);
 -
 -				if (model.displayedMonth == today.getMonth() &&
 -				    model.displayedYear == today.getFullYear() &&
 -				    (dayNumber-1) == today.getDate()) {
 -				    dateButton.id = "todayDateChooserButton";
 -				} else {
 -					dateButton.id = "";
 -				}
++			COMPILE::JS {
++				_nextMonthButton.element.style["flex-grow"] = "0";
+ 			}
 -
 -			// blank out the rest
 -			for(; i < dayButtons.length; i++) {
 -				dateButton = dayButtons[i] as DateChooserButton;
 -				dateButton.dayOfMonth = -1;
 -				dateButton.text = "";
++			_nextMonthButton.style.flexGrow = 0;
++			monthButtonsContainer.addElement(_nextMonthButton);
++			
++			UIBase(_strand).addElement(monthButtonsContainer, false);
++			
++			// DAY NAMES
++			
++			dayNamesContainer = new DateChooserHeader();
++			dayNamesContainer.id = "dateChooserDayNames";
++			dayNamesContainer.className = "DateChooserHeader";
++			dayNamesContainer.height = controlHeight;
++			dayNamesContainer.style = new SimpleCSSStyles();
++			dayNamesContainer.style.flexGrow = 0;
++			COMPILE::JS {
++				dayNamesContainer.element.style["flex-grow"] = "0";
++				dayNamesContainer.element.style["align-items"] = "center";
+ 			}
++			COMPILE::SWF {
++				dayNamesContainer.percentWidth = 100;
++			}
++			UIBase(_strand).addElement(dayNamesContainer, false);
++			
++			// DAYS
++			
++			daysContainer = new DateChooserList();
++			daysContainer.className = "DateChooserList";
++			daysContainer.id = "dateChooserList";
++			daysContainer.style = new SimpleCSSStyles();
++			daysContainer.style.flexGrow = 1;
++			COMPILE::JS {
++				daysContainer.element.style["flex-grow"] = "1";
++			}
++			COMPILE::SWF {
++				daysContainer.percentWidth = 100;
++			}
++			UIBase(_strand).addElement(daysContainer, false);
++			
++			
 +			IEventDispatcher(daysContainer).dispatchEvent( new Event("itemsCreated") );
- 
-             model.addEventListener("selectedDateChanged", selectionChangeHandler);
-         }
- 
-         private function layoutContents():void
-         {
-             var sw:Number = UIBase(_strand).width;
-             var sh:Number = UIBase(_strand).height;
-             
-             _prevMonthButton.x = 0;
-             _prevMonthButton.y = 0;
-             
-             _nextMonthButton.x = sw - _nextMonthButton.width;
-             _nextMonthButton.y = 0;
-             
-             monthLabel.x = _prevMonthButton.x + _prevMonthButton.width;
-             monthLabel.y = 0;
-             monthLabel.width = sw - _prevMonthButton.width - _nextMonthButton.width;
-             monthLabel.text = model.monthNames[model.displayedMonth] + " " +
-                 String(model.displayedYear);
- 
-             dayNamesContainer.x = 0;
-             dayNamesContainer.y = monthLabel.y + monthLabel.height;
-             dayNamesContainer.width = sw;
-             dayNamesContainer.height = monthLabel.height;
-             
-             dayNamesContainer.dataProvider = model.dayNames;
-             
-             daysContainer.x = 0;
-             daysContainer.y = dayNamesContainer.y + dayNamesContainer.height;
-             daysContainer.width = sw;
-             daysContainer.height = sh - monthLabel.height - dayNamesContainer.height;
-             daysContainer.dataProvider = model.days;
-                 
-             IEventDispatcher(_strand).dispatchEvent( new Event("layoutNeeded") );
-             IEventDispatcher(daysContainer).dispatchEvent( new Event("layoutNeeded") );
-         }
- 
-         
++			model.addEventListener("selectedDateChanged", selectionChangeHandler);
+ 		}
 -
++		
  		/**
  		 * @private
  		 */
-         private function selectionChangeHandler(event:Event):void
 -		private function numberOfDaysInMonth(month:Number, year:Number):Number
++		private function updateDisplay():void
  		{
-             layoutContents();
-             var index:Number = model.getIndexForSelectedDate();
-             daysContainer.selectedIndex = index;
 -			var n:int;
 -
 -			if (month == 1) // Feb
 -			{
 -				if (((year % 4 == 0) && (year % 100 != 0)) || (year % 400 == 0)) // leap year
 -					n = 29;
 -				else
 -					n = 28;
 -			}
 -
 -			else if (month == 3 || month == 5 || month == 8 || month == 10)
 -				n = 30;
 -
 -			else
 -				n = 31;
 -
 -			return n;
++			monthLabel.text = model.monthNames[model.displayedMonth] + " " +
++				String(model.displayedYear);
++			
++			dayNamesContainer.dataProvider = model.dayNames;
++			
++			daysContainer.dataProvider = model.days;
  		}
--
++		
  		/**
  		 * @private
  		 */
--		private function handleModelChange(event:Event):void
++		private function selectionChangeHandler(event:Event):void
  		{
-             layoutContents();
 -			updateCalendar();
++			updateDisplay();
++			
++			var index:Number = model.getIndexForSelectedDate();
++			daysContainer.selectedIndex = index;
  		}
  		
+ 		/**
+ 		 * @private
+ 		 */
 -		COMPILE::SWF
 -		protected function displayBackgroundAndBorder(host:UIBase) : void
++		private function handleModelChange(event:Event):void
+ 		{
 -			var backgroundColor:Object = ValuesManager.valuesImpl.getValue(host, "background-color");
 -			var backgroundImage:Object = ValuesManager.valuesImpl.getValue(host, "background-image");
 -			if (backgroundColor != null || backgroundImage != null)
 -			{
 -				if (host.getBeadByType(IBackgroundBead) == null)
 -					var c:Class = ValuesManager.valuesImpl.getValue(host, "iBackgroundBead");
 -				if (c) {
 -					host.addBead( new c() as IBead );
 -				}
 -			}
 -			
 -			var borderStyle:String;
 -			var borderStyles:Object = ValuesManager.valuesImpl.getValue(host, "border");
 -			if (borderStyles is Array)
 -			{
 -				borderStyle = borderStyles[1];
 -			}
 -			if (borderStyle == null)
 -			{
 -				borderStyle = ValuesManager.valuesImpl.getValue(host, "border-style") as String;
 -			}
 -			if (borderStyle != null && borderStyle != "none")
 -			{
 -				if (host.getBeadByType(IBorderBead) == null) {
 -					c = ValuesManager.valuesImpl.getValue(host, "iBorderBead");
 -					if (c) {
 -						host.addBead( new c() as IBead );
 -					}
 -				}
 -			}
++			updateDisplay();
+ 		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DateFieldView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DateFieldView.as
index f709a1f,f709a1f..33bdfbb
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DateFieldView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DateFieldView.as
@@@ -41,6 -41,6 +41,7 @@@ package org.apache.flex.html.bead
  	 * input and button controls. This class also handles the pop-up 
  	 * mechanics.
  	 *  
++	 *  @viewbead
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -109,8 -109,8 +110,11 @@@
  			_button = new TextButton();
  			_button.text = "M";
  			UIBase(_strand).addElement(_button);
--			_button.x = _textInput.width;
--			_button.y = _textInput.y;
++			
++			COMPILE::SWF {
++				_button.x = _textInput.width;
++				_button.y = _textInput.y;
++			}
  			
  			IEventDispatcher(_strand).addEventListener("beadsAdded",handleBeadsAdded);
  		}
@@@ -167,18 -167,18 +171,21 @@@
  					{
  						_popUp = new DateChooser();
  						_popUp.width = 210;
--						_popUp.height = 220;
++						_popUp.height = 230;
  					}
  					
  					var model:IDateChooserModel = _strand.getBeadByType(IDateChooserModel) as IDateChooserModel;
  					_popUp.selectedDate = model.selectedDate;
  					
  					var host:IPopUpHost = UIUtils.findPopUpHost(UIBase(_strand));
--					var point:Point = new Point(_button.x, _button.y+_button.height);
++					var point:Point = new Point(_textInput.width, _button.height);
  					var p2:Point = PointUtils.localToGlobal(point, _strand);
  					var p3:Point = PointUtils.globalToLocal(p2, host);
  					_popUp.x = p3.x;
  					_popUp.y = p3.y;
++					COMPILE::JS {
++						_popUp.element.style.position = "absolute";
++					}
  					
  					host.addElement(_popUp);
  				}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DispatchInputFinishedBead.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DispatchInputFinishedBead.as
index 0000000,0000000..40cc900
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DispatchInputFinishedBead.as
@@@ -1,0 -1,0 +1,140 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	
++	import org.apache.flex.core.IBead;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.IEventDispatcher;
++	
++	COMPILE::JS
++		{
++			import org.apache.flex.core.IRenderedObject;
++			import goog.events;
++		}
++		
++		COMPILE::SWF
++		{
++			import flash.events.FocusEvent;
++			import flash.events.KeyboardEvent;
++			import org.apache.flex.html.beads.ITextFieldView;
++		}
++		
++		/**
++		 *  The DispatchInputFinishedBead class dispatched INPUT_FINISHED on strand
++		 *  when enter is pressed, or when foucus is out.
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public class DispatchInputFinishedBead implements IBead
++		{
++			/**
++			 *  constructor.
++			 *  
++			 *  @langversion 3.0
++			 *  @playerversion Flash 10.2
++			 *  @playerversion AIR 2.6
++			 *  @productversion FlexJS 0.0
++			 */
++			public function DispatchInputFinishedBead()
++			{
++			}
++			
++			public static const INPUT_FINISHED:String = "inputFinished";
++			
++			
++			
++			private var _strand:IStrand;
++			
++			/**
++			 *  @copy org.apache.flex.core.IBead#strand
++			 *  
++			 *  @langversion 3.0
++			 *  @playerversion Flash 10.2
++			 *  @playerversion AIR 2.6
++			 *  @productversion FlexJS 0.0
++			 */
++			public function set strand(value:IStrand):void
++			{
++				_strand = value;
++				
++				COMPILE::SWF
++					{
++						var viewBead:ITextFieldView = _strand.getBeadByType(ITextFieldView) as ITextFieldView;
++						viewBead.textField.addEventListener(KeyboardEvent.KEY_DOWN, keyDownHandler);
++						viewBead.textField.addEventListener(FocusEvent.FOCUS_OUT, focusOutHandler);
++					}
++					COMPILE::JS
++					{
++						goog.events.listen((_strand as IRenderedObject).element, 'keydown', keydownHandler);
++						goog.events.listen((_strand as IRenderedObject).element, 'focusout', focusoutHandler);
++					}
++			}
++			
++			/**
++			 * @private
++			 */
++			COMPILE::SWF
++			protected function focusOutHandler(event:FocusEvent):void
++			{
++				(_strand as IEventDispatcher).dispatchEvent(new Event(INPUT_FINISHED));
++			}
++			
++			/**
++			 * @private
++			 */
++			COMPILE::SWF
++			private function keyDownHandler( event:KeyboardEvent ) : void
++			{
++				// this will otherwise bubble an event of flash.events.Event
++				event.stopImmediatePropagation();
++				if (event.keyCode == 13) //enter
++				{
++					(_strand as IEventDispatcher).dispatchEvent(new Event(INPUT_FINISHED));
++				}
++			}
++			
++			/**
++			 * @private
++			 */
++			COMPILE::JS
++			private function keydownHandler( event:Object ) : void
++			{
++				if (event.keyCode == 13) //enter
++				{
++					(_strand as IEventDispatcher).dispatchEvent(new Event(INPUT_FINISHED));
++				}
++			}
++
++			
++			/**
++			 * @private
++			 */
++			COMPILE::JS
++			private function focusoutHandler( event:Object ) : void
++			{
++				(_strand as IEventDispatcher).dispatchEvent(new Event(INPUT_FINISHED));
++			}
++			
++		}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DispatchKeyboardEventBead.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DispatchKeyboardEventBead.as
index 0000000,0000000..fe09148
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DispatchKeyboardEventBead.as
@@@ -1,0 -1,0 +1,148 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	
++	import org.apache.flex.core.IBead;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.events.KeyboardEvent;
++	import org.apache.flex.events.utils.KeyboardEventConverter;
++	
++	COMPILE::JS
++	{
++		import org.apache.flex.core.IRenderedObject;
++		import goog.events;
++	}
++	
++	COMPILE::SWF
++	{
++		import flash.events.KeyboardEvent;
++		import org.apache.flex.html.beads.ITextFieldView;
++	}
++	
++	/**
++	 *  The DispatchKeyboardEventBead class dispatched INPUT_FINISHED on strand
++	 *  when enter is pressed, or when foucus is out.
++	 *  
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class DispatchKeyboardEventBead implements IBead
++	{
++		/**
++		 *  constructor.
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function DispatchKeyboardEventBead()
++		{
++		}			
++		
++		private var _strand:IStrand;
++		
++		/**
++		 *  @copy org.apache.flex.core.IBead#strand
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function set strand(value:IStrand):void
++		{
++			_strand = value;
++			
++			COMPILE::SWF
++			{
++				if (!attachEventListeners())
++				{
++					(_strand as IEventDispatcher).addEventListener("viewChanged", viewChangedHandler);
++				}
++			}
++			COMPILE::JS
++			{
++				(_strand as Object).element.addEventListener('keydown', keyEventHandler);
++				(_strand as Object).element.addEventListener('keyup', keyEventHandler);
++			}
++		}
++		
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		private function viewChangedHandler(e:Event):void
++		{
++			attachEventListeners();
++		}
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		private function attachEventListeners():Boolean
++		{
++			var viewBead:ITextFieldView = _strand.getBeadByType(ITextFieldView) as ITextFieldView;
++			if (!viewBead) return false;
++			viewBead.textField.addEventListener(flash.events.KeyboardEvent.KEY_DOWN, keyEventHandler);
++			viewBead.textField.addEventListener(flash.events.KeyboardEvent.KEY_UP, keyEventHandler);
++			return true;
++		}
++		
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		protected function keyEventHandler(event:flash.events.KeyboardEvent):void
++		{
++			// this will otherwise bubble an event of flash.events.Event
++			event.stopImmediatePropagation();
++			var newEvent:org.apache.flex.events.KeyboardEvent = KeyboardEventConverter.convert(event);
++			(_strand as IEventDispatcher).dispatchEvent(newEvent);
++			if(newEvent.defaultPrevented)
++			{
++				event.preventDefault();
++			}
++		}
++		
++		/**
++		 * @private
++		 */
++		COMPILE::JS
++		protected function keyEventHandler(event:KeyboardEvent):void
++		{
++			event.stopImmediatePropagation();
++			var newEvent:org.apache.flex.events.KeyboardEvent = KeyboardEventConverter.convert(event);
++			(_strand as IEventDispatcher).dispatchEvent(newEvent);
++			if(newEvent.defaultPrevented)
++			{
++				event.preventDefault();
++			}
++		}
++		
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DropDownListView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DropDownListView.as
index d3d7ebd,d3d7ebd..2e10302
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DropDownListView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/DropDownListView.as
@@@ -18,7 -18,7 +18,6 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads
  {
--	import flash.display.DisplayObject;
  	import flash.display.DisplayObjectContainer;
  	import flash.display.Graphics;
  	import flash.display.Shape;
@@@ -29,14 -29,14 +28,16 @@@
  	import org.apache.flex.core.BeadViewBase;
  	import org.apache.flex.core.CSSTextField;
  	import org.apache.flex.core.IBeadView;
--    import org.apache.flex.core.IChild;
++	import org.apache.flex.core.IChild;
  	import org.apache.flex.core.IPopUpHost;
  	import org.apache.flex.core.ISelectionModel;
  	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.IUIBase;
  	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
--    import org.apache.flex.utils.SolidBorderUtil;
++	import org.apache.flex.utils.SolidBorderUtil;
++	import org.apache.flex.utils.UIUtils;
      
      /**
       *  The DropDownListView class is the default view for
@@@ -45,6 -45,6 +46,7 @@@
       *  down arrow button on the right, but really, the entire
       *  view is the button that will display or dismiss the dropdown.
       *  
++	 *  @viewbead
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
@@@ -112,7 -112,7 +114,7 @@@
           */
  		override public function set strand(value:IStrand):void
  		{
--			super.strand = value;;
++			super.strand = value;
              selectionModel = value.getBeadByType(ISelectionModel) as ISelectionModel;
              selectionModel.addEventListener("selectedIndexChanged", selectionChangeHandler);
              selectionModel.addEventListener("dataProviderChanged", selectionChangeHandler);
@@@ -120,10 -120,10 +122,11 @@@
  			shape.graphics.beginFill(0xCCCCCC);
  			shape.graphics.drawRect(0, 0, 10, 10);
  			shape.graphics.endFill();
--			SimpleButton(value).upState = upSprite;
--			SimpleButton(value).downState = downSprite;
--			SimpleButton(value).overState = overSprite;
--			SimpleButton(value).hitTestState = shape;
++            var button:SimpleButton = value as SimpleButton;
++			button.upState = upSprite;
++            button.downState = downSprite;
++            button.overState = overSprite;
++            button.hitTestState = shape;
  			if (selectionModel.selectedIndex !== -1)
  				text = selectionModel.selectedItem.toString();
              else
@@@ -151,8 -151,8 +154,8 @@@
  		
          private function changeHandler(event:Event):void
          {
--            var ww:Number = DisplayObject(_strand).width;
--            var hh:Number = DisplayObject(_strand).height;
++            var ww:Number = IUIBase(_strand).width;
++            var hh:Number = IUIBase(_strand).height;
              
              upArrows.x = ww - upArrows.width - 6;            
              overArrows.x = ww - overArrows.width - 6;            
@@@ -190,6 -190,6 +193,7 @@@
  		
          private function drawBorder(sprite:Sprite, color:uint, ww:Number, hh:Number):void
          {
++			sprite.graphics.clear();
              SolidBorderUtil.drawBorder(sprite.graphics, 0, 0,
                  ww, hh,
                  0x808080, color, 1, 1, 4);
@@@ -230,8 -230,8 +234,6 @@@
           */
  		public function set text(value:String):void
  		{
--            var ww:Number = DisplayObject(_strand).width;
--            var hh:Number = DisplayObject(_strand).height;
  			upTextField.text = value;
  			downTextField.text = value;
  			overTextField.text = value;
@@@ -278,21 -278,21 +280,19 @@@
           */
          public function set popUpVisible(value:Boolean):void
          {
++            var host:IPopUpHost;
              if (value != _popUpVisible)
              {
                  _popUpVisible = value;
                  if (value)
                  {
--					var root:Object = DisplayObject(_strand).root;
--					var host:DisplayObjectContainer = DisplayObject(_strand).parent;
--                    while (host && !(host is IPopUpHost))
--                        host = host.parent;
--                    if (host)
--                        IPopUpHost(host).addElement(popUp as IChild);
++					host = UIUtils.findPopUpHost(_strand as IUIBase);
++                    IPopUpHost(host).addElement(popUp as IChild);
                  }
                  else
                  {
--                    DisplayObject(_popUp).parent.removeChild(_popUp as DisplayObject);                    
++                    host = UIUtils.findPopUpHost(_strand as IUIBase);
++                    IPopUpHost(host).removeElement(popUp as IChild);
                  }
              }
          }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
index 0000000,0000000..c3351a5
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
@@@ -1,0 -1,0 +1,429 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	import org.apache.flex.core.BeadViewBase;
++	import org.apache.flex.core.IBead;
++	import org.apache.flex.core.IBeadLayout;
++	import org.apache.flex.core.IBeadView;
++	import org.apache.flex.core.ILayoutChild;
++	import org.apache.flex.core.ILayoutHost;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.IUIBase;
++	import org.apache.flex.core.UIBase;
++	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.IEventDispatcher;
++
++	COMPILE::SWF {
++		import org.apache.flex.geom.Size;
++		import org.apache.flex.geom.Rectangle;
++		import org.apache.flex.utils.CSSContainerUtils;
++	}
++
++	/**
++	 *  The GroupView is a bead that manages the layout bead (if any) attached to a Group. This class
++	 *  also provides support for background and border styles for a Group on the SWF platform.
++     *
++	 *  @viewbead
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.8
++	 */
++	public class GroupView extends BeadViewBase implements IBeadView, ILayoutHost
++	{
++		/**
++     	 *  The GroupView class is the default view for
++         *  the org.apache.flex.html.Group class.
++         *  It lets you use some CSS styles to manage the border, background
++         *  and padding around the content area.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++		public function GroupView()
++		{
++			super();
++
++			layoutRunning = false;
++		}
++
++		/**
++		 * The sub-element used as the parent of the container's elements. This does not
++		 * include the chrome elements.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get contentView():ILayoutView
++		{
++			return host as ILayoutView;
++		}
++
++		/**
++		 * The view that can be resized.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get resizableView():IUIBase
++		{
++			return host;
++		}
++
++
++		private var layoutRunning:Boolean;
++
++		/**
++		 * Strand setter.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		override public function set strand(value:IStrand):void
++		{
++			_strand = value;
++			super.strand = value;
++
++			COMPILE::SWF {
++				displayBackgroundAndBorder(host as UIBase);
++			}
++
++			// listen for initComplete to signal that the strand has been initialized
++			// with its beads and children.
++			host.addEventListener("initComplete", handleInitComplete);
++			
++			// listen for when children have been added so additional event listeners
++			// can be placed upon them.
++			host.addEventListener("childrenAdded", handleChildrenAdded);
++			
++			// listen for requests to run the layout.
++			host.addEventListener("layoutNeeded", performLayout);
++		}
++
++		/**
++		 * Handles the initComplete event by completing the setup and kicking off the
++		 * presentation of the contents.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		protected function handleInitComplete(event:Event):void
++		{
++            var ilc:ILayoutChild = host as ILayoutChild;
++			// Complete the setup if the height is sized to content or has been explicitly set
++            // and the width is sized to content or has been explicitly set
++			if ((ilc.isHeightSizedToContent() || !isNaN(ilc.explicitHeight) || !isNaN(ilc.percentHeight)) &&
++                (ilc.isWidthSizedToContent() || !isNaN(ilc.explicitWidth) || !isNaN(ilc.percentWidth))) {
++				completeSetup();
++			}
++			else {
++				// otherwise, wait until the unknown sizes have been set and then finish
++				host.addEventListener("sizeChanged", deferredSizeHandler);
++                host.addEventListener("widthChanged", deferredSizeHandler);
++                host.addEventListener("heightChanged", deferredSizeHandler);
++			}
++		}
++
++		/**
++		 * Handles the case where the size of the host is not immediately known, usually do
++		 * to one of its dimensions being indicated as a percent size.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		protected function deferredSizeHandler(event:Event):void
++		{
++            host.removeEventListener("sizeChanged", deferredSizeHandler);
++            host.removeEventListener("widthChanged", deferredSizeHandler);
++            host.removeEventListener("heightChanged", deferredSizeHandler);
++			
++			completeSetup();
++
++			var num:Number = contentView.numElements;
++			if (num > 0)
++            {
++                performLayout(event);
++            }
++		}
++
++		/**
++		 * Called when the host is ready to complete its setup (usually after its size has been
++		 * determined).
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		protected function completeSetup():void
++		{
++			// listen for changes to strand's size and rerun the layout
++			host.addEventListener("sizeChanged", resizeHandler);
++			host.addEventListener("widthChanged", resizeHandler);
++			host.addEventListener("heightChanged", resizeHandler);
++		}
++
++		/**
++		 * Handles the viewCreated event by performing the first layout if
++		 * there are children already present (ie, from MXML).
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		protected function viewCreatedHandler(event:Event):void
++		{
++			var num:Number = contentView.numElements;
++			if (num > 0)
++			{
++				performLayout(event);
++			}
++		}
++
++		/**
++		 * @private
++		 */
++		protected function handleChildrenAdded(event:Event):void
++		{
++			COMPILE::SWF {
++				var n:Number = contentView.numElements;
++				for(var i:int=0; i < n; i++) {
++					var child:IEventDispatcher = contentView.getElementAt(i) as IEventDispatcher;
++					child.addEventListener("widthChanged", childResizeHandler);
++					child.addEventListener("heightChanged", childResizeHandler);
++					child.addEventListener("sizeChanged", childResizeHandler);
++				}
++			}
++
++			performLayout(event);
++		}
++		
++		/**
++		 * Invoked in response to the strand being resized.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		protected function resizeHandler(event:Event):void
++		{
++			performLayout(event);
++		}
++		
++		/**
++		 * Invoked in response to any child being resized.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		protected function childResizeHandler(event:Event):void
++		{
++			performLayout(event);
++		}
++		
++		/**
++		 * Provides a place for pre-layout actions.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		protected function layoutViewBeforeContentLayout():void
++		{
++			// This has no use for Group but is here so a subclass can override it.
++		}
++
++		/**
++		 * Executes the layout associated with this container. Once the layout has been
++		 * run, it may affect the size of the host or may cause the host to present scroll
++		 * bars view its viewport.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		protected function performLayout(event:Event):void
++		{
++			if (layoutRunning) return;
++
++			layoutRunning = true;
++			
++			// pre-process before layout
++			layoutViewBeforeContentLayout();
++
++			var host:UIBase = _strand as UIBase;
++
++			var layout:IBeadLayout = _strand.getBeadByType(IBeadLayout) as IBeadLayout;
++			if (layout == null) {
++				var c:Class = ValuesManager.valuesImpl.getValue(host, "iBeadLayout");
++				if (c) {
++					layout = new c() as IBeadLayout;
++					_strand.addBead(layout);
++				}
++			}
++
++			if (layout) {
++				layout.layout();
++			}
++
++			// cleanup or adjust after layout
++			layoutViewAfterContentLayout();
++
++			layoutRunning = false;
++			
++			host.dispatchEvent(new Event("layoutComplete"));
++		}
++
++		/**
++		 * Returns the size of the content area including the padding.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		COMPILE::SWF
++		protected function calculateContentSize():Size
++		{
++			var maxWidth:Number = 0;
++			var maxHeight:Number = 0;
++			var num:Number = contentView.numElements;
++
++			for (var i:int=0; i < num; i++) {
++				var child:IUIBase = contentView.getElementAt(i) as IUIBase;
++				if (child == null || !child.visible) continue;
++				var childXMax:Number = child.x + child.width;
++				var childYMax:Number = child.y + child.height;
++				maxWidth = Math.max(maxWidth, childXMax);
++				maxHeight = Math.max(maxHeight, childYMax);
++			}
++
++			var padding:org.apache.flex.geom.Rectangle = CSSContainerUtils.getPaddingMetrics(this._strand);
++			var border:org.apache.flex.geom.Rectangle = CSSContainerUtils.getBorderMetrics(this._strand);
++
++			// return the content size as the max plus right/bottom padding. the x,y position of
++			// each child is already offset by the left/top padding by the layout algorithm.
++			return new Size(maxWidth + padding.right - (border.left+border.right), maxHeight + padding.bottom - (border.top+border.bottom));
++		}
++
++		/**
++		 * @private
++		 */
++		private var adjusting:Boolean = false;
++
++		/**
++		 * Adjusts the size of the host after the layout has been run.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		COMPILE::SWF
++		protected function layoutViewAfterContentLayout():void
++		{
++			if (adjusting) return;
++
++			var host:UIBase = _strand as UIBase;
++
++			adjusting = true;
++
++			var contentSize:Size = calculateContentSize();
++
++			if (host.isWidthSizedToContent() && host.isHeightSizedToContent()) {
++				host.setWidthAndHeight(contentSize.width, contentSize.height, true);
++			}
++			else if (!host.isWidthSizedToContent() && host.isHeightSizedToContent())
++			{
++				host.setHeight(contentSize.height, true);
++			}
++			else if (host.isWidthSizedToContent() && !host.isHeightSizedToContent())
++			{
++				host.setWidth(contentSize.width, true);
++			}
++
++			adjusting = false;
++		}
++		
++		COMPILE::JS
++		protected function layoutViewAfterContentLayout():void
++		{
++			// maybe useful in a subclass on the JS side.
++		}
++
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		protected function displayBackgroundAndBorder(host:UIBase) : void
++		{
++			var backgroundColor:Object = ValuesManager.valuesImpl.getValue(host, "background-color");
++			var backgroundImage:Object = ValuesManager.valuesImpl.getValue(host, "background-image");
++			if (backgroundColor != null || backgroundImage != null)
++			{
++				if (host.getBeadByType(IBackgroundBead) == null)
++					var c:Class = ValuesManager.valuesImpl.getValue(host, "iBackgroundBead");
++				if (c) {
++					host.addBead( new c() as IBead );
++				}
++			}
++
++			var borderStyle:String;
++			var borderStyles:Object = ValuesManager.valuesImpl.getValue(host, "border");
++			if (borderStyles is Array)
++			{
++				borderStyle = borderStyles[1];
++			}
++			if (borderStyle == null)
++			{
++				borderStyle = ValuesManager.valuesImpl.getValue(host, "border-style") as String;
++			}
++			if (borderStyle != null && borderStyle != "none")
++			{
++				if (host.getBeadByType(IBorderBead) == null) {
++					c = ValuesManager.valuesImpl.getValue(host, "iBorderBead");
++					if (c) {
++						host.addBead( new c() as IBead );
++					}
++				}
++			}
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/HScrollBarTrackView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/HScrollBarTrackView.as
index de6a3af,de6a3af..212d29b
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/HScrollBarTrackView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/HScrollBarTrackView.as
@@@ -32,6 -32,6 +32,7 @@@ package org.apache.flex.html.bead
       *  The HScrollBarTrackView class is the view for
       *  the track in a Horizontal ScrollBar.
       *  
++ 	 *  @viewbead
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ImageButtonView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ImageButtonView.as
index 9e1ebdf,9e1ebdf..f54faef
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ImageButtonView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ImageButtonView.as
@@@ -29,11 -29,11 +29,12 @@@ COMPILE::SWF 
  
  	import org.apache.flex.core.UIButtonBase;
  }
--
++    
      import org.apache.flex.core.BeadViewBase;
--	import org.apache.flex.core.IBead;
--	import org.apache.flex.core.IBeadView;
--	import org.apache.flex.core.IStrand;
++    import org.apache.flex.core.IBead;
++    import org.apache.flex.core.IBeadView;
++    import org.apache.flex.core.IChild;
++    import org.apache.flex.core.IStrand;
      import org.apache.flex.core.ValuesManager;
      import org.apache.flex.events.Event;
      import org.apache.flex.events.IEventDispatcher;
@@@ -44,6 -44,6 +45,7 @@@
  	 *  class does not support background and border; only images
  	 *  for the up, over, and active states.
  	 *
++	 *  @viewbead
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -85,14 -85,14 +87,17 @@@
  				shape.graphics.beginFill(0xCCCCCC);
  				shape.graphics.drawRect(0, 0, 10, 10);
  				shape.graphics.endFill();
--				SimpleButton(value).upState = upSprite;
--				SimpleButton(value).downState = downSprite;
--				SimpleButton(value).overState = overSprite;
--				SimpleButton(value).hitTestState = shape;
++                var button:SimpleButton = value as SimpleButton;
++				button.upState = upSprite;
++				button.downState = downSprite;
++				button.overState = overSprite;
++				button.hitTestState = shape;
  
  				setupBackground(upSprite);
  				setupBackground(overSprite, "hover");
  				setupBackground(downSprite, "active");
++				
++				IEventDispatcher(value).addEventListener("sourceChanged", handleSourceChange);
  			}
  		}
  
@@@ -125,8 -125,8 +130,8 @@@
                      if (isNaN(host.explicitWidth) && isNaN(host.percentWidth))
                      {
                          host.setWidth(loader.content.width);
--                        if (host.parent)
--                            (host.parent as IEventDispatcher).dispatchEvent(new org.apache.flex.events.Event("layoutNeeded"));
++                        if (host.parent is IEventDispatcher)
++                            IEventDispatcher(host.parent).dispatchEvent(new org.apache.flex.events.Event("layoutNeeded"));
                      }
                      else
                          loader.content.width = host.width;
@@@ -134,8 -134,8 +139,8 @@@
                      if (isNaN(host.explicitHeight) && isNaN(host.percentHeight))
                      {
                          host.setHeight(loader.content.height);
--                        if (host.parent)
--                            (host.parent as IEventDispatcher).dispatchEvent(new org.apache.flex.events.Event("layoutNeeded"));
++                        if (host.parent is IEventDispatcher)
++                            IEventDispatcher(host.parent).dispatchEvent(new org.apache.flex.events.Event("layoutNeeded"));
                      }
                      else
                          loader.content.height = host.height;
@@@ -143,6 -143,6 +148,17 @@@
  				});
  			}
  		}
++		
++		/**
++		 * @private
++		 */
++		COMPILE::SWF
++		private function handleSourceChange(event:org.apache.flex.events.Event):void
++		{
++			setupBackground(upSprite);
++			setupBackground(overSprite, "hover");
++			setupBackground(downSprite, "active");
++		}
  
  		/**
  		 * @private

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ListView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ListView.as
index 3018600,3018600..0f73421
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ListView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/ListView.as
@@@ -17,13 -17,13 +17,14 @@@
  //
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads
--{	
++{
  	import org.apache.flex.core.BeadViewBase;
  	import org.apache.flex.core.ContainerBase;
  	import org.apache.flex.core.IBead;
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.IBeadModel;
  	import org.apache.flex.core.IBeadView;
++	import org.apache.flex.core.IList;
  	import org.apache.flex.core.ISelectableItemRenderer;
  	import org.apache.flex.core.IItemRenderer;
  	import org.apache.flex.core.IItemRendererParent;
@@@ -46,71 -46,71 +47,89 @@@
  	import org.apache.flex.html.supportClasses.ScrollBar;
  
  	/**
--	 *  The List class creates the visual elements of the org.apache.flex.html.List 
--	 *  component. A List consists of the area to display the data (in the dataGroup), any 
++	 *  The List class creates the visual elements of the org.apache.flex.html.List
++	 *  component. A List consists of the area to display the data (in the dataGroup), any
  	 *  scrollbars, and so forth.
--	 *  
++	 *
++	 *  @viewbead
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class ListView extends ContainerView implements IListView
++	COMPILE::JS
++	public class ListView extends DataContainerView
  	{
  		public function ListView()
  		{
++			super();
  		}
--						
++
  		protected var listModel:ISelectionModel;
--		
--		private var _border:Border;
--		
--		/**
--		 *  The border surrounding the org.apache.flex.html.List.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--        public function get border():Border
--        {
--            return _border;
--        }
--		
++
++		protected var lastSelectedIndex:int = -1;
++
  		/**
--		 *  The area holding the itemRenderers.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
++		 * @private
  		 */
--		public function get dataGroup():IItemRendererParent
++		override protected function handleInitComplete(event:Event):void
++		{
++			listModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
++			listModel.addEventListener("selectedIndexChanged", selectionChangeHandler);
++			listModel.addEventListener("rollOverIndexChanged", rollOverIndexChangeHandler);
++
++			super.handleInitComplete(event);
++		}
++
++		protected function selectionChangeHandler(event:Event):void
  		{
--			(contentView as UIBase).className = "ListDataGroup";
--			return contentView as IItemRendererParent;
++			if (lastSelectedIndex != -1)
++			{
++				var ir:ISelectableItemRenderer = dataGroup.getItemRendererForIndex(lastSelectedIndex) as ISelectableItemRenderer;
++				if (ir != null) ir.selected = false;
++			}
++			if (listModel.selectedIndex != -1)
++			{
++				ir = dataGroup.getItemRendererForIndex(listModel.selectedIndex) as ISelectableItemRenderer;
++				if (ir != null) ir.selected = true;
++			}
++			lastSelectedIndex = listModel.selectedIndex;
  		}
--				
++
++		protected var lastRollOverIndex:int = -1;
++
  		/**
  		 * @private
  		 */
--		override public function get resizableView():IUIBase
++		protected function rollOverIndexChangeHandler(event:Event):void
  		{
--			return _strand as IUIBase;
++			if (lastRollOverIndex != -1)
++			{
++				var ir:ISelectableItemRenderer = dataGroup.getItemRendererForIndex(lastRollOverIndex) as ISelectableItemRenderer;
++				ir.hovered = false;
++			}
++			if (IRollOverModel(listModel).rollOverIndex != -1)
++			{
++				ir = dataGroup.getItemRendererForIndex(IRollOverModel(listModel).rollOverIndex) as ISelectableItemRenderer;
++				ir.hovered = true;
++			}
++			lastRollOverIndex = IRollOverModel(listModel).rollOverIndex;
  		}
--        
--        /**
--         * @private
--         */
--        override public function get host():IUIBase
--        {
--            return _strand as IUIBase;
--        }
--        		
++	}
++
++	COMPILE::SWF
++	public class ListView extends DataContainerView
++	{
++		public function ListView()
++		{
++			super();
++		}
++
++		protected var listModel:ISelectionModel;
++
  		/**
  		 *  @copy org.apache.flex.core.IBead#strand
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -121,42 -121,42 +140,21 @@@
  			_strand = value;
  			super.strand = value;
  		}
--		
--		override protected function completeSetup():void
++
++		/**
++		 * @private
++		 */
++		override protected function handleInitComplete(event:Event):void
  		{
--			super.completeSetup();
--			
--			// list is not interested in UI children, it wants to know when new items
--			// have been added or the dataProvider has changed.
--			
--			host.removeEventListener("childrenAdded", childrenChangedHandler);
--			host.removeEventListener("childrenAdded", performLayout);
--			host.addEventListener("itemsCreated", itemsCreatedHandler);
--			
++			super.handleInitComplete(event);
++
  			listModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
  			listModel.addEventListener("selectedIndexChanged", selectionChangeHandler);
  			listModel.addEventListener("rollOverIndexChanged", rollOverIndexChangeHandler);
--			listModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
  		}
--		
++
  		protected var lastSelectedIndex:int = -1;
--		
--		/**
--		 * @private
--		 */
--		protected function itemsCreatedHandler(event:Event):void
--		{
--			performLayout(event);
--		}
--		
--		/**
--		 * @private
--		 */
--		protected function dataProviderChangeHandler(event:Event):void
--		{
--			performLayout(event);
--		}
--		
++
  		/**
  		 * @private
  		 */
@@@ -174,9 -174,9 +172,9 @@@
  			}
              lastSelectedIndex = listModel.selectedIndex;
  		}
--		
++
  		protected var lastRollOverIndex:int = -1;
--		
++
  		/**
  		 * @private
  		 */
@@@ -194,18 -194,18 +192,5 @@@
  			}
  			lastRollOverIndex = IRollOverModel(listModel).rollOverIndex;
  		}
--        
--        /**
--         *  respond to a change in size or request to re-layout everything
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		override protected function resizeHandler(event:Event):void
--		{
--			super.resizeHandler(event);
--		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
index c52fe93,c52fe93..43af3f8
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
@@@ -19,10 -19,10 +19,15 @@@
  package org.apache.flex.html.beads
  {
  	import org.apache.flex.core.IBeadView;
++	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.ILayoutChild;
--	import org.apache.flex.core.IContentViewHost;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.IChild;
++	import org.apache.flex.core.IContainer;
++	import org.apache.flex.core.IParent;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
++	import org.apache.flex.core.IViewport;
  	import org.apache.flex.core.IViewportModel;
  	import org.apache.flex.core.UIBase;
  	import org.apache.flex.core.ValuesManager;
@@@ -30,23 -30,23 +35,31 @@@
  	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.geom.Rectangle;
  	import org.apache.flex.geom.Size;
++	import org.apache.flex.html.Group;
  	import org.apache.flex.html.Container;
  	import org.apache.flex.html.Panel;
  	import org.apache.flex.html.TitleBar;
  	import org.apache.flex.utils.CSSContainerUtils;
  	import org.apache.flex.utils.CSSUtils;
--	
++	import org.apache.flex.html.beads.layouts.VerticalFlexLayout;
++	import org.apache.flex.html.supportClasses.PanelLayoutProxy;
++
++	COMPILE::SWF {
++		import org.apache.flex.core.SimpleCSSStyles;
++	}
++
  	/**
--	 *  The Panel class creates the visual elements of the org.apache.flex.html.Panel 
++	 *  The Panel class creates the visual elements of the org.apache.flex.html.Panel
  	 *  component. A Panel has a org.apache.flex.html.TitleBar, and content.  A
       *  different View, PanelWithControlBarView, can display a ControlBar.
--	 *  
++	 *
++	 *  @viewbead
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class PanelView extends ContainerView implements IBeadView
++	public class PanelView extends GroupView implements IBeadView
  	{
  		/**
  		 *  constructor.
@@@ -60,11 -60,11 +73,11 @@@
  		{
  			super();
  		}
--		
++
  		private var _titleBar:TitleBar;
--		
++
  		/**
--		 *  The org.apache.flex.html.TitleBar component of the 
++		 *  The org.apache.flex.html.TitleBar component of the
  		 *  org.apache.flex.html.Panel.
  		 *
  		 *  @langversion 3.0
@@@ -76,7 -76,7 +89,7 @@@
  		{
  			return _titleBar;
  		}
--		
++
          /**
           *  @private
           */
@@@ -84,10 -84,10 +97,31 @@@
          {
              _titleBar = value;
          }
--				
++
++		private var _contentArea:Container;
++
++		/**
++		 * The content area of the panel.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get contentArea():Container
++		{
++			return _contentArea;
++		}
++		public function set contentArea(value:Container):void
++		{
++			_contentArea = value;
++		}
++
++		private var _strand:IStrand;
++
  		/**
  		 *  @copy org.apache.flex.core.IBead#strand
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -95,74 -95,74 +129,138 @@@
  		 */
  		override public function set strand(value:IStrand):void
  		{
++			_strand = value;
++
              var host:UIBase = UIBase(value);
--            
++
              if (!_titleBar) {
                  _titleBar = new TitleBar();
  				_titleBar.id = "panelTitleBar";
--				_titleBar.height = 30;
++
++				COMPILE::SWF {
++					_titleBar.percentWidth = 100;
++
++					if (_titleBar.style == null) {
++						_titleBar.style = new SimpleCSSStyles();
++					}
++					_titleBar.style.flexGrow = 0;
++					_titleBar.style.order = 1;
++				}
++
++				COMPILE::JS {
++					_titleBar.element.style["flex-grow"] = "0";
++					_titleBar.element.style["order"] = "1";
++				}
  			}
  			// replace the TitleBar's model with the Panel's model (it implements ITitleBarModel) so that
--			// any changes to values in the Panel's model that correspond values in the TitleBar will 
++			// any changes to values in the Panel's model that correspond values in the TitleBar will
  			// be picked up automatically by the TitleBar.
  			titleBar.model = host.model;
--			            
++
++			if (!_contentArea) {
++				_contentArea = new Container();
++				_contentArea.id = "panelContent";
++				_contentArea.className = "PanelContent";
++
++				COMPILE::SWF {
++					_contentArea.percentWidth = 100;
++
++					if (_contentArea.style == null) {
++						_contentArea.style = new SimpleCSSStyles();
++					}
++					_contentArea.style.flexGrow = 1;
++					_contentArea.style.order = 2;
++				}
++
++				COMPILE::JS {
++					_contentArea.element.style["flex-grow"] = "1";
++					_contentArea.element.style["order"] = "2";
++					_contentArea.element.style["overflow"] = "auto"; // temporary
++				}
++			}
++
++			COMPILE::SWF {
++				IEventDispatcher(value).addEventListener("widthChanged", handleSizeChange);
++				IEventDispatcher(value).addEventListener("heightChanged", handleSizeChange);
++				IEventDispatcher(value).addEventListener("sizeChanged", handleSizeChange);
++				IEventDispatcher(value).addEventListener("childrenAdded", handleChildrenAdded);
++			}
++
              super.strand = value;
++
++			// If the Panel was given a layout, transfer it to the content area.
++			var layoutBead:IBeadLayout = value.getBeadByType(IBeadLayout) as IBeadLayout;
++			if (layoutBead) {
++				value.removeBead(layoutBead);
++
++				var contentLayout:IBeadLayout = _contentArea.getBeadByType(IBeadLayout) as IBeadLayout;
++				if (contentLayout) {
++					_contentArea.removeBead(contentLayout);
++				}
++				_contentArea.addBead(layoutBead);
++			}
++
++			// If the Panel was given a viewport, transfer it to the content area.
++			var viewportBead:IViewport = value.getBeadByType(IViewport) as IViewport;
++			if (viewportBead) {
++				value.removeBead(viewportBead);
++				_contentArea.addBead(viewportBead);
++			}
++
++			// Now give the Panel its own layout
++			layoutBead = new VerticalFlexLayout();
++			value.addBead(layoutBead);
  		}
--		
++
++		private var _panelLayoutProxy:PanelLayoutProxy;
++
++		/**
++		 * The sub-element used as the parent of the container's elements. This does not
++		 * include the chrome elements.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		override public function get contentView():ILayoutView
++		{
++			// we want to return a proxy for the host which will have numElements, getElementAt, etc.
++			// functions that will use the host.$numElements, host.$getElementAt, etc. functions
++			if (_panelLayoutProxy == null) {
++				_panelLayoutProxy = new PanelLayoutProxy(_strand);
++			}
++			return _panelLayoutProxy;
++		}
++
  		override protected function completeSetup():void
  		{
--			(host as IContentViewHost).strandChildren.addElement(titleBar);
++			if (titleBar.parent == null) {
++				(_strand as Panel).$addElement(titleBar);
++			}
++			if (contentArea.parent == null) {
++				(_strand as Panel).$addElement(contentArea as IChild);
++			}
++
  			super.completeSetup();
++			
++			performLayout(null);
  		}
--		
--        /**
--         * Calculate the space taken up by non-content children like a TItleBar in a Panel.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        override protected function getChromeMetrics():Rectangle
--        {
--            return new Rectangle(0, titleBar.height, 0, 0 - titleBar.height);
--        }
--        
--        override protected function layoutViewBeforeContentLayout():void
--        {
--            var vm:IViewportModel = viewportModel;
--            var host:ILayoutChild = this.host as ILayoutChild;
--            vm.borderMetrics = CSSContainerUtils.getBorderMetrics(host);
--            titleBar.x = vm.borderMetrics.left;
--            titleBar.y = vm.borderMetrics.top;
--            if (!host.isWidthSizedToContent())
--                titleBar.width = host.width - vm.borderMetrics.left - vm.borderMetrics.right;
--            vm.chromeMetrics = getChromeMetrics();
--            viewport.setPosition(vm.borderMetrics.left + vm.chromeMetrics.left,
--                vm.borderMetrics.top + vm.chromeMetrics.top);
--            viewport.layoutViewportBeforeContentLayout(
--                !host.isWidthSizedToContent() ? 
--                host.width - vm.borderMetrics.left - vm.borderMetrics.right -
--                vm.chromeMetrics.left - vm.chromeMetrics.right : NaN,
--                !host.isHeightSizedToContent() ?
--                host.height - vm.borderMetrics.top - vm.borderMetrics.bottom -
--                vm.chromeMetrics.top - vm.chromeMetrics.bottom : NaN);
--        }
--        
--		override protected function layoutViewAfterContentLayout():void
++
++		protected function handleSizeChange(event:Event):void
  		{
--            var vm:IViewportModel = viewportModel;
--            var viewportSize:Size = this.viewport.layoutViewportAfterContentLayout();
--            var host:ILayoutChild = this.host as ILayoutChild;
--            var hasWidth:Boolean = !host.isWidthSizedToContent();
--            var hasHeight:Boolean = !host.isHeightSizedToContent();
--            if (!hasWidth) {
--                titleBar.width = viewportSize.width; // should get titlebar to layout and get new height
--                vm.chromeMetrics = this.getChromeMetrics();
--                vm.chromeMetrics.top = titleBar.height;
--            }
--            super.layoutViewAfterContentLayout();
--		}       
++			COMPILE::JS {
++				_titleBar.percentWidth = 100;
++				_contentArea.percentWidth = 100;
++			}
++
++			performLayout(event);
++		}
++
++		private function handleChildrenAdded(event:Event):void
++		{
++			_contentArea.dispatchEvent(new Event("layoutNeeded"));
++			performLayout(event);
++		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelWithControlBarView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelWithControlBarView.as
index 8dfcd42,cfbbae8..3312b85
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelWithControlBarView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelWithControlBarView.as
@@@ -18,9 -18,7 +18,8 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads
  {
- 	import flash.display.Sprite;
- 	
  	import org.apache.flex.core.IBeadView;
++	import org.apache.flex.core.IChild;
  	import org.apache.flex.core.IContentViewHost;
  	import org.apache.flex.core.ILayoutChild;
  	import org.apache.flex.core.IPanelModel;
@@@ -34,21 -32,21 +33,27 @@@
  	import org.apache.flex.geom.Rectangle;
  	import org.apache.flex.geom.Size;
  	import org.apache.flex.html.Container;
++	import org.apache.flex.html.Panel;
  	import org.apache.flex.html.ControlBar;
  	import org.apache.flex.html.TitleBar;
  	import org.apache.flex.utils.CSSContainerUtils;
  	
++	COMPILE::SWF {
++		import org.apache.flex.core.SimpleCSSStyles;
++	}
++	
  	/**
  	 *  The Panel class creates the visual elements of the org.apache.flex.html.Panel 
  	 *  component. A Panel has a org.apache.flex.html.TitleBar, content, and an 
  	 *  optional org.apache.flex.html.ControlBar.
  	 *  
++	 *  @viewbead
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class PanelWithControlBarView extends ContainerView implements IBeadView
++	public class PanelWithControlBarView extends PanelView
  	{
  		/**
  		 *  constructor.
@@@ -60,22 -58,22 +65,7 @@@
  		 */
  		public function PanelWithControlBarView()
  		{
--		}
--		
--		private var _titleBar:TitleBar;
--		
--		/**
--		 *  The org.apache.flex.html.TitleBar component of the 
--		 *  org.apache.flex.html.Panel.
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function get titleBar():TitleBar
--		{
--			return _titleBar;
++			super();
  		}
  		
  		private var _controlBar:ControlBar;
@@@ -103,105 -101,105 +93,65 @@@
  		 */
  		override public function set strand(value:IStrand):void
  		{
--			var host:UIBase = UIBase(value);
++			super.strand = value;
  			
--			// TODO: (aharui) get class to instantiate from CSS
--			if (!_titleBar) {
--				_titleBar = new TitleBar();
--				_titleBar.id = "panelTitleBar";
--				_titleBar.height = 30;
--			}
--			// replace the TitleBar's model with the Panel's model (it implements ITitleBarModel) so that
--			// any changes to values in the Panel's model that correspond values in the TitleBar will 
--			// be picked up automatically by the TitleBar.
--			_titleBar.model = host.model;
++			var host:UIBase = UIBase(_strand);
  			
--			var controlBarItems:Array = (host.model as IPanelModel).controlBar;
--			if( controlBarItems && controlBarItems.length > 0 ) {
--				_controlBar = new ControlBar();
--				_controlBar.id = "panelControlBar";
--				_controlBar.height = 30;
++			_controlBar = new ControlBar();
++			_controlBar.id = "panelControlBar";
++			
++			COMPILE::SWF {
++				_controlBar.percentWidth = 100;
  				
--				for each(var comp:IUIBase in controlBarItems) {
--					_controlBar.addElement(comp, false);
++				if (_controlBar.style == null) {
++					_controlBar.style = new SimpleCSSStyles();
  				}
++				_controlBar.style.flexGrow = 0;
++				_controlBar.style.order = 3;
++			}
++				
++			COMPILE::JS {
++				_controlBar.element.style["flex-grow"] = "0";
++				_controlBar.element.style["order"] = "3";
  			}
--			
--			super.strand = value;
  		}
  		
  		override protected function completeSetup():void
  		{
--			super.completeSetup();
++			if (titleBar.parent == null) {
++				(_strand as Panel).$addElement(titleBar);
++			}
++			if (contentArea.parent == null) {
++				(_strand as Panel).$addElement(contentArea as IChild);
++			}
++			if (controlBar.parent == null) {
++				(_strand as Panel).$addElement(controlBar);
++			}
  			
--			(_strand as IContentViewHost).strandChildren.addElement(titleBar, false);
++			var host:UIBase = UIBase(_strand);
  			
--			if (controlBar) {
--				(_strand as IContentViewHost).strandChildren.addElement(_controlBar, false);
++			var controlBarItems:Array = (host.model as IPanelModel).controlBar;
++			if( controlBarItems && controlBarItems.length > 0 ) {
++				for each(var comp:IUIBase in controlBarItems) {
++					controlBar.addElement(comp, false);
++				}
++				controlBar.childrenAdded();
  			}
++			
++			super.completeSetup();
++			
++			performLayout(null);
  		}
  		
--        /**
--         * Calculate the space taken up by non-content children like a TItleBar in a Panel.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        override protected function getChromeMetrics():Rectangle
--        {
--            return new Rectangle(0, titleBar.height, 0, controlBar.height - titleBar.height);
--        }
--        
--        override protected function layoutViewBeforeContentLayout():void
--        {
--            var vm:IViewportModel = viewportModel;
--            var host:ILayoutChild = this.host as ILayoutChild;
--            var hasHeight:Boolean = !host.isHeightSizedToContent();
--            var hasWidth:Boolean = !host.isWidthSizedToContent();
--            vm.borderMetrics = CSSContainerUtils.getBorderMetrics(host);
--            titleBar.x = vm.borderMetrics.left;
--            titleBar.y = vm.borderMetrics.top;
--            if (hasWidth) 
--            {
--                titleBar.width = host.width - vm.borderMetrics.left - vm.borderMetrics.right;
--                controlBar.width = host.width - vm.borderMetrics.left - vm.borderMetrics.right;
--            }
--            vm.chromeMetrics = getChromeMetrics();
--            controlBar.x = vm.borderMetrics.left;
--            if (hasHeight && hasWidth) 
--                controlBar.y = host.height - vm.borderMetrics.bottom - controlBar.height;
--            
--            viewport.setPosition(vm.borderMetrics.left + vm.chromeMetrics.left,
--                vm.borderMetrics.top + vm.chromeMetrics.top);
--            viewport.layoutViewportBeforeContentLayout(
--                hasWidth ? 
--                    host.width - vm.borderMetrics.left - vm.borderMetrics.right -
--                        vm.chromeMetrics.left - vm.chromeMetrics.right : NaN,
--                hasHeight ?
--                    host.height - vm.borderMetrics.top - vm.borderMetrics.bottom -
--                        vm.chromeMetrics.top - vm.chromeMetrics.bottom : NaN);
--        }
--        
--        override protected function layoutViewAfterContentLayout():void
--        {
--            var vm:IViewportModel = viewportModel;
--            var viewportSize:Size = this.viewport.layoutViewportAfterContentLayout();
--            var host:ILayoutChild = this.host as ILayoutChild;
--            var hasWidth:Boolean = !host.isWidthSizedToContent();
--            var hasHeight:Boolean = !host.isHeightSizedToContent();
--            if (!hasWidth) {
--                titleBar.width = viewportSize.width; // should get titlebar to layout and get new height
--                vm.chromeMetrics = this.getChromeMetrics();
--                vm.chromeMetrics.top = titleBar.height;
--                controlBar.width = viewportSize.width; // should get controlbar to layout and get new height
--                vm.chromeMetrics.bottom = controlBar.height;
--            }
--            super.layoutViewAfterContentLayout();
--            if (!hasHeight) {
--                controlBar.y = host.height - vm.borderMetrics.bottom - controlBar.height;
--            }
--        }       
++		override protected function handleSizeChange(event:Event):void
++		{
++			COMPILE::JS {
++				titleBar.percentWidth = 100;
++				contentArea.percentWidth = 100;
++				controlBar.percentWidth = 100;
++			}
++				
++			performLayout(event);
++		}       
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/RangeStepperView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/RangeStepperView.as
index a05b913,3ac84ce..62506f7
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/RangeStepperView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/RangeStepperView.as
@@@ -34,6 -34,6 +34,7 @@@ package org.apache.flex.html.bead
  	 *  The RangeStepperView bead creates the visual elements of the RangeStepper. This
  	 *  includes an increment button, a decrement button, and label to display the value.
  	 *  
++	 *  @viewbead
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
index 49f3608,49f3608..657beef
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderBead.as
@@@ -19,7 -19,7 +19,7 @@@
  package org.apache.flex.html.beads
  {
  	import flash.display.Graphics;
--	
++
  	import org.apache.flex.core.IBead;
  	import org.apache.flex.core.IStatesObject;
  	import org.apache.flex.core.IStrand;
@@@ -65,14 -65,14 +65,14 @@@
  		public function set strand(value:IStrand):void
  		{
  			_strand = value;
--            IEventDispatcher(value).addEventListener("layoutNeeded", changeHandler);
              IEventDispatcher(value).addEventListener("heightChanged", changeHandler);
              IEventDispatcher(value).addEventListener("widthChanged", changeHandler);
--            IEventDispatcher(value).addEventListener("sizeChanged", changeHandler);
--            changeHandler(null);
++			IEventDispatcher(value).addEventListener("sizeChanged", changeHandler);
++			IEventDispatcher(value).addEventListener("initComplete", changeHandler);
++			IEventDispatcher(value).addEventListener("layoutComplete", changeHandler);
  		}
  		        
--		private function changeHandler(event:Event):void
++		protected function changeHandler(event:Event):void
  		{
              var host:UIBase = UIBase(_strand);
              var g:Graphics = host.graphics;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderWithChangeListenerBead.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderWithChangeListenerBead.as
index 0000000,0000000..ae7440f
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SingleLineBorderWithChangeListenerBead.as
@@@ -1,0 -1,0 +1,89 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.IStyleableObject;
++	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.events.StyleChangeEvent;
++
++    /**
++     *  The SingleLineBorderWithChangeListenerBead adds the ability to react to
++	 *  changes in border style at runtime.
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public class SingleLineBorderWithChangeListenerBead extends SingleLineBorderBead
++	{
++        /**
++         *  Constructor.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function SingleLineBorderWithChangeListenerBead()
++		{
++			super();
++		}
++		
++		private var _strand:IStrand;
++		
++        /**
++         *  @copy org.apache.flex.core.IBead#strand
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		override public function set strand(value:IStrand):void
++		{
++			super.strand = value;
++			_strand = value;
++			IEventDispatcher(value).addEventListener(StyleChangeEvent.STYLE_CHANGE, handleStyleChange);
++		}
++		
++		/**
++		 * @private
++		 */
++		private function handleStyleChange(event:StyleChangeEvent):void
++		{			
++			// see if border style needs to be converted into an array
++			var borderStyles:Object = ValuesManager.valuesImpl.getValue(_strand, "border");
++			if (borderStyles is String) {
++				// it may be just "solid"
++				var list:Array = String(borderStyles).split(" ");
++				if (list.length == 3) {
++					// set it on the strand's style (IValuesImpl does not have setStyle exposed).
++					var host:IStyleableObject = _strand as IStyleableObject;
++					// setting this will trigger this event listener again
++					host.style.border = list;
++				}
++			} else {
++				changeHandler(null);
++			}
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
index a162669,a162669..5833d52
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundBead.as
@@@ -18,17 -18,17 +18,17 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads
  {
++    import flash.display.Graphics;
      import flash.display.Sprite;
--	import flash.display.Graphics;
--	
--	import org.apache.flex.core.IBead;
++    
++    import org.apache.flex.core.IBead;
      import org.apache.flex.core.IBeadView;
      import org.apache.flex.core.ILayoutChild;
--	import org.apache.flex.core.IStrand;
--	import org.apache.flex.core.IUIBase;
--	import org.apache.flex.core.ValuesManager;
--	import org.apache.flex.events.Event;
--	import org.apache.flex.events.IEventDispatcher;
++    import org.apache.flex.core.IStrand;
++    import org.apache.flex.core.IUIBase;
++    import org.apache.flex.core.ValuesManager;
++    import org.apache.flex.events.Event;
++    import org.apache.flex.events.IEventDispatcher;
  
      /**
       *  The SolidBackgroundBead class draws a solid filled background.
@@@ -77,27 -77,27 +77,31 @@@
              IEventDispatcher(host).addEventListener("widthChanged", changeHandler);
  			IEventDispatcher(host).addEventListener("sizeChanged", changeHandler);
  			IEventDispatcher(host).addEventListener("initComplete", changeHandler);
++			IEventDispatcher(host).addEventListener("layoutComplete", changeHandler);
  			
++			setupStyle();
++		}
++		
++		protected function setupStyle():void
++		{
  			var bgColor:Object = ValuesManager.valuesImpl.getValue(host, "background-color");
  			if ((bgColor is String) && (bgColor == "transparent")) {
  				bgColor = null;
  				opacity = 0;
  			}
  			else if( bgColor != null ) {
--				backgroundColor = ValuesManager.valuesImpl.convertColor(bgColor);
++				_backgroundColor = ValuesManager.valuesImpl.convertColor(bgColor);
  			}
  			
  			var bgAlpha:Object = ValuesManager.valuesImpl.getValue(host, "opacity");
  			if( bgAlpha != null ) {
--				opacity = Number(bgAlpha);
++				_opacity = Number(bgAlpha);
++			}
++			
++			var corner:Object = ValuesManager.valuesImpl.getValue(host, "border-radius");
++			if( corner != null ) {
++				_borderRadius = Number(corner);
  			}
--            
--            var corner:Object = ValuesManager.valuesImpl.getValue(host, "border-radius");
--            if( corner != null ) {
--                borderRadius = Number(corner);
--            }
--            
--            changeHandler(null);
  		}
  		
  		private var _backgroundColor:uint;
@@@ -175,9 -175,9 +179,9 @@@
                  changeHandler(null);
          }
          
--		private function changeHandler(event:Event):void
++		protected function changeHandler(event:Event):void
  		{
--            var g:Graphics = Sprite(host).graphics;
++            var g:Graphics = Sprite(host).graphics as Graphics;
              var w:Number = host.width;
              var h:Number = host.height;
  			


[04/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/StringItemRenderer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/StringItemRenderer.as
index 2a0f798,b897012..0f12f1b
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/StringItemRenderer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/StringItemRenderer.as
@@@ -22,17 -22,17 +22,17 @@@ package org.apache.flex.html.supportCla
      {
          import flash.text.TextFieldAutoSize;
          import flash.text.TextFieldType;
--        
--        import org.apache.flex.core.CSSTextField;            
++
++        import org.apache.flex.core.CSSTextField;
      }
      COMPILE::JS
      {
          import org.apache.flex.core.WrappedHTMLElement;
--        import org.apache.flex.html.beads.controllers.ItemRendererMouseController;        
++        import org.apache.flex.html.beads.controllers.ItemRendererMouseController;
      }
      import org.apache.flex.events.Event;
      import org.apache.flex.html.beads.ITextItemRenderer;
--    
++
  	/**
  	 *  The StringItemRenderer class displays data in string form using the data's toString()
  	 *  function.
@@@ -55,20 -55,20 +55,20 @@@
  		public function StringItemRenderer()
  		{
  			super();
--			
++
              COMPILE::SWF
              {
                  textField = new CSSTextField();
                  textField.type = TextFieldType.DYNAMIC;
                  textField.autoSize = TextFieldAutoSize.LEFT;
                  textField.selectable = false;
--                textField.parentDrawsBackground = true;         
++                textField.parentDrawsBackground = true;
              }
  		}
--		
++
          COMPILE::SWF
  		public var textField:CSSTextField;
--		
++
  		/**
  		 * @private
  		 */
@@@ -76,12 -76,12 +76,12 @@@
  		override public function addedToParent():void
  		{
  			super.addedToParent();
--			
++
  			addChild(textField);
  
  			adjustSize();
  		}
--		
++
  		/**
  		 * @private
  		 */
@@@ -89,14 -89,14 +89,14 @@@
  		override public function adjustSize():void
  		{
  			var cy:Number = height/2;
--			
++
  			textField.x = 0;
  			textField.y = cy - textField.height/2;
  			textField.width = width;
--			
++
  			updateRenderer();
  		}
--		
++
  		/**
  		 *  The text currently displayed by the itemRenderer instance.
  		 *
@@@ -109,29 -109,29 +109,29 @@@
  		{
              COMPILE::SWF
              {
--                return textField.text;                    
++                return textField.text;
              }
              COMPILE::JS
              {
                  return this.element.innerHTML;
              }
  		}
--		
++
  		public function set text(value:String):void
  		{
              COMPILE::SWF
              {
--                textField.text = value;                    
++                textField.text = value;
              }
              COMPILE::JS
              {
                  this.element.innerHTML = value;
              }
  		}
--		
++
  		/**
  		 *  Sets the data value and uses the String version of the data for display.
--		 * 
++		 *
  		 *  @param Object data The object being displayed by the itemRenderer instance.
  		 *
  		 *  @langversion 3.0
@@@ -146,33 -146,33 +146,33 @@@
  			if (labelField) text = String(value[labelField]);
  			else if (dataField) text = String(value[dataField]);
  			else text = String(value);
--            
++
              this.text = text;
  		}
--		
++
          COMPILE::JS
          private var controller:ItemRendererMouseController;
--            
++
          COMPILE::JS
          private var backgroundView:WrappedHTMLElement;
--        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
          COMPILE::JS
          override protected function createElement():WrappedHTMLElement
--        {            
 -            element = document.createElement('div') as WrappedHTMLElement;
++        {
 +            element = document.createElement('span') as WrappedHTMLElement;
              positioner = element;
--            positioner.style.position = 'relative';
--            
++            //positioner.style.position = 'relative';
++
              element.flexjs_wrapper = this;
              className = 'StringItemRenderer';
--            
++
              // itemRenderers should provide something for the background to handle
              // the selection and highlight
              backgroundView = element;
--            
++
              return element;
          }
  

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/Viewport.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/Viewport.as
index 285282a,285282a..a7ff82b
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/Viewport.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/Viewport.as
@@@ -32,10 -32,10 +32,15 @@@ package org.apache.flex.html.supportCla
      import org.apache.flex.geom.Size;
  	import org.apache.flex.html.beads.models.ScrollBarModel;
      import org.apache.flex.utils.CSSContainerUtils;
++	COMPILE::SWF
++	{
++		import flash.geom.Rectangle;
++	}
  
      /**
       * A Viewport is the area of a Container set aside for displaying
--     * content and any scrolling controls.
++     * content. If the content exceeds the visible area of the viewport
++	 * it will be clipped or hidden.
  	 *
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
@@@ -76,6 -76,6 +81,7 @@@
          /**
           * @flexjsignorecoercion Class
           */
++		COMPILE::SWF
  		public function set strand(value:IStrand):void
  		{
  			_strand = value;
@@@ -84,8 -84,8 +90,37 @@@
              {
                  var c:Class = ValuesManager.valuesImpl.getValue(_strand, 'iContentView') as Class;
                  contentArea = new c() as UIBase;
++				_strand.addBead(contentArea as IBead);
              }
  		}
++		
++		/**
++		 * @flexjsignorecoercion Class
++		 */
++		COMPILE::JS
++		public function set strand(value:IStrand):void
++		{
++			_strand = value;
++			
++			contentArea = _strand.getBeadByType(IContentView) as UIBase;
++			if (!contentArea)
++			{
++				var c:Class = ValuesManager.valuesImpl.getValue(_strand, 'iContentView') as Class;
++				if (c != null) {
++					var result:Object = new c();
++					if (result != null) {
++						contentArea = result as UIBase;
++						_strand.addBead(contentArea as IBead);
++					}
++				}
++			}
++			
++			if (contentArea == null) {
++				contentArea = value as UIBase;
++			}
++			
++			contentArea.element.style.overflow = "hidden";
++		}
  
          /**
           * @copy org.apache.flex.core.IViewport#setPosition()
@@@ -97,8 -97,8 +132,10 @@@
           */
          public function setPosition(x:Number, y:Number):void
          {
--            contentArea.x = x;
--            contentArea.y = y;
++			COMPILE::SWF {
++            	contentArea.x = x;
++            	contentArea.y = y;
++			}
          }
  
          /**
@@@ -111,10 -111,10 +148,12 @@@
           */
  		public function layoutViewportBeforeContentLayout(width:Number, height:Number):void
  		{
++			COMPILE::SWF {
  			if (!isNaN(width))
                  contentArea.width = width;
              if (!isNaN(height))
                  contentArea.height = height;
++			}
  		}
  
          /**
@@@ -125,26 -125,26 +164,17 @@@
  	     *  @playerversion AIR 2.6
  	     *  @productversion FlexJS 0.0
           */
--		public function layoutViewportAfterContentLayout():Size
++		public function layoutViewportAfterContentLayout(contentSize:Size):void
  		{
--            // pass through all of the children and determine the maxWidth and maxHeight
--            // note: this is not done on the JavaScript side because the browser handles
--            // this automatically.
--            var maxWidth:Number = 0;
--            var maxHeight:Number = 0;
--            var num:Number = contentArea.numElements;
--
--            for (var i:int=0; i < num; i++) {
--                var child:IUIBase = contentArea.getElementAt(i) as IUIBase;
--                if (child == null || !child.visible) continue;
--                var childXMax:Number = child.x + child.width;
--                var childYMax:Number = child.y + child.height;
--                maxWidth = Math.max(maxWidth, childXMax);
--                maxHeight = Math.max(maxHeight, childYMax);
--            }
--
--            var padding:Rectangle = CSSContainerUtils.getPaddingMetrics(this._strand);
--            return new Size(maxWidth + padding.right, maxHeight + padding.bottom);
++			COMPILE::SWF {
++				var hostWidth:Number = UIBase(_strand).width;
++				var hostHeight:Number = UIBase(_strand).height;
++				
++				var rect:flash.geom.Rectangle = new flash.geom.Rectangle(0, 0, hostWidth, hostHeight);
++				contentArea.scrollRect = rect;
++				
++				return;
++			}
  		}
  
  	}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Circle.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Circle.as
index 586bbfd,f76b5c8..8f9ae16
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Circle.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Circle.as
@@@ -15,9 -15,9 +15,11 @@@
  package org.apache.flex.svg
  {
  	import org.apache.flex.graphics.ICircle;
++    import org.apache.flex.graphics.IDrawable;
  
      COMPILE::SWF
      {
++        import flash.display.Graphics;
          import flash.geom.Point;
          import flash.geom.Rectangle;            
      }
@@@ -26,7 -26,7 +28,7 @@@
          import org.apache.flex.core.WrappedHTMLElement;
      }
  
--    public class Circle extends GraphicShape implements ICircle
++    public class Circle extends GraphicShape implements ICircle, IDrawable
      {
  		/**
  		 *  constructor.
@@@ -78,7 -78,7 +80,7 @@@
                  graphics.clear();
                  applyStroke();
                  beginFill(new Rectangle(cx,cy,radius*2, radius*2),new Point(cx-radius,cy-radius));
--                graphics.drawCircle(cx,cy,radius);
++                graphics.drawCircle(cx+radius,cy+radius,radius);
                  endFill();
              }
              COMPILE::JS                
@@@ -109,10 -109,10 +111,15 @@@
              }
          }
          
--        override protected function draw():void
++        override protected function drawImpl():void
          {
              drawCircle(0, 0, radius);
          }
++
++		public function draw():void
++		{
++			drawImpl();
++		}
          
      }
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/DOMWrapper.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/DOMWrapper.as
index d341cba,d341cba..c7ee326
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/DOMWrapper.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/DOMWrapper.as
@@@ -46,7 -46,7 +46,7 @@@ package org.apache.flex.sv
  			element.style.top = "0px";
  			//element.offsetParent = null;
  			positioner = element;
--			positioner.style.position = 'relative';
++			//positioner.style.position = 'relative';
  			
  			return element;
  		}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Ellipse.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Ellipse.as
index 2fb80bd,c2fbabc..b118d30
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Ellipse.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Ellipse.as
@@@ -18,6 -18,6 +18,7 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.svg
  {
++    import org.apache.flex.graphics.IDrawable;
  	import org.apache.flex.graphics.IEllipse;
  
      COMPILE::SWF
@@@ -30,7 -30,7 +31,7 @@@
          import org.apache.flex.core.WrappedHTMLElement;
      }
  
--    public class Ellipse extends GraphicShape implements IEllipse
++    public class Ellipse extends GraphicShape implements IEllipse, IDrawable
      {
  		/**
  		 *  constructor.
@@@ -68,7 -68,7 +69,7 @@@
  			_rx = value;
  		}
  
--		private var _ry:Number;
++ 		private var _ry:Number;
  
  		/**
  		 * The vertical radius of the ellipse.
@@@ -88,27 -88,7 +89,26 @@@
  			_ry = value;
  		}
  
 +        override public function get width():Number
 +        {
 +            return _rx*2;
 +        }
-         
++
 +        override public function set width(value:Number):void
 +        {
 +            _rx = value/2;
 +        }
-         
++
 +        override public function get height():Number
 +        {
 +            return _ry*2;
 +        }
-         
++
 +        override public function set height(value:Number):void
 +        {
 +            _ry = value/2;
 +        }
          
-         
          COMPILE::JS
          private var _ellipse:WrappedHTMLElement;
          
@@@ -116,8 -96,8 +116,6 @@@
           *  Draw the ellipse.
           *  @param xp The x position of the top-left corner of the bounding box of the ellipse.
           *  @param yp The y position of the top-left corner of the bounding box of the ellipse.
--         *  @param width The width of the ellipse.
--         *  @param height The height of the ellipse.
           *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
@@@ -163,10 -143,10 +161,15 @@@
              }
          }
          
--        override protected function draw():void
++        override protected function drawImpl():void
          {
--            drawEllipse(0, 0);    
++            drawEllipse(0, 0);
          }
++
++		public function draw():void
++		{
++			drawImpl();
++		}
          
      }
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/GraphicContainer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/GraphicContainer.as
index 37955f4,8e8498f..8bd841f
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/GraphicContainer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/GraphicContainer.as
@@@ -14,6 -14,6 +14,7 @@@
  package org.apache.flex.svg
  {
      import org.apache.flex.core.ContainerBase;
++    import org.apache.flex.core.IChild;
      import org.apache.flex.core.IFlexJSElement;
      import org.apache.flex.core.ITransformHost;
  
@@@ -21,7 -21,7 +22,6 @@@
  	{
  		import org.apache.flex.core.IContainer;
  		import org.apache.flex.core.UIBase;
--		import org.apache.flex.core.IChild;
  	}
  
  	[DefaultProperty("mxmlContent")]
@@@ -35,44 -35,39 +35,44 @@@
          }
  
      }
--	
++
  	COMPILE::JS
- 	public class GraphicContainer extends UIBase implements ITransformHost, IContainer
 -	public class GraphicContainer extends UIBase implements IContainer
++	public class GraphicContainer extends ContainerBase implements ITransformHost
  	{
  		private var graphicGroup:ContainerBase;
--		
++
  		public function GraphicContainer()
  		{
  			super();
  		}
--		
++
  		/**
  		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
  		 */
  		override protected function createElement():org.apache.flex.core.WrappedHTMLElement
  		{
  			element = document.createElementNS('http://www.w3.org/2000/svg', 'svg') as org.apache.flex.core.WrappedHTMLElement;
--			
++
  			positioner = element;
--			
++
  			// absolute positioned children need a non-null
  			// position value in the parent.  It might
  			// get set to 'absolute' if the container is
  			// also absolutely positioned
--			positioner.style.position = 'relative';
++			//positioner.style.position = 'relative';
  			element.flexjs_wrapper = this;
--			
++
  			graphicGroup = new GraphicGroup();
  			super.addElement(graphicGroup);
  			return element;
  		}
  
-         COMPILE::JS
-         override protected function setClassName(value:String):void
-         {
-             element.setAttribute('class', value);           
-         }
 -		
++		COMPILE::JS
++		override protected function setClassName(value:String):void
++		{
++			element.setAttribute('class', value);
++		}
 +
  		override public function get transformElement():org.apache.flex.core.WrappedHTMLElement
  		{
  			return graphicGroup.element;
@@@ -80,7 -75,7 +80,7 @@@
  
  		/**
  		 *  @copy org.apache.flex.core.IParent#getElementAt()
--		 * 
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -89,11 -84,11 +89,11 @@@
  		override public function getElementAt(index:int):IChild
  		{
  			return graphicGroup.getElementAt(index);
--		}        
--		
++		}
++
  		/**
  		 *  @copy org.apache.flex.core.IParent#addElement()
--		 * 
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -105,10 -100,10 +105,10 @@@
  			if (dispatchEvent)
  				this.dispatchEvent(new Event("childrenAdded"));
  		}
--		
++
  		/**
  		 *  @copy org.apache.flex.core.IParent#addElementAt()
--		 * 
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -120,10 -115,10 +120,10 @@@
  			if (dispatchEvent)
  				this.dispatchEvent(new Event("childrenAdded"));
  		}
--		
++
  		/**
  		 *  @copy org.apache.flex.core.IParent#removeElement()
--		 * 
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -135,23 -130,23 +135,10 @@@
  			if (dispatchEvent)
  				this.dispatchEvent(new Event("childrenRemoved"));
  		}
--		
--		/**
--		 *  @copy org.apache.flex.core.IContainer#childrenAdded()
--		 * 
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function childrenAdded():void
--		{
--			dispatchEvent(new Event("childrenAdded"));
--		}
--		
++
  		/**
  		 *  @copy org.apache.flex.core.IParent#getElementIndex()
--		 * 
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -161,11 -156,11 +148,11 @@@
  		{
  			return graphicGroup.getElementIndex(c);
  		}
--		
--		
++
++
  		/**
  		 *  The number of elements in the parent.
--		 * 
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -175,6 -170,6 +162,23 @@@
  		{
  			return graphicGroup.numElements;
  		}
++
++		COMPILE::JS
++        override public function set x(value:Number):void
++        {
++			super.x = value;
++			// Needed for SVG inside SVG
++			element.setAttribute("x", value);
++        }
++
++		COMPILE::JS
++        override public function set y(value:Number):void
++        {
++			super.y = value;
++			// Needed for SVG inside SVG
++			element.setAttribute("y", value);
++        }
++
  	}
  }
  
@@@ -189,21 -184,21 +193,21 @@@ class GraphicGroup extends ContainerBas
  	override protected function createElement():org.apache.flex.core.WrappedHTMLElement
  	{
  		element = document.createElementNS('http://www.w3.org/2000/svg', 'g') as org.apache.flex.core.WrappedHTMLElement;
--		
++
  		positioner = element;
--		
++
  		// absolute positioned children need a non-null
  		// position value in the parent.  It might
  		// get set to 'absolute' if the container is
  		// also absolutely positioned
--		positioner.style.position = 'relative';
++		//positioner.style.position = 'relative';
  		element.flexjs_wrapper = this;
--		
++
  		/*addEventListener('childrenAdded',
  		runLayoutHandler);
  		addEventListener('elementRemoved',
  		runLayoutHandler);*/
--		
++
  		return element;
  	}
--}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/GraphicShape.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/GraphicShape.as
index 0d5e860,eb1acc1..523bbe3
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/GraphicShape.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/GraphicShape.as
@@@ -16,14 -16,14 +16,18 @@@ package org.apache.flex.sv
  {
  	COMPILE::SWF
      {
--        import flash.geom.Point;
--        import flash.geom.Rectangle;
++		import flash.display.Graphics;
++		import flash.display.Sprite;
++		import flash.geom.Point;
++		import flash.geom.Rectangle;
++		import org.apache.flex.core.WrappedSprite;
      }
      COMPILE::JS
      {
          import org.apache.flex.core.WrappedHTMLElement;
      }
  
++    import org.apache.flex.core.IFlexJSElement;
  	import org.apache.flex.core.UIBase;
  	import org.apache.flex.graphics.IFill;
  	import org.apache.flex.graphics.IStroke;
@@@ -31,6 -31,6 +35,7 @@@
  
  	public class GraphicShape extends UIBase implements IGraphicShape
  	{
++
  		private var _fill:IFill;
  		private var _stroke:IStroke;
  
@@@ -78,7 -78,7 +83,7 @@@
          {
  			super();
          }
--		
++
  		/**
  		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
  		 */
@@@ -87,12 -87,12 +92,10 @@@
  		{
  			element = document.createElementNS('http://www.w3.org/2000/svg', 'svg') as WrappedHTMLElement;
  			element.flexjs_wrapper = this;
--			element.style.left = "0px";
--			element.style.top = "0px";
  			//element.offsetParent = null;
  			positioner = element;
--			positioner.style.position = 'relative';
--			
++			//positioner.style.position = 'relative';
++
  			return element;
  		}
  
@@@ -127,18 -127,18 +130,15 @@@
  		/**
  		 * This is where the drawing methods get called from
  		 */
--		protected function draw():void
++		protected function drawImpl():void
  		{
  			//Overwrite in subclass
  		}
  
  		override public function addedToParent():void
  		{
--            COMPILE::SWF
--            {
--                super.addedToParent();
--            }
--			draw();
++            super.addedToParent();
++			drawImpl();
              COMPILE::JS
              {
                  element.style.overflow = 'visible';
@@@ -175,11 -175,6 +175,12 @@@
              return fillStr + ';' + strokeStr;
          }
  
-         COMPILE::JS
-         override protected function setClassName(value:String):void
-         {
-             element.setAttribute('class', value);           
-         }
++		COMPILE::JS
++		override protected function setClassName(value:String):void
++		{
++			element.setAttribute('class', value);
++		}
++
  
          /**
           * @param x X position.
@@@ -195,8 -190,8 +196,14 @@@
              element.style.position = 'absolute';
              if (!isNaN(x)) element.style.top = x + "px";
              if (!isNaN(y)) element.style.left = y + "px";
++			// element.setAttribute("width", useWidth);
++			// element.setAttribute("height", useHeight);
              element.style.width = useWidth;
              element.style.height = useHeight;
++			// Needed for SVG inside SVG
++			element.setAttribute("x", x);
++			element.setAttribute("y", y);
++			//Needed for SVG inside DOM elements
              element.style.left = x + "px";
              element.style.top = y + "px";
          }
@@@ -223,6 -218,6 +230,10 @@@
              _y = y;
              _xOffset = xOffset;
              _yOffset = yOffset;
++			// Needed for SVG inside SVG
++			element.setAttribute("x", xOffset);
++			element.setAttribute("y", yOffset);
++			//Needed for SVG inside DOM elements
              element.style.left = xOffset + "px";
              element.style.top = yOffset + "px";
          }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Image.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Image.as
index cd0729f,cd0729f..6f660ce
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Image.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Image.as
@@@ -47,7 -47,7 +47,7 @@@ package org.apache.flex.sv
  			element.setAttribute('y', 0);
  			//element.offsetParent = null;
  			positioner = element;
--			positioner.style.position = 'relative';
++			//positioner.style.position = 'relative';
  			addImageElement();
  			return element;
  		}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Path.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Path.as
index fe6b74a,fe6b74a..126a437
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Path.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Path.as
@@@ -14,6 -14,6 +14,7 @@@
  
  package org.apache.flex.svg
  {
++    import org.apache.flex.graphics.IDrawable;
      import org.apache.flex.graphics.IPath;
      import org.apache.flex.graphics.PathBuilder;
  
@@@ -30,7 -30,7 +31,7 @@@
      }
  
  
--    public class Path extends GraphicShape implements IPath
++    public class Path extends GraphicShape implements IPath, IDrawable
      {
  
          private var _data:String;
@@@ -125,9 -125,9 +126,14 @@@
              }
          }
  
--        override protected function draw():void
++        override protected function drawImpl():void
          {
              drawStringPath(0, 0, data);
          }
++
++		public function draw():void
++		{
++			drawImpl();
++		}
      }
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Rect.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Rect.as
index 2426230,64f888d..6cacf41
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Rect.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Rect.as
@@@ -14,6 -14,6 +14,7 @@@
  
  package org.apache.flex.svg
  {
++    import org.apache.flex.graphics.IDrawable;
  	import org.apache.flex.graphics.IRect;
  
      COMPILE::SWF
@@@ -26,7 -26,7 +27,7 @@@
          import org.apache.flex.core.WrappedHTMLElement;
      }
  
--	public class Rect extends GraphicShape implements IRect
++	public class Rect extends GraphicShape implements IRect, IDrawable
  	{
  		/**
  		 *  constructor.
@@@ -111,12 -111,12 +112,12 @@@
                  applyStroke();
                  beginFill(new Rectangle(xp, yp, width, height), new Point(xp,yp));
                  if(isNaN(rx))
--                    graphics.drawRect(x, y, width, height);
++                    graphics.drawRect(0, 0, width, height);
                  else
                  {
                      var dx:Number = rx*2;
                      var dy:Number = isNaN(ry) ? ry : ry*2;
--                    graphics.drawRoundRect(x, y, width, height,dx ,dy);
++                    graphics.drawRoundRect(0, 0, width, height,dx ,dy);
                  }
                  endFill();                    
              }
@@@ -147,16 -147,10 +148,21 @@@
              }
  		}
  		
-         COMPILE::JS
-         override public function get transformElement():WrappedHTMLElement
-         {
-             return _rect;
-         }
 -		override protected function draw():void
++		COMPILE::JS
++		override public function get transformElement():WrappedHTMLElement
++		{
++			return _rect;
++		}
 +
- 		override protected function draw():void
++		override protected function drawImpl():void
  		{
  			drawRect(0,0,width,height);
  		}
++
++		public function draw():void
++		{
++			drawImpl();
++		}
  		
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Text.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Text.as
index 767de41,278dcc0..7b22aab
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Text.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/svg/Text.as
@@@ -18,6 -18,6 +18,7 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.svg
  {
++    import org.apache.flex.graphics.IDrawable;
  	import org.apache.flex.graphics.IText;
  	import org.apache.flex.graphics.SolidColor;
  
@@@ -32,7 -32,7 +33,7 @@@
      }
  	
  	/**
--	 *  Draws a string of characters at a specific location using the stroke
++	 *  Draws a string of characters at a specific location using the fill
  	 *  value of color and alpha.
  	 *
  	 *  @langversion 3.0
@@@ -42,7 -42,7 +43,7 @@@
       *  // TODO (aharui) ignore imports of external linkage interfaces?
       *  @flexjsignoreimport SVGLocatable
  	 */
--	public class Text extends GraphicShape implements IText
++	public class Text extends GraphicShape implements IText, IDrawable
  	{
  		/**
  		 *  constructor.
@@@ -59,7 -59,7 +60,7 @@@
              COMPILE::SWF
              {
                  _textField = new CSSTextField();
--                addChild(_textField);                    
++                addChild(_textField);
              }
  		}
  		
@@@ -140,11 -149,11 +150,15 @@@
              }
  		}
          
--        COMPILE::JS
--        override protected function draw():void
++        override protected function drawImpl():void
          {
-             
 -            drawText(text, x, y);
++            drawText(text,x,y);
          }
  
++		public function draw():void
++		{
++			drawImpl();
++		}
++
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/resources/basic-manifest.xml
index 02a707d,072aed9..7dbe764
--- a/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/Basic/src/main/resources/basic-manifest.xml
@@@ -42,9 -39,9 +41,13 @@@
      <component id="List" class="org.apache.flex.html.List"/>
      <component id="SimpleList" class="org.apache.flex.html.SimpleList"/>
      <component id="CheckBox" class="org.apache.flex.html.CheckBox"/>
++    <component id="CSSCheckBox" class="org.apache.flex.html.CSSCheckBox"/>
      <component id="RadioButton" class="org.apache.flex.html.RadioButton"/>
      <component id="ComboBox" class="org.apache.flex.html.ComboBox"/>
++    <component id="ComboBoxList" class="org.apache.flex.html.supportClasses.ComboBoxList"/>
      <component id="Container" class="org.apache.flex.html.Container"/>
++    <component id="Group" class="org.apache.flex.html.Group"/>
++    <component id="Accordion" class="org.apache.flex.html.Accordion"/>
      <component id="Form" class="org.apache.flex.html.Form"/>
      <component id="HContainer" class="org.apache.flex.html.HContainer"/>
      <component id="VContainer" class="org.apache.flex.html.VContainer"/>
@@@ -61,35 -59,28 +65,41 @@@
      <component id="Tree" class="org.apache.flex.html.Tree"/>
      <component id="BasicLayout" class="org.apache.flex.html.beads.layouts.BasicLayout"/>
      <component id="VerticalLayout" class="org.apache.flex.html.beads.layouts.VerticalLayout"/>
++    <component id="VerticalFlexLayout" class="org.apache.flex.html.beads.layouts.VerticalFlexLayout"/>
      <component id="HorizontalLayout" class="org.apache.flex.html.beads.layouts.HorizontalLayout"/>
++    <component id="HorizontalFlexLayout" class="org.apache.flex.html.beads.layouts.HorizontalFlexLayout"/>
 +    <component id="HorizontalFlowLayout" class="org.apache.flex.html.beads.layouts.HorizontalFlowLayout" />
      <component id="TileLayout" class="org.apache.flex.html.beads.layouts.TileLayout"/>
      <component id="ListView" class="org.apache.flex.html.beads.ListView"/>
 +    <component id="AccordionView" class="org.apache.flex.html.beads.AccordionView"/>
- <!--<component id="MultilineTextFieldView" class="org.apache.flex.html.beads.MultilineTextFieldView"/>-->
-     
++    <component id="CenterElement" class="org.apache.flex.html.beads.CenterElement"/>
+     <!--<component id="MultilineTextFieldView" class="org.apache.flex.html.beads.MultilineTextFieldView"/>-->
 -    
++
      <component id="SimpleAlert" class="org.apache.flex.html.SimpleAlert"/>
      <component id="Alert" class="org.apache.flex.html.Alert"/>
      <component id="Spinner" class="org.apache.flex.html.Spinner"/>
      <component id="Slider" class="org.apache.flex.html.Slider"/>
      <component id="NumericStepper" class="org.apache.flex.html.NumericStepper" />
      <component id="StringItemRenderer" class="org.apache.flex.html.supportClasses.StringItemRenderer"/>
 +    <component id="AccordionItemRenderer" class="org.apache.flex.html.supportClasses.AccordionItemRenderer"/>
 +    <component id="AccordionCollapseBead" class="org.apache.flex.html.beads.AccordionCollapseBead"/>
++    <component id="DispatchInputFinishedBead" class="org.apache.flex.html.beads.DispatchInputFinishedBead"/>
++    <component id="DispatchKeyboardEventBead" class="org.apache.flex.html.beads.DispatchKeyboardEventBead"/>
      <component id="TreeItemRenderer" class="org.apache.flex.html.supportClasses.TreeItemRenderer"/>
-     <component id="MXMLItemRenderer" class="org.apache.flex.html.supportClasses.MXMLItemRenderer"/>
      <component id="DataItemRenderer" class="org.apache.flex.html.supportClasses.DataItemRenderer"/>
++    <component id="MXMLItemRenderer" class="org.apache.flex.html.supportClasses.MXMLItemRenderer"/>
      <component id="ButtonBarButtonItemRenderer" class="org.apache.flex.html.supportClasses.ButtonBarButtonItemRenderer"/>
 +    <component id="DateItemRenderer" class="org.apache.flex.html.supportClasses.DateItemRenderer"/>
 +    <component id="DayNameItemRenderer" class="org.apache.flex.html.supportClasses.DayNameItemRenderer"/>
- 
      <!--
       <component id="TextFieldItemRenderer" class="org.apache.flex.html.supportClasses.TextFieldItemRenderer"/>
--    <component id="HScrollBar" class="org.apache.flex.html.supportClasses.HScrollBar"/>
--    <component id="VScrollBar" class="org.apache.flex.html.supportClasses.VScrollBar"/>
++     <component id="HScrollBar" class="org.apache.flex.html.supportClasses.HScrollBar"/>
++     <component id="VScrollBar" class="org.apache.flex.html.supportClasses.VScrollBar"/>
       <component id="HRuleView" class="org.apache.flex.html.beads.HRuleView" />
       <component id="VRuleView" class="org.apache.flex.html.beads.VRuleView" />
       -->
+     <component id="UnselectableElementBead" class="org.apache.flex.html.beads.UnselectableElementBead"/>
++    <component id="DisableBead" class="org.apache.flex.html.beads.DisableBead" />
      <component id="NumericOnlyTextInputBead" class="org.apache.flex.html.accessories.NumericOnlyTextInputBead" />
      <component id="PasswordInputBead" class="org.apache.flex.html.accessories.PasswordInputBead" />
      <component id="TextPromptBead" class="org.apache.flex.html.accessories.TextPromptBead" />
@@@ -97,24 -88,23 +107,25 @@@
      <component id="VRule" class="org.apache.flex.html.VRule" />
      <component id="Spacer" class="org.apache.flex.html.Spacer" />
      <!--
--    <component id="ImageAndTextButtonView" class="org.apache.flex.html.beads.ImageAndTextButtonView" />
++     <component id="ImageAndTextButtonView" class="org.apache.flex.html.beads.ImageAndTextButtonView" />
       -->
      <component id="ScrollingViewport" class="org.apache.flex.html.supportClasses.ScrollingViewport" />
 -    
 +    <component id="ClippingViewport" class="org.apache.flex.html.supportClasses.ClippingViewport" />
-     
++
      <component id="ArraySelectionModel" class="org.apache.flex.html.beads.models.ArraySelectionModel" />
      <component id="ArrayListSelectionModel" class="org.apache.flex.html.beads.models.ArrayListSelectionModel" />
  
      <component id="DataGrid" class="org.apache.flex.html.DataGrid"/>
      <component id="DataProviderChangeNotifier" class="org.apache.flex.html.beads.DataProviderChangeNotifier"/>
++    <component id="DataProviderCollectionChangeNotifier" class="org.apache.flex.html.beads.DataProviderCollectionChangeNotifier"/>
++    <component id="DataProviderItemsChangeNotifier" class="org.apache.flex.html.beads.DataProviderItemsChangeNotifier"/>
      <component id="DataGridButtonBar" class="org.apache.flex.html.DataGridButtonBar"/>
      <component id="DataGridButtonBarTextButton" class="org.apache.flex.html.DataGridButtonBarTextButton"/>
      <component id="DataGridColumn" class="org.apache.flex.html.supportClasses.DataGridColumn"/>
      <component id="DataGridLinesBead" class="org.apache.flex.html.beads.DataGridLinesBead"/>
      <component id="DataGridColumnList" class="org.apache.flex.html.supportClasses.DataGridColumnList"/>
--    <component id="DataGridLayout" class="org.apache.flex.html.beads.layouts.DataGridLayout" />
--    <component id="DataGridPercentageLayout" class="org.apache.flex.html.beads.layouts.DataGridPercentageLayout" />
--    
++    <component id="DataGridPercentageView" class="org.apache.flex.html.beads.DataGridPercentageView" />
++
      <component id="DataItemRendererFactoryForArrayData" class="org.apache.flex.html.beads.DataItemRendererFactoryForArrayData" />
      <component id="DataItemRendererFactoryForArrayList" class="org.apache.flex.html.beads.DataItemRendererFactoryForArrayList" />
      <component id="DataItemRendererFactoryForHierarchicalData" class="org.apache.flex.html.beads.DataItemRendererFactoryForHierarchicalData" />
@@@ -122,11 -112,8 +133,10 @@@
      <component id="TextItemRendererFactoryForStringVectorData" class="org.apache.flex.html.beads.TextItemRendererFactoryForStringVectorData" />
  
      <component id="DateChooser" class="org.apache.flex.html.DateChooser"/>
 +    <component id="DateChooserList" class="org.apache.flex.html.supportClasses.DateChooserList" />
 +    <component id="DateChooserHeader" class="org.apache.flex.html.supportClasses.DateChooserHeader" />
      <component id="DateField" class="org.apache.flex.html.DateField"/>
      <component id="VerticalColumnLayout" class="org.apache.flex.html.beads.layouts.VerticalColumnLayout" />
-     <component id="ComboBoxList" class="org.apache.flex.html.supportClasses.ComboBoxList" />
  
      <component id="ToolTipBead" class="org.apache.flex.html.accessories.ToolTipBead" />
  
@@@ -137,10 -123,9 +147,11 @@@
      <component id="OneFlexibleChildVerticalLayout" class="org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout"/>
      <component id="OneFlexibleChildHorizontalLayout" class="org.apache.flex.html.beads.layouts.OneFlexibleChildHorizontalLayout"/>
      <component id="MXMLBeadView" class="org.apache.flex.html.MXMLBeadView"/>
-     <component id="DisableBead" class="org.apache.flex.html.beads.DisableBead"/>
+ 
++    <component id="SubAppLoader" class="org.apache.flex.html.SubAppLoader" />
 +
      <component id="Border" class="org.apache.flex.html.supportClasses.Border"/>
--    
++
      <component id="WebBrowser" class="org.apache.flex.html.WebBrowser" />
  
  </componentPackage>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/resources/defaults.css
index b27bc0b,431c564..9ecea43
--- a/frameworks/projects/Basic/src/main/resources/defaults.css
+++ b/frameworks/projects/Basic/src/main/resources/defaults.css
@@@ -34,40 -34,15 +34,49 @@@
      box-sizing: border-box;
  }
  
 +Accordion
 +{
 +	IBeadModel: ClassReference("org.apache.flex.html.beads.models.ArraySelectionModel");
 +	IBeadView:  ClassReference("org.apache.flex.html.beads.AccordionView");			
 +	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController");
 +	IBeadLayout: ClassReference("org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout");
 +	IContentView: ClassReference("org.apache.flex.html.supportClasses.DataGroup");
 +	IDataProviderItemRendererMapper: ClassReference("org.apache.flex.html.beads.DataItemRendererFactoryForArrayData");
 +	IItemRendererClassFactory: ClassReference("org.apache.flex.core.ItemRendererClassFactory");
 +	IItemRenderer: ClassReference("org.apache.flex.html.supportClasses.AccordionItemRenderer");
 +	IViewport: ClassReference("org.apache.flex.html.supportClasses.ClippingViewport");
 +	IViewportModel: ClassReference("org.apache.flex.html.beads.models.ViewportModel");
 +	IAccordionCollapseBead: ClassReference("org.apache.flex.html.beads.AccordionCollapseBead");
 +	border-style: solid;
 +	border-color: #222222;
 +}
 +
 +AccordionItemRenderer
 +{
 +	IBeadController: ClassReference("org.apache.flex.html.beads.controllers.AccordionItemRendererMouseController");
 +	IBeadView: ClassReference("org.apache.flex.html.beads.AccordionItemRendererView");
 +}
 +
 +Alert
 +{
 +    IBeadModel: ClassReference("org.apache.flex.html.beads.models.AlertModel");
 +       
 +    background-color: #FFFFFF;
 +    border-style: solid;
 +    border-color: #000000;
 +    border-width: 1px;
 +}
 +
 +
+ .unselectable
+ {
+     -moz-user-select: -moz-none;
+     -khtml-user-select: none;
+     -webkit-user-select: none;
+     -o-user-select: none;
+     user-select: none;
+ }
+ 
  Application
  {
  	padding: 0px;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Express/src/main/flex/org/apache/flex/express/TextButton.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Express/src/main/flex/org/apache/flex/express/TextButton.as
index 53e6ffd,286f0eb..38f33f1
--- a/frameworks/projects/Express/src/main/flex/org/apache/flex/express/TextButton.as
+++ b/frameworks/projects/Express/src/main/flex/org/apache/flex/express/TextButton.as
@@@ -60,29 -62,30 +64,54 @@@ package org.apache.flex.expres
  			dispatchEvent(new Event("enabledChanged"));
  		}
  		
 +		[Bindable("enabledChanged")]
 +		/**
 +		 * Can enable or disable interaction with the control.
 +		 */
 +		COMPILE::SWF
 +		override public function get enabled():Boolean
 +		{
 +			return _enabled;
 +		}
 +		COMPILE::SWF
 +		override public function set enabled(value:Boolean):void
 +		{
 +			_enabled = value;
 +			
 +			if (_disableBead == null) {
 +				_disableBead = new DisableBead();
 +				addBead(_disableBead);
 +			}
 +			
 +			_disableBead.disabled = !value;
 +				
 +			dispatchEvent(new Event("enabledChanged"));
 +		}
 +
+ 		[Bindable("toolTipChanged")]
+ 		/**
+ 		 * Displays a hint when the mouse hovers over the button
+ 		 */
+ 		public function get toolTip():String
+ 		{
+ 			if (_toolTipBead) {
+ 				return _toolTipBead.toolTip;
+ 			}
+ 			else {
+ 				return null;
+ 			}
+ 		}
+ 		public function set toolTip(value:String):void
+ 		{
+ 			_toolTipBead = getBeadByType(ToolTipBead) as ToolTipBead;
+ 			
+ 			if (_toolTipBead == null) {
+ 				_toolTipBead = new ToolTipBead();
+ 				addBead(_toolTipBead);
+ 			}
+ 			_toolTipBead.toolTip = value;
+ 			
+ 			dispatchEvent(new Event("toolTipChanged"));
+ 		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Graphics/build.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/Graphics/build.xml
index 51c89ad,01cbeb5..08dd3bb
--- a/frameworks/projects/Graphics/build.xml
+++ b/frameworks/projects/Graphics/build.xml
@@@ -74,28 -74,23 +74,29 @@@
          <echo message="Compiling libs/${ant.project.name}.swc"/>
          <echo message="FLEX_HOME: ${FLEX_HOME}"/>
          <echo message="FALCON_HOME: ${FALCON_HOME}"/>
 +        <echo message="FALCONJX_HOME: ${FALCONJX_HOME}"/>
          
 -        <compc fork="true"
 -            output="${basedir}/target/${target.name}">
 -            <jvmarg line="${compc.jvm.args}"/>
 -            <load-config filename="${basedir}/src/main/config/compile-as-config.xml" />
 +        <java jar="${FALCONJX_HOME}/lib/compc.jar" fork="true" >
 +            <jvmarg value="-Xmx384m" />
 +            <jvmarg value="-Dsun.io.useCanonCaches=false" />
 +            <jvmarg value="-Dflexcompiler=${FALCONJX_HOME}/../compiler" />
 +            <jvmarg value="-Dflexlib=${FLEXJS_HOME}/frameworks" />
 +            <arg value="+flexlib=${FLEX_HOME}/frameworks" />
              <arg value="+playerglobal.version=${playerglobal.version}" />
              <arg value="+env.AIR_HOME=${env.AIR_HOME}" />
 -            <arg value="-define=COMPILE::SWF,true" />
 -            <arg value="-define=COMPILE::JS,false" />
 +            <arg value="-compiler.strict-xml=true" />
 +            <arg value="-compiler.targets=SWF,JSFlex" />
 +            <arg value="-output=${basedir}/target/${target.name}" />
 +            <arg value="-load-config=${basedir}/src/main/config/compile-swf-config.xml" />
 +            <arg value="-js-load-config=${FLEX_HOME}/frameworks/js-config.xml" />
 +            <arg value="-js-load-config+=${basedir}/../../js/FlexJS/projects/${ant.project.name}JS/src/main/config/compile-js-config.xml" />
+             <arg value="-compiler.byte-array-embed-class=org.apache.flex.core.ByteArrayAsset" />
 -        </compc>
 -        <copy file="${basedir}/target/${target.name}" tofile="${FLEXJS_HOME}/frameworks/libs/${target.name}" />
 +        </java>
      </target>
      
 -    <target name="check-compiler" depends="check-falcon-home">
 +    <target name="check-compiler" depends="check-falcon-home,check-falconjx-home">
          <path id="lib.path">
 -            <fileset dir="${FALCON_HOME}/lib" includes="falcon-flexTasks.jar"/>
 +            <fileset dir="${FALCONJX_HOME}/lib" includes="falcon-flexTasks.jar"/>
          </path>
          <taskdef resource="flexTasks.tasks" classpathref="lib.path"/>
      </target>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Graphics/pom.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/Graphics/pom.xml
index 4689a76,4c89405..912d678
--- a/frameworks/projects/Graphics/pom.xml
+++ b/frameworks/projects/Graphics/pom.xml
@@@ -54,7 -109,7 +109,8 @@@
            <includeClasses>
              <includeClass>GraphicsClasses</includeClass>
            </includeClasses>
 +          <skipExtern>true</skipExtern>
+           <additionalCompilerOptions>-compiler.byte-array-embed-class=org.apache.flex.core.ByteArrayAsset</additionalCompilerOptions>
          </configuration>
        </plugin>
      </plugins>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Graphics/src/main/config/compile-swf-config.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/Graphics/src/main/config/compile-swf-config.xml
index 97799ad,0000000..fdbf2a6
mode 100644,000000..100644
--- a/frameworks/projects/Graphics/src/main/config/compile-swf-config.xml
+++ b/frameworks/projects/Graphics/src/main/config/compile-swf-config.xml
@@@ -1,91 -1,0 +1,92 @@@
 +<!--
 +
 +  Licensed to the Apache Software Foundation (ASF) under one or more
 +  contributor license agreements.  See the NOTICE file distributed with
 +  this work for additional information regarding copyright ownership.
 +  The ASF licenses this file to You under the Apache License, Version 2.0
 +  (the "License"); you may not use this file except in compliance with
 +  the License.  You may obtain a copy of the License at
 +
 +      http://www.apache.org/licenses/LICENSE-2.0
 +
 +  Unless required by applicable law or agreed to in writing, software
 +  distributed under the License is distributed on an "AS IS" BASIS,
 +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +  See the License for the specific language governing permissions and
 +  limitations under the License.
 +
 +-->
 +<flex-config>
 +
 +    <compiler>
 +        <accessible>false</accessible>
 +        
 +        <external-library-path>
 +            <path-element>${env.AIR_HOME}/frameworks/libs/air/airglobal.swc</path-element>
 +            <path-element>../../../../../libs/Core.swc</path-element>
 +        </external-library-path>
 +        
 +		<mxml>
 +			<children-as-data>true</children-as-data>
 +		</mxml>
 +		<binding-value-change-event>org.apache.flex.events.ValueChangeEvent</binding-value-change-event>
 +		<binding-value-change-event-kind>org.apache.flex.events.ValueChangeEvent</binding-value-change-event-kind>
 +		<binding-value-change-event-type>valueChange</binding-value-change-event-type>
++		<byte-array-embed-class>org.apache.flex.core.ByteArrayAsset</byte-array-embed-class>
 +
 +        <define>
 +            <name>COMPILE::SWF</name>
 +            <value>true</value>
 +        </define>
 +        <define>
 +            <name>COMPILE::JS</name>
 +            <value>false</value>
 +        </define>
 +
 +        <keep-as3-metadata>
 +          <name>Bindable</name>
 +          <name>Managed</name>
 +          <name>ChangeEvent</name>
 +          <name>NonCommittingChangeEvent</name>
 +          <name>Transient</name>
 +        </keep-as3-metadata>
 +	  
 +        <locale/>
 +        
 +        <library-path/>
 +
 +        <namespaces>
 +            <namespace>
 +                <uri>library://ns.apache.org/flexjs/basic</uri>
 +                <manifest>../resources/basic-manifest.xml</manifest>
 +            </namespace>
 +            <namespace>
 +                <uri>library://ns.apache.org/flexjs/svg</uri>
 +                <manifest>../resources/svg-manifest.xml</manifest>
 +            </namespace>
 +        </namespaces>
 +        
 +        <source-path>
 +            <path-element>../flex</path-element>
 +        </source-path>
 +        
 +        <warn-no-constructor>false</warn-no-constructor>
 +    </compiler>
 +    
 +    <include-file>
 +        <name>defaults.css</name>
 +        <path>../resources/defaults.css</path>
 +    </include-file>
 +    
 +    <include-classes>
 +        <class>GraphicsClasses</class>
 +    </include-classes>
 +    
 +    <include-namespaces>
 +        <uri>library://ns.apache.org/flexjs/basic</uri>
 +    </include-namespaces>
 +        
 +    <target-player>${playerglobal.version}</target-player>
 +	
 +
 +</flex-config>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/HTML/src/main/flex/HTMLClasses.as
----------------------------------------------------------------------
diff --cc frameworks/projects/HTML/src/main/flex/HTMLClasses.as
index bf64031,0e7e052..0cf5594
--- a/frameworks/projects/HTML/src/main/flex/HTMLClasses.as
+++ b/frameworks/projects/HTML/src/main/flex/HTMLClasses.as
@@@ -26,8 -26,202 +26,8 @@@ packag
   *  from the classes specified in manifest.xml.
   */
  internal class HTMLClasses
 -{	
 -    import org.apache.flex.html.ToolTip; ToolTip;
 -	import org.apache.flex.html.accessories.NumericOnlyTextInputBead; NumericOnlyTextInputBead;
 -	import org.apache.flex.html.beads.DispatchInputFinishedBead; DispatchInputFinishedBead;
 -	import org.apache.flex.html.accessories.PasswordInputBead; PasswordInputBead;
 -	import org.apache.flex.html.accessories.TextPromptBead; TextPromptBead;
 -    import org.apache.flex.html.beads.AlertView; AlertView;
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.BackgroundImageBead; BackgroundImageBead;
 -	}
 -	import org.apache.flex.html.beads.ButtonBarView; ButtonBarView;
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.CheckBoxView; CheckBoxView;
 -	}
 -	import org.apache.flex.html.beads.ComboBoxView; ComboBoxView;
 -    import org.apache.flex.html.beads.ContainerView; ContainerView;
 -	import org.apache.flex.html.beads.GroupView; GroupView;
 -	COMPILE::SWF
 -	{
 -	    import org.apache.flex.html.beads.ControlBarMeasurementBead; ControlBarMeasurementBead;
 -	    import org.apache.flex.html.beads.CSSButtonView; CSSButtonView;
 -	    import org.apache.flex.html.beads.CSSImageAndTextButtonView; CSSImageAndTextButtonView;
 -		import org.apache.flex.html.beads.CSSTextButtonView; CSSTextButtonView;
 -	    import org.apache.flex.html.beads.CSSTextToggleButtonView; CSSTextToggleButtonView;
 -		import org.apache.flex.html.beads.DropDownListView; DropDownListView;
 -		import org.apache.flex.html.beads.CloseButtonView; CloseButtonView;
 -    	import org.apache.flex.html.beads.ImageAndTextButtonView; ImageAndTextButtonView;
 -	}
 -	import org.apache.flex.html.beads.ImageView; org.apache.flex.html.beads.ImageView;
 -	import org.apache.flex.html.beads.BinaryImageLoader; BinaryImageLoader;
 -	import org.apache.flex.html.beads.models.BinaryImageModel; BinaryImageModel;
 -	import org.apache.flex.html.beads.ImageButtonView; ImageButtonView;
 -	import org.apache.flex.html.beads.ListView; ListView;
 -	COMPILE::SWF
 -	{
 -	    import org.apache.flex.html.beads.NumericStepperView; NumericStepperView;
 -	}
 -	import org.apache.flex.html.beads.PanelView; PanelView;
 -	import org.apache.flex.html.supportClasses.PanelLayoutProxy; PanelLayoutProxy;
 -	import org.apache.flex.html.beads.PanelWithControlBarView; PanelWithControlBarView;
 -	import org.apache.flex.html.beads.AccordionItemRendererView; AccordionItemRendererView;
 -	import org.apache.flex.html.beads.SliderView; SliderView;
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.RadioButtonView; RadioButtonView;
 -		import org.apache.flex.html.beads.VScrollBarView; VScrollBarView;
 -		import org.apache.flex.html.beads.HScrollBarView; HScrollBarView;
 -    	import org.apache.flex.html.beads.ScrollBarView; ScrollBarView;
 -		import org.apache.flex.html.beads.SliderThumbView; SliderThumbView;
 -		import org.apache.flex.html.beads.SliderTrackView; SliderTrackView;
 -		import org.apache.flex.html.beads.SimpleAlertView; SimpleAlertView;
 -    	import org.apache.flex.html.beads.SingleLineBorderBead; SingleLineBorderBead;
 -		import org.apache.flex.html.beads.SingleLineBorderWithChangeListenerBead; SingleLineBorderWithChangeListenerBead;
 -	}
 -	import org.apache.flex.html.beads.SpinnerView; SpinnerView;
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.SolidBackgroundBead; SolidBackgroundBead;
 -		import org.apache.flex.html.beads.SolidBackgroundWithChangeListenerBead; SolidBackgroundWithChangeListenerBead;
 -    	import org.apache.flex.html.beads.TextButtonMeasurementBead; TextButtonMeasurementBead;
 -		import org.apache.flex.html.beads.TextFieldLabelMeasurementBead; TextFieldLabelMeasurementBead;
 -    	import org.apache.flex.html.beads.TextAreaView; TextAreaView;
 -    	import org.apache.flex.html.beads.TextButtonView; TextButtonView;
 -    	import org.apache.flex.html.beads.TextFieldView; TextFieldView;
 -    	import org.apache.flex.html.beads.TextInputView; TextInputView;
 -	    import org.apache.flex.html.beads.TextInputWithBorderView; TextInputWithBorderView;
 -	    import org.apache.flex.html.beads.models.AlertModel; AlertModel;
 -	}
 -	import org.apache.flex.html.beads.models.AlertModel; AlertModel;
 -	import org.apache.flex.html.beads.models.ArraySelectionModel; ArraySelectionModel;
 -	import org.apache.flex.html.beads.models.ArrayListSelectionModel; ArrayListSelectionModel;
 -    import org.apache.flex.html.beads.models.RangeModel; RangeModel;
 -    import org.apache.flex.html.beads.models.RangeModelExtended; RangeModelExtended;
 -	import org.apache.flex.html.beads.models.ComboBoxModel; ComboBoxModel;
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.models.ImageModel; ImageModel;
 -	    import org.apache.flex.html.beads.models.ImageAndTextModel; ImageAndTextModel;
 -	}
 -	import org.apache.flex.html.beads.models.PanelModel; PanelModel;
 -	COMPILE::SWF
 -	{
 -	    import org.apache.flex.html.beads.models.SingleLineBorderModel; SingleLineBorderModel;
 -	}
 -	import org.apache.flex.html.beads.models.TextModel; TextModel;
 -    import org.apache.flex.html.beads.models.TitleBarModel; TitleBarModel;
 -	import org.apache.flex.html.beads.models.ToggleButtonModel; ToggleButtonModel;
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.models.ValueToggleButtonModel; ValueToggleButtonModel;
 -	}
 -	import org.apache.flex.html.beads.models.ViewportModel; ViewportModel;
 -	COMPILE::SWF
 -	{
 -	    import org.apache.flex.html.beads.controllers.AlertController; AlertController;
 -    	import org.apache.flex.html.beads.controllers.DropDownListController; DropDownListController;
 -		import org.apache.flex.html.beads.controllers.EditableTextKeyboardController; EditableTextKeyboardController;
 -	}
 -	import org.apache.flex.html.beads.controllers.ComboBoxController; ComboBoxController;
 -	import org.apache.flex.html.beads.controllers.AccordionItemRendererMouseController; AccordionItemRendererMouseController;
 -    import org.apache.flex.html.beads.controllers.ItemRendererMouseController; ItemRendererMouseController;
 -    import org.apache.flex.html.beads.controllers.ListSingleSelectionMouseController; ListSingleSelectionMouseController;
 -	import org.apache.flex.html.beads.controllers.TreeSingleSelectionMouseController; TreeSingleSelectionMouseController;
 -	import org.apache.flex.html.beads.controllers.SliderMouseController; SliderMouseController;
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.controllers.SpinnerMouseController; SpinnerMouseController;
 -	    import org.apache.flex.html.beads.controllers.VScrollBarMouseController; VScrollBarMouseController;
 -		import org.apache.flex.html.beads.controllers.HScrollBarMouseController; HScrollBarMouseController;
 -	}
 -	import org.apache.flex.html.beads.layouts.ButtonBarLayout; ButtonBarLayout;
 -    import org.apache.flex.html.beads.layouts.VerticalLayout; VerticalLayout;
 -	import org.apache.flex.html.beads.layouts.VerticalFlexLayout; VerticalFlexLayout;
 -	import org.apache.flex.html.beads.layouts.HorizontalLayout; HorizontalLayout;
 -	import org.apache.flex.html.beads.layouts.HorizontalFlexLayout; HorizontalFlexLayout;
 -    import org.apache.flex.html.beads.layouts.BasicLayout; BasicLayout;
 -	import org.apache.flex.html.beads.layouts.OneFlexibleChildHorizontalLayout; OneFlexibleChildHorizontalLayout;
 -	import org.apache.flex.html.beads.layouts.OneFlexibleChildVerticalLayout; OneFlexibleChildVerticalLayout;
 -
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.layouts.HScrollBarLayout; HScrollBarLayout;
 -    	import org.apache.flex.html.beads.layouts.VScrollBarLayout; VScrollBarLayout;
 -		import org.apache.flex.html.supportClasses.ContainerContentArea; ContainerContentArea;
 -	}
 -	import org.apache.flex.html.beads.layouts.TileLayout; TileLayout;
 -    import org.apache.flex.html.beads.TextItemRendererFactoryForArrayData; TextItemRendererFactoryForArrayData;
 -	import org.apache.flex.html.beads.DataItemRendererFactoryForArrayData; DataItemRendererFactoryForArrayData;
 -	import org.apache.flex.html.beads.DataItemRendererFactoryForArrayList; DataItemRendererFactoryForArrayList;
 -	import org.apache.flex.html.beads.DataItemRendererFactoryForHierarchicalData; DataItemRendererFactoryForHierarchicalData;
 -	import org.apache.flex.html.supportClasses.DataGroup; DataGroup;
 -	import org.apache.flex.html.supportClasses.Viewport; Viewport;
 -	import org.apache.flex.html.supportClasses.ScrollingViewport; ScrollingViewport;
 -	import org.apache.flex.html.supportClasses.DataGridButtonBarButtonItemRenderer; DataGridButtonBarButtonItemRenderer;
 -
 -	import org.apache.flex.html.DataGridButtonBarTextButton; DataGridButtonBarTextButton;
 -	import org.apache.flex.html.DataGridButtonBar; DataGridButtonBar;
 -	import org.apache.flex.html.beads.DataGridColumnView; DataGridColumnView;
 -	import org.apache.flex.html.beads.DataGridView; DataGridView;
 -	import org.apache.flex.html.beads.DataGridPercentageView; DataGridPercentageView;
 -	import org.apache.flex.html.beads.DateChooserView; DateChooserView;
 -	import org.apache.flex.html.beads.DateFieldView; DateFieldView;
 -	import org.apache.flex.html.beads.DecrementButtonView; DecrementButtonView;
 -	import org.apache.flex.html.beads.IncrementButtonView; IncrementButtonView;
 -	import org.apache.flex.html.beads.RangeStepperView; RangeStepperView;
 -    import org.apache.flex.html.beads.layouts.FlexibleFirstChildHorizontalLayout; FlexibleFirstChildHorizontalLayout;
 -	import org.apache.flex.html.beads.models.DataGridModel; DataGridModel;
 -	import org.apache.flex.html.beads.models.DateChooserModel; DateChooserModel;
 -	import org.apache.flex.html.beads.models.DataGridPresentationModel; DataGridPresentationModel;
 -	import org.apache.flex.html.beads.controllers.DateChooserMouseController; DateChooserMouseController;
 -	import org.apache.flex.html.beads.controllers.DateFieldMouseController; DateFieldMouseController;
 -	import org.apache.flex.html.beads.controllers.RangeStepperMouseController; RangeStepperMouseController;
 -	import org.apache.flex.html.supportClasses.DataGridColumn; DataGridColumn;
 -	import org.apache.flex.html.supportClasses.DateChooserButton; DateChooserButton;
 -	import org.apache.flex.html.supportClasses.DateHeaderButton; DateHeaderButton;
 -	import org.apache.flex.html.supportClasses.DateItemRenderer; DateItemRenderer;
 -	import org.apache.flex.html.supportClasses.GraphicsItemRenderer; GraphicsItemRenderer;
 -	import org.apache.flex.html.supportClasses.DateChooserList; DateChooserList;
 -
 -    import org.apache.flex.html.beads.TitleBarView; TitleBarView;
 -    import org.apache.flex.html.beads.TitleBarMeasurementBead; TitleBarMeasurementBead;
 -
 -	import org.apache.flex.html.beads.WebBrowserView; WebBrowserView;
 -	import org.apache.flex.html.beads.models.WebBrowserModel; WebBrowserModel;
 -
 -	import org.apache.flex.core.ListBase; ListBase;
 -	import org.apache.flex.core.FilledRectangle; FilledRectangle;
 -    import org.apache.flex.core.UIBase; UIBase;
 -    import org.apache.flex.core.SimpleApplication; SimpleApplication;
 -	import org.apache.flex.svg.GraphicContainer; GraphicContainer;
 -	import org.apache.flex.svg.DOMWrapper; DOMWrapper;
 -
 -	import org.apache.flex.svg.GraphicShape; GraphicShape;
 -	import org.apache.flex.svg.Rect; Rect;
 -	import org.apache.flex.svg.Ellipse; Ellipse;
 -	import org.apache.flex.svg.Circle; Circle;
 -	import org.apache.flex.svg.Image; Image;
 -	import org.apache.flex.svg.BinaryImage; BinaryImage;
 -	import org.apache.flex.svg.beads.ImageView; org.apache.flex.svg.beads.ImageView;
 -	import org.apache.flex.svg.Path; Path;
 -	import org.apache.flex.svg.Text; Text;
 -	import org.apache.flex.svg.CompoundGraphic; CompoundGraphic;
 -
 -    import org.apache.flex.html.beads.models.DataProviderModel; DataProviderModel;
 -    import org.apache.flex.html.beads.DataContainerView; DataContainerView;
 +{
- 	import org.apache.flex.html.Module; Module;
+ 
 -	COMPILE::SWF
 -	{
 -		import org.apache.flex.html.beads.HRuleView; HRuleView;
 -		import org.apache.flex.html.beads.VRuleView; VRuleView;
 -		import org.apache.flex.html.beads.MultilineTextFieldView; MultilineTextFieldView;
 -	}
 -	
 -	import org.apache.flex.html.SubAppLoader; SubAppLoader;
  }
  
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/HTML/src/main/resources/basic-manifest.xml
index 0a233ac,65f21d7..3d60024
--- a/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
@@@ -42,5 -174,5 +42,6 @@@
  
      <component id="InnerHTML" class="org.apache.flex.html.beads.InnerHTML" />
      <component id="TextNode" class="org.apache.flex.html.TextNode" />
++    <component id="HTMLText" class="org.apache.flex.html.HTMLText"/>
  
  </componentPackage>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/MaterialDesignLite/src/main/config/compile-swf-config.xml
----------------------------------------------------------------------
diff --cc frameworks/projects/MaterialDesignLite/src/main/config/compile-swf-config.xml
index f24bd02,0000000..c67a914
mode 100644,000000..100644
--- a/frameworks/projects/MaterialDesignLite/src/main/config/compile-swf-config.xml
+++ b/frameworks/projects/MaterialDesignLite/src/main/config/compile-swf-config.xml
@@@ -1,98 -1,0 +1,99 @@@
 +<!--
 +
 +  Licensed to the Apache Software Foundation (ASF) under one or more
 +  contributor license agreements.  See the NOTICE file distributed with
 +  this work for additional information regarding copyright ownership.
 +  The ASF licenses this file to You under the Apache License, Version 2.0
 +  (the "License"); you may not use this file except in compliance with
 +  the License.  You may obtain a copy of the License at
 +
 +      http://www.apache.org/licenses/LICENSE-2.0
 +
 +  Unless required by applicable law or agreed to in writing, software
 +  distributed under the License is distributed on an "AS IS" BASIS,
 +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +  See the License for the specific language governing permissions and
 +  limitations under the License.
 +
 +-->
 +<flex-config>
 +
 +    <compiler>
 +        <accessible>false</accessible>
 +        
 +        <external-library-path>
 +            <path-element>${env.AIR_HOME}/frameworks/libs/air/airglobal.swc</path-element>
 +            <path-element>../../../../../libs/Binding.swc</path-element>
 +            <path-element>../../../../../libs/Core.swc</path-element>
 +            <path-element>../../../../../libs/Graphics.swc</path-element>
++            <path-element>../../../../../libs/Collections.swc</path-element>
 +            <path-element>../../../../../libs/HTML.swc</path-element>
 +            <path-element>../../../../../libs/Basic.swc</path-element>
 +        </external-library-path>
 +        
 +        <allow-subclass-overrides>true</allow-subclass-overrides>
 +		<mxml>
 +			<children-as-data>true</children-as-data>
 +		</mxml>
 +		<binding-value-change-event>org.apache.flex.events.ValueChangeEvent</binding-value-change-event>
 +		<binding-value-change-event-kind>org.apache.flex.events.ValueChangeEvent</binding-value-change-event-kind>
 +		<binding-value-change-event-type>valueChange</binding-value-change-event-type>
 +
 +        <define>
 +            <name>COMPILE::SWF</name>
 +            <value>true</value>
 +        </define>
 +        <define>
 +            <name>COMPILE::JS</name>
 +            <value>false</value>
 +        </define>
 +
 +        <keep-as3-metadata>
 +          <name>Bindable</name>
 +          <name>Managed</name>
 +          <name>ChangeEvent</name>
 +          <name>NonCommittingChangeEvent</name>
 +          <name>Transient</name>
 +        </keep-as3-metadata>
 +	  
 +        <locale/>
 +        
 +        <library-path/>
 +
 +        <namespaces>
 +            <namespace>
 +                <uri>library://ns.apache.org/flexjs/mdl</uri>
 +                <manifest>../resources/mdl-manifest.xml</manifest>
 +            </namespace>
 +            <namespace>
 +                <uri>library://ns.apache.org/flexjs/mdl</uri>
 +                <manifest>../resources/mdl-as-manifest.xml</manifest>
 +            </namespace>
 +        </namespaces>
 +        
 +        <source-path>
 +            <path-element>../flex</path-element>
 +        </source-path>
 +        
 +        <warn-no-constructor>false</warn-no-constructor>
 +    </compiler>
 +    
 +    <include-file>
 +        <name>defaults.css</name>
 +        <path>../resources/defaults.css</path>
 +    </include-file>
 +
 +    <include-lookup-only>true</include-lookup-only>
 +    
 +    <include-classes>
 +        <class>MDLClasses</class>
 +    </include-classes>
 +    
 +    <include-namespaces>
 +        <uri>library://ns.apache.org/flexjs/mdl</uri>
 +    </include-namespaces>
 +        
 +    <target-player>${playerglobal.version}</target-player>
 +	
 +
 +</flex-config>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/RadioButton.as
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Mobile/src/main/flex/org/apache/flex/mobile/TitleView.as
----------------------------------------------------------------------


[06/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
index 29a8b6d,501799f..148866b
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalLayout.as
@@@ -18,11 -18,10 +18,14 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
  {
++	import org.apache.flex.core.LayoutBase;
++	
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.IBeadModel;
  	import org.apache.flex.core.ILayoutChild;
  	import org.apache.flex.core.ILayoutHost;
-     import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ILayoutParent;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
@@@ -32,8 -31,8 +35,10 @@@
  	import org.apache.flex.geom.Rectangle;
  	import org.apache.flex.utils.CSSContainerUtils;
  	import org.apache.flex.utils.CSSUtils;
--    COMPILE::JS
--    {
++	COMPILE::SWF {
++			import org.apache.flex.core.UIBase;
++	}
++    COMPILE::JS {
          import org.apache.flex.core.WrappedHTMLElement;
      }
  
@@@ -42,17 -41,17 +47,17 @@@
       *  bead.  It takes the set of children and lays them out
       *  horizontally in one row, separating them according to
       *  CSS layout rules for margin and vertical-align styles.
--     *  
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class HorizontalLayout implements IBeadLayout
++	public class HorizontalLayout extends LayoutBase implements IBeadLayout
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -60,272 -59,268 +65,140 @@@
           */
  		public function HorizontalLayout()
  		{
++			super();
  		}
--		
--        // the strand/host container is also an ILayoutChild because
--        // can have its size dictated by the host's parent which is
--        // important to know for layout optimization
--		private var host:ILayoutChild;
--		
++
          /**
           *  @copy org.apache.flex.core.IBead#strand
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
           *  @productversion FlexJS 0.0
--		 *  @flexjsignorecoercion HTMLElement
++         *  @flexjsignorecoercion HTMLElement
++         *  @flexjsignorecoercion org.apache.flex.core.IUIBase
           */
--		public function set strand(value:IStrand):void
++		override public function set strand(value:IStrand):void
  		{
--			host = value as ILayoutChild;
++			super.strand = value;
++			
              COMPILE::JS
              {
-                 var base:IUIBase = value as IUIBase;
-                 if (base.element.style.display !== "none") {
-                     base.element.style.display = "block";
-                 }
 -                ((value as IUIBase).element as HTMLElement).style.display = 'block';
++				var base:IUIBase = value as IUIBase;
++				if (base.element.style.display !== "none") {
++					base.element.style.display = "block";
++				}
              }
  		}
--	
++
          /**
           * @copy org.apache.flex.core.IBeadLayout#layout
           * @flexjsignorecoercion org.apache.flex.core.ILayoutHost
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
--		public function layout():Boolean
++		override public function layout():Boolean
  		{
              COMPILE::SWF
              {
--                //trace(DOMPathUtil.getPath(host), event ? event.type : "fixed size");
-                 var layoutParent:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -                var layoutParent:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--                var contentView:IParentIUIBase = layoutParent.contentView;
--                var padding:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
--                
--                var n:int = contentView.numElements;
--                var hostSizedToContent:Boolean = host.isHeightSizedToContent();
--                var ilc:ILayoutChild;
--                var marginLeft:Object;
--                var marginRight:Object;
--                var marginTop:Object;
--                var marginBottom:Object;
--                var margin:Object;
--                var maxHeight:Number = 0;
--                // asking for contentView.height can result in infinite loop if host isn't sized already
--                var h:Number = hostSizedToContent ? 0 : contentView.height;
--                var w:Number = contentView.width;
--                var verticalMargins:Array = [];
--                
--                for (var i:int = 0; i < n; i++)
--                {
--                    var child:IUIBase = contentView.getElementAt(i) as IUIBase;
--                    if (child == null || !child.visible) continue;
--                    var top:Number = ValuesManager.valuesImpl.getValue(child, "top");
--                    var bottom:Number = ValuesManager.valuesImpl.getValue(child, "bottom");
--                    margin = ValuesManager.valuesImpl.getValue(child, "margin");
--                    marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
--                    marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
--                    marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
--                    marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
--                    var ml:Number = CSSUtils.getLeftValue(marginLeft, margin, w);
--                    var mr:Number = CSSUtils.getRightValue(marginRight, margin, w);
--                    var mt:Number = CSSUtils.getTopValue(marginTop, margin, h);
--                    var mb:Number = CSSUtils.getBottomValue(marginBottom, margin, h);
--                    
--                    ilc = child as ILayoutChild;
--                    var lastmr:Number;
--                    if (marginLeft == "auto")
--                        ml = 0;
--                    if (marginRight == "auto")
--                        mr = 0;
--                    var xx:Number;
--                    if (i == 0)
--                    {
--                        if (ilc)
--                            ilc.setX(ml + padding.left);
--                        else
--                            child.x = ml + padding.left;
--                    }
--                    else
--                    {
--                        if (ilc)
--                            ilc.setX(xx + ml + lastmr);
--                        else
--                            child.x = xx + ml + lastmr;
--                    }
--                    if (ilc)
--                    {
--                        if (!isNaN(ilc.percentWidth))
--                            ilc.setWidth(contentView.width * ilc.percentWidth / 100, !isNaN(ilc.percentHeight));
--                    }
--                    lastmr = mr;
--                    var marginObject:Object = {};
--                    verticalMargins[i] = marginObject;
--                    var valign:* = ValuesManager.valuesImpl.getValue(child, "vertical-align");
--                    marginObject.valign = valign;
--                    if (!hostSizedToContent)
--                    {
--                        // if host is sized by parent,
--                        // we can position and size children horizontally now
--                        setPositionAndHeight(child, top, mt, padding.top, bottom, mb, padding.bottom, h, valign);
--                        maxHeight = Math.max(maxHeight, mt + child.height + mb);
--                    }
--                    else
--                    {
--                        if (!isNaN(top))
--                        {
--                            mt = top;
--                            marginObject.top = mt;
--                        }
--                        if (!isNaN(bottom))
--                        {
--                            mb = bottom;
--                            marginObject.bottom = mb;
--                        }
--                        maxHeight = Math.max(maxHeight, mt + child.height + mb);
--                    }
--                    xx = child.x + child.width;
--                }
--                if (hostSizedToContent)
--                {
--                    ILayoutChild(contentView).setHeight(maxHeight, true);
--                    if (host.isWidthSizedToContent())
--                        ILayoutChild(contentView).setWidth(xx, true);
--                    for (i = 0; i < n; i++)
--                    {
--                        child = contentView.getElementAt(i) as IUIBase;
--                        if (child == null || !child.visible) continue;
--                        var obj:Object = verticalMargins[i];
--                        setPositionAndHeight(child, obj.top, obj.marginTop, padding.top,
--                            obj.bottom, obj.marginBottom, padding.bottom, maxHeight, obj.valign);
--                    }
--                }
--                
--                // Only return true if the contentView needs to be larger; that new
--                // size is stored in the model.
--                var sizeChanged:Boolean = true;
--                
--                host.dispatchEvent( new Event("layoutComplete") );
--                
--                return sizeChanged;
--                
++				var contentView:ILayoutView = layoutView;
++
++				var n:Number = contentView.numElements;
++				if (n == 0) return false;
++
++				var maxWidth:Number = 0;
++				var maxHeight:Number = 0;
++				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
++				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
++				var hostWidth:Number = hostWidthSizedToContent ? 0 : contentView.width;
++				var hostHeight:Number = hostHeightSizedToContent ? 0 : contentView.height;
++
++				var ilc:ILayoutChild;
++				var data:Object;
++				var canAdjust:Boolean = false;
++
++				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
++				
++				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++				// resulting adjusted value may be less than zero.
++				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++
++				var xpos:Number = borderMetrics.left + paddingMetrics.left;
++				var ypos:Number = borderMetrics.top + paddingMetrics.left;
++
++				// First pass determines the data about the child.
++				for(var i:int=0; i < n; i++)
++				{
++					var child:IUIBase = contentView.getElementAt(i) as IUIBase;
++					if (child == null || !child.visible) continue;
++					var positions:Object = childPositions(child);
++					var margins:Object = childMargins(child, hostWidth, hostHeight);
++
++					ilc = child as ILayoutChild;
++
++					xpos += margins.left;
++
++					var childYpos:Number = ypos + margins.top; // default y position
++
++					if (!hostHeightSizedToContent) {
++						var childHeight:Number = child.height;
++						if (ilc != null && !isNaN(ilc.percentHeight)) {
++							childHeight = hostHeight * ilc.percentHeight/100.0;
++							ilc.setHeight(childHeight);
++						}
++						// the following code middle-aligns the child, but since HTML does not
++						// do this normally, this code is commented. (Use HorizontalFlexLayout for
++						// vertically centered elements in a horizontal row).
++//						childYpos = hostHeight/2 - (childHeight + mt + mb)/2;
++					}
++
++					if (ilc) {
++						ilc.setX(xpos);
++						ilc.setY(childYpos);
++
++						if (!hostWidthSizedToContent && !isNaN(ilc.percentWidth)) {
++							var newWidth:Number = hostWidth * ilc.percentWidth / 100;
++							ilc.setWidth(newWidth);
++						}
++
++					} else {
++						child.x = xpos;
++						child.y = childYpos;
++					}
++
++					xpos += child.width + margins.right;
++				}
++
++				return true;
++
              }
              COMPILE::JS
              {
                  var children:Array;
                  var i:int;
                  var n:int;
--                
-                 var viewBead:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -                var viewBead:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--                var contentView:IParentIUIBase = viewBead.contentView;
++				var contentView:IParentIUIBase = layoutView as IParentIUIBase;
++
++				contentView.element.style["white-space"] = "nowrap";
++
                  children = contentView.internalChildren();
--                var hasHeight:Boolean = !host.isHeightSizedToContent();
--                var hasWidth:Boolean = !host.isWidthSizedToContent();
--                var maxHeight:Number = 0;
--                var computedWidth:Number = 0;
++
++
                  n = children.length;
                  for (i = 0; i < n; i++)
                  {
                      var child:WrappedHTMLElement = children[i] as WrappedHTMLElement;
-                     if (child == null) continue;
--                    child.flexjs_wrapper.internalDisplay = 'inline-block';
--                    if (child.style.display == 'none')
--                        child.flexjs_wrapper.setDisplayStyleForLayout('inline-block');
--                    else
--                        child.style.display = 'inline-block';
--                    maxHeight = Math.max(maxHeight, child.offsetHeight);
--                    if (!hasWidth) {
--                        var cv:Object = getComputedStyle(child);
--                        var mls:String = cv['margin-left'];
--                        var ml:Number = Number(mls.substring(0, mls.length - 2));
--                        var mrs:String = cv['margin-right'];
--                        var mr:Number = Number(mrs.substring(0, mrs.length - 2));
--                        computedWidth += ml + child.offsetWidth + mr;
--                    }
--                    child.flexjs_wrapper.dispatchEvent('sizeChanged');
--                }
--                // if there are children and maxHeight is ok, use it.
--                // maxHeight can be NaN if the child hasn't been rendered yet.
--                if (!hasHeight && n > 0 && !isNaN(maxHeight)) {
--                    contentView.height = maxHeight;
--                }
--                if (!hasWidth && n > 0 && !isNaN(computedWidth)) {
--                    contentView.width = computedWidth + 1; // some browser need one more pixel
--                }
++					if (child == null) continue;
++					child.flexjs_wrapper.setDisplayStyleForLayout('inline-block');
++					if (child.style.display !== 'none')
++					{
++						child.style.display = 'inline-block';
++					}
++				}
++
                  return true;
              }
  		}
--        
--        COMPILE::SWF
--        private function setPositionAndHeight(child:IUIBase, top:Number, mt:Number, pt:Number,
--                                             bottom:Number, mb:Number, pb:Number, h:Number,
--                                             valign:*):void
--        {
--            var heightSet:Boolean = false;
--            
--            var hh:Number = h;
--            var ilc:ILayoutChild = child as ILayoutChild;
--            if (ilc)
--            {
--                if (!isNaN(ilc.percentHeight))
--                    ilc.setHeight(h * ilc.percentHeight / 100, true);
--            }
--            if (valign == "top")
--            {
--                if (!isNaN(top))
--                {
--                    if (ilc)
--                        ilc.setY(top + mt);
--                    else
--                        child.y = top + mt;
--                    hh -= top + mt;
--                }
--                else 
--                {
--                    if (ilc)
--                        ilc.setY(mt + pt);
--                    else
--                        child.y = mt + pt;
--                    hh -= mt + pt;
--                }
--                if (ilc.isHeightSizedToContent())
--                {
--                    if (!isNaN(bottom))
--                    {
--                        if (!isNaN(top))
--                        {
--                            if (ilc)
--                                ilc.setHeight(hh - bottom - mb, true);
--                            else 
--                            {
--                                child.height = hh - bottom - mb;
--                                heightSet = true;
--                            }
--                        }
--                    }
--                }
--            }
--            else if (valign == "bottom")
--            {
--                if (!isNaN(bottom))
--                {
--                    if (ilc)
--                        ilc.setY(h - bottom - mb - child.height);
--                    else
--                        child.y = h - bottom - mb - child.height;
--                }
--                else
--                {
--                    if (ilc)
--                        ilc.setY(h - mb - child.height);
--                    else
--                        child.y = h - mb - child.height;
--                }
--            }
--            else
--                child.y = (h - child.height) / 2;                    
--            if (!heightSet)
--                child.dispatchEvent(new Event("sizeChanged"));
--        }
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
index e4d1cd5,c052442..c90f223
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
@@@ -18,18 -18,20 +18,21 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
  {
 -	import org.apache.flex.core.IBeadLayout;
++	import org.apache.flex.core.LayoutBase;
  	import org.apache.flex.core.IDocument;
  	import org.apache.flex.core.ILayoutChild;
  	import org.apache.flex.core.ILayoutHost;
-     import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ILayoutParent;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
 -	import org.apache.flex.core.UIBase;
  	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.core.UIBase;
  	import org.apache.flex.events.Event;
 -	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.geom.Rectangle;
++	import org.apache.flex.utils.CSSContainerUtils;
  	import org.apache.flex.utils.CSSUtils;
--    import org.apache.flex.utils.CSSContainerUtils;
  
      /**
       *  The OneFlexibleChildHorizontalLayout class is a simple layout
@@@ -38,17 -40,17 +41,17 @@@
       *  CSS layout rules for margin and padding styles. But it
       *  will size the one child to take up as much or little
       *  room as possible.
--     *  
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
- 	public class OneFlexibleChildHorizontalLayout implements IOneFlexibleChildLayout, IDocument
 -	public class OneFlexibleChildHorizontalLayout implements IBeadLayout, IDocument
++	public class OneFlexibleChildHorizontalLayout extends HorizontalLayout implements IOneFlexibleChildLayout, IDocument
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -56,63 -58,50 +59,46 @@@
           */
  		public function OneFlexibleChildHorizontalLayout()
  		{
++			super();
  		}
--		
 -        
 -        /**
 -         *  The id of the flexible child
 -         *  
 -         *  @langversion 3.0
 -         *  @playerversion Flash 10.2
 -         *  @playerversion AIR 2.6
 -         *  @productversion FlexJS 0.0
 -         */
 -        public var flexibleChild:String;
--        
++
++
 +        private var _flexibleChild:String;
-         
++
          private var actualChild:ILayoutChild;
--        
--        // the strand/host container is also an ILayoutChild because
--        // can have its size dictated by the host's parent which is
--        // important to know for layout optimization
--        private var host:ILayoutChild;
--		
++
          /**
           *  @private
           *  The document.
           */
          private var document:Object;
-         
-         /**
-          *  The id of the flexible child
-          *  
-          *  @langversion 3.0
-          *  @playerversion Flash 10.2
-          *  @playerversion AIR 2.6
-          *  @productversion FlexJS 0.0
-          */
-         public function get flexibleChild():String
-         {
-             return _flexibleChild;
-         }
-         
-         /**
-          * @private
-          */
-         public function set flexibleChild(value:String):void
-         {
-             _flexibleChild = value;
-         }
--        
--        /**
--         *  @copy org.apache.flex.core.IBead#strand
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		public function set strand(value:IStrand):void
++
++		/**
++		 *  The id of the flexible child
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get flexibleChild():String
+ 		{
 -            host = value as ILayoutChild;
++			return _flexibleChild;
+ 		}
 -	
++
++		/**
++		 * @private
++		 */
++		public function set flexibleChild(value:String):void
 +		{
-             host = value as ILayoutChild;
++			_flexibleChild = value;
 +		}
- 	
++
          private var _maxWidth:Number;
--        
++
          /**
           *  @copy org.apache.flex.core.IBead#maxWidth
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -122,20 -111,20 +108,20 @@@
          {
              return _maxWidth;
          }
--        
++
          /**
--         *  @private 
++         *  @private
           */
          public function set maxWidth(value:Number):void
          {
              _maxWidth = value;
          }
--        
++
          private var _maxHeight:Number;
--        
++
          /**
           *  @copy org.apache.flex.core.IBead#maxHeight
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -145,201 -134,199 +131,201 @@@
          {
              return _maxHeight;
          }
--        
++
          /**
--         *  @private 
++         *  @private
           */
          public function set maxHeight(value:Number):void
          {
              _maxHeight = value;
          }
--        
++
          /**
           * @copy org.apache.flex.core.IBeadLayout#layout
           */
--		public function layout():Boolean
++		COMPILE::JS
++		override public function layout():Boolean
  		{
-             var layoutParent:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -            var layoutParent:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--            var contentView:IParentIUIBase = layoutParent ? layoutParent.contentView : IParentIUIBase(host);
--            var padding:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
--            actualChild = document[flexibleChild];
++			var contentView:ILayoutView = layoutView;
++
++			actualChild = document[flexibleChild];
++
++			// set the display on the contentView
++			contentView.element.style["display"] = "flex";
++			contentView.element.style["flex-flow"] = "row";
++			contentView.element.style["align-items"] = "center";
  
--            var ilc:ILayoutChild;
  			var n:int = contentView.numElements;
--			var marginLeft:Object;
--			var marginRight:Object;
--			var marginTop:Object;
--			var marginBottom:Object;
--			var margin:Object;
--			maxHeight = 0;
--			var verticalMargins:Array = new Array(n);
++			if (n == 0) return false;
++
++			for(var i:int=0; i < n; i++) {
++				var child:UIBase = contentView.getElementAt(i) as UIBase;
++				child.element.style["flex-grow"] = (child == actualChild) ? "1" : "0";
++				child.element.style["flex-shrink"] = "0";
++			}
++
++			return true;
++		}
++
++		COMPILE::SWF
++		override public function layout():Boolean
++		{
++			var contentView:ILayoutView = layoutView;
++			var actualChild:IUIBase = document.hasOwnProperty(flexibleChild) ? document[flexibleChild] : null;
++
++			var n:Number = contentView.numElements;
++			if (n == 0) return false;
+ 			
 -            var ww:Number = contentView.width - padding.right;
 -            var hh:Number = contentView.height;
 -            var xx:int = padding.left;
 -            var flexChildIndex:int;
 -            var ml:Number;
 -            var mr:Number;
 -            var mt:Number;
 -            var mb:Number;
 -            var lastmr:Number;
 -            var lastml:Number;
 -            var valign:Object;
 -            var hostSizedToContent:Boolean = host.isHeightSizedToContent();
 -            
 -            for (var i:int = 0; i < n; i++)
 -            {
 -                var child:IUIBase = contentView.getElementAt(i) as IUIBase;
 -                if (child == actualChild)
 -                {
 -                    flexChildIndex = i;
 -                    break;
 -                }
 -                margin = ValuesManager.valuesImpl.getValue(child, "margin");
 -                marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
 -                marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
 -                marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
 -                marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
 -                mt = CSSUtils.getTopValue(marginTop, margin, hh);
 -                mb = CSSUtils.getBottomValue(marginBottom, margin, hh);
 -                mr = CSSUtils.getRightValue(marginRight, margin, ww);
 -                ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
 -                child.y = mt + padding.top;
 -                if (child is ILayoutChild)
 -                {
 -                    ilc = child as ILayoutChild;
 -                    if (!isNaN(ilc.percentHeight))
 -                        ilc.setHeight(contentView.height * ilc.percentHeight / 100, true);
 -                }
 -                maxHeight = Math.max(maxHeight, mt + child.height + mb);
 -                child.x = xx + ml;
 -                xx += child.width + ml + mr;
 -                lastmr = mr;
 -                valign = ValuesManager.valuesImpl.getValue(child, "vertical-align");
 -                verticalMargins[i] = { marginTop: mt, marginBottom: mb, valign: valign };
 -            }
 -
 -            if (n > 0 && n > flexChildIndex)
 -            {
 -                for (i = n - 1; i > flexChildIndex; i--)
 -    			{
 -    				child = contentView.getElementAt(i) as IUIBase;
 -    				margin = ValuesManager.valuesImpl.getValue(child, "margin");
 -					marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
 -					marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
 -					marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
 -					marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
 -    				mt = CSSUtils.getTopValue(marginTop, margin, hh);
 -    				mb = CSSUtils.getTopValue(marginBottom, margin, hh);
 -                    mr = CSSUtils.getRightValue(marginRight, margin, ww);
 -                    ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
 -                    child.y = mt + padding.top;
 -                    if (child is ILayoutChild)
 -                    {
 -                        ilc = child as ILayoutChild;
 -                        if (!isNaN(ilc.percentHeight))
 -                            ilc.setHeight(contentView.height * ilc.percentHeight / 100, true);
 -                    }
 -                    maxHeight = Math.max(maxHeight, mt + child.height + mb);
 -                    child.x = ww - child.width - mr;
 -    				ww -= child.width + ml + mr;
 -    				lastml = ml;
 -                    valign = ValuesManager.valuesImpl.getValue(child, "vertical-align");
 -                    verticalMargins[i] = { marginTop: mt, marginBottom: mb, valign: valign };
 -    			}
 -            
 -                child = contentView.getElementAt(flexChildIndex) as IUIBase;
 -                margin = ValuesManager.valuesImpl.getValue(child, "margin");
 -                marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
 -                marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
 -                marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
 -                marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
 -                mt = CSSUtils.getTopValue(marginTop, margin, hh);
 -                mb = CSSUtils.getTopValue(marginBottom, margin, hh);
 -                mr = CSSUtils.getRightValue(marginRight, margin, ww);
 -                ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
 -                if (child is ILayoutChild)
 -                {
 -                    ilc = child as ILayoutChild;
 -                    if (!isNaN(ilc.percentHeight))
 -                        ilc.setHeight(contentView.height * ilc.percentHeight / 100, true);
 -                }
 -                child.x = xx + ml;
 -                child.width = ww - child.x;
 -                maxHeight = Math.max(maxHeight, mt + child.height + mb);
 -                valign = ValuesManager.valuesImpl.getValue(child, "vertical-align");
 -                verticalMargins[flexChildIndex] = { marginTop: mt, marginBottom: mb, valign: valign };
 -            }
 -            if (hostSizedToContent)
 -                ILayoutChild(contentView).setHeight(maxHeight + padding.top + padding.bottom, true);
 -            
 -            for (i = 0; i < n; i++)
++			// if the layoutView's width cannot be determined then this layout
++			// will not work, so default to HorizontalLayout
++			if (host.isWidthSizedToContent()) {
++				return super.layout();
++			}
++
++			var maxWidth:Number = 0;
++			var maxHeight:Number = 0;
++			var hostSizedToContent:Boolean = host.isHeightSizedToContent();
++			var hostWidth:Number = contentView.width;
++			var hostHeight:Number = hostSizedToContent ? 0 : contentView.height;
++
++			var ilc:ILayoutChild;
++			var data:Object;
++			var canAdjust:Boolean = false;
++			var margins:Object;
++
++			var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++			var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
 +			
-             var ww:Number = contentView.width - padding.right;
-             var hh:Number = contentView.height;
-             var xx:int = padding.left;
-             var flexChildIndex:int;
-             var ml:Number;
-             var mr:Number;
-             var mt:Number;
-             var mb:Number;
-             var lastmr:Number;
-             var lastml:Number;
-             var valign:Object;
-             var hostSizedToContent:Boolean = host.isHeightSizedToContent();
-             
-             for (var i:int = 0; i < n; i++)
-             {
-                 var child:IUIBase = contentView.getElementAt(i) as IUIBase;
-                 if (child == null || !child.visible) continue;
-                 if (child == actualChild)
-                 {
-                     flexChildIndex = i;
-                     break;
-                 }
-                 margin = ValuesManager.valuesImpl.getValue(child, "margin");
-                 marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
-                 marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
-                 marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
-                 marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
-                 mt = CSSUtils.getTopValue(marginTop, margin, hh);
-                 mb = CSSUtils.getBottomValue(marginBottom, margin, hh);
-                 mr = CSSUtils.getRightValue(marginRight, margin, ww);
-                 ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
-                 child.y = mt + padding.top;
-                 if (child is ILayoutChild)
-                 {
-                     ilc = child as ILayoutChild;
-                     if (!isNaN(ilc.percentHeight))
-                         ilc.setHeight(contentView.height * ilc.percentHeight / 100, true);
-                 }
-                 maxHeight = Math.max(maxHeight, mt + child.height + mb);
-                 child.x = xx + ml;
-                 xx += child.width + ml + mr;
-                 lastmr = mr;
-                 valign = ValuesManager.valuesImpl.getValue(child, "vertical-align");
-                 verticalMargins[i] = { marginTop: mt, marginBottom: mb, valign: valign };
-             }
- 
-             if (n > 0 && n > flexChildIndex)
-             {
-                 for (i = n - 1; i > flexChildIndex; i--)
-     			{
-     				child = contentView.getElementAt(i) as IUIBase;
-                     if (child == null || !child.visible) continue;
-     				margin = ValuesManager.valuesImpl.getValue(child, "margin");
- 					marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
- 					marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
- 					marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
- 					marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
-     				mt = CSSUtils.getTopValue(marginTop, margin, hh);
-     				mb = CSSUtils.getTopValue(marginBottom, margin, hh);
-                     mr = CSSUtils.getRightValue(marginRight, margin, ww);
-                     ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
-                     child.y = mt + padding.top;
-                     if (child is ILayoutChild)
-                     {
-                         ilc = child as ILayoutChild;
-                         if (!isNaN(ilc.percentHeight))
-                             ilc.setHeight(contentView.height * ilc.percentHeight / 100, true);
-                     }
-                     maxHeight = Math.max(maxHeight, mt + child.height + mb);
-                     child.x = ww - child.width - mr;
-     				ww -= child.width + ml + mr;
-     				lastml = ml;
-                     valign = ValuesManager.valuesImpl.getValue(child, "vertical-align");
-                     verticalMargins[i] = { marginTop: mt, marginBottom: mb, valign: valign };
-     			}
-             
-                 child = contentView.getElementAt(flexChildIndex) as IUIBase;
-                 margin = ValuesManager.valuesImpl.getValue(child, "margin");
-                 marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
-                 marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
-                 marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
-                 marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
-                 mt = CSSUtils.getTopValue(marginTop, margin, hh);
-                 mb = CSSUtils.getTopValue(marginBottom, margin, hh);
-                 mr = CSSUtils.getRightValue(marginRight, margin, ww);
-                 ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
-                 if (child is ILayoutChild)
-                 {
-                     ilc = child as ILayoutChild;
-                     if (!isNaN(ilc.percentHeight))
-                         ilc.setHeight(contentView.height * ilc.percentHeight / 100, true);
-                 }
-                 child.x = xx + ml;
-                 child.width = ww - child.x;
-                 maxHeight = Math.max(maxHeight, mt + child.height + mb);
-                 valign = ValuesManager.valuesImpl.getValue(child, "vertical-align");
-                 verticalMargins[flexChildIndex] = { marginTop: mt, marginBottom: mb, valign: valign };
-             }
-             if (hostSizedToContent)
-                 ILayoutChild(contentView).setHeight(maxHeight + padding.top + padding.bottom, true);
-             
-             for (i = 0; i < n; i++)
++			// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++			// resulting adjusted value may be less than zero.
++			hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++			hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++
++			var xpos:Number = borderMetrics.left + paddingMetrics.left;
++			var ypos:Number = borderMetrics.top + paddingMetrics.left;
++			var child:IUIBase;
++			var childHeight:Number;
++			var i:int;
++			var childYpos:Number;
++			var adjustLeft:Number = 0;
++			var adjustRight:Number = hostWidth + borderMetrics.left + paddingMetrics.left;
++
++			// first work from left to right
++			for(i=0; i < n; i++)
++			{
++				child = contentView.getElementAt(i) as IUIBase;
++				if (child == null || !child.visible) continue;
++				if (child == actualChild) break;
++
++				margins = childMargins(child, hostWidth, hostHeight);
++				ilc = child as ILayoutChild;
++
++				xpos += margins.left;
++
++				childYpos = ypos + margins.top; // default y position
++
++				if (!hostSizedToContent) {
++					childHeight = child.height;
++					if (ilc != null && !isNaN(ilc.percentHeight)) {
++						childHeight = host.height * ilc.percentHeight/100.0;
++						ilc.setHeight(childHeight);
++					}
++					// the following code middle-aligns the child
++					childYpos = hostHeight/2 - childHeight/2 + ypos;
++				}
++
++				if (ilc) {
++					ilc.setX(xpos);
++					ilc.setY(childYpos);
++
++					if (!isNaN(ilc.percentWidth)) {
++						ilc.setWidth(hostWidth * ilc.percentWidth / 100);
++					}
++
++				} else {
++					child.x = xpos;
++					child.y = childYpos;
++				}
++
++				xpos += child.width + margins.right;
++				adjustLeft = xpos;
++			}
++
++			// then work from right to left
++			xpos = hostWidth + borderMetrics.left + paddingMetrics.left;
++
++			for(i=(n-1); actualChild != null && i >= 0; i--)
  			{
--				var obj:Object = verticalMargins[i]
  				child = contentView.getElementAt(i) as IUIBase;
--                setPositionAndHeight(child, obj.top, obj.marginTop, padding.top,
--                    obj.bottom, obj.marginBottom, padding.bottom, maxHeight, obj.valign);
++				if (child == null || !child.visible) continue;
++				if (child == actualChild) break;
++
++				margins = childMargins(child, hostWidth, hostHeight);
++				ilc = child as ILayoutChild;
++
++				childYpos = ypos + margins.top; // default y position
++
++				if (!hostSizedToContent) {
++					childHeight = child.height;
++					if (ilc != null && !isNaN(ilc.percentHeight)) {
++						childHeight = hostHeight * ilc.percentHeight/100.0;
++						ilc.setHeight(childHeight);
++					}
++					// the following code middle-aligns the child
++					childYpos = hostHeight/2 - childHeight/2 + ypos;
++				}
++
++				if (ilc) {
++					if (!isNaN(ilc.percentWidth)) {
++						ilc.setWidth(hostWidth * ilc.percentWidth / 100);
++					}
++				}
++
++				xpos -= child.width + margins.right;
++
++				if (ilc) {
++					ilc.setX(xpos);
++					ilc.setY(childYpos);
++				} else {
++					child.x = xpos;
++					child.y = childYpos;
++				}
++
++				xpos -= margins.left;
++				adjustRight = xpos;
++			}
++
++			// now adjust the actualChild to fill the space.
++			if (actualChild != null) {
++				margins = childMargins(actualChild, hostWidth, hostHeight);
++				ilc = actualChild as ILayoutChild;
++				if (!hostSizedToContent) {
++					childHeight = actualChild.height;
++					if (ilc != null && !isNaN(ilc.percentHeight)) {
++						childHeight = hostHeight * ilc.percentHeight/100.0;
++						ilc.setHeight(childHeight);
++					}
++				}
++				childYpos = ypos + margins.top;
++				if (!hostSizedToContent) {
++					childYpos = hostHeight/2 - childHeight/2 + ypos;
++				}
++				actualChild.x = adjustLeft + margins.left;
++				actualChild.y = childYpos;
++				if (ilc) {
++					ilc.setWidth((adjustRight-margins.right) - (adjustLeft+margins.left));
++				} else {
++					actualChild.width = (adjustRight-margins.right) - (adjustLeft+margins.left);
++				}
  			}
++
              return true;
  		}
  
--        private function setPositionAndHeight(child:IUIBase, top:Number, mt:Number, pt:Number,
--                                              bottom:Number, mb:Number, pb:Number, h:Number, valign:String):void
--        {
--            var heightSet:Boolean = false; // if we've set the height in a way that gens a change event
--            var ySet:Boolean = false; // if we've set the y yet.
--            
--            var hh:Number = h;
--            var ilc:ILayoutChild = child as ILayoutChild;
--            if (!isNaN(top))
--            {
--                child.y = top + mt;
--                ySet = true;
--                hh -= top + mt;
--            }
--            else 
--            {
--                hh -= mt;
--            }
--            if (!isNaN(bottom))
--            {
--                if (!isNaN(top))
--                {
--                    if (ilc)
--                        ilc.setHeight(hh - bottom - mb, true);
--                    else 
--                    {
--                        child.height = hh - bottom - mb;
--                        heightSet = true;
--                    }
--                }
--                else
--                {
--                    child.y = h - bottom - mb - child.height - 1; // some browsers don't like going to the edge
--                    ySet = true;
--                }
--            }
--            if (ilc)
--            {
--                if (!isNaN(ilc.percentHeight))
--                    ilc.setHeight(h * ilc.percentHeight / 100, true);
--            }
--            if (valign == "middle")
--                child.y = (h - child.height) / 2;
--            else if (valign == "bottom")
--                child.y = h - child.height - mb;
--            else
--                child.y = mt + pt;
--            if (!heightSet)
--                child.dispatchEvent(new Event("sizeChanged"));
--        }
--        
          public function setDocument(document:Object, id:String = null):void
          {
--            this.document = document;	
++            this.document = document;
          }
      }
--        
++
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
index 23dd88a,77af305..9242d91
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
@@@ -18,19 -18,19 +18,22 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
  {
 -	import org.apache.flex.core.IBeadLayout;
++	import org.apache.flex.core.LayoutBase;
  	import org.apache.flex.core.IDocument;
  	import org.apache.flex.core.ILayoutChild;
  	import org.apache.flex.core.ILayoutHost;
-     import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ILayoutParent;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.IStrand;
-     import org.apache.flex.core.IStyleableObject;
++	import org.apache.flex.core.IStyleableObject;
  	import org.apache.flex.core.IUIBase;
--	import org.apache.flex.core.UIBase;
  	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.core.UIBase;
  	import org.apache.flex.events.Event;
 -	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.geom.Rectangle;
--    import org.apache.flex.utils.CSSContainerUtils;
++	import org.apache.flex.utils.CSSContainerUtils;
++	import org.apache.flex.utils.CSSUtils;
  
      /**
       *  The OneFlexibleChildVerticalLayout class is a simple layout
@@@ -39,17 -39,17 +42,17 @@@
       *  CSS layout rules for margin and padding styles. But it
       *  will size the one child to take up as much or little
       *  room as possible.
--     *  
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
- 	public class OneFlexibleChildVerticalLayout implements IOneFlexibleChildLayout, IDocument
 -	public class OneFlexibleChildVerticalLayout implements IBeadLayout, IDocument
++	public class OneFlexibleChildVerticalLayout extends VerticalLayout implements IOneFlexibleChildLayout, IDocument
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -57,62 -57,50 +60,46 @@@
           */
  		public function OneFlexibleChildVerticalLayout()
  		{
++			super();
  		}
--		
 -        
 -        /**
 -         *  The id of the flexible child
 -         *  
 -         *  @langversion 3.0
 -         *  @playerversion Flash 10.2
 -         *  @playerversion AIR 2.6
 -         *  @productversion FlexJS 0.0
 -         */
 -        public var flexibleChild:String;
 -        
++
++
 +        private var _flexibleChild:String;
-         
++
          private var actualChild:ILayoutChild;
--        
--        // the strand/host container is also an ILayoutChild because
--        // can have its size dictated by the host's parent which is
--        // important to know for layout optimization
--        private var host:ILayoutChild;
--		
++
          /**
           *  @private
           *  The document.
           */
          private var document:Object;
-         
-         /**
-          *  The id of the flexible child
-          *  
-          *  @langversion 3.0
-          *  @playerversion Flash 10.2
-          *  @playerversion AIR 2.6
-          *  @productversion FlexJS 0.0
-          */
-         public function get flexibleChild():String
-         {
-             return _flexibleChild;
-         }
-         
-         /**
-          * @private
-          */
-         public function set flexibleChild(value:String):void
-         {
-             _flexibleChild = value;
-         }
--        
--        /**
--         *  @copy org.apache.flex.core.IBead#strand
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		public function set strand(value:IStrand):void
++
++		/**
++		 *  The id of the flexible child
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get flexibleChild():String
 +		{
-             host = value as ILayoutChild;
++			return _flexibleChild;
 +		}
- 	       
++
++		/**
++		 * @private
++		 */
++		public function set flexibleChild(value:String):void
+ 		{
 -            host = value as ILayoutChild;
++			_flexibleChild = value;
+ 		}
 -	       
++
          private var _maxWidth:Number;
--        
++
          /**
           *  @copy org.apache.flex.core.IBead#maxWidth
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -122,20 -110,20 +109,20 @@@
          {
              return _maxWidth;
          }
--        
++
          /**
--         *  @private 
++         *  @private
           */
          public function set maxWidth(value:Number):void
          {
              _maxWidth = value;
          }
--        
++
          private var _maxHeight:Number;
--        
++
          /**
           *  @copy org.apache.flex.core.IBead#maxHeight
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -145,351 -133,327 +132,202 @@@
          {
              return _maxHeight;
          }
--        
++
          /**
--         *  @private 
++         *  @private
           */
          public function set maxHeight(value:Number):void
          {
              _maxHeight = value;
          }
-         
-         // TODO get rid of this
-         private function getActualChildById(contentView:IParentIUIBase, id:String):ILayoutChild
-         {
-             var result:ILayoutChild;
-             for (var i:int = 0; i < contentView.numElements; i++)
-             {
-                 var child:IStyleableObject = contentView.getElementAt(i) as IStyleableObject;
-                 if (child.id == id)
-                 {
-                     return child as ILayoutChild;
-                 }
-             }
-             return null;
-         }
--        
++
          /**
           * @copy org.apache.flex.core.IBeadLayout#layout
           */
--		public function layout():Boolean
++		COMPILE::JS
++		override public function layout():Boolean
  		{
-             var layoutParent:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -            var layoutParent:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--            var contentView:IParentIUIBase = layoutParent ? layoutParent.contentView : IParentIUIBase(host);
--            var padding:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
-             if (document && document.hasOwnProperty(flexibleChild))
-             {
-                 actualChild = document[flexibleChild];
-             } 
-             else
-             {
-                 actualChild = getActualChildById(contentView, flexibleChild);
-             }
-             
-             var ilc:ILayoutChild;
++			var contentView:ILayoutView = layoutView;
++
+ 			actualChild = document[flexibleChild];
 -            
 -            var ilc:ILayoutChild;
++
++			// set the display on the contentView
++			contentView.element.style["display"] = "flex";
++			contentView.element.style["flex-flow"] = "column";
++			contentView.element.style["align-items"] = "center";
++
  			var n:int = contentView.numElements;
--			var marginLeft:Object;
--			var marginRight:Object;
--			var marginTop:Object;
--			var marginBottom:Object;
--			var margin:Object;
--			maxWidth = 0;
--            
--            var w:Number = contentView.width;			
--            var hh:Number = contentView.height - padding.bottom;
--            var yy:int = padding.top;
--            var flexChildIndex:int;
--            var ml:Number;
--            var mr:Number;
--            var mt:Number;
--            var mb:Number;
--            var lastmb:Number;
--            var lastmt:Number;
--            var halign:Object;
--            var left:Number;
--            var right:Number;
--            
--            for (var i:int = 0; i < n; i++)
--            {
--                var child:IUIBase = contentView.getElementAt(i) as IUIBase;
-                 if (child == null || !child.visible) continue;
--                ilc = child as ILayoutChild;
--                left = ValuesManager.valuesImpl.getValue(child, "left");
--                right = ValuesManager.valuesImpl.getValue(child, "right");
--                if (child == actualChild)
--                {
--                    flexChildIndex = i;
--                    break;
--                }
--                margin = ValuesManager.valuesImpl.getValue(child, "margin");
--                if (margin is Array)
--                {
--                    if (margin.length == 1)
--                        marginLeft = marginTop = marginRight = marginBottom = margin[0];
--                    else if (margin.length <= 3)
--                    {
--                        marginLeft = marginRight = margin[1];
--                        marginTop = marginBottom = margin[0];
--                    }
--                    else if (margin.length == 4)
--                    {
--                        marginLeft = margin[3];
--                        marginBottom = margin[2];
--                        marginRight = margin[1];
--                        marginTop = margin[0];					
--                    }
--                }
--                else if (margin == null)
--                {
--                    marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
--                    marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
--                    marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
--                    marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
--                }
--                else
--                {
--                    marginLeft = marginTop = marginBottom = marginRight = margin;
--                }
--                mt = Number(marginTop);
--                if (isNaN(mt))
--                    mt = 0;
--                mb = Number(marginBottom);
--                if (isNaN(mb))
--                    mb = 0;
--                if (ilc)
--                {
--                    if (!isNaN(ilc.percentHeight))
--                        ilc.setHeight(contentView.height * ilc.percentHeight / 100, !isNaN(ilc.percentWidth));
--                }
--                if (marginLeft == "auto")
--                    ml = 0;
--                else
--                {
--                    ml = Number(marginLeft);
--                    if (isNaN(ml))
--                        ml = 0;
--                }
--                if (marginRight == "auto")
--                    mr = 0;
--                else
--                {
--                    mr = Number(marginRight);
--                    if (isNaN(mr))
--                        mr = 0;
--                }
--                if (child is ILayoutChild)
--                {
--                    ilc = child as ILayoutChild;
--                    if (!isNaN(ilc.percentWidth))
--                        ilc.setWidth(contentView.width * ilc.percentWidth / 100, !isNaN(ilc.percentHeight));
--                }
--                maxWidth = Math.max(maxWidth, ml + child.width + mr);
--                setPositionAndWidth(child, left, ml, padding.left, right, mr, padding.right, w);
--                child.y = yy + mt;
--                yy += child.height + mt + mb;
--                lastmb = mb;
--            }
--
--            if (n > 0 && n > flexChildIndex)
--            {
--                for (i = n - 1; i > flexChildIndex; i--)
--    			{
--    				child = contentView.getElementAt(i) as IUIBase;
-                     if (child == null || !child.visible) continue;
--                    ilc = child as ILayoutChild;
--                    left = ValuesManager.valuesImpl.getValue(child, "left");
--                    right = ValuesManager.valuesImpl.getValue(child, "right");
--    				margin = ValuesManager.valuesImpl.getValue(child, "margin");
--    				if (margin is Array)
--    				{
--    					if (margin.length == 1)
--    						marginLeft = marginTop = marginRight = marginBottom = margin[0];
--    					else if (margin.length <= 3)
--    					{
--    						marginLeft = marginRight = margin[1];
--    						marginTop = marginBottom = margin[0];
--    					}
--    					else if (margin.length == 4)
--    					{
--    						marginLeft = margin[3];
--    						marginBottom = margin[2];
--    						marginRight = margin[1];
--    						marginTop = margin[0];					
--    					}
--    				}
--    				else if (margin == null)
--    				{
--    					marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
--    					marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
--    					marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
--    					marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
--    				}
--    				else
--    				{
--    					marginLeft = marginTop = marginBottom = marginRight = margin;
--    				}
--    				mt = Number(marginTop);
--    				if (isNaN(mt))
--    					mt = 0;
--    				mb = Number(marginBottom);
--    				if (isNaN(mb))
--    					mb = 0;
--                    if (ilc)
--                    {
--                        if (!isNaN(ilc.percentHeight))
--                            ilc.setHeight(contentView.height * ilc.percentHeight / 100, !isNaN(ilc.percentWidth));
--                    }
--    				if (marginLeft == "auto")
--    					ml = 0;
--    				else
--    				{
--    					ml = Number(marginLeft);
--    					if (isNaN(ml))
--    						ml = 0;
--    				}
--    				if (marginRight == "auto")
--    					mr = 0;
--    				else
--    				{
--    					mr = Number(marginRight);
--    					if (isNaN(mr))
--    						mr = 0;
--    				}
--                    if (child is ILayoutChild)
--                    {
--                        ilc = child as ILayoutChild;
--                        if (!isNaN(ilc.percentWidth))
--                            ilc.setWidth(contentView.width * ilc.percentWidth / 100, !isNaN(ilc.percentHeight));
--                    }
--                    setPositionAndWidth(child, left, ml, padding.left, right, mr, padding.right, w);
--                    maxWidth = Math.max(maxWidth, ml + child.width + mr);
--                    child.y = hh - child.height - mb;
--    				hh -= child.height + mt + mb;
--    				lastmt = mt;
--    			}
--            } 
--            
--            child = contentView.getElementAt(flexChildIndex) as IUIBase;
--            ilc = child as ILayoutChild;
--            left = ValuesManager.valuesImpl.getValue(child, "left");
--            right = ValuesManager.valuesImpl.getValue(child, "right");
--            margin = ValuesManager.valuesImpl.getValue(child, "margin");
--            if (margin is Array)
--            {
--                if (margin.length == 1)
--                    marginLeft = marginTop = marginRight = marginBottom = margin[0];
--                else if (margin.length <= 3)
--                {
--                    marginLeft = marginRight = margin[1];
--                    marginTop = marginBottom = margin[0];
--                }
--                else if (margin.length == 4)
--                {
--                    marginLeft = margin[3];
--                    marginBottom = margin[2];
--                    marginRight = margin[1];
--                    marginTop = margin[0];					
--                }
--            }
--            else if (margin == null)
--            {
--                marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
--                marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
--                marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
--                marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
--            }
--            else
--            {
--                marginLeft = marginTop = marginBottom = marginRight = margin;
--            }
--            mt = Number(marginTop);
--            if (isNaN(mt))
--                mt = 0;
--            mb = Number(marginBottom);
--            if (isNaN(mb))
--                mb = 0;
--            if (ilc)
--            {
--                if (!isNaN(ilc.percentHeight))
--                    ilc.setHeight(contentView.height * ilc.percentHeight / 100, !isNaN(ilc.percentWidth));
--            }
--            if (marginLeft == "auto")
--                ml = 0;
--            else
--            {
--                ml = Number(marginLeft);
--                if (isNaN(ml))
--                    ml = 0;
--            }
--            if (marginRight == "auto")
--                mr = 0;
--            else
--            {
--                mr = Number(marginRight);
--                if (isNaN(mr))
--                    mr = 0;
--            }
--            if (child is ILayoutChild)
--            {
--                ilc = child as ILayoutChild;
--                if (!isNaN(ilc.percentWidth))
--                    ilc.setWidth(contentView.width * ilc.percentWidth / 100, !isNaN(ilc.percentHeight));
--            }
--            setPositionAndWidth(child, left, ml, padding.left, right, mr, padding.right, w);
--            maxWidth = Math.max(maxWidth, ml + child.width + mr);
--            child.y = yy + mt;
--            child.height = hh - mb - child.y;
--            
--            return true;
++			if (n == 0) return false;
++
++			for(var i:int=0; i < n; i++) {
++				var child:UIBase = contentView.getElementAt(i) as UIBase;
++				child.element.style["flex-grow"] = (child == actualChild) ? "1" : "0";
++				child.element.style["flex-shrink"] = "0";
++			}
++
++			return true;
++		}
++
++		COMPILE::SWF
++		override public function layout():Boolean
++		{
++			var contentView:ILayoutView = layoutView;
++			var actualChild:IUIBase = document.hasOwnProperty(flexibleChild) ? document[flexibleChild] : null;
++
++			var n:Number = contentView.numElements;
++			if (n == 0) return false;
++			
++			// if the layoutView has no determined height, this layout cannot run
++			// so fall back to VerticalLayout
++			if (host.isHeightSizedToContent()) {
++				return super.layout();
++			}
++
++			var maxWidth:Number = 0;
++			var maxHeight:Number = 0;
++			var hostSizedToContent:Boolean = host.isWidthSizedToContent();
++			var hostWidth:Number = hostSizedToContent ? 0 : contentView.width;
++			var hostHeight:Number = contentView.height;
++
++			var ilc:ILayoutChild;
++			var data:Object;
++			var canAdjust:Boolean = false;
++			var margins:Object;
++
++			var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++			var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
++			
++			// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++			// resulting adjusted value may be less than zero.
++			hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++			hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++
++			var xpos:Number = borderMetrics.left + paddingMetrics.left;
++			var ypos:Number = borderMetrics.top + paddingMetrics.left;
++			var child:IUIBase;
++			var childWidth:Number;
++			var i:int;
++			var childXpos:Number;
++			var adjustTop:Number = 0;
++			var adjustBottom:Number = hostHeight + borderMetrics.top + paddingMetrics.top;
++
++			// first work from top to bottom
++			for(i=0; i < n; i++)
++			{
++				child = contentView.getElementAt(i) as IUIBase;
++				if (child == null || !child.visible) continue;
++				if (child == actualChild) break;
++
++				margins = childMargins(child, hostWidth, hostHeight);
++				ilc = child as ILayoutChild;
++
++				ypos += margins.top;
++
++				childXpos = xpos + margins.left; // default x position
++
++				if (!hostSizedToContent) {
++					childWidth = child.width;
++					if (ilc != null && !isNaN(ilc.percentWidth)) {
++						childWidth = hostWidth * ilc.percentWidth/100.0;
++						ilc.setWidth(childWidth);
++					}
++					// the following code middle-aligns the child
++					childXpos = hostWidth/2 - childWidth/2 + xpos;
++				}
++
++				if (ilc) {
++					ilc.setX(childXpos);
++					ilc.setY(ypos);
++
++					if (!isNaN(ilc.percentHeight)) {
++						ilc.setHeight(hostHeight * ilc.percentHeight / 100);
++					}
++
++				} else {
++					child.x = childXpos;
++					child.y = ypos;
++				}
++
++				ypos += child.height + margins.bottom;
++				adjustTop = ypos;
++			}
++
++			// then work from bottom to top
++			ypos = hostHeight + borderMetrics.top + paddingMetrics.top;
++
++			for(i=(n-1); actualChild != null && i >= 0; i--)
++			{
++				child = contentView.getElementAt(i) as IUIBase;
++				if (child == null || !child.visible) continue;
++				if (child == actualChild) break;
++
++				margins = childMargins(child, hostWidth, hostHeight);
++				ilc = child as ILayoutChild;
++
++				childXpos = xpos + margins.left; // default x position
++
++				if (!hostSizedToContent) {
++					childWidth = child.width;
++					if (ilc != null && !isNaN(ilc.percentWidth)) {
++						childWidth = hostWidth * ilc.percentWidth/100.0;
++						ilc.setWidth(childWidth);
++					}
++					// the following code middle-aligns the child
++					childXpos = hostWidth/2 - childWidth/2 + xpos;
++				}
++
++				if (ilc) {
++					if (!isNaN(ilc.percentHeight)) {
++						ilc.setHeight(hostHeight * ilc.percentHeight / 100);
++					}
++				}
++
++				ypos -= child.height + margins.bottom;
++
++				if (ilc) {
++					ilc.setX(childXpos);
++					ilc.setY(ypos);
++				} else {
++					child.x = childXpos;
++					child.y = ypos;
++				}
++
++				ypos -= margins.top;
++				adjustBottom = ypos;
++			}
++
++			// now adjust the actualChild to fill the space.
++			if (actualChild != null) {
++				margins = childMargins(actualChild, hostWidth, hostHeight);
++				ilc = actualChild as ILayoutChild;
++				if (!hostSizedToContent) {
++					childWidth = actualChild.width;
++					if (ilc != null && !isNaN(ilc.percentWidth)) {
++						childWidth = hostWidth * ilc.percentWidth/100.0;
++						ilc.setWidth(childWidth);
++					}
++				}
++				childXpos = xpos + margins.left;
++				if (!hostSizedToContent) {
++					childXpos = hostWidth/2 - childWidth/2 + xpos;
++				}
++				actualChild.x = childXpos
++				actualChild.y = adjustTop + margins.top;
++				if (ilc) {
++					ilc.setHeight((adjustBottom-margins.bottom) - (adjustTop+margins.top));
++				} else {
++					actualChild.height = (adjustBottom-margins.bottom) - (adjustTop+margins.top);
++				}
++			}
++
++			return true;
  		}
  
--        private function setPositionAndWidth(child:IUIBase, left:Number, ml:Number, pl:Number,
--                                             right:Number, mr:Number, pr:Number, w:Number):void
--        {
--            var widthSet:Boolean = false;
--            
--            var ww:Number = w;
--            var ilc:ILayoutChild = child as ILayoutChild;
--            if (!isNaN(left))
--            {
--                child.x = left + ml;
--                ww -= left + ml;
--            }
--            else 
--            {
--                if (isNaN(right))
--                    child.x = ml + pl;
--                ww -= ml;
--            }
--            if (!isNaN(right))
--            {
--                if (!isNaN(left))
--                {
--                    if (ilc)
--                        ilc.setWidth(ww - right - mr, true);
--                    else
--                    {
--                        child.width = ww - right - mr;
--                        widthSet = true;
--                    }
--                }
--                else
--                    child.x = w - right - mr - child.width - 1; // some browsers don't like going all the way to the edge
--            }
--            if (ilc)
--            {
--                if (!isNaN(ilc.percentWidth))
--                    ilc.setWidth(w * ilc.percentWidth / 100, true);
--            }
--            if (!widthSet)
--                child.dispatchEvent(new Event("sizeChanged"));
--        }
--        
          public function setDocument(document:Object, id:String = null):void
          {
--            this.document = document;	
++            this.document = document;
          }
--        
++
      }
--        
++
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TileLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TileLayout.as
index 8c489d6,a7917ff..4ff6565
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TileLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/TileLayout.as
@@@ -18,16 -18,14 +18,21 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
  {
++	import org.apache.flex.core.LayoutBase;
  	import org.apache.flex.core.IBeadLayout;
-     import org.apache.flex.core.IChild;
  	import org.apache.flex.core.ILayoutHost;
-     import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ILayoutParent;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
++	import org.apache.flex.core.IChild;
  	import org.apache.flex.core.UIBase;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.geom.Rectangle;
++	import org.apache.flex.utils.CSSUtils;
++	import org.apache.flex.utils.CSSContainerUtils;
  
  	/**
  	 *  The TileLayout class bead sizes and positions the elements it manages into rows and columns.
@@@ -40,7 -38,7 +45,7 @@@
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class TileLayout implements IBeadLayout
++	public class TileLayout extends LayoutBase implements IBeadLayout
  	{
  		/**
  		 *  constructor.
@@@ -52,21 -50,21 +57,7 @@@
  		 */
  		public function TileLayout()
  		{
--		}
--
--		private var _strand:IStrand;
--
--		/**
--		 *  @copy org.apache.flex.core.IBead#strand
--		 *
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function set strand(value:IStrand):void
--		{
--			_strand = value;
++			super();
  		}
  
  		private var _numColumns:Number = 4;
@@@ -131,14 -129,14 +122,14 @@@
          /**
           * @copy org.apache.flex.core.IBeadLayout#layout
           */
--		public function layout():Boolean
++		override public function layout():Boolean
  		{
++			var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++			var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
++			
  			COMPILE::SWF
  			{
--				// this is where the layout is calculated
--				var host:UIBase = _strand as UIBase;
-                 var p:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -				var p:ILayoutHost = _strand.getBeadByType(ILayoutHost) as ILayoutHost;
--				var area:UIBase = p.contentView as UIBase;
++				var area:UIBase = layoutView as UIBase;
  
  				var xpos:Number = 0;
  				var ypos:Number = 0;
@@@ -146,20 -144,19 +137,23 @@@
  				var useHeight:Number = rowHeight;
  				var n:Number = area.numElements;
  				if (n == 0) return false;
++				
++				var adjustedWidth:Number = Math.floor(host.width - borderMetrics.left - borderMetrics.right);
++				var adjustedHeight:Number = Math.floor(host.height - borderMetrics.top - borderMetrics.bottom);
  
  				var realN:Number = n;
  				for(var j:int=0; j < n; j++)
  				{
  					var testChild:IUIBase = area.getElementAt(i) as IUIBase;
-                     if (testChild == null || !testChild.visible) realN--;
 -					if (testChild && !testChild.visible) realN--;
++					if (testChild == null || !testChild.visible) realN--;
  				}
  
--				if (isNaN(useWidth)) useWidth = Math.floor(host.width / numColumns); // + gap
++				if (isNaN(useWidth)) useWidth = Math.floor(adjustedWidth / numColumns); // + gap
  				if (isNaN(useHeight)) {
  					// given the width and total number of items, how many rows?
  					var numRows:Number = Math.floor(realN/numColumns);
-                     if (host.isHeightSizedToContent) useHeight = 30; // default height
-                     else useHeight = Math.floor(host.height / numRows);
 -					useHeight = Math.floor(host.height / numRows);
++					if (host.isHeightSizedToContent) useHeight = 30; // default height
++					else useHeight = Math.floor(adjustedHeight / numRows);
  				}
  
  				var maxWidth:Number = useWidth;
@@@ -168,7 -165,7 +162,7 @@@
  				for(var i:int=0; i < n; i++)
  				{
  					var child:IUIBase = area.getElementAt(i) as IUIBase;
-                     if (child == null || !child.visible) continue;
 -					if (child && !child.visible) continue;
++					if (child == null || !child.visible) continue;
  					child.width = useWidth;
  					child.height = useHeight;
  					child.x = xpos;
@@@ -193,8 -190,8 +187,6 @@@
  				// size is stored in the model.
  				var sizeChanged:Boolean = true;
  
--				IEventDispatcher(_strand).dispatchEvent( new Event("layoutComplete") );
--
  				return sizeChanged;
  			}
  			COMPILE::JS
@@@ -207,17 -204,15 +199,17 @@@
  				var ypos:Number;
  				var useWidth:Number;
  				var useHeight:Number;
++				var adjustedWidth:Number = Math.floor(host.width - borderMetrics.left - borderMetrics.right);
++				var adjustedHeight:Number = Math.floor(host.height - borderMetrics.top - borderMetrics.bottom);
  
--				var host:UIBase = _strand as UIBase;
-                 var viewBead:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -				var viewBead:ILayoutHost = _strand.getBeadByType(ILayoutHost) as ILayoutHost;
--				var contentView:IParentIUIBase = viewBead.contentView;
++				var contentView:IParentIUIBase = layoutView as IParentIUIBase;
++				
  				children = contentView.internalChildren();
  				n = children.length;
  				if (n === 0) return false;
  
--				viewBead.contentView.width = host.width;
-                 viewBead.contentView.element.style["display"] = "flex";
-                 viewBead.contentView.element.style["flex-flow"] = "row wrap";
++				contentView.element.style["display"] = "flex";
++				contentView.element.style["flex-flow"] = "row wrap";
  
  				var realN:int = n;
  				for (i = 0; i < n; i++)
@@@ -231,12 -226,11 +223,14 @@@
  				useWidth = columnWidth;
  				useHeight = rowHeight;
  
--				if (isNaN(useWidth)) useWidth = Math.floor(host.width / numColumns); // + gap
++				if (isNaN(useWidth)) {
++					useWidth = Math.floor(adjustedWidth / numColumns); // + gap
++				}
  				if (isNaN(useHeight)) {
  					// given the width and total number of items, how many rows?
  					var numRows:Number = Math.floor(realN / numColumns);
-                     if (host.isHeightSizedToContent) useHeight = 30; // default height
-                     else useHeight = Math.floor(host.height / numRows);
 -					useHeight = Math.floor(host.height / numRows);
++					if (host.isHeightSizedToContent) useHeight = 30; // default height
++					else useHeight = Math.floor(adjustedHeight / numRows);
  				}
  
  				for (i = 0; i < n; i++)

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalColumnLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalColumnLayout.as
index 3117d22,6eaa30a..e489d85
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalColumnLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalColumnLayout.as
@@@ -17,11 -17,10 +17,13 @@@
  //
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
--{	
++{
++	import org.apache.flex.core.LayoutBase;
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.IContainer;
  	import org.apache.flex.core.ILayoutHost;
-     import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ILayoutParent;
  	import org.apache.flex.core.IMeasurementBead;
  	import org.apache.flex.core.IParent;
  	import org.apache.flex.core.IStrand;
@@@ -32,23 -31,23 +34,23 @@@
  	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.geom.Rectangle;
  	import org.apache.flex.utils.CSSUtils;
--    import org.apache.flex.utils.CSSContainerUtils;    
--	
++    import org.apache.flex.utils.CSSContainerUtils;
++
  	/**
  	 * ColumnLayout is a class that organizes the positioning of children
  	 * of a container into a set of columns where each column's width is set to
  	 * the maximum size of all of the children in that column.
--	 *  
++	 *
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class VerticalColumnLayout implements IBeadLayout
++	public class VerticalColumnLayout extends LayoutBase implements IBeadLayout
  	{
  		/**
  		 *  constructor
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -56,29 -55,29 +58,15 @@@
  		 */
  		public function VerticalColumnLayout()
  		{
++			super();
  		}
--		
--		private var _strand:IStrand;
--		
--		/**
--		 *  @copy org.apache.flex.core.IBead#strand
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function set strand(value:IStrand):void
--		{
--			_strand = value;
--		}
--		
--		
++
++
  		private var _numColumns:int;
--		
++
  		/**
  		 * The number of columns.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -92,19 -91,19 +80,18 @@@
  		{
  			_numColumns = value;
  		}
--		
++
          /**
           * @copy org.apache.flex.core.IBeadLayout#layout
           */
--		public function layout():Boolean
--		{			
--            var host:UIBase = UIBase(_strand);
-             var layoutParent:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -            var layoutParent:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--            var contentView:IParent = layoutParent.contentView;
++		override public function layout():Boolean
++		{
++			var contentView:ILayoutView = layoutView;
++			
              var padding:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
  			var sw:Number = host.width;
  			var sh:Number = host.height;
--			
++
              var hasWidth:Boolean = !host.isWidthSizedToContent();
              var hasHeight:Boolean = !host.isHeightSizedToContent();
  			var e:IUIBase;
@@@ -116,45 -115,44 +103,29 @@@
  			for (i = 0; i < numColumns; i++)
  				columns[i] = 0;
  
--            var marginLeft:Object;
--            var marginRight:Object;
--            var marginTop:Object;
--            var marginBottom:Object;
--            var margin:Object;
--            var ml:Number;
--            var mr:Number;
--            var mt:Number;
--            var mb:Number;
  			var n:int = contentView.numElements;
              var rowData:Object = { rowHeight: 0 };
--			
++
  			// determine max widths of columns
  			for (i = 0; i < n; i++) {
  				e = contentView.getElementAt(i) as IUIBase;
-                 if (e == null || !e.visible) continue;
--                margin = ValuesManager.valuesImpl.getValue(e, "margin");
--                marginLeft = ValuesManager.valuesImpl.getValue(e, "margin-left");
--                marginTop = ValuesManager.valuesImpl.getValue(e, "margin-top");
--                marginRight = ValuesManager.valuesImpl.getValue(e, "margin-right");
--                marginBottom = ValuesManager.valuesImpl.getValue(e, "margin-bottom");
--                mt = CSSUtils.getTopValue(marginTop, margin, sh);
--                mb = CSSUtils.getBottomValue(marginBottom, margin, sh);
--                mr = CSSUtils.getRightValue(marginRight, margin, sw);
--                ml = CSSUtils.getLeftValue(marginLeft, margin, sw);
--                data.push({ mt: mt, mb: mb, mr: mr, ml: ml});
++				if (e == null || !e.visible) continue;
++				var margins:Object = childMargins(e, sw, sh);
++				
++                data.push({ mt: margins.top, mb: margins.bottom, mr: margins.right, ml: margins.left});
  				var thisPrefWidth:int = 0;
  				if (e is IStrand)
  				{
  					var measure:IMeasurementBead = e.getBeadByType(IMeasurementBead) as IMeasurementBead;
  					if (measure)
--						thisPrefWidth = measure.measuredWidth + ml + mr;
++						thisPrefWidth = measure.measuredWidth + margins.left + margins.right;
  					else
--						thisPrefWidth = e.width + ml + mr;						
++						thisPrefWidth = e.width + margins.left + margins.right;
  				}
  				else
--					thisPrefWidth = e.width + ml + mr;
--				
--                rowData.rowHeight = Math.max(rowData.rowHeight, e.height + mt + mb);
++					thisPrefWidth = e.width + margins.left + margins.right;
++
++                rowData.rowHeight = Math.max(rowData.rowHeight, e.height + margins.top + margins.bottom);
  				columns[col] = Math.max(columns[col], thisPrefWidth);
                  col = col + 1;
                  if (col == numColumns)
@@@ -164,18 -162,17 +135,18 @@@
                      col = 0;
                  }
  			}
--			
++
              var lastmb:Number = 0;
  			var curx:int = padding.left;
  			var cury:int = padding.top;
  			var maxHeight:int = 0;
              var maxWidth:int = 0;
  			col = 0;
--			for (i = 0; i < n; i++) 
++			for (i = 0; i < n; i++)
              {
  				e = contentView.getElementAt(i) as IUIBase;
-                 if (e == null || !e.visible) continue;
--				e.x = curx + ml;
++				if (e == null || !e.visible) continue;
++				e.x = curx + data[i].ml;
  				e.y = cury + data[i].mt;
  				curx += columns[col++];
                  maxHeight = Math.max(maxHeight, e.y + e.height + data[i].mb);
@@@ -188,14 -185,14 +159,6 @@@
  					curx = padding.left;
  				}
  			}
--			if (!hasWidth && n > 0 && !isNaN(maxWidth))
--            {
--                UIBase(contentView).setWidth(maxWidth, true);
--            }
--            if (!hasHeight && n > 0 && !isNaN(maxHeight))
--            {
--                UIBase(contentView).setHeight(maxHeight, true);
--            }
  			return true;
  		}
  	}


[27/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - sync up a change to UIHTMLWrapper

Posted by ah...@apache.org.
sync up a change to UIHTMLWrapper


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/8d8ba2f2
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/8d8ba2f2
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/8d8ba2f2

Branch: refs/heads/develop
Commit: 8d8ba2f256ee6b4287d6b455ac654457f8b976d9
Parents: 0865052
Author: Alex Harui <ah...@apache.org>
Authored: Mon Apr 24 20:58:42 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Mon Apr 24 20:58:42 2017 -0700

----------------------------------------------------------------------
 .../src/main/flex/org/apache/flex/core/HTMLElementWrapper.as | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/8d8ba2f2/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/HTMLElementWrapper.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/HTMLElementWrapper.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/HTMLElementWrapper.as
index 6ba908d..d67686e 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/HTMLElementWrapper.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/HTMLElementWrapper.as
@@ -108,7 +108,7 @@ package org.apache.flex.core
         /**
          * allow access from overrides
          */
-		protected var _model:IBeadModel;
+		protected var _model:Object;
         
         /**
          * @flexjsignorecoercion Class 
@@ -127,11 +127,15 @@ package org.apache.flex.core
             return _model;
         }
         
+        [Bindable("modelChanged")]
         public function set model(value:Object):void
         {
             if (_model != value)
             {
-                addBead(value as IBead);
+                if (value is IBead)
+                    addBead(value as IBead);
+                else
+                    _model = value;
                 dispatchEvent(new org.apache.flex.events.Event("modelChanged"));
             }
         }


[44/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - in browser, looks like block stretches child blocks

Posted by ah...@apache.org.
in browser, looks like block stretches child blocks


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/e981c3d3
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/e981c3d3
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/e981c3d3

Branch: refs/heads/develop
Commit: e981c3d3119f6240504ee4c1ddb25d6c8f7a2dc9
Parents: 8377006
Author: Alex Harui <ah...@apache.org>
Authored: Fri Apr 28 00:00:52 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Apr 28 00:00:52 2017 -0700

----------------------------------------------------------------------
 .../flex/org/apache/flex/html/beads/layouts/VerticalLayout.as   | 5 +++++
 1 file changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/e981c3d3/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
index 6357e9f..16c81a0 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
@@ -126,6 +126,11 @@ package org.apache.flex.html.beads.layouts
 							childWidth = hostWidth * ilc.percentWidth/100.0;
 							ilc.setWidth(childWidth);
 						}
+						else if (ilc.isWidthSizedToContent() && !margins.auto)
+						{
+							childWidth = hostWidth;
+							ilc.setWidth(childWidth);
+						}
 						if (margins.auto)
 							childXpos = (hostWidth - childWidth) / 2;
 					}


[50/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual

Posted by ah...@apache.org.
Merge branch 'develop' into dual

Conflicts:
	frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/SliderView.as


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/b350e4de
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/b350e4de
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/b350e4de

Branch: refs/heads/develop
Commit: b350e4de95e985aa68b4a208c77aee3e9f357781
Parents: e087822 fd709d1
Author: Alex Harui <ah...@apache.org>
Authored: Sun Apr 30 20:07:46 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Sun Apr 30 20:07:46 2017 -0700

----------------------------------------------------------------------
 LICENSE                                         | 24 +++++++++++++-
 NOTICE                                          |  2 +-
 .../CordovaCameraExample-app.xml                |  2 +-
 examples/flexjs/DesktopMap/DesktopMap-app.xml   |  2 +-
 examples/flexjs/MapSearch/MapSearch-app.xml     |  2 +-
 .../flexjs/MobileStocks/MobileStocks-app.xml    |  2 +-
 .../StorageExample/StorageExample-app.xml       |  2 +-
 .../main/flex/org/apache/flex/html/DateField.as | 33 +++++---------------
 .../org/apache/flex/html/beads/SliderView.as    |  4 +++
 .../projects/Core/.actionScriptProperties       |  1 +
 .../flex/org/apache/flex/express/Application.as |  2 ++
 .../projects/Graphics/.actionScriptProperties   |  1 +
 .../projects/HTML/.actionScriptProperties       |  1 +
 13 files changed, 45 insertions(+), 33 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b350e4de/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateField.as
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b350e4de/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SliderView.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SliderView.as
index ea31cf9,071dd8d..009fb8c
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SliderView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SliderView.as
@@@ -183,7 -171,8 +183,11 @@@ package org.apache.flex.html.bead
  		private function setThumbPositionFromValue( value:Number ) : void
  		{
  			var p:Number = (value-rangeModel.minimum)/(rangeModel.maximum-rangeModel.minimum);
 -			var xloc:Number = p*(UIBase(_strand).width - _thumb.width);
 -			
 +			var xloc:Number = (p*_track.width); 
++			COMPILE::JS
++			{
++				_thumb.element.style.position = 'absolute';
++			}
  			_thumb.x = xloc;
  		}
  	}


[07/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundWithChangeListenerBead.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundWithChangeListenerBead.as
index 0000000,0000000..80462c9
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/SolidBackgroundWithChangeListenerBead.as
@@@ -1,0 -1,0 +1,71 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads
++{
++	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.StyleChangeEvent;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.UIBase;
++	import org.apache.flex.html.beads.SolidBackgroundBead;
++	
++	/**
++	 * Same as SolidBackgroundBead except it listens for StyleChangeEvent events
++	 * and reacts by refreshing the background of its strand.
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++	 */
++	public class SolidBackgroundWithChangeListenerBead extends SolidBackgroundBead
++	{
++		/**
++		 * Constructor.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++		 */
++		public function SolidBackgroundWithChangeListenerBead()
++		{
++			super();
++		}
++		
++		/**
++		 * @private
++		 */
++		override public function set strand(value:IStrand):void
++		{
++			super.strand = value;
++			IEventDispatcher(value).addEventListener(StyleChangeEvent.STYLE_CHANGE, handleStyleChange);
++
++		}
++		
++		/**
++		 * @private
++		 */
++		private function handleStyleChange(event:StyleChangeEvent):void
++		{
++			setupStyle();
++			changeHandler(null);
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.as
index a0910d3,9ffd9fe..7752e90
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.as
@@@ -19,6 -19,6 +19,7 @@@
  package org.apache.flex.html.beads
  {
      import org.apache.flex.core.IBead;
++	import org.apache.flex.core.IList;
  	import org.apache.flex.core.IDataProviderItemRendererMapper;
      import org.apache.flex.core.IItemRendererClassFactory;
      import org.apache.flex.core.IItemRendererParent;
@@@ -75,24 -75,23 +76,26 @@@
  		public function set strand(value:IStrand):void
  		{
  			_strand = value;
--			IEventDispatcher(value).addEventListener("beadsAdded",finishSetup);
  			IEventDispatcher(value).addEventListener("initComplete",finishSetup);
  		}
  		
  		private function finishSetup(event:Event):void
  		{
  			selectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
--			var listView:IListView = _strand.getBeadByType(IListView) as IListView;
--			dataGroup = listView.dataGroup;
  			selectionModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
              
-             _itemRendererFactory = _strand.getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
-             if (!_itemRendererFactory)
++			// if the host component inherits from DataContainerBase, the itemRendererClassFactory will 
++			// already have been loaded by DataContainerBase.addedToParent function.
+             if (!itemRendererFactory)
              {
--                _itemRendererFactory = new (ValuesManager.valuesImpl.getValue(_strand, "iItemRendererClassFactory")) as IItemRendererClassFactory;
--                _strand.addBead(_itemRendererFactory);
++				_itemRendererFactory = _strand.getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
++				if (!_itemRendererFactory)
++				{
++	                _itemRendererFactory = new (ValuesManager.valuesImpl.getValue(_strand, "iItemRendererClassFactory")) as IItemRendererClassFactory;
++    	            _strand.addBead(_itemRendererFactory);
++				}
              }
-                             
+             
  			dataProviderChangeHandler(null);
  		}
  		
@@@ -126,23 -125,23 +129,24 @@@
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
           *  @productversion FlexJS 0.0
--         */
--		protected var dataGroup:IItemRendererParent;
--		
++         */		
  		private function dataProviderChangeHandler(event:Event):void
  		{
  			var dp:Array = selectionModel.dataProvider as Array;
  			if (!dp)
  				return;
  			
--			dataGroup.removeAllElements();
++			var list:IList = _strand as IList;
++			var dataGroup:IItemRendererParent = list.dataGroup;
++			
++			dataGroup.removeAllItemRenderers();
  			
  			var n:int = dp.length; 
  			for (var i:int = 0; i < n; i++)
  			{
  				var tf:ITextItemRenderer = itemRendererFactory.createItemRenderer(dataGroup) as ITextItemRenderer;
                  tf.index = i;
--                dataGroup.addElement(tf);
++                dataGroup.addItemRenderer(tf);
                  if (selectionModel.labelField)
                      tf.text = dp[i][selectionModel.labelField];
                  else

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForStringVectorData.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForStringVectorData.as
index b0c11b5,b0c11b5..d0d49a2
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForStringVectorData.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextItemRendererFactoryForStringVectorData.as
@@@ -22,8 -22,8 +22,10 @@@ package org.apache.flex.html.bead
      import org.apache.flex.core.IBead;
      import org.apache.flex.core.IItemRendererClassFactory;
      import org.apache.flex.core.IItemRendererParent;
++	import org.apache.flex.core.IList;
      import org.apache.flex.core.ISelectionModel;
      import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.EventDispatcher;
  	import org.apache.flex.events.IEventDispatcher;
@@@ -74,15 -74,15 +76,26 @@@
  		public function set strand(value:IStrand):void
  		{
  			_strand = value;
--			IEventDispatcher(value).addEventListener("beadsAdded",finishSetup);
++			IEventDispatcher(value).addEventListener("initComplete",finishSetup);
  		}
  		
  		private function finishSetup(event:Event):void
  		{
  			selectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
--			var listView:IListView = _strand.getBeadByType(IListView) as IListView;
--			dataGroup = listView.dataGroup;
--			selectionModel.addEventListener("dataProviderChange", dataProviderChangeHandler);
++			selectionModel.addEventListener("dataProviderChanged", dataProviderChangeHandler);
++			
++			// if the host component inherits from DataContainerBase, the itemRendererClassFactory will 
++			// already have been loaded by DataContainerBase.addedToParent function.
++			if (!itemRendererFactory)
++			{
++				_itemRendererFactory = _strand.getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
++				if (!_itemRendererFactory)
++				{
++					_itemRendererFactory = new (ValuesManager.valuesImpl.getValue(_strand, "iItemRendererClassFactory")) as IItemRendererClassFactory;
++					_strand.addBead(_itemRendererFactory);
++				}
++			}
++			
  			dataProviderChangeHandler(null);
  		}
  		
@@@ -123,14 -123,14 +136,17 @@@
  		{
  			var dp:Vector.<String> = selectionModel.dataProvider as Vector.<String>;
  			
--			dataGroup.removeAllElements();
++			var list:IList = _strand as IList;
++			var dataGroup:IItemRendererParent = list.dataGroup;
++			
++			dataGroup.removeAllItemRenderers();
  			
  			var n:int = dp.length; 
  			for (var i:int = 0; i < n; i++)
  			{
  				var tf:ITextItemRenderer = itemRendererFactory.createItemRenderer(dataGroup) as ITextItemRenderer;
                  tf.index = i;
--                dataGroup.addElement(tf);
++                dataGroup.addItemRenderer(tf);
  				tf.text = dp[i];
  				
  				var newEvent:ItemRendererEvent = new ItemRendererEvent(ItemRendererEvent.CREATED);

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TitleBarView.mxml
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TitleBarView.mxml
index 206f43e,206f43e..0f27523
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TitleBarView.mxml
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TitleBarView.mxml
@@@ -47,12 -47,12 +47,12 @@@ limitations under the License
          <js:LayoutChangeNotifier watchedProperty="{titleLabel.text}" />
      </js:beads>
  
--    <js:Label id="titleLabel" text="{ITitleBarModel(model).title}" >
++    <js:Label id="titleLabel" text="{ITitleBarModel(model).title}" className="TitleBarTitle" >
          <js:style>
--            <js:SimpleCSSStyles fontWeight="inherit" margin="5" />
++            <js:SimpleCSSStyles fontWeight="inherit" marginRight="5" marginLeft="5" />
          </js:style>
      </js:Label>
--    <js:CloseButton id="closeButton" click="clickHandler()"
--                       visible="{ITitleBarModel(model).showCloseButton}"/>
++    <js:CloseButton id="closeButton" click="clickHandler()" className="TitleBarCloseButton"
++                    visible="{ITitleBarModel(model).showCloseButton}"/>
      
  </js:MXMLBeadView>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/controllers/ComboBoxController.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/controllers/ComboBoxController.as
index b381b5b,12fb59c..a3d3dc2
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/controllers/ComboBoxController.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/controllers/ComboBoxController.as
@@@ -42,39 -66,39 +42,39 @@@ package org.apache.flex.html.beads.cont
  		public function set strand(value:IStrand):void
  		{
  			_strand = value;
 -            IEventDispatcher(value).addEventListener(MouseEvent.CLICK, clickHandler);
 +			
 +			viewBead = _strand.getBeadByType(IComboBoxView) as IComboBoxView;
 +			if (viewBead) {
 +				finishSetup(null);
 +			} else {
 +				IEventDispatcher(_strand).addEventListener("viewChanged", finishSetup);
 +			}
 +		}
 +		
 +		private function finishSetup(event:Event):void
 +		{
 +			if (viewBead == null) {
 +				viewBead = _strand.getBeadByType(IComboBoxView) as IComboBoxView;
 +			}
 +			
 +			IEventDispatcher(viewBead.popupButton).addEventListener("click", handleButtonClick);
- 			IEventDispatcher(viewBead.popUp).addEventListener("change", handleListChange);
  		}
  		
 -		/**
 -		 * @private
 -		 */
 -        private function clickHandler(event:MouseEvent):void
 -        {
 -            var viewBead:IComboBoxView = _strand.getBeadByType(IComboBoxView) as IComboBoxView;
 -            viewBead.popUpVisible = true;
 -            var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
 -            var popUpModel:ISelectionModel = viewBead.popUp.getBeadByType(ISelectionModel) as ISelectionModel;
 -            popUpModel.dataProvider = selectionModel.dataProvider;
 -            popUpModel.selectedIndex = selectionModel.selectedIndex;
 -			DisplayObject(viewBead.popUp).width = DisplayObject(_strand).width;
 -			DisplayObject(viewBead.popUp).height = 200;
 -			DisplayObject(viewBead.popUp).x = DisplayObject(_strand).x;
 -			DisplayObject(viewBead.popUp).y = DisplayObject(_strand).y;
 -            IEventDispatcher(viewBead.popUp).addEventListener("change", changeHandler);
 -        }
 -        
 -		/**
 -		 * @private
 -		 */
 -        private function changeHandler(event:Event):void
 -        {
 -            var viewBead:IComboBoxView = _strand.getBeadByType(IComboBoxView) as IComboBoxView;
 -            viewBead.popUpVisible = false;
 -            var selectionModel:ISelectionModel = _strand.getBeadByType(ISelectionModel) as ISelectionModel;
 -            var popUpModel:ISelectionModel = viewBead.popUp.getBeadByType(ISelectionModel) as ISelectionModel;
 -            selectionModel.selectedIndex = popUpModel.selectedIndex;
 +		private function handleButtonClick(event:MouseEvent):void
 +		{			
 +			viewBead.popUpVisible = !viewBead.popUpVisible;
++			IEventDispatcher(viewBead.popUp).addEventListener("change", handleListChange);
 +		}
 +		
 +		private function handleListChange(event:Event):void
 +		{
 +			var list:List = viewBead.popUp as List;
 +			var input:TextInput = viewBead.textInputField as TextInput;
 +			input.text = list.selectedItem as String;
 +			
 +			viewBead.popUpVisible = false;
 +			
  			IEventDispatcher(_strand).dispatchEvent(new Event("change"));
 -        }
 -	
 +		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
index 096d721,b566354..72c42d8
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/BasicLayout.as
@@@ -18,12 -18,11 +18,14 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
  {
++	import org.apache.flex.core.LayoutBase;
  	
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.ILayoutChild;
  	import org.apache.flex.core.ILayoutHost;
-     import org.apache.flex.core.ILayoutParent;
--	import org.apache.flex.core.IParentIUIBase;
++	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.IParent;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
      import org.apache.flex.core.UIBase;
@@@ -31,24 -30,24 +33,23 @@@
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
      import org.apache.flex.utils.CSSUtils;
--	//import org.apache.flex.utils.dbg.DOMPathUtil;
  
      /**
       *  The BasicLayout class is a simple layout
       *  bead.  It takes the set of children and lays them out
       *  as specified by CSS properties like left, right, top
       *  and bottom.
--     *  
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class BasicLayout implements IBeadLayout
++	public class BasicLayout extends LayoutBase implements IBeadLayout
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -56,391 -55,389 +57,136 @@@
           */
  		public function BasicLayout()
  		{
++			super();
  		}
--		
--        // the strand/host container is also an ILayoutChild because
--        // can have its size dictated by the host's parent which is
--        // important to know for layout optimization
--        private var host:ILayoutChild;
--        		
--        /**
--         *  @copy org.apache.flex.core.IBead#strand
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		public function set strand(value:IStrand):void
--		{
--            host = value as ILayoutChild;
--		}
--	        
++
          /**
           * @copy org.apache.flex.core.IBeadLayout#layout
  		 * @flexjsignorecoercion org.apache.flex.core.ILayoutHost
  		 * @flexjsignorecoercion org.apache.flex.core.UIBase
           */
--		public function layout():Boolean
++		override public function layout():Boolean
  		{
              COMPILE::SWF
              {
--                //trace(DOMPathUtil.getPath(host), event ? event.type : "fixed size");
-                 var layoutParent:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -                var layoutParent:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--                var contentView:IParentIUIBase = layoutParent ? layoutParent.contentView : IParentIUIBase(host);
--                
--                var gotMargin:Boolean;
--                var marginLeft:Object;
--                var marginRight:Object;
--                var marginTop:Object;
--                var marginBottom:Object;
--                var margin:Object;
--                var ml:Number;
--                var mr:Number;
--                var mt:Number;
--                var mb:Number;
--                var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
--                var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
--                var w:Number = hostWidthSizedToContent ? 0 : contentView.width;
--                var h:Number = hostHeightSizedToContent ? 0 : contentView.height;
--                var n:int = contentView.numElements;
--                var maxWidth:Number = 0;
--                var maxHeight:Number = 0;
--                var childData:Array = [];
++				var contentView:ILayoutView = layoutView;
++
++				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
++				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
++
++				var w:Number = hostWidthSizedToContent ? 0 : contentView.width;
++				var h:Number = hostHeightSizedToContent ? 0 : contentView.height;
++
++				var n:int = contentView.numElements;
++
                  for (var i:int = 0; i < n; i++)
                  {
                      var child:IUIBase = contentView.getElementAt(i) as IUIBase;
-                     if (child == null || !child.visible) continue;
--                    var left:Number = ValuesManager.valuesImpl.getValue(child, "left");
--                    var right:Number = ValuesManager.valuesImpl.getValue(child, "right");
--                    var top:Number = ValuesManager.valuesImpl.getValue(child, "top");
--                    var bottom:Number = ValuesManager.valuesImpl.getValue(child, "bottom");
++					if (child == null || !child.visible) continue;
++
++					var positions:Object = childPositions(child);
++					var margins:Object = childMargins(child, contentView.width, contentView.height);
                      var ww:Number = w;
                      var hh:Number = h;
--                    
++
                      var ilc:ILayoutChild = child as ILayoutChild;
--                    if (!isNaN(left))
++
++					// set the top edge of the child
++                    if (!isNaN(positions.left))
                      {
                          if (ilc)
--                            ilc.setX(left);
++                            ilc.setX(positions.left+margins.left);
                          else
--                            child.x = left;
--                        ww -= left;
++                            child.x = positions.left+margins.left;
++                        ww -= positions.left + margins.left;
                      }
--                    if (!isNaN(top))
++
++					// set the left edge of the child
++                    if (!isNaN(positions.top))
                      {
                          if (ilc)
--                            ilc.setY(top);
--                        else
--                            child.y = top;
--                        hh -= top;
--                    }
--                    if (ilc)
--                    {
--                        if (!hostWidthSizedToContent)
--                        {
--                            if (!isNaN(ilc.percentWidth))
--                                ilc.setWidth((ww - (isNaN(right) ? 0 : right)) * ilc.percentWidth / 100, true);
--                        }
--                        else
--                            childData[i] = { bottom: bottom, right: right, ww: ww, ilc: ilc, child: child };
--                    }
--                    if (!isNaN(right))
--                    {
--                        if (!hostWidthSizedToContent)
--                        {
--                            if (!isNaN(left))
--                            {
--                                if (ilc)
--                                    ilc.setWidth(ww - right, true);
--                                else
--                                    child.width = ww - right;
--                            }
--                            else
--                            {
--                                if (ilc)
--                                    ilc.setX( w - right - child.width);
--                                else
--                                    child.x = w - right - child.width;
--                            }
--                        }
++                            ilc.setY(positions.top+margins.top);
                          else
--                            childData[i] = { ww: ww, left: left, right: right, ilc: ilc, child: child };
--                    }
--                    
--                    if (isNaN(right) && isNaN(left))
--                    {
--                        margin = ValuesManager.valuesImpl.getValue(child, "margin");
--                        gotMargin = true;
--                        marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
--                        marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
--                        var horizontalCenter:Boolean = 
--                            (marginLeft == "auto" && marginRight == "auto") ||
--                            (margin is String && margin == "auto") ||
--                            (margin is Array && 
--                                ((margin.length < 4 && margin[1] == "auto") ||
--                                    (margin.length == 4 && margin[1] == "auto" && margin[3] == "auto")));
--                        if (!hostWidthSizedToContent)
--                        {
--                            if (!horizontalCenter)
--                            {
--                                mr = CSSUtils.getRightValue(marginRight, margin, ww);
--                                ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
--                                if (ilc)
--                                    ilc.setX(ml);
--                                else
--                                    child.x = ml;
--                                if (ilc && isNaN(ilc.percentWidth) && isNaN(ilc.explicitWidth))
--                                    child.width = ww - child.x - mr;
--                            }
--                            else
--                            {
--                                if (ilc)
--                                    ilc.setX((ww - child.width) / 2);
--                                else
--                                    child.x = (ww - child.width) / 2;    
--                            }
--                        }
--                        else 
--                        {
--                            if (!horizontalCenter)
--                            {
--                                mr = CSSUtils.getRightValue(marginRight, margin, ww);
--                                ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
--                                if (ilc)
--                                    ilc.setX(ml);
--                                else
--                                    child.x = ml;
--                                if (ilc && isNaN(ilc.percentWidth) && isNaN(ilc.explicitWidth))
--                                    childData[i] = { ww: ww, left: ml, right: mr, ilc: ilc, child: child };
--                            }
--                            else
--                            {
--                                childData[i] = { ww: ww, center: true, ilc: ilc, child: child };                            
--                            }
--                        }
--                        
--                    }
--                    if (isNaN(top) && isNaN(bottom))
--                    {
--                        if (!gotMargin)
--                            margin = ValuesManager.valuesImpl.getValue(child, "margin");
--                        marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
--                        marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
--                        mt = CSSUtils.getTopValue(marginTop, margin, hh);
--                        mb = CSSUtils.getBottomValue(marginBottom, margin, hh);
--                        if (ilc)
--                            ilc.setY(mt);
--                        else
--                            child.y = mt;
--                        /* browsers don't use margin-bottom to stretch things vertically
--                        if (!hostHeightSizedToContent)
--                        {
--                        if (ilc && isNaN(ilc.percentHeight) && isNaN(ilc.explicitHeight))
--                        child.height = hh - child.y - mb;
--                        }
--                        else
--                        {
--                        if (!childData[i])
--                        childData[i] = { hh: hh, bottom: mb, ilc: ilc, child: child };
--                        else
--                        {
--                        childData[i].hh = hh;
--                        childData[i].bottom = mb;
--                        }
--                        }
--                        */
--                    }
--                    
--                    if (ilc)
--                    {
--                        if (!hostHeightSizedToContent)
--                        {
--                            if (!isNaN(ilc.percentHeight))
--                                ilc.setHeight((hh - (isNaN(bottom) ? 0 : bottom)) * ilc.percentHeight / 100, true);
--                        }
--                        else
--                        {
--                            if (!childData[i])
--                                childData[i] = { hh: hh, bottom: bottom, ilc: ilc, child: child };
--                            else
--                            {
--                                childData[i].hh = hh;
--                                childData[i].bottom = bottom;
--                            }
--                        }
--                    }
--                    if (!isNaN(bottom))
--                    {
--                        if (!hostHeightSizedToContent)
--                        {
--                            if (!isNaN(top))
--                            {
--                                if (ilc)
--                                    ilc.setHeight(hh - bottom, true);
--                                else
--                                    child.height = hh - bottom;
--                            }
--                            else
--                            {
--                                if (ilc)
--                                    ilc.setY(h - bottom - child.height);
--                                else
--                                    child.y = h - bottom - child.height;
--                            }
--                        }
--                        else
--                        {
--                            if (!childData[i])
--                                childData[i] = { top: top, bottom: bottom, hh:hh, ilc: ilc, child: child };
--                            else
--                            {
--                                childData[i].top = top;
--                                childData[i].bottom = bottom;
--                                childData[i].hh = hh;
--                            }
--                        }
--                    }
--                    if (!childData[i])
--                        child.dispatchEvent(new Event("sizeChanged"));
--                    maxWidth = Math.max(maxWidth, child.x + child.width);
--                    maxHeight = Math.max(maxHeight, child.y + child.height);
--                }
--                if (hostHeightSizedToContent || hostWidthSizedToContent)
--                {
--                    for (i = 0; i < n; i++)
--                    {
--                        var data:Object = childData[i];
--                        if (data)
--                        {
--                            if (hostWidthSizedToContent)
--                            {
--                                if (data.ilc && !isNaN(data.ilc.percentWidth))
--                                    data.ilc.setWidth((data.ww - (isNaN(data.right) ? 0 : data.right)) * data.ilc.percentWidth / 100, true);
--                                if (data.center)
--                                {
--                                    if (data.ilc)
--                                        data.ilc.setX((data.ww - data.child.width) / 2);
--                                    else
--                                        data.child.x = (data.ww - data.child.width) / 2; 
--                                }
--                                else if (!isNaN(data.right))
--                                {
--                                    if (!isNaN(data.left))
--                                    {
--                                        if (data.ilc)
--                                            data.ilc.setWidth(data.ww - data.right, true);
--                                        else
--                                            data.child.width = data.ww - data.right;
--                                    }
--                                    else
--                                    {
--                                        if (data.ilc)
--                                            data.ilc.setX(maxWidth - data.right - data.child.width);
--                                        else
--                                            data.child.x = maxWidth - data.right - data.child.width;
--                                    }
--                                }
--                            }
--                            if (hostHeightSizedToContent)
--                            {
--                                if (data.ilc && !isNaN(data.ilc.percentHeight))
--                                    data.ilc.setHeight((data.hh - (isNaN(data.bottom) ? 0 : data.bottom)) * data.ilc.percentHeight / 100, true);
--                                if (!isNaN(data.bottom))
--                                {
--                                    if (!isNaN(data.top))
--                                    {
--                                        if (data.ilc)
--                                            data.ilc.setHeight(data.hh - data.bottom, true);
--                                        else
--                                            data.child.height = data.hh - data.bottom;
--                                    }
--                                    else
--                                    {
--                                        if (data.ilc)
--                                            data.ilc.setY(maxHeight - data.bottom - data.child.height);
--                                        else
--                                            data.child.y = maxHeight - data.bottom - data.child.height;
--                                    }
--                                }
--                            }
--                            child.dispatchEvent(new Event("sizeChanged"));
--                        }
++                            child.y = positions.top+margins.top;
++                        hh -= positions.top + margins.top;
                      }
++
++					// set the right edge of the child
++					if (!isNaN(positions.right))
++					{
++						if (!hostWidthSizedToContent)
++						{
++							if (!isNaN(positions.left))
++							{
++								if (ilc)
++									ilc.setWidth(ww - positions.right - margins.right, false);
++								else
++									child.width = ww - positions.right - margins.right;
++							}
++							else
++							{
++								if (ilc)
++									ilc.setX( w - positions.right - margins.left - child.width - margins.right);
++								else
++									child.x = w - positions.right - margins.left - child.width - margins.right;
++							}
++						}
++					}
++					else if (ilc != null && !isNaN(ilc.percentWidth) && !hostWidthSizedToContent)
++					{
++						ilc.setWidth((ww - margins.right - margins.left) * ilc.percentWidth/100, false);
++					}
++
++					// set the bottm edge of the child
++					if (!isNaN(positions.bottom))
++					{
++						if (!hostHeightSizedToContent)
++						{
++							if (!isNaN(positions.top))
++							{
++								if (ilc)
++									ilc.setHeight(hh - positions.bottom - margins.bottom, false);
++								else
++									child.height = hh - positions.bottom - margins.bottom;
++							}
++							else
++							{
++								if (ilc)
++									ilc.setY( h - positions.bottom - child.height - margins.bottom);
++								else
++									child.y = h - positions.bottom - child.height - margins.bottom;
++							}
++						}
++					}
++					else if (ilc != null && !isNaN(ilc.percentHeight) && !hostHeightSizedToContent)
++					{
++						ilc.setHeight((hh - margins.top - margins.bottom) * ilc.percentHeight/100, false);
++					}
                  }
--                
--                host.dispatchEvent( new Event("layoutComplete") );
--                
++
                  return true;
--                
++
              }
++
              COMPILE::JS
              {
                  var i:int
                  var n:int;
--                var h:Number;
--                var w:Number;
--                
-                 var viewBead:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -                var viewBead:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--                var contentView:IParentIUIBase = viewBead.contentView;
--                w = contentView.width;
--                var hasWidth:Boolean = !host.isWidthSizedToContent();
--                h = contentView.height;
--                var hasHeight:Boolean = !host.isHeightSizedToContent();
--                var maxHeight:Number = 0;
--                var maxWidth:Number = 0;
++				var contentView:ILayoutView = layoutView;
++
                  n = contentView.numElements;
--                for (i = 0; i < n; i++) {
--                    var child:UIBase = contentView.getElementAt(i) as UIBase;
-                     if (child == null || !child.visible) continue;
--                    child.setDisplayStyleForLayout('block');
--                    var left:Number = org.apache.flex.core.ValuesManager.valuesImpl.getValue(child, 'left');
--                    var right:Number = org.apache.flex.core.ValuesManager.valuesImpl.getValue(child, 'right');
--                    var top:Number = org.apache.flex.core.ValuesManager.valuesImpl.getValue(child, 'top');
--                    var bottom:Number = org.apache.flex.core.ValuesManager.valuesImpl.getValue(child, 'bottom');
--                    var margin:String = org.apache.flex.core.ValuesManager.valuesImpl.getValue(child, 'margin');
--                    var marginLeft:String = org.apache.flex.core.ValuesManager.valuesImpl.getValue(child, 'margin-left');
--                    var marginRight:String = org.apache.flex.core.ValuesManager.valuesImpl.getValue(child, 'margin-right');
--                    var horizontalCenter:Boolean =
--                        (marginLeft == 'auto' && marginRight == 'auto') ||
--                        (typeof(margin) === 'string' && margin == 'auto') ||
--                        (margin && margin.hasOwnProperty('length') &&
--                            ((margin.length < 4 && margin[1] == 'auto') ||
--                                (margin.length == 4 && margin[1] == 'auto' && margin[3] == 'auto')));
--                    
--                    if (!isNaN(left)) {
--                        child.positioner.style.position = 'absolute';
--                        child.positioner.style.left = left.toString() + 'px';
--                    }
--                    if (!isNaN(top)) {
--                        child.positioner.style.position = 'absolute';
--                        child.positioner.style.top = top.toString() + 'px';
--                    }
--                    if (!isNaN(right)) {
--                        child.positioner.style.position = 'absolute';
--                        child.positioner.style.right = right.toString() + 'px';
--                    }
--                    if (!isNaN(bottom)) {
--                        child.positioner.style.position = 'absolute';
--                        child.positioner.style.bottom = bottom.toString() + 'px';
--                    }
--                    if (horizontalCenter)
--                    {
--                        child.positioner.style.position = 'absolute';
--                        child.positioner.style.left = ((w - child.width) / 2).toString() + 'px';
--                    }
--                    child.dispatchEvent('sizeChanged');
--                    maxWidth = Math.max(maxWidth, child.positioner.offsetLeft + child.positioner.offsetWidth);
--                    maxHeight = Math.max(maxHeight, child.positioner.offsetTop + child.positioner.offsetHeight);
--                }
--                // if there are children and maxHeight is ok, use it.
--                // maxHeight can be NaN if the child hasn't been rendered yet.
--                if (!hasWidth && n > 0 && !isNaN(maxWidth)) {
--                    contentView.width = maxWidth;
--                }
--                if (!hasHeight && n > 0 && !isNaN(maxHeight)) {
--                    contentView.height = maxHeight;
--                }
++
++				// host must have either have position:absolute or position:relative
++				if (contentView.element.style.position != "absolute" && contentView.element.style.position != "relative") {
++					contentView.element.style.position = "relative";
++				}
++
++				// each child must have position:absolute for BasicLayout to work
++				for (i=0; i < n; i++) {
++					var child:UIBase = contentView.getElementAt(i) as UIBase;
++					child.positioner.style.position = "absolute";
++				}
++
                  return true;
              }
  		}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
index 5bd1159,5bd1159..761e1c7
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/ButtonBarLayout.as
@@@ -17,40 -17,40 +17,46 @@@
  //
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
--{	
++{
  	import org.apache.flex.core.IBeadLayout;
--	import org.apache.flex.core.IItemRendererClassFactory;
--	import org.apache.flex.core.IItemRendererParent;
  	import org.apache.flex.core.ILayoutHost;
++	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.ISelectableItemRenderer;
  	import org.apache.flex.core.ISelectionModel;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
  	import org.apache.flex.core.IViewportModel;
++	import org.apache.flex.core.LayoutBase;
++	import org.apache.flex.core.SimpleCSSStyles;
  	import org.apache.flex.core.UIBase;
  	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.html.List;
  	import org.apache.flex.html.beads.ButtonBarView;
--	
++	import org.apache.flex.html.beads.models.ButtonBarModel;
++	import org.apache.flex.geom.Rectangle;
++	import org.apache.flex.utils.CSSUtils;
++	import org.apache.flex.utils.CSSContainerUtils;
++
  	/**
--	 *  The ButtonBarLayout class bead sizes and positions the org.apache.flex.html.Button 
--	 *  elements that make up a org.apache.flex.html.ButtonBar. This bead arranges the Buttons 
++	 *  The ButtonBarLayout class bead sizes and positions the org.apache.flex.html.Button
++	 *  elements that make up a org.apache.flex.html.ButtonBar. This bead arranges the Buttons
  	 *  horizontally and makes them all the same width unless the buttonWidths property has been set in which case
  	 *  the values stored in that array are used.
--	 *  
++	 *
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class ButtonBarLayout implements IBeadLayout
++	public class ButtonBarLayout extends HorizontalFlexLayout implements IBeadLayout
  	{
  		/**
  		 *  constructor.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -58,29 -58,29 +64,16 @@@
  		 */
  		public function ButtonBarLayout()
  		{
++			super();
  		}
--		
--		private var _strand:IStrand;
--		
--		/**
--		 *  @copy org.apache.flex.core.IBead#strand
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function set strand(value:IStrand):void
--		{
--			_strand = value;
--		}
--		
++
++		private var _widthType:Number = ButtonBarModel.PIXEL_WIDTHS;
  		private var _buttonWidths:Array = null;
--		
++
  		/**
  		 *  An array of widths (Number), one per button. These values supersede the
  		 *  default of equally-sized buttons.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -94,50 -94,50 +87,85 @@@
  		{
  			_buttonWidths = value;
  		}
--		
++
  		/**
  		 * @copy org.apache.flex.core.IBeadLayout#layout
  		 */
--		public function layout():Boolean
++		override public function layout():Boolean
  		{
--			var layoutParent:ILayoutHost = _strand.getBeadByType(ILayoutHost) as ILayoutHost;
--			var contentView:IParentIUIBase = layoutParent.contentView as IParentIUIBase;
--			var itemRendererParent:IItemRendererParent = contentView as IItemRendererParent;
--			var viewportModel:IViewportModel = (layoutParent as ButtonBarView).viewportModel;
--			
--			var n:int = contentView.numElements;
--			var realN:int = n;
--			
--			for (var j:int=0; j < n; j++)
--			{
--				var child:IUIBase = itemRendererParent.getElementAt(j) as IUIBase;
--				if (child == null || !child.visible) realN--;
++			var contentView:ILayoutView = layoutView;
++
++			var model:ButtonBarModel = (host as IStrand).getBeadByType(ButtonBarModel) as ButtonBarModel;
++			if (model) {
++				buttonWidths = model.buttonWidths;
++				_widthType = model.widthType;
  			}
--			
--			var xpos:Number = 0;
--			var useWidth:Number = contentView.width / realN;
--			var useHeight:Number = contentView.height;
--			
++
++			var n:int = contentView.numElements;
++
  			for (var i:int=0; i < n; i++)
  			{
--				var ir:ISelectableItemRenderer = itemRendererParent.getElementAt(i) as ISelectableItemRenderer;
++				var ir:ISelectableItemRenderer = contentView.getElementAt(i) as ISelectableItemRenderer;
  				if (ir == null || !UIBase(ir).visible) continue;
--				UIBase(ir).y = 0;
--				UIBase(ir).x = xpos;
--				if (!isNaN(useHeight) && useHeight > 0) {
--					UIBase(ir).height = useHeight;
--				}
  				
--				if (buttonWidths) UIBase(ir).width = Number(buttonWidths[i]);
--				else if (!isNaN(useWidth) && useWidth > 0) {
--					UIBase(ir).width = useWidth;
++				COMPILE::SWF {
++					if (buttonWidths) {
++						var widthValue:* = buttonWidths[i];
++
++						if (_widthType == ButtonBarModel.PIXEL_WIDTHS) {
++							if (widthValue != null) UIBase(ir).width = Number(widthValue);
++							if (UIBase(ir).style == null) {
++								UIBase(ir).style = new SimpleCSSStyles();
++							}
++							UIBase(ir).style.flexGrow = 0;
++						}
++						else if (_widthType == ButtonBarModel.PROPORTIONAL_WIDTHS) {
++							if (widthValue != null) {
++								if (UIBase(ir).style == null) {
++									UIBase(ir).style = new SimpleCSSStyles();
++								}
++								UIBase(ir).style.flexGrow = Number(widthValue);
++							}
++						}
++						else if (_widthType == ButtonBarModel.PERCENT_WIDTHS) {
++							if (widthValue != null) UIBase(ir).percentWidth = Number(widthValue);
++							if (UIBase(ir).style == null) {
++								UIBase(ir).style = new SimpleCSSStyles();
++							}
++							UIBase(ir).style.flexGrow = 0;
++						}
++					} else {
++						if (UIBase(ir).style == null) {
++							UIBase(ir).style = new SimpleCSSStyles();
++						}
++						UIBase(ir).style.flexGrow = 1;
++					}
++				}
++
++				COMPILE::JS {
++					// otherwise let the flexbox layout handle matters on its own.
++					if (buttonWidths) {
++						var widthValue:* = buttonWidths[i];
++
++						if (_widthType == ButtonBarModel.PIXEL_WIDTHS) {
++							if (widthValue != null) UIBase(ir).width = Number(widthValue);
++						}
++						else if (_widthType == ButtonBarModel.PROPORTIONAL_WIDTHS) {
++							if (widthValue != null) UIBase(ir).element.style["flex-grow"] = String(widthValue);
++						}
++						else if (_widthType == ButtonBarModel.PERCENT_WIDTHS) {
++							if (widthValue != null) UIBase(ir).percentWidth = Number(widthValue);
++						}
++					} else {
++						UIBase(ir).element.style["flex-grow"] = "1";
++					}
++					
++					UIBase(ir).height = contentView.height;
  				}
--				xpos += UIBase(ir).width;
  			}
--			
--			IEventDispatcher(_strand).dispatchEvent( new Event("layoutComplete") );
--			
--            return true;
++
++			// now let the horizontal layout take care of things.
++			return super.layout();
  		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/FlexibleFirstChildHorizontalLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/FlexibleFirstChildHorizontalLayout.as
index 0b3c3fa,4198fea..f276074
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/FlexibleFirstChildHorizontalLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/FlexibleFirstChildHorizontalLayout.as
@@@ -18,10 -18,9 +18,12 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
  {
++	import org.apache.flex.core.LayoutBase;
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.ILayoutChild;
++	import org.apache.flex.core.ILayoutView;
      import org.apache.flex.core.ILayoutHost;
-     import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutParent;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
@@@ -34,6 -33,6 +36,7 @@@
      import org.apache.flex.geom.Rectangle;
      import org.apache.flex.html.supportClasses.Viewport;
      import org.apache.flex.utils.CSSContainerUtils;
++	import org.apache.flex.utils.CSSUtils;
  
      /**
       *  The FlexibleFirstChildHorizontalLayout class is a simple layout
@@@ -42,17 -41,17 +45,17 @@@
       *  CSS layout rules for margin and padding styles. But it
       *  will size the first child to take up as much or little
       *  room as possible.
--     *  
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class FlexibleFirstChildHorizontalLayout implements IBeadLayout
++	public class FlexibleFirstChildHorizontalLayout extends HorizontalLayout
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -60,31 -59,31 +63,14 @@@
           */
  		public function FlexibleFirstChildHorizontalLayout()
  		{
++			super();
  		}
--		
--        // the strand/host container is also an ILayoutChild because
--        // can have its size dictated by the host's parent which is
--        // important to know for layout optimization
--        private var host:ILayoutChild;
--		
--        /**
--         *  @copy org.apache.flex.core.IBead#strand
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--		public function set strand(value:IStrand):void
--		{
--            host = value as ILayoutChild;
--		}
--		
++
          private var _maxWidth:Number;
--        
++
          /**
           *  @copy org.apache.flex.core.IBead#maxWidth
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -94,20 -93,20 +80,20 @@@
          {
              return _maxWidth;
          }
--        
++
          /**
--         *  @private 
++         *  @private
           */
          public function set maxWidth(value:Number):void
          {
              _maxWidth = value;
          }
--        
++
          private var _maxHeight:Number;
--        
++
          /**
           *  @copy org.apache.flex.core.IBead#maxHeight
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -117,131 -116,129 +103,128 @@@
          {
              return _maxHeight;
          }
--        
++
          /**
--         *  @private 
++         *  @private
           */
          public function set maxHeight(value:Number):void
          {
              _maxHeight = value;
          }
--        
++
          /**
           * @copy org.apache.flex.core.IBeadLayout#layout
           */
--		public function layout():Boolean
++		COMPILE::SWF
++		override public function layout():Boolean
  		{
-             var layoutParent:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -			var layoutParent:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--			var contentView:IParentIUIBase = layoutParent.contentView as IParentIUIBase;
--            var padding:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
--            var hostSizedToContent:Boolean = host.isHeightSizedToContent();
++			var contentView:ILayoutView = layoutView;
++
++			var n:Number = contentView.numElements;
++			if (n == 0) return false;
  			
--			var n:int = contentView.numElements;
--			var marginLeft:Object;
--			var marginRight:Object;
--			var marginTop:Object;
--			var marginBottom:Object;
--			var margin:Object;
--			maxHeight = 0;
--			var verticalMargins:Array = [];
++			// if the layoutView has no width yet, this layout cannot
++			// be run successfully, so default to HorizontalLayout.
++			if (host.isWidthSizedToContent()) {
++				return super.layout();
++			}
++
++			var maxWidth:Number = 0;
++			var maxHeight:Number = 0;
++			var hostSizedToContent:Boolean = host.isHeightSizedToContent();
++			var hostWidth:Number = contentView.width;
++			var hostHeight:Number = hostSizedToContent ? 0 : contentView.height;
++
++			var ilc:ILayoutChild;
++			var data:Object;
++			var canAdjust:Boolean = false;
++
++			var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++			var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
  			
--            var xx:Number = contentView.width;
--            if (isNaN(xx) || xx <= 0)
--                return true;
--            xx -= padding.right + 1; // some browsers won't layout to the edge
--            
--            for (var i:int = n - 1; i >= 0; i--)
++			// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++			// resulting adjusted value may be less than zero.
++			hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++			hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++
++			var xpos:Number = hostWidth + borderMetrics.left + paddingMetrics.left;
++			var ypos:Number = borderMetrics.top + paddingMetrics.left;
++			var adjustedWidth:Number = 0;
++
++			for(var i:int=(n-1); i >= 0; i--)
  			{
  				var child:IUIBase = contentView.getElementAt(i) as IUIBase;
-                 if (child == null || !child.visible) continue;
--				margin = ValuesManager.valuesImpl.getValue(child, "margin");
--				if (margin is Array)
--				{
--					if (margin.length == 1)
--						marginLeft = marginTop = marginRight = marginBottom = margin[0];
--					else if (margin.length <= 3)
--					{
--						marginLeft = marginRight = margin[1];
--						marginTop = marginBottom = margin[0];
--					}
--					else if (margin.length == 4)
--					{
--						marginLeft = margin[3];
--						marginBottom = margin[2];
--						marginRight = margin[1];
--						marginTop = margin[0];					
++				if (child == null || !child.visible) continue;
++				var positions:Object = childPositions(child);
++				var margins:Object = childMargins(child, hostWidth, hostHeight);
++
++				ilc = child as ILayoutChild;
++
++				var childYpos:Number = ypos + margins.top; // default y position
++
++				if (!hostSizedToContent) {
++					var childHeight:Number = child.height;
++					if (ilc != null && !isNaN(ilc.percentHeight)) {
++						childHeight = hostHeight * ilc.percentHeight/100.0;
++						ilc.setHeight(childHeight);
  					}
++					// the following code middle-aligns the child
++					childYpos = hostHeight/2 - childHeight/2;
  				}
--				else if (margin == null)
--				{
--					marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
--					marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
--					marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
--					marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
--				}
--				else
--				{
--					marginLeft = marginTop = marginBottom = marginRight = margin;
++
++				if (ilc) {
++					if (!isNaN(ilc.percentWidth)) {
++						ilc.setWidth(hostWidth * ilc.percentWidth / 100);
++					}
  				}
--				var ml:Number;
--				var mr:Number;
--				var mt:Number;
--				var mb:Number;
--				var lastmr:Number;
--				mt = Number(marginTop);
--				if (isNaN(mt))
--					mt = 0;
--				mb = Number(marginBottom);
--				if (isNaN(mb))
--					mb = 0;
--				if (marginLeft == "auto")
--					ml = 0;
--				else
--				{
--					ml = Number(marginLeft);
--					if (isNaN(ml))
--						ml = 0;
++
++				if (i > 0) {
++					xpos -= child.width + margins.right;
++					adjustedWidth = child.width;
++				} else {
++					adjustedWidth = xpos - (borderMetrics.left + paddingMetrics.left + margins.left + margins.right);
++					xpos = borderMetrics.left + paddingMetrics.left + margins.left;
  				}
--				if (marginRight == "auto")
--					mr = 0;
--				else
--				{
--					mr = Number(marginRight);
--					if (isNaN(mr))
--						mr = 0;
++
++				if (ilc) {
++					ilc.setX(xpos);
++					ilc.setY(childYpos);
++					ilc.setWidth(adjustedWidth);
++
++				} else {
++					child.x = xpos;
++					child.y = childYpos;
++					child.width = adjustedWidth;
  				}
--				child.y = mt + padding.top;
--				if (i == 0)
--                {
--                    child.x = ml + padding.left;
--                    child.width = xx - mr - child.x;
--                }
--				else
--                    child.x = xx - child.width - mr;
--                maxHeight = Math.max(maxHeight, mt + child.height + mb);
--				xx -= child.width + mr + ml;
--				lastmr = mr;
--				var valign:Object = ValuesManager.valuesImpl.getValue(child, "vertical-align");
--				verticalMargins.push({ marginTop: mt, marginBottom: mb, valign: valign });
++
++				xpos -= margins.left;
  			}
--			for (i = 0; i < n; i++)
--			{
--				var obj:Object = verticalMargins[0]
--				child = contentView.getElementAt(i) as IUIBase;
-                 if (child == null || !child.visible) continue;
-                 if (obj.valign == "middle")
 -				if (obj.valign == "middle")
--					child.y = (maxHeight - child.height) / 2;
--				else if (valign == "bottom")
--					child.y = maxHeight - child.height - obj.marginBottom;
--				else
--					child.y = obj.marginTop;
++
++			return true;
++		}
++
++		COMPILE::JS
++		override public function layout():Boolean
++		{
++			var contentView:ILayoutView = layoutView;
++
++			// set the display on the contentView
++			contentView.element.style["display"] = "flex";
++			contentView.element.style["flex-flow"] = "row";
++			contentView.element.style["align-items"] = "center";
++
++			var n:int = contentView.numElements;
++			if (n == 0) return false;
++
++			for(var i:int=0; i < n; i++) {
++				var child:UIBase = contentView.getElementAt(i) as UIBase;
++				child.element.style["flex-grow"] = (i == 0) ? "1" : "0";
++				child.element.style["flex-shrink"] = "0";
  			}
--            if (hostSizedToContent)
--                ILayoutChild(contentView).setHeight(maxHeight + padding.top + padding.bottom, true);
--			
--            return true;
++
++			return true;
  		}
  
      }
--        
++
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HScrollBarLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HScrollBarLayout.as
index 38b97ec,38b97ec..f8b5ddd
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HScrollBarLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HScrollBarLayout.as
@@@ -18,15 -18,15 +18,16 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
  {
--	import flash.display.DisplayObject;
  	
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.IScrollBarModel;
  	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.UIBase;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
      import org.apache.flex.geom.Rectangle;
  	import org.apache.flex.html.beads.IScrollBarView;
++	import org.apache.flex.html.Button;
  	import org.apache.flex.utils.CSSContainerUtils;
  
      /**
@@@ -82,27 -82,27 +83,28 @@@
                  sbModel = _strand.getBeadByType(IScrollBarModel) as IScrollBarModel
  					
  			var metrics:Rectangle = CSSContainerUtils.getBorderAndPaddingMetrics(_strand);
--                    
--			var w:Number = DisplayObject(_strand).width + metrics.left + metrics.right;
--			var increment:DisplayObject = sbView.increment;
--			var decrement:DisplayObject = sbView.decrement;
--			var track:DisplayObject = sbView.track;
--			var thumb:DisplayObject = sbView.thumb;
++            
++            var host:UIBase = UIBase(_strand);
++			var w:Number = host.width + metrics.left + metrics.right;
++			var increment:Button = sbView.increment;
++			var decrement:Button = sbView.decrement;
++			var track:Button = sbView.track;
++			var thumb:Button = sbView.thumb;
  			
--			decrement.x = 0;
++			decrement.x = 1;
  			decrement.y = 0;
--			decrement.height = DisplayObject(_strand).height;
--			decrement.width = DisplayObject(_strand).height;
++			decrement.height = host.height - 2;
++			decrement.width = host.height;
  			
--			increment.height = DisplayObject(_strand).height;
--			increment.width = DisplayObject(_strand).height;
--			increment.x = w - increment.width - 1;
++			increment.height = host.height - 2;
++			increment.width = host.height;
++			increment.x = w - increment.width - 2;
  			increment.y = 0;
  
--			track.x = decrement.width;
++			track.x = decrement.width + 4;
  			track.y = 0;
--			track.height = DisplayObject(_strand).height;
--			track.width = increment.x - decrement.width;
++			track.height = host.height;
++			track.width = increment.x - decrement.width - 5;
              thumb.width = sbModel.pageSize / (sbModel.maximum - sbModel.minimum) * track.width;
  			if (track.width > thumb.width)
  			{

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlexLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlexLayout.as
index 0000000,0000000..cad6827
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlexLayout.as
@@@ -1,0 -1,0 +1,264 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads.layouts
++{
++//	import org.apache.flex.html.beads.layouts.HorizontalLayout;
++
++	import org.apache.flex.core.LayoutBase;
++	import org.apache.flex.core.ILayoutChild;
++	import org.apache.flex.core.ILayoutHost;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.IParentIUIBase;
++	import org.apache.flex.core.UIBase;
++
++	COMPILE::SWF {
++		import org.apache.flex.core.IUIBase;
++		import org.apache.flex.core.ValuesManager;
++		import org.apache.flex.events.Event;
++		import org.apache.flex.events.IEventDispatcher;
++		import org.apache.flex.geom.Rectangle;
++		import org.apache.flex.utils.CSSUtils;
++		import org.apache.flex.utils.CSSContainerUtils;
++	}
++
++	public class HorizontalFlexLayout extends LayoutBase
++	{
++		/**
++		 * Constructor.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function HorizontalFlexLayout()
++		{
++			super();
++		}
++
++		private var _grow:Number = -1;
++
++		/**
++		 * Sets the amount items grow in proportion to other items.
++		 * The default is 0 which prevents the items from expanding to
++		 * fit the space. Use a negative value to unset this property.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get grow():Number {
++			return _grow;
++		}
++		public function set grow(value:Number):void {
++			_grow = value;
++		}
++
++		private var _shrink:Number = -1;
++
++		/**
++		 * Sets the amount an item may shrink in proportion to other items.
++		 * The default is 1 which allows items to shrink to fit into the space.
++		 * Set this to 0 if you want to allow scrolling of the space. Use a
++		 * negative value to unset this property.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get shrink():Number {
++			return _shrink;
++		}
++		public function set shrink(value:Number):void {
++			_shrink = value;
++		}
++
++		/**
++		 * @copy org.apache.flex.core.IBeadLayout#layout
++		 * @flexjsignorecoercion org.apache.flex.core.ILayoutHost
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		override public function layout():Boolean
++		{
++			COMPILE::SWF {
++				var contentView:ILayoutView = layoutView;
++
++				var n:Number = contentView.numElements;
++				if (n == 0) return false;
++
++				var spacing:String = "none";
++
++				var maxWidth:Number = 0;
++				var maxHeight:Number = 0;
++				var growCount:Number = 0;
++				var childData:Array = [];
++				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
++				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
++				var hostWidth:Number = hostWidthSizedToContent ? host.width : contentView.width;
++				var hostHeight:Number = hostHeightSizedToContent ? host.height : contentView.height;
++
++				var ilc:ILayoutChild;
++				var data:Object;
++				var canAdjust:Boolean = false;
++				
++				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
++				
++				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++				// resulting adjusted value may be less than zero.
++				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++				
++				if ((hostWidth <= 0 && !hostWidthSizedToContent) || (hostHeight <= 0 && !hostHeightSizedToContent)) return false;
++				
++				var remainingWidth:Number = hostWidth;
++
++				//trace("HorizontalFlexLayout for "+UIBase(host).id+" with remainingWidth: "+remainingWidth);
++
++				// First pass determines the data about the child.
++				for(var i:int=0; i < n; i++)
++				{
++					var child:IUIBase = contentView.getElementAt(i) as IUIBase;
++					if (child == null || !child.visible) {
++						childData.push({width:0, height:0, mt:0, ml:0, mr:0, mb:0, canAdjust:false});
++						continue;
++					}
++
++					ilc = child as ILayoutChild;
++					
++					var margins:Object = childMargins(child, hostWidth, hostHeight);
++
++					var flexGrow:Object = ValuesManager.valuesImpl.getValue(child, "flex-grow");
++					var growValue:Number = 0;
++					if (flexGrow != null) {
++						growValue = Number(flexGrow);
++						if (!isNaN(growValue) && growValue > 0) growCount++;
++						else growValue = 0;
++					}
++
++					var useHeight:Number = -1;
++					if (!hostHeightSizedToContent) {
++						if (ilc) {
++							if (!isNaN(ilc.percentHeight)) useHeight = hostHeight * (ilc.percentHeight/100.0);
++							else if (!isNaN(ilc.explicitHeight)) useHeight = ilc.explicitHeight;
++							else useHeight = hostHeight;
++						}
++					}
++
++					var useWidth:Number = -1;
++					if (ilc) {
++						if (!isNaN(ilc.explicitWidth)) useWidth = ilc.explicitWidth;
++						else if (!isNaN(ilc.percentWidth)) useWidth = hostWidth * (ilc.percentWidth/100.0);
++						else if (ilc.width > 0) useWidth = ilc.width;
++					}
++					if (growValue == 0 && useWidth > 0) remainingWidth -= useWidth + margins.left + margins.right;
++					else remainingWidth -= margins.left + margins.right;
++
++					if (maxWidth < useWidth) maxWidth = useWidth;
++					if (maxHeight < useHeight) maxHeight = useHeight;
++
++					childData.push({width:useWidth, height:useHeight, 
++						            mt:margins.top, ml:margins.left, mr:margins.right, mb:margins.bottom, 
++									grow:growValue, canAdjust:canAdjust});
++				}
++
++				var xpos:Number = borderMetrics.left + paddingMetrics.left;
++				var ypos:Number = borderMetrics.top + paddingMetrics.top;
++
++				// Second pass sizes and positions the children based on the data gathered.
++				for(i=0; i < n; i++)
++				{
++					child = contentView.getElementAt(i) as IUIBase;
++					data = childData[i];
++					//if (data.width == 0 || data.height == 0) continue;
++
++					useHeight = (data.height < 0 ? maxHeight : data.height);
++
++					var setWidth:Boolean = true;
++					if (data.width != 0) {
++						if (data.grow > 0 && growCount > 0) {
++							useWidth = remainingWidth / growCount;
++							setWidth = false;
++						} else {
++							useWidth = data.width;
++						}
++					} else {
++						useWidth = child.width;
++					}
++
++					ilc = child as ILayoutChild;
++					if (ilc) {
++						ilc.setX(xpos + data.ml);
++						ilc.setY(ypos + data.mt);
++						if (data.height > 0) {
++							//ilc.height = useHeight;
++							ilc.setHeight(useHeight);
++						}
++						if (useWidth > 0) {
++							if (setWidth) ilc.setWidth(useWidth);
++							else ilc.width = useWidth;
++						}
++					} else {
++						child.x = xpos + data.ml;
++						child.y = ypos + data.mt;
++						child.height = useHeight;
++						if (data.width > 0) {
++							child.width = useWidth;
++						}
++					}
++
++					xpos += useWidth + data.mr + data.ml;
++
++					//trace("HorizontalFlexLayout: setting child "+i+" to "+child.width+" x "+child.height+" at "+child.x+", "+child.y);
++				}
++
++				//trace("HorizontalFlexLayout: complete");
++
++				return true;
++			}
++
++			COMPILE::JS {
++				var contentView:ILayoutView = layoutView;
++
++				// set the display on the contentView
++				contentView.element.style["display"] = "flex";
++				contentView.element.style["flex-flow"] = "row";
++
++				var n:int = contentView.numElements;
++				if (n == 0) return false;
++
++				for(var i:int=0; i < n; i++) {
++					var child:UIBase = contentView.getElementAt(i) as UIBase;
++					if (grow >= 0) child.element.style["flex-grow"] = String(grow);
++					if (shrink >= 0) child.element.style["flex-shrink"] = String(shrink);
++				}
++
++				return true;
++			}
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlowLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlowLayout.as
index 8f3561a,0000000..84484cb
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlowLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/HorizontalFlowLayout.as
@@@ -1,288 -1,0 +1,268 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.beads.layouts
 +{
++	import org.apache.flex.core.LayoutBase;
 +	import org.apache.flex.core.IBeadLayout;
 +	import org.apache.flex.core.ILayoutHost;
 +	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
 +	import org.apache.flex.core.IParentIUIBase;
 +	import org.apache.flex.core.IStrand;
 +	import org.apache.flex.core.IUIBase;
 +	import org.apache.flex.core.UIBase;
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.events.IEventDispatcher;
 +
 +	/**
 +	 *  The HorizontalFlowLayout class bead sizes and positions the elements it manages into rows
 +	 *  and columns. It does this by seeing how many elements will fit horizontally and then flow
 +	 *  the remainder onto the next lines. If an element does not already have an explicit or percentage
 +	 *  size, a size is chosen for it based on the defaultColumnCount property which divides the
 +	 *  layout space into equal number of cells as a default measurement.
- 	 * 
++	 *
 +	 *  The height of each row is determined by the tallest element in the row. The next row flows
 +	 *  below that.
 +	 *
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
 +	 *  @productversion FlexJS 0.0
 +	 */
- 	public class HorizontalFlowLayout implements IBeadLayout
++	public class HorizontalFlowLayout extends LayoutBase implements IBeadLayout
 +	{
 +		/**
 +		 *  constructor.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function HorizontalFlowLayout()
 +		{
- 		}
- 
- 		private var _strand:IStrand;
- 
- 		/**
- 		 *  @copy org.apache.flex.core.IBead#strand
- 		 *
- 		 *  @langversion 3.0
- 		 *  @playerversion Flash 10.2
- 		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.0
- 		 */
- 		public function set strand(value:IStrand):void
- 		{
- 			_strand = value;
++			super();
 +		}
 +
 +		private var _defaultColumnCount:Number = 4;
 +		private var _computedColumnWidth:Number = Number.NaN;
 +		private var _columnGap:int = 4;
 +		private var _rowGap:int = 4;
 +		private var _useChildWidth:Boolean = false;
- 		
++
 +		/**
 +		 *  The amount of spacing between the columns.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function get columnGap():int
 +		{
 +			return _columnGap;
 +		}
 +		public function set columnGap(value:int):void
 +		{
 +			_columnGap = value;
 +		}
- 		
++
 +		/**
 +		 *  Amount of spacing between the rows.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function get rowGap():int
 +		{
 +			return _rowGap;
 +		}
 +		public function set rowGap(value:int):void
 +		{
 +			_rowGap = value;
 +		}
 +
 +		/**
 +		 *  The default number of columns the layout should assume should any or
 +		 *  all of the elements not have explicit or percentage widths. This value is
- 		 *  used to divide the layout width into equal-width columns. An element's 
++		 *  used to divide the layout width into equal-width columns. An element's
 +		 *  own width overrides this computed width, allowing for a ragged grid
 +		 *  arrangement.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function get defaultColumnCount():Number
 +		{
 +			return _defaultColumnCount;
 +		}
 +		public function set defaultColumnCount(value:Number):void
 +		{
 +			_defaultColumnCount = value;
 +		}
 +
 +		/**
 +		 *  The calculated width of each column, in pixels. If left unspecified, the
 +		 *  columnWidth is determined by dividing the defaultColumnCount into the
 +		 *  strand's bounding box width.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function get computedColumnWidth():Number
 +		{
 +			return _computedColumnWidth;
 +		}
 +		public function set computedColumnWidth(value:Number):void
 +		{
 +			_computedColumnWidth = value;
 +		}
- 		
++
 +		/**
 +		 *  Determines whether or not each child's width is set from the column size (false) or
 +		 *  uses its own width (true). Default is false.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function get useChildWidth():Boolean
 +		{
 +			return _useChildWidth;
 +		}
 +		public function set useChildWidth(value:Boolean):void
 +		{
 +			_useChildWidth = value;
 +		}
 +
 +        /**
 +         * @copy org.apache.flex.core.IBeadLayout#layout
 +         */
- 		public function layout():Boolean
++		override public function layout():Boolean
 +		{
 +			COMPILE::SWF
 +			{
- 				// this is where the layout is calculated
- 				var host:UIBase = _strand as UIBase;
- 				var p:ILayoutHost = (host as ILayoutParent).getLayoutHost();
- 				var area:UIBase = p.contentView as UIBase;
- 				
++				var area:UIBase = layoutView as UIBase;
++
 +				var n:Number = area.numElements;
 +				if (n == 0) return false;
- 				
++
 +				// if a computedColumnWidth hasn't been preset, calculate it
 +				// based on the default column count, giving equal-width columns.
 +				if (isNaN(computedColumnWidth)) {
 +					_computedColumnWidth = area.width / defaultColumnCount;
 +				}
- 				
++
 +				var maxWidth:Number = area.width;
 +				var maxHeight:Number = 0;
 +				var xpos:Number = columnGap/2;
 +				var ypos:Number = rowGap/2;
 +				var useWidth:Number = 0;
- 				
++
 +				for(var i:int=0; i < n; i++)
 +				{
 +					var child:UIBase = area.getElementAt(i) as UIBase;
 +					if (child == null || !child.visible) continue;
- 					
++
 +					if (!isNaN(child.explicitWidth)) useWidth = child.explicitWidth;
 +					else if (!isNaN(child.percentWidth)) useWidth = maxWidth * (child.percentWidth/100.0);
 +					else useWidth = _computedColumnWidth;
- 					
++
 +					if (xpos+useWidth > maxWidth) {
 +						ypos += maxHeight + rowGap;
 +						xpos = columnGap/2;
 +						maxHeight = 0;
 +					}
- 					
++
 +					child.x = xpos;
 +					child.y = ypos;
 +					if (!useChildWidth) {
 +						child.setWidth(useWidth)
 +					}
- 					
++
 +					var childWidth:Number = child.width;
 +					var childHeight:Number = child.height;
 +					maxHeight = Math.max(maxHeight, childHeight);
- 					
++
 +					xpos += childWidth + columnGap;
 +				}
- 				
- 				IEventDispatcher(_strand).dispatchEvent( new Event("layoutComplete") );
- 				
++
 +				return true;
 +			}
 +			COMPILE::JS
 +			{
 +				var children:Array;
 +				var i:int;
 +				var n:int;
 +				var child:UIBase;
 +				var xpos:Number;
 +				var ypos:Number;
 +				var useWidth:Number;
 +				var useHeight:Number;
 +
- 				var host:UIBase = _strand as UIBase;
- 				var viewBead:ILayoutHost = (host as ILayoutParent).getLayoutHost();
- 				var area:IParentIUIBase = viewBead.contentView as IParentIUIBase;
++				var area:IParentIUIBase = layoutView as IParentIUIBase;
++				
 +				children = area.internalChildren();
 +				n = children.length;
 +				if (n === 0) return false;
 +
 +				area.width = host.width;
- 				
++
 +				var element:HTMLElement = area.element as HTMLElement;
 +				element.style["flexFlow"] = "row wrap";
 +				element.style["display"] = "flex";
- 				
++
 +				// if a computedColumnWidth hasn't been preset, calculate it
 +				// based on the default column count, giving equal-width columns.
 +				if (isNaN(computedColumnWidth)) {
 +					_computedColumnWidth = host.width / defaultColumnCount;
 +				}
 +
 +				for (i = 0; i < n; i++)
 +				{
 +					child = children[i].flexjs_wrapper;
 +					if (!child.visible) continue;
- 					
++
 +					if (!isNaN(child.explicitWidth)) useWidth = child.explicitWidth;
 +					else if (!isNaN(child.percentWidth)) useWidth = host.width * (child.percentWidth/100.0);
 +					else useWidth = _computedColumnWidth;
- 					
++
 +					if (useChildWidth) {
 +						children[i].style["position"] = null;
 +					} else {
 +						child.width = useWidth;
 +					}
 +					children[i].style["margin-top"] = String(_rowGap/2)+"px";
 +					children[i].style["margin-bottom"] = String(_rowGap/2)+"px";
 +					children[i].style["margin-left"] = String(_columnGap/2)+"px";
 +					children[i].style["margin-right"] = String(_columnGap/2)+"px";
 +				}
- 				
- 				IEventDispatcher(_strand).dispatchEvent( new Event("layoutComplete") );
- 				
++
 +				return true;
 +			}
 +		}
 +	}
 +}


[17/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - fix after merge

Posted by ah...@apache.org.
fix after merge


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/4941e12c
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/4941e12c
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/4941e12c

Branch: refs/heads/develop
Commit: 4941e12cdb7c7ce5c8c92b8d983734393ffa4354
Parents: 1691921
Author: Alex Harui <ah...@apache.org>
Authored: Fri Apr 21 09:31:12 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Apr 21 09:31:12 2017 -0700

----------------------------------------------------------------------
 .../Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as       | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/4941e12c/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as
index 9643b58..0935c2c 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as
@@ -746,7 +746,7 @@ package org.apache.flex.core
 				_model = bead as IBeadModel;
             else if (bead is IBeadView)
                 _view = bead as IBeadView;
-			//bead.strand = this; // super.addBead already did this!
+			bead.strand = this; // super.addBead already did this!
 		}
 		
         /**


[39/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - JS layout always runs (once)

Posted by ah...@apache.org.
JS layout always runs (once)


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/f4a69682
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/f4a69682
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/f4a69682

Branch: refs/heads/develop
Commit: f4a696828aa118bbaa13ffd81ca513369481f716
Parents: 712a17e
Author: Alex Harui <ah...@apache.org>
Authored: Thu Apr 27 14:07:11 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Apr 27 14:15:18 2017 -0700

----------------------------------------------------------------------
 .../Basic/src/main/flex/org/apache/flex/core/LayoutBase.as   | 8 ++++++++
 1 file changed, 8 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f4a69682/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
index 979ebc7..adadc75 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
@@ -174,11 +174,19 @@ package org.apache.flex.core
 		{
 			sawInitComplete = true;
 			
+			COMPILE::SWF
+			{
 			// Complete the setup if the height is sized to content or has been explicitly set
             // and the width is sized to content or has been explicitly set
 			if ((host.isHeightSizedToContent() || !isNaN(host.explicitHeight)) &&
                 (host.isWidthSizedToContent() || !isNaN(host.explicitWidth)))
 	    		performLayout();
+			}
+			COMPILE::JS
+			{
+				// always run layout since there are no size change events
+	    		performLayout();
+			}
 		}
 		
 		/**


[30/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Adding TableExample.

Posted by ah...@apache.org.
Adding TableExample.


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/525d9a8d
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/525d9a8d
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/525d9a8d

Branch: refs/heads/develop
Commit: 525d9a8d6d9c5791e4e1b3205107346a57930886
Parents: b0d78b3
Author: Peter Ent <pe...@apache.org>
Authored: Tue Apr 25 15:15:20 2017 -0400
Committer: Peter Ent <pe...@apache.org>
Committed: Tue Apr 25 15:15:20 2017 -0400

----------------------------------------------------------------------
 examples/build.xml                              |   2 +
 examples/flexjs/TableExample/README.txt         |  33 +++++
 examples/flexjs/TableExample/build.xml          |  55 +++++++++
 examples/flexjs/TableExample/pom.xml            |  64 ++++++++++
 .../src/main/flex/MyInitialView.mxml            | 121 +++++++++++++++++++
 .../src/main/flex/TableExample.mxml             |  33 +++++
 6 files changed, 308 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/525d9a8d/examples/build.xml
----------------------------------------------------------------------
diff --git a/examples/build.xml b/examples/build.xml
index 77f4ab0..b4fac50 100644
--- a/examples/build.xml
+++ b/examples/build.xml
@@ -97,6 +97,7 @@
         <ant dir="${basedir}/flexjs/ChartExample"/>
         <ant dir="${basedir}/flexjs/StorageExample"/>
         <ant dir="${basedir}/flexjs/StyleExample"/>
+        <ant dir="${basedir}/flexjs/TableExample"/>
         <ant dir="${basedir}/flexjs/TodoListSampleApp"/>
         <ant dir="${basedir}/flexjs/TeamPage"/>
         <ant dir="${basedir}/flexjs/TreeExample"/>
@@ -138,6 +139,7 @@
         <ant dir="${basedir}/flexjs/ChartExample" target="clean"/>
         <ant dir="${basedir}/flexjs/StorageExample" target="clean"/>
         <ant dir="${basedir}/flexjs/StyleExample" target="clean"/>
+        <ant dir="${basedir}/flexjs/TableExample" target="clean"/>
         <ant dir="${basedir}/flexjs/TodoListSampleApp" target="clean"/>
         <ant dir="${basedir}/flexjs/TeamPage" target="clean"/>
         <ant dir="${basedir}/flexjs/TreeExample" target="clean"/>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/525d9a8d/examples/flexjs/TableExample/README.txt
----------------------------------------------------------------------
diff --git a/examples/flexjs/TableExample/README.txt b/examples/flexjs/TableExample/README.txt
new file mode 100644
index 0000000..1faac9c
--- /dev/null
+++ b/examples/flexjs/TableExample/README.txt
@@ -0,0 +1,33 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+DESCRIPTION
+
+The TableExample demonstrates the use of the Table component. Using Table, you
+can build column by row structured grids. When cross compiled to JavaScript, the
+Table component produces an HTML <table> structure.
+
+This Flex application may be run as a Flash SWF or cross-compiled (using Falcon JX)
+into JavaScript and HTML and run without Flash.
+
+COMPONENTS and BEADS
+
+- Table
+- TableRow
+- TableHeader and TableCell

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/525d9a8d/examples/flexjs/TableExample/build.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/TableExample/build.xml b/examples/flexjs/TableExample/build.xml
new file mode 100644
index 0000000..6a3df12
--- /dev/null
+++ b/examples/flexjs/TableExample/build.xml
@@ -0,0 +1,55 @@
+<?xml version="1.0"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+
+
+<project name="tableexample" default="main" basedir=".">
+    <property name="FLEXJS_HOME" location="../../.."/>
+    <property name="example" value="TableExample" />
+    
+    <property file="${FLEXJS_HOME}/env.properties"/>
+    <property environment="env"/>
+    <property file="${FLEXJS_HOME}/build.properties"/>
+    <property name="FLEX_HOME" value="${FLEXJS_HOME}"/>
+    
+    <include file="${basedir}/../../build_example.xml" />
+
+    <target name="main" depends="clean,build_example.compile" description="Clean build of ${example}">
+    	<!--<mkdir dir="${basedir}/bin/js-debug/assets" />
+        <copy todir="${basedir}/bin/js-debug/assets" >
+            <fileset dir="${basedir}/src/main/resources/assets">
+                <include name="**" />
+            </fileset>
+        </copy>
+        <mkdir dir="${basedir}/bin/js-release/assets" />
+        <copy todir="${basedir}/bin/js-release/assets" >
+            <fileset dir="${basedir}/src/main/resources/assets">
+                <include name="**" />
+            </fileset>
+        </copy>-->
+    </target>
+    
+    <target name="clean">
+        <delete dir="${basedir}/bin" failonerror="false" />
+        <delete dir="${basedir}/bin-debug" failonerror="false" />
+        <delete dir="${basedir}/bin-release" failonerror="false" />
+        <delete dir="${basedir}/target" failonerror="false" />
+    </target>
+    
+</project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/525d9a8d/examples/flexjs/TableExample/pom.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/TableExample/pom.xml b/examples/flexjs/TableExample/pom.xml
new file mode 100644
index 0000000..c0affb7
--- /dev/null
+++ b/examples/flexjs/TableExample/pom.xml
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <!--
+        Flash Version: CSS problems
+  -->
+
+  <parent>
+    <groupId>org.apache.flex.flexjs.examples</groupId>
+    <artifactId>examples-flexjs</artifactId>
+    <version>0.8.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>TableExample</artifactId>
+  <version>0.8.0-SNAPSHOT</version>
+  <packaging>swf</packaging>
+
+  <name>Apache Flex - FlexJS: Examples: FlexJS: TableExample</name>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.flex.flexjs.compiler</groupId>
+        <artifactId>flexjs-maven-plugin</artifactId>
+        <extensions>true</extensions>
+        <configuration>
+          <mainClass>TableExample.mxml</mainClass>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+  <dependencies>
+    <dependency>
+      <groupId>com.adobe.flash.framework</groupId>
+      <artifactId>playerglobal</artifactId>
+      <version>${flash.version}</version>
+      <type>swc</type>
+      <scope>provided</scope>
+    </dependency>
+  </dependencies>
+
+</project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/525d9a8d/examples/flexjs/TableExample/src/main/flex/MyInitialView.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/TableExample/src/main/flex/MyInitialView.mxml b/examples/flexjs/TableExample/src/main/flex/MyInitialView.mxml
new file mode 100644
index 0000000..c2f81dd
--- /dev/null
+++ b/examples/flexjs/TableExample/src/main/flex/MyInitialView.mxml
@@ -0,0 +1,121 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+-->
+<js:View xmlns:fx="http://ns.adobe.com/mxml/2009"
+				xmlns:js="library://ns.apache.org/flexjs/basic">
+    
+	<fx:Style>
+		@namespace js "library://ns.apache.org/flexjs/basic";
+		
+		
+		.Table {
+			backgroundColor: orange;
+			padding: 4px;
+		}
+		
+		.TableHeader {
+			backgroundColor: aliceblue;
+			border: 1px solid orange;
+		}
+		
+		.TableCell {
+			backgroundColor: lightblue;
+			border: 1px solid orange;
+		}
+		
+		.CellGroup {
+			backgroundColor: aliceblue;
+			padding: 6px;
+		}
+		
+	</fx:Style>
+	
+	<js:beads>
+		<js:ViewDataBinding />
+	</js:beads>
+	
+	<js:Table width="500" height="400" >
+		<!-- By placing the width on the cell of the first row, you effectively set the
+		     width for the rest of the cells in each column. Here, the widths are set to
+		     percentage values but you can use pixel values as well.
+		-->
+		<js:TableRow>
+			<js:TableHeader width="25%">
+				<js:Label text="Apples" />
+			</js:TableHeader>
+			<js:TableHeader width="50%">
+				<js:Label text="Oranges" />
+			</js:TableHeader>
+			<js:TableHeader width="25%">
+				<js:Label text="Grapes" />
+			</js:TableHeader>
+		</js:TableRow>
+		<js:TableRow>
+			<js:TableCell>
+				<js:Label text="Row 1, Col 1" />
+			</js:TableCell>
+			<js:TableCell>
+				<js:Label text="Row 1, Col 2" />
+			</js:TableCell>
+			<js:TableCell>
+				<js:Label text="Row 1, Col 3" />
+			</js:TableCell>
+		</js:TableRow>
+		<js:TableRow>
+			<js:TableCell>
+				<js:Label text="Row 2, Col 1" />
+			</js:TableCell>
+			<js:TableCell>
+				<js:Label text="Row 2, Col 2" />
+			</js:TableCell>
+			<js:TableCell>
+				<js:Label text="Row 2, Col 3" />
+			</js:TableCell>
+		</js:TableRow>
+		<js:TableRow>
+			<js:TableCell>
+				<js:Label text="Row 3, Col 1" />
+			</js:TableCell>
+			<js:TableCell>
+				<!-- By using a Group within a cell you have better control of the
+				     layout.
+				-->
+				<js:Group className="CellGroup">
+					<js:beads>
+						<js:VerticalLayout />
+					</js:beads>
+					<js:Label text="Row 3" />
+					<js:Label text="+" />
+					<js:Label text="Col 2" />
+				</js:Group>
+			</js:TableCell>
+			<js:TableCell>
+				<js:Group className="CellGroup">
+					<js:beads>
+						<js:HorizontalLayout />
+					</js:beads>
+					<js:Label text="Row 3" />
+					<js:Label text="+" />
+					<js:Label text="Col 3" />
+				</js:Group>
+			</js:TableCell>
+		</js:TableRow>
+	</js:Table>
+
+</js:View>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/525d9a8d/examples/flexjs/TableExample/src/main/flex/TableExample.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/TableExample/src/main/flex/TableExample.mxml b/examples/flexjs/TableExample/src/main/flex/TableExample.mxml
new file mode 100644
index 0000000..2d5c972
--- /dev/null
+++ b/examples/flexjs/TableExample/src/main/flex/TableExample.mxml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!---
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+-->
+<js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
+				   xmlns:local="*"
+				   xmlns:models="models.*"
+				   xmlns:js="library://ns.apache.org/flexjs/basic" 
+				   >
+	
+	<js:valuesImpl>
+		<js:SimpleCSSValuesImpl />
+	</js:valuesImpl>
+	<js:initialView>
+		<local:MyInitialView />
+	</js:initialView>
+</js:Application>


[33/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Missing style def in flash media query for DataGrid.

Posted by ah...@apache.org.
Missing style def in flash media query for DataGrid.


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/16c4fea0
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/16c4fea0
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/16c4fea0

Branch: refs/heads/develop
Commit: 16c4fea0a6c5e064708d64692803021fd25987b7
Parents: 7ffe9dd
Author: Peter Ent <pe...@apache.org>
Authored: Thu Apr 27 10:07:27 2017 -0400
Committer: Peter Ent <pe...@apache.org>
Committed: Thu Apr 27 10:07:27 2017 -0400

----------------------------------------------------------------------
 frameworks/projects/Basic/src/main/resources/defaults.css | 5 +++++
 1 file changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/16c4fea0/frameworks/projects/Basic/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/resources/defaults.css b/frameworks/projects/Basic/src/main/resources/defaults.css
index 6617124..be9a3bd 100644
--- a/frameworks/projects/Basic/src/main/resources/defaults.css
+++ b/frameworks/projects/Basic/src/main/resources/defaults.css
@@ -649,6 +649,11 @@ global
 		IBackgroundBead: ClassReference('org.apache.flex.html.beads.SolidBackgroundBead');
 	}
 	
+	DataGrid {
+		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
+		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
+	}
+	
 	DataContainer {
 		IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
 		IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");


[05/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
index 0000000,0000000..f495acc
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
@@@ -1,0 -1,0 +1,260 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads.layouts
++{
++	//import org.apache.flex.html.beads.layouts.VerticalLayout;
++
++	import org.apache.flex.core.LayoutBase;
++	import org.apache.flex.core.ILayoutChild;
++	import org.apache.flex.core.ILayoutHost;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.UIBase;
++	import org.apache.flex.core.IParentIUIBase;
++
++	COMPILE::SWF {
++		import org.apache.flex.core.IUIBase;
++		import org.apache.flex.core.ValuesManager;
++		import org.apache.flex.events.Event;
++		import org.apache.flex.events.IEventDispatcher;
++		import org.apache.flex.geom.Rectangle;
++		import org.apache.flex.utils.CSSUtils;
++		import org.apache.flex.utils.CSSContainerUtils;
++	}
++
++	public class VerticalFlexLayout extends LayoutBase
++	{
++		/**
++		 * Constructor.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function VerticalFlexLayout()
++		{
++			super();
++		}
++
++		private var _grow:Number = -1;
++
++		/**
++		 * Sets the amount items grow in proportion to other items.
++		 * The default is 0 which prevents the items from expanding to
++		 * fit the space. Use a negative value to unset this property.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get grow():Number {
++			return _grow;
++		}
++		public function set grow(value:Number):void {
++			_grow = value;
++		}
++
++		private var _shrink:Number = -1;
++
++		/**
++		 * Sets the amount an item may shrink in proportion to other items.
++		 * The default is 1 which allows items to shrink to fit into the space.
++		 * Set this to 0 if you want to allow scrolling of the space. Use a negative
++		 * value to unset this property.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get shrink():Number {
++			return _shrink;
++		}
++		public function set shrink(value:Number):void {
++			_shrink = value;
++		}
++
++		/**
++		 *
++		 *  @flexjsignorecoercion org.apache.flex.core.ILayoutHost
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		override public function layout():Boolean
++		{
++			COMPILE::SWF {
++				var contentView:ILayoutView = layoutView;
++
++				var n:Number = contentView.numElements;
++				if (n == 0) return false;
++
++				var spacing:String = "none";
++
++				var maxWidth:Number = 0;
++				var maxHeight:Number = 0;
++				var growCount:Number = 0;
++				var childData:Array = [];
++				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
++				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
++				var hostWidth:Number = hostWidthSizedToContent ? host.width : contentView.width;
++				var hostHeight:Number = hostHeightSizedToContent ? host.height : contentView.height;
++
++				var ilc:ILayoutChild;
++				var data:Object;
++				var canAdjust:Boolean = false;
++				
++				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
++				
++				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++				// resulting adjusted value may be less than zero.
++				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++				
++				var remainingHeight:Number = hostHeight;
++
++				//trace("VerticalFlexLayout for "+UIBase(host).id+" with remainingHeight: "+remainingHeight);
++
++				// First pass determines the data about the child.
++				for(var i:int=0; i < n; i++)
++				{
++					var child:IUIBase = contentView.getElementAt(i) as IUIBase;
++					if (child == null || !child.visible) {
++						childData.push({width:0, height:0, mt:0, ml:0, mr:0, mb:0, grow:0, canAdjust:false});
++						continue;
++					}
++
++					ilc = child as ILayoutChild;
++					
++					var margins:Object = childMargins(child, hostWidth, hostHeight);
++
++					var flexGrow:Object = ValuesManager.valuesImpl.getValue(child, "flex-grow");
++					var growValue:Number = 0;
++					if (flexGrow != null) {
++						growValue = Number(flexGrow);
++						if (!isNaN(growValue) && growValue > 0) growCount++;
++						else growValue = 0;
++					}
++
++					var useWidth:Number = -1;
++					if (!hostWidthSizedToContent) {
++						if (ilc) {
++							if (!isNaN(ilc.percentWidth)) useWidth = hostWidth * (ilc.percentWidth/100.0);
++							else if (!isNaN(ilc.explicitWidth)) useWidth = ilc.explicitWidth;
++							else useWidth = hostWidth;
++						}
++					}
++
++					var useHeight:Number = -1;
++					if (ilc) {
++						if (!isNaN(ilc.explicitHeight)) useHeight = ilc.explicitHeight;
++						else if (!isNaN(ilc.percentHeight)) useHeight = hostHeight * (ilc.percentHeight/100.0);
++						else if (ilc.height > 0) useHeight = ilc.height;
++					}
++					if (growValue == 0 && useHeight > 0) remainingHeight -= useHeight + margins.top + margins.bottom;
++					else remainingHeight -= margins.top + margins.bottom;
++
++					if (maxWidth < useWidth) maxWidth = useWidth;
++					if (maxHeight < useHeight) maxHeight = useHeight;
++
++					childData.push({width:useWidth, height:useHeight, 
++						            mt:margins.top, ml:margins.left, mr:margins.right, mb:margins.bottom, 
++									grow:growValue, canAdjust:canAdjust});
++				}
++
++				var xpos:Number = borderMetrics.left + paddingMetrics.left;
++				var ypos:Number = borderMetrics.top + paddingMetrics.top;
++
++				// Second pass sizes and positions the children based on the data gathered.
++				for(i=0; i < n; i++)
++				{
++					child = contentView.getElementAt(i) as IUIBase;
++					data = childData[i];
++
++					useWidth = (data.width < 0 ? hostWidth : data.width);
++
++					var setHeight:Boolean = true;
++					if (data.height != 0) {
++						if (data.grow > 0 && growCount > 0) {
++							useHeight = remainingHeight / growCount;
++							setHeight = false;
++						} else {
++							useHeight = data.height;
++						}
++					} else {
++						useHeight = child.height;
++					}
++
++					ilc = child as ILayoutChild;
++					if (ilc) {
++						ilc.setX(xpos + data.ml);
++						ilc.setY(ypos + data.mt);
++						if (data.width > 0) {
++							//ilc.width = useWidth;
++							ilc.setWidth(useWidth);
++						}
++						if (useHeight > 0) {
++							if (setHeight) ilc.setHeight(useHeight);
++							else ilc.height = useHeight;
++						}
++					} else {
++						child.x = xpos + data.ml;
++						child.y = ypos + data.mt;
++						child.width = useWidth;
++						if (useHeight > 0) {
++							child.height = useHeight;
++						}
++					}
++
++					ypos += useHeight + data.mt + data.mb;
++
++					//trace("VerticalFlexLayout: setting child "+i+" to "+child.width+" x "+child.height+" at "+child.x+", "+child.y);
++				}
++
++				//trace("VerticalFlexLayout: complete");
++
++				return true;
++			}
++
++			COMPILE::JS {
++				var contentView:ILayoutView = layoutView;
++
++				contentView.element.style["display"] = "flex";
++				contentView.element.style["flex-flow"] = "column";
++
++				var n:int = contentView.numElements;
++				if (n == 0) return false;
++
++				for(var i:int=0; i < n; i++) {
++					var child:UIBase = contentView.getElementAt(i) as UIBase;
++					if (grow >= 0) child.element.style["flex-grow"] = String(grow);
++					if (shrink >= 0) child.element.style["flex-shrink"] = String(shrink);
++				}
++
++				return true;
++			}
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
index 857a458,dd02989..a8b9774
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalLayout.as
@@@ -18,41 -18,40 +18,44 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.beads.layouts
  {
++	import org.apache.flex.core.LayoutBase;
++	
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.IBeadModel;
  	import org.apache.flex.core.ILayoutChild;
  	import org.apache.flex.core.ILayoutHost;
-     import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ILayoutParent;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.IUIBase;
  	import org.apache.flex.core.ValuesManager;
  	COMPILE::JS
  	{
--		import org.apache.flex.core.WrappedHTMLElement;			
++		import org.apache.flex.core.WrappedHTMLElement;
  	}
  	import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
  	import org.apache.flex.geom.Rectangle;
  	import org.apache.flex.utils.CSSContainerUtils;
  	import org.apache.flex.utils.CSSUtils;
--	
++
  	/**
  	 *  The VerticalLayout class is a simple layout
  	 *  bead.  It takes the set of children and lays them out
  	 *  vertically in one column, separating them according to
  	 *  CSS layout rules for margin and horizontal-align styles.
--	 *  
++	 *
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class VerticalLayout implements IBeadLayout
++	public class VerticalLayout extends LayoutBase implements IBeadLayout
  	{
  		/**
  		 *  Constructor.
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
@@@ -60,304 -59,304 +63,123 @@@
  		 */
  		public function VerticalLayout()
  		{
++			super();
  		}
--		
--		// the strand/host container is also an ILayoutChild because
--		// can have its size dictated by the host's parent which is
--		// important to know for layout optimization
--		private var host:ILayoutChild;
--		
--		/**
--		 *  @copy org.apache.flex.core.IBead#strand
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function set strand(value:IStrand):void
--		{
--			host = value as ILayoutChild; 
--		}
--		
++
  		/**
  		 *  Layout children vertically
--		 *  
++		 *
  		 *  @langversion 3.0
  		 *  @playerversion Flash 10.2
  		 *  @playerversion AIR 2.6
  		 *  @productversion FlexJS 0.0
  		 *  @flexjsignorecoercion org.apache.flex.core.ILayoutHost
  		 */
--		public function layout():Boolean
++		override public function layout():Boolean
  		{
  			COMPILE::SWF
  			{
-                 var layoutParent:ILayoutHost = (host as ILayoutParent).getLayoutHost();
 -				var layoutParent:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--				var contentView:IParentIUIBase = layoutParent ? layoutParent.contentView : IParentIUIBase(host);
--				var padding:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
--				
--				var n:int = contentView.numElements;
--				var hasHorizontalFlex:Boolean;
--				var hostSizedToContent:Boolean = host.isWidthSizedToContent();
--				var flexibleHorizontalMargins:Array = [];
--				var ilc:ILayoutChild;
--				var marginLeft:Object;
--				var marginRight:Object;
--				var marginTop:Object;
--				var marginBottom:Object;
--				var margin:Object;
++				var contentView:ILayoutView = layoutView;
++
++				var n:Number = contentView.numElements;
++				if (n == 0) return false;
++
  				var maxWidth:Number = 0;
--				var cssValue:*;
--				// asking for contentView.width can result in infinite loop if host isn't sized already
--				var w:Number = hostSizedToContent ? 0 : contentView.width;
--				var h:Number = contentView.height;
++				var maxHeight:Number = 0;
++				var hostWidthSizedToContent:Boolean = host.isWidthSizedToContent();
++				var hostHeightSizedToContent:Boolean = host.isHeightSizedToContent();
++				var hostWidth:Number = hostWidthSizedToContent ? 0 : contentView.width;
++				var hostHeight:Number = hostHeightSizedToContent ? 0 : contentView.height;
++
++				var ilc:ILayoutChild;
++				var data:Object;
++				var canAdjust:Boolean = false;
++
++				var paddingMetrics:Rectangle = CSSContainerUtils.getPaddingMetrics(host);
++				var borderMetrics:Rectangle = CSSContainerUtils.getBorderMetrics(host);
  				
--				for (var i:int = 0; i < n; i++)
++				// adjust the host's usable size by the metrics. If hostSizedToContent, then the
++				// resulting adjusted value may be less than zero.
++				hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
++				hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
++
++				var xpos:Number = borderMetrics.left + paddingMetrics.left;
++				var ypos:Number = borderMetrics.top + paddingMetrics.left;
++
++				// First pass determines the data about the child.
++				for(var i:int=0; i < n; i++)
  				{
  					var child:IUIBase = contentView.getElementAt(i) as IUIBase;
  					if (child == null || !child.visible) continue;
++					var positions:Object = childPositions(child);
++					var margins:Object = childMargins(child, hostWidth, hostHeight);
++
  					ilc = child as ILayoutChild;
--					var left:Number = NaN;
--					cssValue = ValuesManager.valuesImpl.getValue(child, "left");
--					if (cssValue !== undefined)
--						left = CSSUtils.toNumber(cssValue);
--					var right:Number = NaN;
--					cssValue = ValuesManager.valuesImpl.getValue(child, "right");
--					if (cssValue !== undefined)
--						right = CSSUtils.toNumber(cssValue);
--					margin = ValuesManager.valuesImpl.getValue(child, "margin");
--					marginLeft = ValuesManager.valuesImpl.getValue(child, "margin-left");
--					marginTop = ValuesManager.valuesImpl.getValue(child, "margin-top");
--					marginRight = ValuesManager.valuesImpl.getValue(child, "margin-right");
--					marginBottom = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
--					var ml:Number = CSSUtils.getLeftValue(marginLeft, margin, w);
--					var mr:Number = CSSUtils.getRightValue(marginRight, margin, w);
--					var mt:Number = CSSUtils.getTopValue(marginTop, margin, h);
--					var mb:Number = CSSUtils.getBottomValue(marginBottom, margin, h);
--					var lastmb:Number;
--					var yy:Number;
--					if (i == 0)
--					{
--						if (ilc)
--							ilc.setY(mt + padding.top);
--						else
--							child.y = mt + padding.top;
--					}
--					else
--					{
--						if (ilc)
--							ilc.setY(yy + Math.max(mt, lastmb));
--						else
--							child.y = yy + Math.max(mt, lastmb);
--					}
--					if (ilc)
--					{
--						if (!isNaN(ilc.percentHeight))
--							ilc.setHeight(contentView.height * ilc.percentHeight / 100, !isNaN(ilc.percentWidth));
--					}
--					lastmb = mb;
--					var marginObject:Object = {};
--					flexibleHorizontalMargins[i] = marginObject;
--					if (marginLeft == "auto")
--					{
--						ml = 0;
--						marginObject.marginLeft = marginLeft;
--						hasHorizontalFlex = true;
--					}
--					else
--					{
--						ml = Number(marginLeft);
--						if (isNaN(ml))
--						{
--							ml = 0;
--							marginObject.marginLeft = marginLeft;
--						}
--						else
--							marginObject.marginLeft = ml;
--					}
--					if (marginRight == "auto")
--					{
--						mr = 0;
--						marginObject.marginRight = marginRight;
--						hasHorizontalFlex = true;
--					}
--					else
--					{
--						mr = Number(marginRight);
--						if (isNaN(mr))
--						{
--							mr = 0;
--							marginObject.marginRight = marginRight;
--						}
--						else
--							marginObject.marginRight = mr;
--					}
--					if (!hostSizedToContent)
--					{
--						// if host is sized by parent,
--						// we can position and size children horizontally now
--						setPositionAndWidth(child, left, ml, padding.left, 
--							right, mr, padding.right, w);
--					}
--					else
--					{
--						if (!isNaN(left))
--						{
--							ml = left;
--							marginObject.left = ml;
--						}
--						if (!isNaN(right))
--						{
--							mr = right;
--							marginObject.right = mr;
++
++					ypos += margins.top;
++
++					var childXpos:Number = xpos + margins.left; // default x position
++
++					if (!hostWidthSizedToContent) {
++						var childWidth:Number = child.width;
++						if (ilc != null && !isNaN(ilc.percentWidth)) {
++							childWidth = hostWidth * ilc.percentWidth/100.0;
++							ilc.setWidth(childWidth);
  						}
--						maxWidth = Math.max(maxWidth, ml + child.width + mr);                    
++						// the following code center-aligns the child, but since HTML does not
++						// do this normally, this code is commented. (Use VerticalFlexLayout for
++						// horizontally centered elements in a vertical column).
++						//					childXpos = hostWidth/2 - (childWidth + ml + mr)/2;
  					}
--					yy = child.y + child.height;
--				}
--				if (hostSizedToContent)
--				{
--					for (i = 0; i < n; i++)
--					{
--						child = contentView.getElementAt(i) as IUIBase;
--						if (child == null || !child.visible) continue;
--						var obj:Object = flexibleHorizontalMargins[i];
--						setPositionAndWidth(child, obj.left, obj.marginLeft, padding.left,
--							obj.right, obj.marginRight, padding.right, maxWidth);
--					}
--				}
--				if (hasHorizontalFlex)
--				{
--					for (i = 0; i < n; i++)
--					{
--						child = contentView.getElementAt(i) as IUIBase;
--						if (child == null || !child.visible) continue;
--						ilc = child as ILayoutChild;
--						obj = flexibleHorizontalMargins[i];
--						if (hasHorizontalFlex)
--						{
--							if (ilc)
--							{
--								if (obj.marginLeft == "auto" && obj.marginRight == "auto")
--									ilc.setX(maxWidth - child.width / 2);
--								else if (obj.marginLeft == "auto")
--									ilc.setX(maxWidth - child.width - obj.marginRight - padding.right);                            
--							}
--							else
--							{
--								if (obj.marginLeft == "auto" && obj.marginRight == "auto")
--									child.x = maxWidth - child.width / 2;
--								else if (obj.marginLeft == "auto")
--									child.x = maxWidth - child.width - obj.marginRight - padding.right;
--							}
++
++					if (ilc) {
++						ilc.setX(childXpos);
++						ilc.setY(ypos);
++
++						if (!hostHeightSizedToContent && !isNaN(ilc.percentHeight)) {
++							var newHeight:Number = hostHeight * ilc.percentHeight / 100;
++							ilc.setHeight(newHeight);
  						}
++
++					} else {
++						child.x = childXpos;
++						child.y = ypos;
  					}
++
++					ypos += child.height + margins.bottom;
  				}
--				
--				// Only return true if the contentView needs to be larger; that new
--				// size is stored in the model.
--				var sizeChanged:Boolean = true;
--				
--				host.dispatchEvent( new Event("layoutComplete") );
--				
--				return sizeChanged;
--				
++
++				return true;
  			}
  			COMPILE::JS
  			{
  				var children:Array;
  				var i:int;
  				var n:int;
++				var contentView:IParentIUIBase = layoutView as IParentIUIBase;
  				
-                 var viewBead:ILayoutHost = (host as ILayoutParent).getLayoutHost()
 -				var viewBead:ILayoutHost = host.getBeadByType(ILayoutHost) as ILayoutHost;
--				var contentView:IParentIUIBase = viewBead.contentView;
  				children = contentView.internalChildren();
--				var scv:Object = getComputedStyle(host.positioner);
--				var hasWidth:Boolean = !host.isWidthSizedToContent();
--				var maxWidth:Number = 0;
  				n = children.length;
  				for (i = 0; i < n; i++)
  				{
  					var child:WrappedHTMLElement = children[i];
  					child.flexjs_wrapper.setDisplayStyleForLayout('block');
--					if (child.style.display === 'none') 
++					if (child.style.display === 'none')
  					{
  						child.flexjs_wrapper.setDisplayStyleForLayout('block');
--					} 
--					else 
++					}
++					else
  					{
  						// block elements don't measure width correctly so set to inline for a second
  						child.style.display = 'inline-block';
--						maxWidth = Math.max(maxWidth, child.offsetLeft + child.offsetWidth);
  						child.style.display = 'block';
  					}
  					child.flexjs_wrapper.dispatchEvent('sizeChanged');
  				}
--				if (!hasWidth && n > 0 && !isNaN(maxWidth)) {
--					var pl:String = scv['padding-left'];
--					var pr:String = scv['padding-right'];
--					var npl:int = parseInt(pl.substring(0, pl.length - 2), 10);
--					var npr:int = parseInt(pr.substring(0, pr.length - 2), 10);
--					maxWidth += npl + npr;
--					contentView.width = maxWidth;
--				}
++
  				return true;
  			}
  		}
--		
--		COMPILE::SWF
--		private function setPositionAndWidth(child:IUIBase, left:Number, ml:Number, pl:Number,
--											 right:Number, mr:Number, pr:Number, w:Number):void
--		{
--			var widthSet:Boolean = false;
--			
--			var ww:Number = w;
--			var ilc:ILayoutChild = child as ILayoutChild;
--			if (!isNaN(left))
--			{
--                if (ilc)
--                    ilc.setX(left + ml);
--                else
--    				child.x = left + ml;
--				ww -= left + ml;
--			}
--			else 
--			{
--                if (ilc)
--                    ilc.setX(ml + pl);
--                else
--    				child.x = ml + pl;
--				ww -= ml + pl;
--			}
--			if (!isNaN(right))
--			{
--				if (!isNaN(left))
--				{
--					if (ilc)
--						ilc.setWidth(ww - right - mr, true);
--					else
--					{
--						child.width = ww - right - mr;
--						widthSet = true;
--					}
--				}
--				else
--                {
--                    if (ilc)
--                        ilc.setX(w - right - mr - child.width);
--                    else
--    					child.x = w - right - mr - child.width;
--                }
--			}
--			if (ilc)
--			{
--				if (!isNaN(ilc.percentWidth))
--					ilc.setWidth(w * ilc.percentWidth / 100, true);
--			}
--			if (!widthSet)
--				child.dispatchEvent(new Event("sizeChanged"));
--		}
--		
++
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/models/ButtonBarModel.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/models/ButtonBarModel.as
index 0000000,0000000..9eb6a24
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/models/ButtonBarModel.as
@@@ -1,0 -1,0 +1,102 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads.models
++{
++	import org.apache.flex.core.IRollOverModel;
++	import org.apache.flex.core.ISelectionModel;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.EventDispatcher;
++			
++    /**
++     *  The ArraySelectionModel class is a selection model for
++     *  a dataProvider that is an array. It assumes that items
++     *  can be fetched from the dataProvider
++     *  dataProvider[index].  Other selection models
++     *  would support other kinds of data providers.
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public class ButtonBarModel extends ArraySelectionModel
++	{
++		public static const PIXEL_WIDTHS:Number = 0;
++		public static const PROPORTIONAL_WIDTHS:Number = 1;
++		public static const PERCENT_WIDTHS:Number = 2;
++		
++        /**
++         *  Constructor.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function ButtonBarModel()
++		{
++		}
++		
++		private var _buttonWidths:Array = null;
++		
++		/**
++		 *  The widths of each button. This property may be null (the default) in which
++		 *  case the buttons are equally sized. Or this array may contain values, one per
++		 *  button, which either indicate each button's width in pixels (set .widthType
++		 *  to ButtonBarModel.PIXEL_WIDTHS) or proportional to other buttons (set
++		 *  .widthType to ButtonBarModel.PROPORTIONAL_WIDTHS). The array can also contain
++		 *  specific percentages (set .widthType to ButtonBarModel.PERCENT_WIDTHS). If 
++		 *  this array is set, the number of entries must match the number of buttons. 
++		 *  However, any entry may be null to indicate the button's default size is to be used.
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get buttonWidths():Array
++		{
++			return _buttonWidths;
++		}
++		public function set buttonWidths(value:Array):void
++		{
++			_buttonWidths = value;
++			dispatchEvent(new Event("buttonWidthsChanged"));
++		}
++		
++		private var _widthType:Number = ButtonBarModel.PIXEL_WIDTHS;
++		
++		/**
++		 * Indicates how to interpret the values of the buttonWidths array.
++		 * 
++		 * PIXEL_WIDTHS: all of the values are exact pixel widths (unless a value is null).
++		 * PROPORTIONAL_WIDTHS: all of the values are proportions. Use 1 to indicate normal, 2 to be 2x, etc. Use 0 (or null) to mean fixed default size.
++		 */
++		public function get widthType():Number
++		{
++			return _widthType;
++		}
++		public function set widthType(value:Number):void
++		{
++			_widthType = value;
++			dispatchEvent(new Event("widthTypeChanged"));
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/models/NonNullTextModel.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/models/NonNullTextModel.as
index 0000000,0000000..aefb25f
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/models/NonNullTextModel.as
@@@ -1,0 -1,0 +1,125 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.beads.models
++{	
++	import org.apache.flex.core.IBead;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.ITextModel;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.EventDispatcher;
++	import org.apache.flex.events.IEventDispatcher;
++		
++    /**
++     *  The TextModel class is most basic data model for a
++     *  component that displays text.  All FlexJS components
++     *  that display text should also support HTML, although
++     *  the Flash Player implementations may only support
++     *  a subset of HTML. 
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public class NonNullTextModel extends EventDispatcher implements IBead, ITextModel
++	{
++        /**
++         *  Constructor.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function NonNullTextModel()
++		{
++		}
++		
++		private var _strand:IStrand;
++		
++        /**
++         *  @copy org.apache.flex.core.IBead#strand
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function set strand(value:IStrand):void
++		{
++			_strand = value;
++		}
++
++		private var _text:String = "";
++
++        /**
++         *  @copy org.apache.flex.core.ITextModel#text
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++        public function get text():String
++		{
++			return _text;
++		}
++		
++        /**
++         *  @private
++         */
++		public function set text(value:String):void
++		{
++            if (value == null)
++                value = "";
++			if (value != _text)
++			{
++				_text = value;
++				dispatchEvent(new Event("textChange"));
++			}
++		}
++		
++		private var _html:String;
++        
++        /**
++         *  @copy org.apache.flex.core.ITextModel#html
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function get html():String
++		{
++			return _html;
++		}
++		
++        /**
++         *  @private
++         */
++		public function set html(value:String):void
++		{
++			if (value != _html)
++			{
++				_html = value;
++				dispatchEvent(new Event("htmlChange"));
++			}
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ButtonBarButtonItemRenderer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ButtonBarButtonItemRenderer.as
index 1d320e3,1d320e3..214125e
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ButtonBarButtonItemRenderer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ButtonBarButtonItemRenderer.as
@@@ -92,6 -92,6 +92,24 @@@ package org.apache.flex.html.supportCla
  		}
  		
  		/**
++		 * @private
++		 */
++		override public function setWidth(value:Number, noEvent:Boolean = false):void
++		{
++			super.setWidth(value, noEvent);
++			textButton.width = value;
++		}
++		
++		/**
++		 * @private
++		 */
++		override public function setHeight(value:Number, noEvent:Boolean = false):void
++		{
++			super.setHeight(value, noEvent);
++			textButton.height = value;
++		}
++		
++		/**
  		 *  The data to be displayed by the itemRenderer instance. For ButtonBarItemRenderer, the
  		 *  data's string version is used as the label for the Button.
  		 *
@@@ -107,6 -107,6 +125,7 @@@
  			var added:Boolean = false;
  			if (textButton == null) {
  				textButton = new TextButton();
++				textButton.percentWidth = 100;
  				
  				// listen for clicks on the button and translate them into
  				// an itemClicked event.

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/CheckBoxIcon.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/CheckBoxIcon.as
index 92c3f53,92c3f53..c9eeefb
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/CheckBoxIcon.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/CheckBoxIcon.as
@@@ -82,7 -82,7 +82,7 @@@ package org.apache.flex.html.supportCla
  			element = input as WrappedHTMLElement;
  
  			positioner = element;
--			positioner.style.position = 'relative';
++			//positioner.style.position = 'relative';
  
  			(element as WrappedHTMLElement).flexjs_wrapper = this;
  

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ClippingViewport.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ClippingViewport.as
index 9ef88cf,0000000..16d6d3e
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ClippingViewport.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ClippingViewport.as
@@@ -1,137 -1,0 +1,132 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.supportClasses
 +{
 +	import org.apache.flex.core.IBead;
 +	import org.apache.flex.core.IBeadLayout;
 +	import org.apache.flex.core.IViewport;
 +	import org.apache.flex.core.UIBase;
 +	import org.apache.flex.geom.Size;
 +
 +	COMPILE::JS
 +	{
 +		import org.apache.flex.core.IStrand;
 +	}
 +    COMPILE::SWF
 +    {
 +        import flash.geom.Rectangle;
 +    }
 +
 +	/**
 +	 * The ClippingViewport extends the Viewport class and makes 
 +	 * sure that items extending outside the Container are hidden.
 +	 *
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
 +	 *  @productversion FlexJS 0.0
 +	 */
 +	public class ClippingViewport extends Viewport implements IBead, IViewport
 +	{
 +		/**
 +		 * Constructor
 +	     *
 +	     *  @langversion 3.0
 +	     *  @playerversion Flash 10.2
 +	     *  @playerversion AIR 2.6
 +	     *  @productversion FlexJS 0.0
 +		 */
 +		public function ClippingViewport()
 +		{
 +		}
 +
 +        /**
 +         * @flexjsignorecoercion HTMLElement 
 +         */
 +        COMPILE::JS
 +        override public function set strand(value:IStrand):void
 +        {
 +            super.strand = value;
 +            (contentView.element as HTMLElement).style.overflow = 'hidden';
 +        }
 +
 +        private var viewportWidth:Number;
 +        private var viewportHeight:Number;
 +
 +        /**
 +         * @copy org.apache.flex.core.IViewport
 +         */
 +        override public function layoutViewportBeforeContentLayout(width:Number, height:Number):void
 +        {
 +           super.layoutViewportBeforeContentLayout(width, height);
 +           viewportWidth = width;
 +           viewportHeight = height;
 +        }
 +
 +        /**
 +         * @copy org.apache.flex.core.IViewport
 +         */
- 		override public function layoutViewportAfterContentLayout():Size
++		override public function layoutViewportAfterContentLayout(contentSize:Size):void
 +		{
 +            COMPILE::SWF
 +            {
- 	             var contentSize:Size;
++	             //var contentSize:Size;
 +                do
 +                {
-                     contentSize = super.layoutViewportAfterContentLayout();
++                    /*contentSize = */super.layoutViewportAfterContentLayout(contentSize);
 +                    if (isNaN(viewportHeight))
 +                        viewportHeight = contentSize.height;
 +                    if (isNaN(viewportWidth))
 +                        viewportWidth = contentSize.width;
 +
 +                    var host:UIBase = UIBase(_strand);
 +                    var visibleWidth:Number;
 +                    var visibleHeight:Number;
 +
 +                    var needsLayout:Boolean = false;
 +                    // resize content area
 +                    if (!isNaN(visibleWidth) || !isNaN(visibleHeight))
 +                    {
 +                        if (!isNaN(visibleWidth))
 +                            needsLayout = visibleWidth != contentView.width;
 +                        if (!isNaN(visibleHeight))
 +                            needsLayout = visibleHeight != contentView.height;
 +                        if (!isNaN(visibleWidth) && !isNaN(visibleHeight))
 +                            contentArea.setWidthAndHeight(visibleWidth, visibleHeight, false);
 +                        else if (!isNaN(visibleWidth))
 +                            contentArea.setWidth(visibleWidth, false);
 +                        else if (!isNaN(visibleHeight))
 +                            contentArea.setHeight(visibleHeight, false);
 +                    }
 +                    if (needsLayout)
 +                    {
 +                        var layout:IBeadLayout = host.getBeadByType(IBeadLayout) as IBeadLayout;
 +                        layout.layout();
 +                    }
 +                } while (needsLayout);
 +
 +                var rect:Rectangle = new Rectangle(0, 0, viewportWidth,viewportHeight);
 +                contentArea.scrollRect = rect;
-                 return contentSize;
 +
 +            }
-             COMPILE::JS
-             {
-                 return new Size(contentView.width, contentView.height);
-             }
 +
 +		}
 +
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ContainerContentArea.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ContainerContentArea.as
index 461c57e,6e1bb69..53d9bd5
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ContainerContentArea.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ContainerContentArea.as
@@@ -18,29 -18,26 +18,28 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.supportClasses
  {
--	import org.apache.flex.core.IContentView;
++	import org.apache.flex.core.IBead;
++	import org.apache.flex.core.IStrand;
  	import org.apache.flex.core.UIBase;
      import org.apache.flex.events.Event;
  	import org.apache.flex.events.IEventDispatcher;
-     COMPILE::SWF {
-         import org.apache.flex.core.IChild;
-     }
 -	
++	import org.apache.flex.core.IChild;
++	import org.apache.flex.core.ILayoutView;
 +
      /**
       *  The ContainerContentArea class implements the contentView for
--     *  a Container.  Container's don't always parent their children directly as
--     *  that makes it harder to handle scrolling.
--     *  
++     *  a Container on the SWF platform.
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class ContainerContentArea extends UIBase implements IContentView
++	public class ContainerContentArea extends UIBase implements IBead, ILayoutView
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -51,39 -48,34 +50,18 @@@
  			super();
              addEventListener("layoutNeeded", forwardEventHandler);
  		}
--        
++		
++		protected var host:IStrand;
++		
++		public function set strand(value:IStrand):void
++		{
++			host = value;
++		}
++
          private function forwardEventHandler(event:Event):void
          {
              if (parent is IEventDispatcher)
                  (parent as IEventDispatcher).dispatchEvent(event);
          }
--		
--		/**
--		 *  @copy org.apache.flex.core.IItemRendererParent#removeAllElements()
--		 *  
--		 *  @langversion 3.0
--		 *  @playerversion Flash 10.2
--		 *  @playerversion AIR 2.6
--		 *  @productversion FlexJS 0.0
--		 */
--		public function removeAllElements():void
--		{
--			COMPILE::SWF
--			{
-                 var n:Number = numElements;
-                 for (var i:Number = n-1; i >= 0; i--) {
-                     var child:IChild = getElementAt(i);
-                     removeElement(child,false);
-                 }
--				removeChildren(0);					
--			}
--			COMPILE::JS
--			{
--				while (element.hasChildNodes()) 
--				{
--					element.removeChild(element.lastChild);
--				}
--			}
--		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGridButtonBarButtonItemRenderer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGridButtonBarButtonItemRenderer.as
index f6663a5,f6663a5..d05036f
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGridButtonBarButtonItemRenderer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGridButtonBarButtonItemRenderer.as
@@@ -66,6 -66,6 +66,7 @@@ package org.apache.flex.html.supportCla
  			var added:Boolean = false;
  			if (textButton == null) {
  				textButton = new DataGridButtonBarTextButton();
++				textButton.percentWidth = 100;
  				
  				// listen for clicks on the button and translate them into
  				// an itemClicked event.
@@@ -77,5 -77,5 +78,14 @@@
  			
  			if (added) addElement(textButton);
  		}
++		
++		/**
++		 * @private
++		 */
++		COMPILE::JS
++		override public function adjustSize():void
++		{
++			// not neeed for JS platform
++		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGridColumnList.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGridColumnList.as
index bb0fa65,bb0fa65..e612517
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGridColumnList.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGridColumnList.as
@@@ -56,6 -56,6 +56,7 @@@ package org.apache.flex.html.supportCla
  		public function DataGridColumnList()
  		{
  			super();
++			typeNames = "DataGridColumnList";
  		}
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGroup.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGroup.as
index f7ebf01,f7ebf01..b6ebb71
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGroup.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataGroup.as
@@@ -41,7 -41,7 +41,7 @@@ package org.apache.flex.html.supportCla
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class DataGroup extends ContainerContentArea implements IItemRendererParent, IContentView
++	public class DataGroup extends ContainerContentArea implements IItemRendererParent
  	{
          /**
           *  Constructor.
@@@ -56,55 -56,55 +56,87 @@@
  			super();
  		}
  		
++		/*
++		* IItemRendererParent
++		*/
++		
  		/**
++		 * @copy org.apache.flex.core.IItemRendererParent#addItemRenderer()
  		 * @private
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
  		 */
--		override public function addElement(c:IChild, dispatchEvent:Boolean = true):void
++		public function addItemRenderer(renderer:IItemRenderer):void
  		{
--			super.addElement(c, dispatchEvent);
++			addElement(renderer, true);
  			
  			var newEvent:ItemAddedEvent = new ItemAddedEvent("itemAdded");
--			newEvent.item = c;
++			newEvent.item = renderer;
  			
--			var strand:IEventDispatcher = parent as IEventDispatcher;
--			strand.dispatchEvent(newEvent);
++			(host as IEventDispatcher).dispatchEvent(newEvent);
  		}
  		
  		/**
++		 * @copy org.apache.flex.core.IItemRendererParent#removeItemRenderer()
  		 * @private
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
  		 */
--		override public function removeElement(c:IChild, dispatchEvent:Boolean = true):void
--		{	
--			super.removeElement(c, dispatchEvent);
++		public function removeItemRenderer(renderer:IItemRenderer):void
++		{
++			removeElement(renderer, true);
  			
  			var newEvent:ItemRemovedEvent = new ItemRemovedEvent("itemRemoved");
--			newEvent.item = c;
++			newEvent.item = renderer;
  			
--			var strand:IEventDispatcher = parent as IEventDispatcher;
--			strand.dispatchEvent(newEvent);
++			(host as IEventDispatcher).dispatchEvent(newEvent);
  		}
--
--        /**
--         *  @copy org.apache.flex.core.IItemRendererParent#getItemRendererForIndex()
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--         */
--        public function getItemRendererForIndex(index:int):IItemRenderer
--        {
++		
++		/**
++		 * @copy org.apache.flex.core.IItemRendererParent#removeAllItemRenderers()
++		 * @private
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function removeAllItemRenderers():void
++		{
++			while (numElements > 0) {
++				var child:IChild = getElementAt(0);
++				removeItemRenderer(child as IItemRenderer);
++			}
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.IItemRendererParent#getItemRendererForIndex()
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function getItemRendererForIndex(index:int):IItemRenderer
++		{
  			if (index < 0 || index >= numElements) return null;
--            return getElementAt(index) as IItemRenderer;
--        }
++			return getElementAt(index) as IItemRenderer;
++		}
  		
  		/**
  		 *  Refreshes the itemRenderers. Useful after a size change by the data group.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
++		 *
++		 *  @copy org.apache.flex.core.IItemRendererParent#updateAllItemRenderers()
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
  		 */
  		public function updateAllItemRenderers():void
  		{

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataItemRenderer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataItemRenderer.as
index 8b4ad5b,8b4ad5b..7154689
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataItemRenderer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataItemRenderer.as
@@@ -163,7 -163,7 +163,7 @@@ package org.apache.flex.html.supportCla
  		{
  			element = document.createElement('div') as WrappedHTMLElement;
  			positioner = element;
--			positioner.style.position = 'relative';
++			//positioner.style.position = 'relative';
  
  			element.flexjs_wrapper = this;
  			className = 'DataItemRenderer';

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataProviderNotifierBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataProviderNotifierBase.as
index 0000000,0000000..6c7eb08
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DataProviderNotifierBase.as
@@@ -1,0 -1,0 +1,154 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.supportClasses
++{
++	import org.apache.flex.core.IBead;
++	import org.apache.flex.core.IBeadModel;
++	import org.apache.flex.core.IDocument;
++	import org.apache.flex.core.ISelectionModel;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.UIBase;
++	import org.apache.flex.events.IEventDispatcher;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.collections.ArrayList;
++	
++	/**
++	 *  Base class for all data provider notifiers.
++	 *  
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.0
++	 */
++	public class DataProviderNotifierBase implements IBead, IDocument
++	{
++		/**
++		 *  constructor.
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function DataProviderNotifierBase()
++		{
++		}
++		
++		protected var dataProvider:ArrayList;
++		
++		protected var _strand:IStrand;
++		
++		/**
++		 *  @copy org.apache.flex.core.IBead#strand
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function set strand(value:IStrand):void
++		{
++			_strand = value;
++			
++			if (_strand[destinationPropertyName] == null) {
++				var model:IBeadModel = UIBase(_strand).model as IBeadModel;
++				IEventDispatcher(model).addEventListener(changeEventName, destinationChangedHandler);
++			}
++			else {
++				destinationChangedHandler(null);
++			}
++		}
++		
++		protected function destinationChangedHandler(event:Event):void
++		{
++
++		}
++		
++		protected var document:Object;
++		
++		/**
++		 * @private
++		 */
++		public function setDocument(document:Object, id:String = null):void
++		{
++			this.document = document;
++		}
++		
++		private var _destinationPropertyName:String;
++		
++		public function get destinationPropertyName():String
++		{
++			return _destinationPropertyName;
++		}
++		public function set destinationPropertyName(value:String):void
++		{
++			_destinationPropertyName = value;
++		}
++		
++		private var _changeEventName:String;
++		
++		public function get changeEventName():String
++		{
++			return _changeEventName;
++		}
++		public function set changeEventName(value:String):void
++		{
++			_changeEventName = value;
++		}
++		
++		private var _sourceID:String;
++		
++		/**
++		 *  The ID of the object holding the ArrayList, usually a model.
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get sourceID():String
++		{
++			return _sourceID;
++		}
++		public function set sourceID(value:String):void
++		{
++			_sourceID = value;
++		}
++		
++		private var _propertyName:String;
++		
++		/**
++		 *  The property in the sourceID that is the ArrayList.
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get propertyName():String
++		{
++			return _propertyName;
++		}
++		
++		public function set propertyName(value:String):void
++		{
++			_propertyName = value;
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DateChooserHeader.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DateChooserHeader.as
index 775a140,0000000..0fde1c9
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DateChooserHeader.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/DateChooserHeader.as
@@@ -1,66 -1,0 +1,64 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.supportClasses
 +{
 +	import org.apache.flex.html.DataContainer;
- 	import org.apache.flex.html.beads.layouts.TileLayout;
++	import org.apache.flex.html.beads.layouts.HorizontalFlexLayout;
 +	
 +	/**
 +	 *  The DateChooserHeader is the container for the days of the week labels
 +	 *  in the DateChooser.
 +	 *
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
 +	 *  @productversion FlexJS 0.0
 +	 */
 +	public class DateChooserHeader extends DataContainer
 +	{
 +		/**
 +		 * Constructor.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function DateChooserHeader()
 +		{
 +			super();
 +			
- 			tileLayout = new TileLayout();
- 			tileLayout.numColumns = 7;
- 			addBead(tileLayout);
++			myLayout = new HorizontalFlexLayout();
++			addBead(myLayout);
 +		}
 +		
 +		/**
 +		 * @private
 +		 */
- 		private var tileLayout:TileLayout;
++		private var myLayout:HorizontalFlexLayout;
 +		
 +		/**
 +		 * @private
 +		 */
 +		override public function set height(value:Number):void
 +		{
 +			super.height = value;
- 			tileLayout.rowHeight = value;
 +		}
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/MXMLItemRenderer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/MXMLItemRenderer.as
index cacac1e,0000000..de1b304
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/MXMLItemRenderer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/MXMLItemRenderer.as
@@@ -1,83 -1,0 +1,84 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html.supportClasses
 +{
 +	import org.apache.flex.core.ILayoutHost;
 +	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
 +	import org.apache.flex.core.IStrand;
 +	import org.apache.flex.core.IBead;
 +	import org.apache.flex.core.IBeadLayout;
 +	import org.apache.flex.core.IParentIUIBase;
 +    import org.apache.flex.events.Event;
 +
 +	/**
 +	 *  The MXMLItemRenderer class is the base class for itemRenderers that are MXML-based
 +	 *  and provides support for a layout and a data object.
 +	 *
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
 +	 *  @productversion FlexJS 0.0
 +	 */
- 	public class MXMLItemRenderer extends DataItemRenderer implements ILayoutParent, ILayoutHost, IStrand
++	public class MXMLItemRenderer extends DataItemRenderer implements ILayoutParent, ILayoutHost, IStrand, ILayoutView
 +	{
 +		/**
 +		 *  constructor.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function MXMLItemRenderer()
 +		{
 +			super();
 +		}
- 		
++
 +        [Bindable("dataChange")]
 +        override public function set data(value:Object):void
 +        {
 +            if (value != data)
 +            {
 +                super.data = value;
 +                dispatchEvent(new Event("dataChange"));
 +            }
 +        }
-         
++
 +		public function getLayoutHost():ILayoutHost
 +		{
- 			return this; 
++			return this;
 +		}
- 		
- 		public function get contentView():IParentIUIBase
++
++		public function get contentView():ILayoutView
 +		{
 +			return this;
 +		}
- 		
++
 +		override public function adjustSize():void
 +		{
 +			var layout:IBeadLayout = getBeadByType(IBeadLayout) as IBeadLayout;
 +			if (layout != null) {
 +				layout.layout();
 +			}
 +		}
 +
 +
 +	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/PanelLayoutProxy.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/PanelLayoutProxy.as
index 0000000,0000000..4ebc174
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/PanelLayoutProxy.as
@@@ -1,0 -1,0 +1,132 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html.supportClasses
++{
++	import org.apache.flex.core.UIBase;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.IChild;
++	import org.apache.flex.events.IEventDispatcher;
++
++	import org.apache.flex.html.Panel;
++
++	COMPILE::JS {
++		import org.apache.flex.core.WrappedHTMLElement;
++	}
++
++    /**
++     *  The PanelLayoutProxy class is used by Panel in order for layouts to operate
++	 *  on the Panel itself. If Panel were being used, its numElements, getElementAt, etc.
++	 *  functions would actually redirect to its Container content. In order for a layout
++	 *  to work on the Panel directly (its TitleBar, Container, and ControlBar children),
++	 *  this proxy is used which will invoke the Panel's $numElements, $getElementAt, etc
++	 *  functions.
++     *
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public class PanelLayoutProxy implements ILayoutView
++	{
++        /**
++         *  Constructor.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function PanelLayoutProxy(host:Object)
++		{
++			super();
++			_host = host;
++		}
++
++		private var _host:Object;
++
++		public function get host():Object
++		{
++			return _host;
++		}
++
++		/**
++		 *  The width of the bounding box.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get width():Number {
++			return (host as Panel).width;
++		}
++
++		/**
++		 * The height of the bounding box.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get height():Number {
++			return (host as Panel).height;
++		}
++
++		/**
++		 *  The number of elements in the parent.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function get numElements():int
++		{
++			return (host as Panel).$numElements;
++		}
++
++		/**
++		 *  Get a component from the parent.
++		 *
++		 *  @param c The index of the subcomponent.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function getElementAt(index:int):IChild
++		{
++			return (host as Panel).$getElementAt(index);
++		}
++
++		COMPILE::JS
++		public function get somethingelse():WrappedHTMLElement
++		{
++			return (host as Panel).element;
++		}
++
++		COMPILE::JS
++		public function get element():WrappedHTMLElement
++		{
++			return (host as Panel).element;
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/RadioButtonIcon.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/RadioButtonIcon.as
index 119400f,119400f..3c29ae5
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/RadioButtonIcon.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/RadioButtonIcon.as
@@@ -101,7 -101,7 +101,7 @@@ package org.apache.flex.html.supportCla
  			element = input as WrappedHTMLElement;
  
  			positioner = element;
--			positioner.style.position = 'relative';
++			//positioner.style.position = 'relative';
  
  			(element as WrappedHTMLElement).flexjs_wrapper = this;
  

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ScrollingViewport.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ScrollingViewport.as
index 46ba9a6,46ba9a6..444606b
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ScrollingViewport.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/supportClasses/ScrollingViewport.as
@@@ -18,12 -18,12 +18,9 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html.supportClasses
  {
--    COMPILE::SWF
--    {
--        import flash.geom.Rectangle;
--    }
  	import org.apache.flex.core.IBead;
  	import org.apache.flex.core.IBeadLayout;
++	import org.apache.flex.core.IContainer;
  	import org.apache.flex.core.IContentViewHost;
  	import org.apache.flex.core.IParentIUIBase;
  	import org.apache.flex.core.IStrand;
@@@ -33,12 -33,12 +30,16 @@@
      COMPILE::SWF
      {
          import org.apache.flex.core.IViewportScroller;
++		import org.apache.flex.utils.CSSContainerUtils;
++		import flash.geom.Rectangle;
++		import org.apache.flex.geom.Rectangle;
      }
  	import org.apache.flex.core.UIBase;
  	import org.apache.flex.events.Event;
  	import org.apache.flex.geom.Size;
  	import org.apache.flex.html.beads.ScrollBarView;
  	import org.apache.flex.html.beads.models.ScrollBarModel;
++	import org.apache.flex.geom.Rectangle;
  
  	/**
  	 * The ScrollingViewport extends the Viewport class by adding horizontal and
@@@ -51,6 -51,6 +52,71 @@@
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
++	COMPILE::JS
++	public class ScrollingViewport extends Viewport implements IBead, IViewport
++	{
++		/**
++		 * Constructor
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.0
++		 */
++		public function ScrollingViewport()
++		{
++			super();
++		}
++		
++		public function get verticalScrollPosition():Number
++		{
++			return this.contentView.positioner.scrollTop;
++		}
++		public function set verticalScrollPosition(value:Number):void
++		{
++			this.contentView.positioner.scrollTop = value;
++		}
++		
++		public function get horizontalScrollPosition():Number
++		{
++			return this.contentView.positioner.scrollLeft;
++		}
++		public function set horizontalScrollPosition(value:Number):void
++		{
++			this.contentView.positioner.scrollLeft = value;
++		}
++		
++		/**
++		 * @flexjsignorecoercion HTMLElement 
++		 */
++		override public function set strand(value:IStrand):void
++		{
++			super.strand = value;
++			if (contentView == null) {
++				(value as UIBase).element.style.overflow = "auto";
++			} else {
++				(contentView as UIBase).element.style.overflow = "auto";
++			}
++		}
++		
++		/**
++		* @copy org.apache.flex.core.IViewport
++		*/
++		override public function layoutViewportBeforeContentLayout(width:Number, height:Number):void
++		{
++			// does nothing for the JS platform
++		}
++		
++		/**
++		 * @copy org.apache.flex.core.IViewport
++		 */
++		override public function layoutViewportAfterContentLayout(contentSize:Size):void
++		{
++			// does nothing for the JS platform
++		}
++	}
++	
++	COMPILE::SWF
  	public class ScrollingViewport extends Viewport implements IBead, IViewport
  	{
  		/**
@@@ -63,88 -63,88 +129,45 @@@
  		 */
  		public function ScrollingViewport()
  		{
++			super();
  		}
  
--        COMPILE::SWF
  		private var _verticalScroller:ScrollBar;
  
--        COMPILE::SWF
  		public function get verticalScroller():IViewportScroller
  		{
  			return _verticalScroller;
  		}
  
--        COMPILE::SWF
  		private var _horizontalScroller:ScrollBar
  
--        COMPILE::SWF
  		public function get horizontalScroller():IViewportScroller
  		{
  			return _horizontalScroller;
  		}
  
--        COMPILE::SWF
          private var _verticalScrollPosition:Number = 0;
  
          public function get verticalScrollPosition():Number
          {
--            COMPILE::SWF
--            {
--                return _verticalScrollPosition;
--            }
--            COMPILE::JS
--            {
--                return this.contentView.positioner.scrollTop;
--            }
++			return _verticalScrollPosition;
          }
          public function set verticalScrollPosition(value:Number):void
          {
--            COMPILE::SWF
--            {
--                _verticalScrollPosition = value;
--                handleVerticalScrollChange();
--            }
--            COMPILE::JS
--            {
--                this.contentView.positioner.scrollTop = value;
--            }
++			_verticalScrollPosition = value;
++			handleVerticalScrollChange();
          }
  
--        COMPILE::SWF
          private var _horizontalScrollPosition:Number = 0;
  
          public function get horizontalScrollPosition():Number
          {
--            COMPILE::SWF
--            {
--                return _horizontalScrollPosition;
--            }
--            COMPILE::JS
--            {
--                return this.contentView.positioner.scrollLeft;
--            }
++			return _horizontalScrollPosition;
          }
          public function set horizontalScrollPosition(value:Number):void
          {
--            COMPILE::SWF
--            {
--                _horizontalScrollPosition = value;
--                handleHorizontalScrollChange();
--            }
--            COMPILE::JS
--            {
--                this.contentView.positioner.scrollLeft = value;
--            }
--        }
--
--        /**
--         * @flexjsignorecoercion HTMLElement 
--         */
--        COMPILE::JS
--        override public function set strand(value:IStrand):void
--        {
--            super.strand = value;
--            (contentView.element as HTMLElement).style.overflow = 'auto';
++			_horizontalScrollPosition = value;
++			handleHorizontalScrollChange();
          }
  
          private var viewportWidth:Number;
@@@ -155,127 -155,127 +178,90 @@@
           */
          override public function layoutViewportBeforeContentLayout(width:Number, height:Number):void
          {
--           super.layoutViewportBeforeContentLayout(width, height);
--           viewportWidth = width;
--           viewportHeight = height;
++           	super.layoutViewportBeforeContentLayout(width, height);
++           	viewportWidth = width;
++           	viewportHeight = height;
          }
  
          /**
           * @copy org.apache.flex.core.IViewport
           */
--		override public function layoutViewportAfterContentLayout():Size
++		override public function layoutViewportAfterContentLayout(contentSize:Size):void
  		{
--            COMPILE::SWF
--            {
--                var hadV:Boolean = _verticalScroller != null && _verticalScroller.visible;
--                var hadH:Boolean = _horizontalScroller != null && _horizontalScroller.visible;
--                var contentSize:Size;
--                do
--                {
--                    contentSize = super.layoutViewportAfterContentLayout();
--                    if (isNaN(viewportHeight))
--                        viewportHeight = contentSize.height;
--                    if (isNaN(viewportWidth))
--                        viewportWidth = contentSize.width;
--
--                    var host:UIBase = UIBase(_strand);
--                    var visibleWidth:Number;
--                    var visibleHeight:Number;
--                    var needV:Boolean = contentSize.height > viewportHeight;
--                    var needH:Boolean = contentSize.width > viewportWidth;
--
--                    if (needV)
--                    {
--                        if (_verticalScroller == null) {
--                            _verticalScroller = createVerticalScrollBar();
--                            (host as IContentViewHost).strandChildren.addElement(_verticalScroller);
--                        }
--                    }
--                    if (needH)
--                    {
--                        if (_horizontalScroller == null) {
--                            _horizontalScroller = createHorizontalScrollBar();
--                            (host as IContentViewHost).strandChildren.addElement(_horizontalScroller);
--                        }
--                    }
--
--                    if (needV)
--                    {
--                        _verticalScroller.visible = true;
--                        _verticalScroller.x = contentArea.x + viewportWidth - _verticalScroller.width;
--                        _verticalScroller.y = contentArea.y;
--                        _verticalScroller.setHeight(viewportHeight - (needH ? _horizontalScroller.height : 0), true);
--                        visibleWidth = _verticalScroller.x;
--                    }
--                    else if (_verticalScroller)
--                        _verticalScroller.visible = false;
--
--                    if (needH)
--                    {
--                        _horizontalScroller.visible = true;
--                        _horizontalScroller.x = contentArea.x;
--                        _horizontalScroller.y = contentArea.y + viewportHeight - _horizontalScroller.height;
--                        _horizontalScroller.setWidth(viewportWidth - (needV ? _verticalScroller.width : 0), true);
--                        visibleHeight = _horizontalScroller.y;
--                    }
--
--                    var needsLayout:Boolean = false;
--                    // resize content area if needed to get out from under scrollbars
--                    if (!isNaN(visibleWidth) || !isNaN(visibleHeight))
--                    {
--                        if (!isNaN(visibleWidth))
--                            needsLayout = visibleWidth != contentView.width;
--                        if (!isNaN(visibleHeight))
--                            needsLayout = visibleHeight != contentView.height;
--                        if (!isNaN(visibleWidth) && !isNaN(visibleHeight))
--                            contentArea.setWidthAndHeight(visibleWidth, visibleHeight, false);
--                        else if (!isNaN(visibleWidth))
--                            contentArea.setWidth(visibleWidth, false);
--                        else if (!isNaN(visibleHeight))
--                            contentArea.setHeight(visibleHeight, false);
--                    }
--                    if (needsLayout)
--                    {
--                        var layout:IBeadLayout = host.getBeadByType(IBeadLayout) as IBeadLayout;
--                        layout.layout();
--                    }
--                } while (needsLayout && (needV != hadV || needH == hadH));
--                if (_verticalScroller)
--                {
--                    ScrollBarModel(_verticalScroller.model).maximum = contentSize.height;
--                    ScrollBarModel(_verticalScroller.model).pageSize = contentArea.height;
--                    ScrollBarModel(_verticalScroller.model).pageStepSize = contentArea.height;
--                    if (contentSize.height > contentArea.height &&
--                        (contentSize.height - contentArea.height) < _verticalScrollPosition)
--                        _verticalScrollPosition = contentSize.height - contentArea.height;
--                }
--                if (_horizontalScroller)
--                {
--                    ScrollBarModel(_horizontalScroller.model).maximum = contentSize.width;
--                    ScrollBarModel(_horizontalScroller.model).pageSize = contentArea.width;
--                    ScrollBarModel(_horizontalScroller.model).pageStepSize = contentArea.width;
--                    if (contentSize.width > contentArea.width &&
--                        (contentSize.width - contentArea.width) < _horizontalScrollPosition)
--                        _horizontalScrollPosition = contentSize.width - contentArea.width;
--                }
--
--                var rect:Rectangle = new Rectangle(_horizontalScrollPosition, _verticalScrollPosition,
--                    (_verticalScroller != null && _verticalScroller.visible) ?
--                    _verticalScroller.x : viewportWidth,
--                    (_horizontalScroller != null && _horizontalScroller.visible) ?
--                    _horizontalScroller.y : viewportHeight);
--                contentArea.scrollRect = rect;
--                return contentSize;
--
--            }
--            COMPILE::JS
--            {
--                return new Size(contentView.width, contentView.height);
--            }
--
++			var hadV:Boolean = _verticalScroller != null && _verticalScroller.visible;
++			var hadH:Boolean = _horizontalScroller != null && _horizontalScroller.visible;
++			
++			var hostWidth:Number = UIBase(_strand).width;
++			var hostHeight:Number = UIBase(_strand).height;
++			
++			var borderMetrics:org.apache.flex.geom.Rectangle = CSSContainerUtils.getBorderMetrics(_strand);
++			
++			hostWidth -= borderMetrics.left + borderMetrics.right;
++			hostHeight -= borderMetrics.top + borderMetrics.bottom;
++			
++			var needV:Boolean = contentSize.height > viewportHeight;
++			var needH:Boolean = contentSize.width > viewportWidth;
++			
++			if (needV)
++			{
++				if (_verticalScroller == null) {
++					_verticalScroller = createVerticalScrollBar();
++					(_strand as IContainer).strandChildren.addElement(_verticalScroller);
++				}
++			}
++			if (needH)
++			{
++				if (_horizontalScroller == null) {
++					_horizontalScroller = createHorizontalScrollBar();
++					(_strand as IContainer).strandChildren.addElement(_horizontalScroller);
++				}
++			}
++			
++			if (needV)
++			{
++				_verticalScroller.visible = true;
++				_verticalScroller.x = UIBase(_strand).width - borderMetrics.right - _verticalScroller.width;
++				_verticalScroller.y = borderMetrics.top;
++				_verticalScroller.setHeight(hostHeight - (needH ? _horizontalScroller.height : 0), true);
++				
++				ScrollBarModel(_verticalScroller.model).maximum = contentSize.height;
++				ScrollBarModel(_verticalScroller.model).pageSize = contentArea.height;
++				ScrollBarModel(_verticalScroller.model).pageStepSize = contentArea.height;
++				
++				if (contentSize.height > contentArea.height &&
++					(contentSize.height - contentArea.height) < _verticalScrollPosition)
++					_verticalScrollPosition = contentSize.height - contentArea.height;
++			}
++			else if (_verticalScroller) {
++				_verticalScroller.visible = false;
++			}
++			
++			if (needH)
++			{
++				_horizontalScroller.visible = true;
++				_horizontalScroller.x = 0;
++				_horizontalScroller.y = UIBase(_strand).height - borderMetrics.bottom - _horizontalScroller.height;
++				_horizontalScroller.setWidth(hostWidth - (needV ? _verticalScroller.width : 0), true);
++				
++				ScrollBarModel(_horizontalScroller.model).maximum = contentSize.width;
++				ScrollBarModel(_horizontalScroller.model).pageSize = contentArea.width;
++				ScrollBarModel(_horizontalScroller.model).pageStepSize = contentArea.width;
++				
++				if (contentSize.width > contentArea.width &&
++					(contentSize.width - contentArea.width) < _horizontalScrollPosition)
++					_horizontalScrollPosition = contentSize.width - contentArea.width;
++			} 
++			else if (_horizontalScroller) {
++				_horizontalScroller.visible = false;
++			}
++			
++			var rect:flash.geom.Rectangle = new flash.geom.Rectangle(_horizontalScrollPosition, _verticalScrollPosition,
++				(_verticalScroller != null && _verticalScroller.visible) ? _verticalScroller.x : hostWidth,
++				(_horizontalScroller != null && _horizontalScroller.visible) ? _horizontalScroller.y : hostHeight);
++			
++			contentArea.scrollRect = rect;
  		}
  
--		COMPILE::SWF
  		private function createVerticalScrollBar():ScrollBar
  		{
  			var vsbm:ScrollBarModel = new ScrollBarModel();
@@@ -293,7 -293,7 +279,6 @@@
  			return vsb;
  		}
  
--        COMPILE::SWF
  		private function createHorizontalScrollBar():ScrollBar
  		{
  			var hsbm:ScrollBarModel = new ScrollBarModel();
@@@ -311,31 -311,31 +296,28 @@@
  			return hsb;
  		}
  
--        COMPILE::SWF
  		private function handleVerticalScroll(event:Event):void
  		{
  			var host:UIBase = UIBase(_strand);
  			var vpos:Number = ScrollBarModel(_verticalScroller.model).value;
--			var rect:Rectangle = contentArea.scrollRect;
++			var rect:flash.geom.Rectangle = contentArea.scrollRect;
  			rect.y = vpos;
  			contentArea.scrollRect = rect;
  
  			_verticalScrollPosition = vpos;
  		}
  
--        COMPILE::SWF
  		private function handleHorizontalScroll(event:Event):void
  		{
  			var host:UIBase = UIBase(_strand);
  			var hpos:Number = ScrollBarModel(_horizontalScroller.model).value;
--			var rect:Rectangle = contentArea.scrollRect;
++			var rect:flash.geom.Rectangle = contentArea.scrollRect;
  			rect.x = hpos;
  			contentArea.scrollRect = rect;
  
  			_horizontalScrollPosition = hpos;
  		}
  
--        COMPILE::SWF
  		private function handleVerticalScrollChange():void
  		{
  			if (_verticalScroller) {
@@@ -343,7 -343,7 +325,6 @@@
  			}
  		}
  
--        COMPILE::SWF
  		private function handleHorizontalScrollChange():void
  		{
  			if (_horizontalScroller) {


[11/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - Merge branch 'develop' into dual. Clean build. Now to get it to run

Posted by ah...@apache.org.
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/GroupBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/GroupBase.as
index 0000000,0000000..e4dfb1f
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/GroupBase.as
@@@ -1,0 -1,0 +1,280 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.core
++{
++	import org.apache.flex.core.IContentViewHost;
++	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutHost;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.ValueChangeEvent;
++	import org.apache.flex.states.State;
++	import org.apache.flex.utils.MXMLDataInterpreter;
++
++    /**
++     *  Indicates that the state change has completed.  All properties
++     *  that need to change have been changed, and all transitinos
++     *  that need to run have completed.  However, any deferred work
++     *  may not be completed, and the screen may not be updated until
++     *  code stops executing.
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.8
++     */
++    [Event(name="stateChangeComplete", type="org.apache.flex.events.Event")]
++    
++    /**
++     *  Indicates that the initialization of the container is complete.
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.8
++     */
++    [Event(name="initComplete", type="org.apache.flex.events.Event")]
++    
++    /**
++     *  Indicates that the children of the container is have been added.
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.8
++     */
++    [Event(name="childrenAdded", type="org.apache.flex.events.Event")]
++    
++    /**
++     *  The GroupBase class is the base class for most simple containers
++     *  in FlexJS.  It is usable as the root tag of MXML
++     *  documents and UI controls and containers are added to it.
++     *  
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.8
++     */
++	public class GroupBase extends UIBase implements IStatesObject, IContainer, ILayoutParent, ILayoutView, IContentViewHost
++	{
++        /**
++         *  Constructor.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++		public function GroupBase()
++		{
++			super();            
++		}
++		
++		/**
++		 * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
++		 */
++		COMPILE::JS
++		override protected function createElement():WrappedHTMLElement
++		{
++			element = document.createElement('div') as WrappedHTMLElement;
++			element.flexjs_wrapper = this;
++			
++			positioner = element;
++			
++			return element;
++		}
++		
++		/*
++		 * IContainer
++		 */
++        
++        /**
++         *  @private
++         */
++        public function childrenAdded():void
++        {
++            dispatchEvent(new Event("childrenAdded"));
++        }
++		
++		/*
++		 * Utility
++		 */
++		
++		/**
++		 * Dispatches a "layoutNeeded" event
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		public function layoutNeeded():void
++		{
++			dispatchEvent( new Event("layoutNeeded") );
++		}
++		
++		/*
++		 * ILayoutParent
++		 */
++		
++		/**
++		 * Returns the ILayoutHost which is its view. From ILayoutParent.
++		 *
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function getLayoutHost():ILayoutHost
++		{
++			return view as ILayoutHost;
++		}
++		
++		/**
++		 * @copy org.apache.flex.core.IContentViewHost#strandChildren
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		public function get strandChildren():IParent
++		{
++			return this;
++		}
++		
++        private var _states:Array;
++        
++        /**
++         *  The array of view states. These should
++         *  be instances of org.apache.flex.states.State.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++        public function get states():Array
++        {
++            return _states;
++        }
++
++        /**
++         *  @private
++         *  @flexjsignorecoercion Class
++         *  @flexjsignorecoercion org.apache.flex.core.IBead
++         */
++        public function set states(value:Array):void
++        {
++            _states = value;
++            _currentState = _states[0].name;
++            
++			try{
++				if (getBeadByType(IStatesImpl) == null)
++                {
++                    var c:Class = ValuesManager.valuesImpl.getValue(this, "iStatesImpl") as Class;
++                    var b:Object = new c();
++					addBead(b as IBead);
++                }
++			}
++			//TODO:  Need to handle this case more gracefully
++			catch(e:Error)
++			{
++                COMPILE::SWF
++                {
++                    trace(e.message);                        
++                }
++			}
++            
++        }
++        
++        /**
++         *  <code>true</code> if the array of states
++         *  contains a state with this name.
++         * 
++         *  @param state The state namem.
++         *  @return True if state in state array
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++        public function hasState(state:String):Boolean
++        {
++            for each (var s:State in _states)
++            {
++                if (s.name == state)
++                    return true;
++            }
++            return false;
++        }
++        
++        private var _currentState:String;
++        
++        [Bindable("currentStateChange")]
++        /**
++         *  The name of the current state.
++         * 
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++        public function get currentState():String
++        {
++            return _currentState;   
++        }
++
++        /**
++         *  @private
++         */
++        public function set currentState(value:String):void
++        {
++            var event:ValueChangeEvent = new ValueChangeEvent("currentStateChange", false, false, _currentState, value)
++            _currentState = value;
++            dispatchEvent(event);
++        }
++        
++        private var _transitions:Array;
++        
++        /**
++         *  The array of transitions.
++         *  
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++        public function get transitions():Array
++        {
++            return _transitions;   
++        }
++        
++        /**
++         *  @private
++         */
++        public function set transitions(value:Array):void
++        {
++            _transitions = value;   
++        }
++
++    }
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/IList.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/IList.as
index 0000000,0000000..3162b3b
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/IList.as
@@@ -1,0 -1,0 +1,48 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.core
++{
++	import org.apache.flex.core.IItemRendererParent;
++	import org.apache.flex.core.IItemRendererProvider;
++
++    /**
++     *  The IList interface is implemented by any component that supports being
++	 *  a "list" which means its content is generated by a factory and whose
++	 *  children are item renderers (IItemRenderer).
++     * 
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	public interface IList extends IItemRendererProvider
++	{
++        /**
++         *  Returns the component within the list (maybe even the list shell itself)
++		 *  which will be the parent of each itemRenderer.
++         * 
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		function get dataGroup():IItemRendererParent;
++		
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
index 0000000,0000000..dde6448
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.as
@@@ -1,0 -1,0 +1,166 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.core
++{
++
++	import org.apache.flex.core.IBeadLayout;
++	import org.apache.flex.core.ILayoutChild;
++	import org.apache.flex.core.ILayoutHost;
++	import org.apache.flex.core.ILayoutParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.IParent;
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.ValuesManager;
++    import org.apache.flex.utils.CSSUtils;
++
++    /**
++     *  This class is the base class for most, if not all, layouts. 
++     *
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.8
++     */
++	public class LayoutBase implements IBeadLayout
++	{
++        /**
++         *  Constructor.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++		public function LayoutBase()
++		{
++		}
++
++        /**
++		 * The strand/host container is also an ILayoutChild because
++         * it can have its size dictated by the host's parent which is
++         * important to know for layout optimization.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++        protected var host:ILayoutChild;
++
++        /**
++         *  @copy org.apache.flex.core.IBead#strand
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 * 
++		 * @flexjsignorecoercion org.apache.flex.core.ILayoutChild
++         */
++		public function set strand(value:IStrand):void
++		{
++            host = value as ILayoutChild;
++		}
++		
++		/**
++		 * Returns an object of margins for the given child.
++		 * 
++		 * @param child Object The element whose margins are required.
++		 * @param hostWidth Number The usable width dimension of the host.
++		 * @param hostHeight Number The usable height dimension of the host.
++		 * 
++		 * @return Object A structure of {top:Number, left:Number, bottom:Number, right:Number}
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		protected function childMargins(child:Object, hostWidth:Number, hostHeight:Number):Object
++		{
++			var margin:Object = ValuesManager.valuesImpl.getValue(child, "margin");
++			var marginLeft:Object = ValuesManager.valuesImpl.getValue(child, "margin-left");
++			var marginTop:Object = ValuesManager.valuesImpl.getValue(child, "margin-top");
++			var marginRight:Object = ValuesManager.valuesImpl.getValue(child, "margin-right");
++			var marginBottom:Object = ValuesManager.valuesImpl.getValue(child, "margin-bottom");
++			var ml:Number = CSSUtils.getLeftValue(marginLeft, margin, hostWidth);
++			var mr:Number = CSSUtils.getRightValue(marginRight, margin, hostWidth);
++			var mt:Number = CSSUtils.getTopValue(marginTop, margin, hostHeight);
++			var mb:Number = CSSUtils.getBottomValue(marginBottom, margin, hostHeight);
++			if (marginLeft == "auto")
++				ml = 0;
++			if (marginRight == "auto")
++				mr = 0;
++			
++			return {left:ml, top:mt, right:mr, bottom:mb};
++		}
++		
++		/**
++		 * Returns an object containing the child's positioning values.
++		 * 
++		 * @param child Object The element whose positions are required.
++		 * 
++		 * @return Object A structure of {top:Number, left:Number, bottom:Number, right:Number}
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 */
++		protected function childPositions(child:Object):Object
++		{
++			var left:Number = ValuesManager.valuesImpl.getValue(child, "left");
++			var right:Number = ValuesManager.valuesImpl.getValue(child, "right");
++			var top:Number = ValuesManager.valuesImpl.getValue(child, "top");
++			var bottom:Number = ValuesManager.valuesImpl.getValue(child, "bottom");
++			
++			return {top:top, left:left, bottom:bottom, right:right};
++		}
++		
++		/**
++		 * Returns the ILayoutView for the host.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++		 * 
++		 * @flexjsignorecoercion org.apache.flex.core.ILayoutParent
++		 */
++		protected function get layoutView():ILayoutView
++		{
++			var viewBead:ILayoutHost = (host as ILayoutParent).getLayoutHost();
++			return viewBead.contentView;
++		}
++
++        /**
++         * @copy org.apache.flex.core.IBeadLayout#layout
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++		public function layout():Boolean
++		{
++            // override in subclass
++			return false;
++		}
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ListBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ListBase.as
index 562e74e,562e74e..3ec846a
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ListBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ListBase.as
@@@ -17,15 -17,15 +17,12 @@@
  //
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.core
--{
--	import org.apache.flex.core.IMXMLDocument;
--	import org.apache.flex.core.ValuesManager;
--	import org.apache.flex.core.ILayoutParent;
--	import org.apache.flex.events.Event;
--	import org.apache.flex.events.ValueChangeEvent;
--	import org.apache.flex.states.State;
--	import org.apache.flex.utils.MXMLDataInterpreter;
--    
++{    
++	/*
++	 *************
++	 * THIS CLASS IS NO LONGER NEEDED. INHERIT FROM DataContainerBase
++	 */
++	
      /**
       *  The ListBase class is the base class for most lists
       *  in FlexJS.
@@@ -35,7 -35,7 +32,7 @@@
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class ListBase extends UIBase implements IContentViewHost, ILayoutParent
++	public class ListBase extends DataContainerBase
  	{
          /**
           *  Constructor.
@@@ -47,89 -47,89 +44,7 @@@
           */
  		public function ListBase()
  		{
--			super();
--            
--			_strandChildren = new ListBaseStrandChildren(this);
++			super();            
  		}
--		
--		private var _strandChildren:ListBaseStrandChildren;
--		
--		/**
--		 * @private
--		 */
--		public function get strandChildren():IParent
--		{
--			return _strandChildren;
--		}
--		
--		/**
--		 * @private
--		 */
--		public function getLayoutHost():ILayoutHost
--		{
--			return view as ILayoutHost; 
--		}
--		
--		/**
--		 * @private
--         * @suppress {undefinedNames}
--		 * Support strandChildren.
--		 */
--		public function $numElements():int
--		{
--			return super.numElements();
--		}
--		
--		
--		/**
--		 * @private
--         * @suppress {undefinedNames}
--		 * Support strandChildren.
--		 */
--		public function $addElement(c:IChild, dispatchEvent:Boolean = true):void
--		{
--			super.addElement(c, dispatchEvent);
--		}
--		
--		/**
--		 * @private
--         * @suppress {undefinedNames}
--		 * Support strandChildren.
--		 */
--		public function $addElementAt(c:IChild, index:int, dispatchEvent:Boolean = true):void
--		{
--			super.addElementAt(c, index, dispatchEvent);
--		}
--		
--		/**
--		 * @private
--         * @suppress {undefinedNames}
--		 * Support strandChildren.
--		 */
--		public function $removeElement(c:IChild, dispatchEvent:Boolean = true):void
--		{
--			super.removeElement(c, dispatchEvent);
--		}
--		
--		/**
--		 * @private
--         * @suppress {undefinedNames}
--		 * Support strandChildren.
--		 */
--		public function $getElementIndex(c:IChild):int
--		{
--			return super.getElementIndex(c);
--		}
--		
--		/**
--		 * @private
--         * @suppress {undefinedNames}
--		 * Support strandChildren.
--		 */
--		public function $getElementAt(index:int):IChild
--		{
--			return super.getElementAt(index);
--		}
--
      }
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIBase.as
index ca34c66,842ec95..d917b8d
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIBase.as
@@@ -158,6 -157,6 +158,7 @@@ package org.apache.flex.cor
              COMPILE::SWF
              {
                  MouseEventConverter.setupInstanceConverters(this);
++                doubleClickEnabled = true; // make JS and flash consistent
              }
              
              COMPILE::JS
@@@ -651,7 -646,7 +652,7 @@@
          COMPILE::JS
          public function set x(value:Number):void
          {
--            positioner.style.position = 'absolute';
++            //positioner.style.position = 'absolute';
              positioner.style.left = value.toString() + 'px';
          }
  
@@@ -684,7 -679,7 +685,7 @@@
  			}
  			COMPILE::JS
  			{
--				positioner.style.position = 'absolute';
++				//positioner.style.position = 'absolute';
  				positioner.style.left = value.toString() + 'px';
  			}
          }
@@@ -707,7 -702,7 +708,7 @@@
          COMPILE::JS
          public function set y(value:Number):void
          {
--            positioner.style.position = 'absolute';
++            //positioner.style.position = 'absolute';
              positioner.style.top = value.toString() + 'px';
          }
          
@@@ -740,7 -735,7 +741,7 @@@
  			}
  			COMPILE::JS
  			{
--				positioner.style.position = 'absolute';
++				//positioner.style.position = 'absolute';
  				positioner.style.top = value.toString() + 'px';				
  			}
          }
@@@ -1192,6 -1177,6 +1193,10 @@@
              COMPILE::JS
              {
                  var children:Array = internalChildren();
++                if (children.length == 0)
++                {
++                    return null;
++                }
                  return children[index].flexjs_wrapper;
              }
          }        
@@@ -1469,7 -1454,7 +1474,7 @@@
              if (positioner == null)
                  positioner = element;
              positioner.style.display = 'block';
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              
              element.flexjs_wrapper = this;
              

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as
index de37c99,de37c99..9643b58
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/UIButtonBase.as
@@@ -103,14 -103,14 +103,12 @@@ package org.apache.flex.cor
  		 */
  		override public function set x(value:Number):void
  		{
--			if (super.x != value) {
--				super.x = _x = value;
--                if (!style)
--                    style = { left: value };
--                else
--                    style.left = value;
--				dispatchEvent(new Event("xChanged"));
--			}
++			super.x = _x = value;
++			if (!style)
++				style = { left: value };
++			else
++				style.left = value;
++			dispatchEvent(new Event("xChanged"));
  		}
  		
          private var _y:Number;
@@@ -120,14 -120,14 +118,12 @@@
  		 */
  		override public function set y(value:Number):void
  		{
--			if (super.y != value) {
--				super.y = _y = value;
--                if (!style)
--                    style = { top: value };
--                else
--                    style.top = value;
--				dispatchEvent(new Event("yChanged"));
--			}
++			super.y = _y = value;
++			if (!style)
++				style = { top: value };
++			else
++				style.top = value;
++			dispatchEvent(new Event("yChanged"));
  		}
  		
  		/**
@@@ -750,7 -750,7 +746,7 @@@
  				_model = bead as IBeadModel;
              else if (bead is IBeadView)
                  _view = bead as IBeadView;
--			bead.strand = this;
++			//bead.strand = this; // super.addBead already did this!
  		}
  		
          /**

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/View.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/View.as
index 2d0f2c4,2d0f2c4..27882f3
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/View.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/View.as
@@@ -17,7 -17,7 +17,18 @@@
  //
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.core
--{    
++{    	
++	import org.apache.flex.core.IMXMLDocument;
++	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.utils.MXMLDataInterpreter;
++	
++	/**
++	 * The default property uses when additional MXML content appears within an element's
++	 * definition in an MXML file.
++	 */
++	[DefaultProperty("mxmlContent")]
++	
      /**
       *  The View class is the class for most views in a FlexJS
       *  application.  It is generally used as the root tag of MXML
@@@ -29,6 -29,6 +40,84 @@@
       *  @productversion FlexJS 0.0
       */
  	public class View extends ViewBase
--	{
++	{		
++		public function View()
++		{
++			super();
++		}
++		
++		private var _mxmlDescriptor:Array;
++		private var _mxmlDocument:Object = this;
++		private var _initialized:Boolean;
++		
++		/**
++		 * @private
++		 */
++		override public function addedToParent():void
++		{
++			if (!_initialized)
++			{
++				// each MXML file can also have styles in fx:Style block
++				ValuesManager.valuesImpl.init(this);
++			}
++			
++			super.addedToParent();
++			
++			if (!_initialized)
++			{
++				MXMLDataInterpreter.generateMXMLInstances(_mxmlDocument, this, MXMLDescriptor);
++				
++				dispatchEvent(new Event("initBindings"));
++				dispatchEvent(new Event("initComplete"));
++				_initialized = true;
++				
++				// - why was this added here? childrenAdded(); //?? Is this necessary since MXMLDataInterpreter will already have called it
++			}
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.Application#MXMLDescriptor
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get MXMLDescriptor():Array
++		{
++			return _mxmlDescriptor;
++		}
++		
++		/**
++		 *  @private
++		 */
++		public function setMXMLDescriptor(document:Object, value:Array):void
++		{
++			_mxmlDocument = document;
++			_mxmlDescriptor = value;
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.Application#generateMXMLAttributes()
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function generateMXMLAttributes(data:Array):void
++		{
++			MXMLDataInterpreter.generateMXMLProperties(this, data);
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.ItemRendererClassFactory#mxmlContent
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public var mxmlContent:Array;
      }
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ViewBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ViewBase.as
index b385d74,73092af..cd9b835
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ViewBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/ViewBase.as
@@@ -23,36 -23,36 +23,36 @@@ package org.apache.flex.cor
      //--------------------------------------
      //  Events
      //--------------------------------------
--    
++
      /**
       *  Dispatched at startup. Attributes and sub-instances of
       *  the MXML document have been created and assigned.
       *  The component lifecycle is different
       *  than the Flex SDK.  There is no creationComplete event.
--     *  
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
  	[Event(name="initComplete", type="org.apache.flex.events.Event")]
--    
++
  	[DefaultProperty("mxmlContent")]
--    
++
      /**
       *  The ViewBase class is the base class for most views in a FlexJS
       *  application.
--     *  
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--	public class ViewBase extends ContainerBase implements IPopUpHost, IApplicationView, ILayoutParent
++	public class ViewBase extends GroupBase implements IPopUpHost, IApplicationView
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -61,19 -61,19 +61,19 @@@
  		public function ViewBase()
  		{
  			super();
--            
++
  			className = "flexjs";
  		}
--		
++
  		private var _applicationModel:Object;
--		
++
  		[Bindable("modelChanged")]
--        
++
          /**
           *  A reference to the Application's model.  Usually,
           *  a view is displaying the main model for an
           *  application.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -83,7 -83,7 +83,7 @@@
  		{
  			return _applicationModel;
  		}
--        
++
          /**
           *  @private
           */
@@@ -92,20 -92,20 +92,6 @@@
              _applicationModel = value;
              dispatchEvent(new Event("modelChanged"));
          }
--		
--		/**
--		 * Implements the ILayoutParent protocol by returning the bead that
--		 * is acting as the host for layout.
--         *  
--         *  @langversion 3.0
--         *  @playerversion Flash 10.2
--         *  @playerversion AIR 2.6
--         *  @productversion FlexJS 0.0
--		 */
--		public function getLayoutHost():ILayoutHost
--		{
- 			return view as ILayoutHost;
 -			return getBeadByType(ILayoutHost) as ILayoutHost;
--		}
  
      }
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ButtonBar.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ButtonBar.as
index e4c58e7,e4c58e7..0dffead
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ButtonBar.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ButtonBar.as
@@@ -18,23 -18,23 +18,26 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html
  {
++	import org.apache.flex.html.beads.models.ButtonBarModel;
++	
      COMPILE::JS
      {
--        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
      }
  
  	/**
  	 *  The ButtonBar class is a component that displays a set of Buttons. The ButtonBar
--	 *  is actually a List with a default horizontal layout and an itemRenderer that 
++	 *  is actually a List with a default horizontal layout and an itemRenderer that
  	 *  produces Buttons. The ButtonBar uses the following beads:
--	 * 
++	 *
  	 *  org.apache.flex.core.IBeadModel: the data model for the ButtonBar, including the dataProvider.
  	 *  org.apache.flex.core.IBeadView: constructs the parts of the component.
  	 *  org.apache.flex.core.IBeadController: handles input events.
  	 *  org.apache.flex.core.IBeadLayout: sizes and positions the component parts.
  	 *  org.apache.flex.core.IDataProviderItemRendererMapper: produces itemRenderers.
  	 *  org.apache.flex.core.IItemRenderer: the class or class factory to use.
--	 *  
++	 *
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
@@@ -54,7 -54,7 +57,25 @@@
  		{
  			super();
  		}
--        
++		
++		public function get buttonWidths():Array
++		{
++			return ButtonBarModel(model).buttonWidths;
++		}
++		public function set buttonWidths(value:Array):void
++		{
++			ButtonBarModel(model).buttonWidths = value;
++		}
++		
++		public function get widthType():Number
++		{
++			return ButtonBarModel(model).widthType;
++		}
++		public function set widthType(value:Number):void
++		{
++			ButtonBarModel(model).widthType = value;
++		}
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
@@@ -62,14 -62,14 +83,12 @@@
          override protected function createElement():WrappedHTMLElement
          {
              element = document.createElement('div') as WrappedHTMLElement;
--            element.style.overflow = 'auto';
              positioner = element;
--            positioner.style.position = 'relative';
--            
++
              className = 'ButtonBar';
--            
++
              element.flexjs_wrapper = this;
--            
++
              return element;
          }
  	}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ButtonBase.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ButtonBase.as
index a30f0cf,a30f0cf..72d19e1
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ButtonBase.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ButtonBase.as
@@@ -84,7 -84,7 +84,6 @@@ package org.apache.flex.htm
              element.setAttribute('type', 'button');
              
              positioner = element;
--            positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
              
              /* AJH comment out until we figure out why it is needed

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CSSCheckBox.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CSSCheckBox.as
index 0000000,0000000..40c0b7a
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CSSCheckBox.as
@@@ -1,0 -1,0 +1,219 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html
++{
++    COMPILE::SWF
++    {
++        import flash.events.MouseEvent;
++    }
++
++	import org.apache.flex.core.IStrand;
++	import org.apache.flex.core.IToggleButtonModel;
++	import org.apache.flex.core.IUIBase;
++    COMPILE::SWF
++    {
++        import org.apache.flex.core.UIButtonBase;
++    }
++    COMPILE::JS
++    {
++        import org.apache.flex.core.UIBase;
++        import org.apache.flex.core.WrappedHTMLElement;
++		import org.apache.flex.html.supportClasses.CheckBoxIcon;
++    }
++	import org.apache.flex.events.Event;
++	import org.apache.flex.events.MouseEvent;
++
++    //--------------------------------------
++    //  Events
++    //--------------------------------------
++
++    /**
++     *  Dispatched when the user checks or un-checks the CSSCheckBox.
++     *
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++	[Event(name="change", type="org.apache.flex.events.Event")]
++
++    /**
++     *  The CSSCheckBox class implements the common user interface
++     *  control.  The CSSCheckBox includes its text label and is styleable using CSS.
++     * To style the checkbox control, a `checkClassName` should be specified which corresponds to a CSS class name.
++     *
++     *  @toplevel
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.0
++     */
++    COMPILE::SWF
++	public class CSSCheckBox extends UIButtonBase implements IStrand
++	{
++        /**
++         *  Constructor.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function CSSCheckBox()
++		{
++			super();
++
++			addEventListener(org.apache.flex.events.MouseEvent.CLICK, internalMouseHandler);
++		}
++
++        /**
++         *  The text label for the CSSCheckBox.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function get text():String
++		{
++			return IToggleButtonModel(model).text;
++		}
++
++        /**
++         *  @private
++         */
++		public function set text(value:String):void
++		{
++			IToggleButtonModel(model).text = value;
++		}
++
++        [Bindable("change")]
++        /**
++         *  <code>true</code> if the check mark is displayed.
++         *
++         *  @default false
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.0
++         */
++		public function get selected():Boolean
++		{
++			return IToggleButtonModel(model).selected;
++		}
++
++        /**
++         *  @private
++         */
++		public function set selected(value:Boolean):void
++		{
++			IToggleButtonModel(model).selected = value;
++		}
++
++		private function internalMouseHandler(event:org.apache.flex.events.MouseEvent) : void
++		{
++			selected = !selected;
++			dispatchEvent(new Event("change"));
++		}
++        private var _checkClassName:String;
++        public function get checkClassName():String
++        {
++            return _checkClassName;
++        }
++        public function set checkClassName(value:String):void
++        {
++            _checkClassName = value;
++        }
++        
++	}
++
++    COMPILE::JS
++    public class CSSCheckBox extends UIBase
++    {
++
++		private var _label:WrappedHTMLElement;
++		private var _icon:CheckBoxIcon;
++		private var _styleDiv:WrappedHTMLElement;
++        private var _textNode:WrappedHTMLElement
++
++		private static var _checkNumber:Number = 0;
++
++        /**
++         * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
++         */
++        override protected function createElement():WrappedHTMLElement
++        {
++            element = document.createElement('label') as WrappedHTMLElement;
++			_label = element;
++			_icon = new CheckBoxIcon();
++            element.appendChild(_icon.element);
++            // Add a span to allow checkbox styling
++            _styleDiv = document.createElement('div') as WrappedHTMLElement;
++            if(_checkClassName)
++                _styleDiv.setAttribute("class",_checkClassName)
++            element.appendChild(_styleDiv);
++            _textNode = document.createTextNode('') as WrappedHTMLElement;
++            element.appendChild(_textNode);
++
++            positioner = element;
++            //positioner.style.position = 'relative';
++            element.flexjs_wrapper = this;
++			_icon.element.flexjs_wrapper = this;
++            _styleDiv.flexjs_wrapper = this;
++
++            className = 'CSSCheckBox';
++            typeNames = 'CSSCheckBox';
++
++            return element;
++        }
++
++        private var _checkClassName:String;
++        public function get checkClassName():String
++        {
++            return _checkClassName;
++        }
++        public function set checkClassName(value:String):void
++        {
++            _checkClassName = value;
++            if(_styleDiv)
++                _styleDiv.setAttribute("class",_checkClassName);
++        }
++
++        public function get text():String
++        {
++            return _textNode.nodeValue;
++        }
++
++        public function set text(value:String):void
++        {
++            _textNode.nodeValue = value;
++        }
++
++        public function get selected():Boolean
++        {
++            return (_icon.element as HTMLInputElement).checked;
++        }
++
++        public function set selected(value:Boolean):void
++        {
++           (_icon.element as HTMLInputElement).checked = value;
++        }
++    }
++
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as
index 5b8e0a5,632b539..ef78a05
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/CheckBox.as
@@@ -57,6 -57,6 +57,7 @@@ package org.apache.flex.htm
       *  The CheckBox class implements the common user interface
       *  control.  The CheckBox includes its text label.
       *
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
@@@ -168,7 -153,7 +155,7 @@@
              element.appendChild(document.createTextNode(''));
  
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
  			_icon.element.flexjs_wrapper = this;
  

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Container.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Container.as
index fe35dde,ee30b7f..cbcf526
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Container.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Container.as
@@@ -19,19 -19,17 +19,18 @@@
  package org.apache.flex.html
  {
  	import org.apache.flex.core.ContainerBase;
--	import org.apache.flex.core.IChrome;
--	import org.apache.flex.core.IContainer;
-     import org.apache.flex.core.ILayoutParent;
-     import org.apache.flex.core.ILayoutHost;
--	import org.apache.flex.core.IUIBase;
--    COMPILE::JS
--    {
--        import org.apache.flex.core.WrappedHTMLElement;            
--    }
++	import org.apache.flex.core.IMXMLDocument;
++	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.events.Event;
++	import org.apache.flex.utils.MXMLDataInterpreter;
  	
++	/**
++	 * The default property uses when additional MXML content appears within an element's
++	 * definition in an MXML file.
++	 */
  	[DefaultProperty("mxmlContent")]
--    
++
++	
      /**
       *  The Container class implements a basic container for
       *  other controls and containers.  The position and size
@@@ -60,6 -58,6 +59,7 @@@
       *  control and not a Container because the Alert does not
       *  support an arbitrary set of children.
       *  
++     *  @toplevel
       *  @see org.apache.flex.html.beads.layout
       *  @see org.apache.flex.html.supportClasses.ScrollingViewport
       *  @langversion 3.0
@@@ -67,7 -65,7 +67,7 @@@
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */    
- 	public class Container extends ContainerBase implements ILayoutParent
 -	public class Container extends ContainerBase
++	public class Container extends ContainerBase implements IMXMLDocument
  	{
          /**
           *  Constructor.
@@@ -81,35 -79,30 +81,79 @@@
  		{
  			super();
  		}
--
-         public function getLayoutHost():ILayoutHost
-         {
-             return view as ILayoutHost; 
-         }
-             
--        /**
--         * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
--         */
--        COMPILE::JS
--        override protected function createElement():WrappedHTMLElement
--        {
--            element = document.createElement('div') as WrappedHTMLElement;
--            
--            positioner = element;
--            
--            // absolute positioned children need a non-null
--            // position value in the parent.  It might
--            // get set to 'absolute' if the container is
--            // also absolutely positioned
--            positioner.style.position = 'relative';
--            element.flexjs_wrapper = this;
--            
--            /*addEventListener('childrenAdded',
--            runLayoutHandler);
--            addEventListener('elementRemoved',
--            runLayoutHandler);*/
--            
--            return element;
--        }        
++		
++		private var _mxmlDescriptor:Array;
++		private var _mxmlDocument:Object = this;
++		private var _initialized:Boolean;
++		
++		/**
++		 * @private
++		 */
++		override public function addedToParent():void
++		{
++			if (!_initialized)
++			{
++				// each MXML file can also have styles in fx:Style block
++				ValuesManager.valuesImpl.init(this);
++			}
++			
++			super.addedToParent();
++			
++			if (!_initialized)
++			{
++				MXMLDataInterpreter.generateMXMLInstances(_mxmlDocument, this, MXMLDescriptor);
++				
++				dispatchEvent(new Event("initBindings"));
++				dispatchEvent(new Event("initComplete"));
++				_initialized = true;
++				
++				//?? why is this here? childrenAdded(); //?? Is this needed since MXMLDataInterpreter will have already called it
++			}
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.Application#MXMLDescriptor
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get MXMLDescriptor():Array
++		{
++			return _mxmlDescriptor;
++		}
++		
++		/**
++		 *  @private
++		 */
++		public function setMXMLDescriptor(document:Object, value:Array):void
++		{
++			_mxmlDocument = document;
++			_mxmlDescriptor = value;
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.Application#generateMXMLAttributes()
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function generateMXMLAttributes(data:Array):void
++		{
++			MXMLDataInterpreter.generateMXMLProperties(this, data);
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.ItemRendererClassFactory#mxmlContent
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public var mxmlContent:Array;
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ControlBar.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ControlBar.as
index da65539,da65539..588bd8c
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ControlBar.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ControlBar.as
@@@ -18,36 -18,36 +18,36 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html
  {
--	
++
  	import org.apache.flex.core.IBeadLayout;
  	import org.apache.flex.core.IChrome;
--	import org.apache.flex.core.IContainer;
  	import org.apache.flex.core.ValuesManager;
      COMPILE::JS
      {
--        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
      }
  
  	/**
  	 *  The ControlBar class is used within a Panel as a place to position
--	 *  additional controls. The ControlBar appears at the bottom of the 
++	 *  additional controls. The ControlBar appears at the bottom of the
  	 *  org.apache.flex.html.Panel
  	 *  and is not part of the Panel's scrollable content area. The ControlBar
  	 *  is a Container and implements the org.apache.flex.core.IChrome interface, indicating that is
  	 *  outside of the Container's content area. The ControlBar uses the following
  	 *  beads:
--	 * 
++	 *
  	 *  org.apache.flex.core.IBeadModel: the data model for the component.
  	 *  org.apache.flex.core.IMeasurementBead: helps determine the overlay size of the ControlBar for layout.
  	 *  org.apache.flex.core.IBorderBead: if present, displays a border around the component.
  	 *  org.apache.flex.core.IBackgroundBead: if present, displays a solid background below the ControlBar.
--	 *  
++	 *
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class ControlBar extends Container implements IContainer, IChrome
++	public class ControlBar extends Group implements IChrome
  	{
  		/**
  		 *  constructor.
@@@ -60,40 -60,40 +60,36 @@@
  		public function ControlBar()
  		{
  			super();
--			
++
  			className = "ControlBar";
  		}
--		
++
  		/**
  		 * @private
  		 */
  		override public function addedToParent():void
  		{
--			super.addedToParent();	
++			super.addedToParent();
  			
  			if( getBeadByType(IBeadLayout) == null ) {
  				var layout:IBeadLayout = new (ValuesManager.valuesImpl.getValue(this, "iBeadLayout")) as IBeadLayout;
  				addBead(layout);
  			}
  		}
--        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
          COMPILE::JS
          override protected function createElement():WrappedHTMLElement
          {
--            element = document.createElement('div') as WrappedHTMLElement;
--            element.className = 'ControlBar';
--            element.style.display = 'inline';
--            typeNames = 'ControlBar';
--            
--            positioner = element;
--            positioner.style.position = 'relative';
--            element.flexjs_wrapper = this;
--            
++			element = document.createElement('div') as WrappedHTMLElement;
++			
++			positioner = element;
++			element.flexjs_wrapper = this;
++
              return element;
--        }        
++        }
  
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataContainer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataContainer.as
index 5d33d55,0000000..231ba42
mode 100644,000000..100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataContainer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataContainer.as
@@@ -1,255 -1,0 +1,145 @@@
 +////////////////////////////////////////////////////////////////////////////////
 +//
 +//  Licensed to the Apache Software Foundation (ASF) under one or more
 +//  contributor license agreements.  See the NOTICE file distributed with
 +//  this work for additional information regarding copyright ownership.
 +//  The ASF licenses this file to You under the Apache License, Version 2.0
 +//  (the "License"); you may not use this file except in compliance with
 +//  the License.  You may obtain a copy of the License at
 +//
 +//      http://www.apache.org/licenses/LICENSE-2.0
 +//
 +//  Unless required by applicable law or agreed to in writing, software
 +//  distributed under the License is distributed on an "AS IS" BASIS,
 +//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 +//  See the License for the specific language governing permissions and
 +//  limitations under the License.
 +//
 +////////////////////////////////////////////////////////////////////////////////
 +package org.apache.flex.html
 +{
++	import org.apache.flex.core.DataContainerBase;
++	
 +	import org.apache.flex.core.ContainerBaseStrandChildren;
 +	import org.apache.flex.core.IContentViewHost;
++	import org.apache.flex.core.IChild;
 +	import org.apache.flex.core.IDataProviderItemRendererMapper;
 +	import org.apache.flex.core.IFactory;
 +	import org.apache.flex.core.IItemRendererClassFactory;
- 	import org.apache.flex.core.IItemRendererProvider;
++	import org.apache.flex.core.IItemRenderer;
++	import org.apache.flex.core.IItemRendererParent;
++	import org.apache.flex.core.ILayoutView;
++	import org.apache.flex.core.IList;
 +	import org.apache.flex.core.IListPresentationModel;
 +	import org.apache.flex.core.IRollOverModel;
 +	import org.apache.flex.core.IDataProviderModel;
 +	import org.apache.flex.core.ListBase;
 +	import org.apache.flex.core.UIBase;
 +	import org.apache.flex.core.ValuesManager;
 +    COMPILE::JS
 +    {
 +        import org.apache.flex.core.WrappedHTMLElement;
 +        import org.apache.flex.html.beads.ListView;
 +        import org.apache.flex.html.supportClasses.DataGroup;
 +    }
 +	import org.apache.flex.events.Event;
 +	import org.apache.flex.events.IEventDispatcher;
 +	import org.apache.flex.html.beads.models.ListPresentationModel;
- 	
++	import org.apache.flex.html.beads.IListView;
++
 +	/**
 +	 *  Indicates that the initialization of the list is complete.
- 	 *  
++	 *
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
 +	 *  @productversion FlexJS 0.0
 +	 */
 +	[Event(name="initComplete", type="org.apache.flex.events.Event")]
- 	
++
 +	/**
- 	 *  The List class is a component that displays multiple data items. The List uses
++	 *  The DataContainer class is a component that displays multiple data items. The DataContainer uses
 +	 *  the following bead types:
- 	 * 
++	 *
 +	 *  org.apache.flex.core.IBeadModel: the data model, which includes the dataProvider.
 +	 *  org.apache.flex.core.IBeadView:  the bead that constructs the visual parts of the list.
 +	 *  org.apache.flex.core.IBeadController: the bead that handles input and output.
 +	 *  org.apache.flex.core.IBeadLayout: the bead responsible for the size and position of the itemRenderers.
 +	 *  org.apache.flex.core.IDataProviderItemRendererMapper: the bead responsible for creating the itemRenders.
 +	 *  org.apache.flex.core.IItemRenderer: the class or factory used to display an item in the list.
- 	 *  
++	 *
 +	 *  @langversion 3.0
 +	 *  @playerversion Flash 10.2
 +	 *  @playerversion AIR 2.6
 +	 *  @productversion FlexJS 0.0
 +	 */
- 	public class DataContainer extends ListBase implements IItemRendererProvider
++	public class DataContainer extends DataContainerBase
 +	{
 +		/**
 +		 *  constructor.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function DataContainer()
 +		{
 +			super();
- 			addEventListener("beadsAdded", beadsAddedHandler);
 +		}
- 		
++
 +		/**
 +		 *  The name of field within the data used for display. Each item of the
 +		 *  data should have a property with this name.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function get labelField():String
 +		{
 +			return IDataProviderModel(model).labelField;
 +		}
 +		public function set labelField(value:String):void
 +		{
 +            IDataProviderModel(model).labelField = value;
 +		}
- 		
++
 +		/**
 +		 *  The data being display by the List.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +        public function get dataProvider():Object
 +        {
 +            return IDataProviderModel(model).dataProvider;
 +        }
 +        public function set dataProvider(value:Object):void
 +        {
 +            IDataProviderModel(model).dataProvider = value;
 +        }
 +
- 			
++
 +		/**
 +		 *  The presentation model for the list.
 +		 *
 +		 *  @langversion 3.0
 +		 *  @playerversion Flash 10.2
 +		 *  @playerversion AIR 2.6
 +		 *  @productversion FlexJS 0.0
 +		 */
 +		public function get presentationModel():IListPresentationModel
 +		{
 +			var presModel:IListPresentationModel = getBeadByType(IListPresentationModel) as IListPresentationModel;
 +			if (presModel == null) {
 +				presModel = new ListPresentationModel();
 +				addBead(presModel);
 +			}
 +			return presModel;
 +		}
- 		
- 		/**
- 		 *  The default height of each cell in every column
- 		 *
- 		 *  @langversion 3.0
- 		 *  @playerversion Flash 10.2
- 		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.0
- 		 */
- 		public function get rowHeight():Number
- 		{
- 			return presentationModel.rowHeight;
- 		}
- 		public function set rowHeight(value:Number):void
- 		{
- 			presentationModel.rowHeight = value;
- 		}
- 				
- 		private var _itemRenderer:IFactory;
- 		
- 		/**
- 		 *  The class or factory used to display each item.
- 		 *
- 		 *  @langversion 3.0
- 		 *  @playerversion Flash 10.2
- 		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.0
- 		 */
- 		public function get itemRenderer():IFactory
- 		{
- 			return _itemRenderer;
- 		}
- 		public function set itemRenderer(value:IFactory):void
- 		{
- 			_itemRenderer = value;
- 		}
- 		
- 		/**
- 		 * Returns whether or not the itemRenderer property has been set.
- 		 *
- 		 *  @see org.apache.flex.core.IItemRendererProvider
- 		 *
- 		 *  @langversion 3.0
- 		 *  @playerversion Flash 10.2
- 		 *  @playerversion AIR 2.6
- 		 *  @productversion FlexJS 0.0
- 		 */
- 		public function get hasItemRenderer():Boolean
- 		{
- 			var result:Boolean = false;
- 			
- 			COMPILE::SWF {
- 				result = _itemRenderer != null;
- 			}
- 			
- 			COMPILE::JS {
- 				var test:* = _itemRenderer;
- 				result = _itemRenderer !== null && test !== undefined;
- 			}
- 			
- 			return result;
- 		}
- 		
- 		
- 		/**
- 		 * @private
- 		 */
- 		override public function addedToParent():void
- 		{
-             super.addedToParent();
-             		
- 			dispatchEvent(new Event("initComplete"));
- 		}
-         
- 		/**
- 		 * @private
- 		 */
- 	    private function beadsAddedHandler(e:Event):void
- 		{
-             if (getBeadByType(IDataProviderItemRendererMapper) == null)
-             {
-                 var mapper:IDataProviderItemRendererMapper = new (ValuesManager.valuesImpl.getValue(this, "iDataProviderItemRendererMapper")) as IDataProviderItemRendererMapper;
-                 addBead(mapper);
-             }
- 			var itemRendererFactory:IItemRendererClassFactory = getBeadByType(IItemRendererClassFactory) as IItemRendererClassFactory;
- 			if (!itemRendererFactory)
- 			{
- 				itemRendererFactory = new (ValuesManager.valuesImpl.getValue(this, "iItemRendererClassFactory")) as IItemRendererClassFactory;
- 				addBead(itemRendererFactory);
- 			}
- 		}
- 		
-         /**
-          * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
-          */
-         COMPILE::JS
-         override protected function createElement():WrappedHTMLElement
-         {
-             super.createElement();
-             className = 'List';
-             
-             return element;
-         }        
- 
-         /**
-          * @flexjsignorecoercion org.apache.flex.html.beads.ListView 
-          * @flexjsignorecoercion org.apache.flex.html.supportClasses.DataGroup 
-          */
-         COMPILE::JS
-         override public function internalChildren():Array
-         {
-             var listView:ListView = getBeadByType(ListView) as ListView;
-             var dg:DataGroup = listView.dataGroup as DataGroup;
-             var renderers:Array = dg.internalChildren();
-             return renderers;
-         };
 +   	}
 +}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataGrid.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataGrid.as
index fcb4029,c271134..fda1b46
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataGrid.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DataGrid.as
@@@ -22,7 -22,6 +22,7 @@@ package org.apache.flex.htm
  	import org.apache.flex.core.IDataGridModel;
  	import org.apache.flex.core.IDataGridPresentationModel;
  	import org.apache.flex.core.UIBase;
-     import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.core.ValuesManager;
  	import org.apache.flex.html.beads.models.DataGridPresentationModel;
  	
  	[Event(name="change", type="org.apache.flex.events.Event")]
@@@ -35,12 -34,12 +35,13 @@@
  	 *  view bead (usually org.apache.flex.html.beads.DataGridView) constructs these parts while 
  	 *  itemRenderer factories contruct the elements to display the data in each cell.
  	 *  
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class DataGrid extends UIBase
++	public class DataGrid extends Group
  	{
  		/**
  		 *  constructor.
@@@ -104,18 -103,8 +105,17 @@@
  		{
  			return IDataGridModel(model).selectedIndex;
  		}
-         public function set selectedIndex(value:int):void
-         {
-             IDataGridModel(model).selectedIndex = value;
-         }
- 
++		public function set selectedIndex(value:int):void
++		{
++			IDataGridModel(model).selectedIndex = value;
++		}
++		
++		/**
++		 * @private
++		 */
++		private var _presentationModel:IDataGridPresentationModel;
  		
  		/**
-          * @private
-          */
-         private var _presentationModel:IDataGridPresentationModel;
-                
-         /**
  		 *  The DataGrid's presentation model
  		 *
  		 *  @langversion 3.0
@@@ -125,22 -114,16 +125,22 @@@
  		 */
  		public function get presentationModel():IDataGridPresentationModel
  		{
-             if (_presentationModel == null) {
-                 var c:Class = ValuesManager.valuesImpl.getValue(this, "iDataGridPresentationModel");
-                 if (c) {
-                     var presModel:Object = new c();
-                     _presentationModel = presModel as IDataGridPresentationModel;
-                     if (_presentationModel != null) {
-                         addBead(_presentationModel as IBead);
-                     }
-                 }
-             }
-             return _presentationModel;
-         }
-         
-         public function set presentationModel(value:IDataGridPresentationModel):void
-         {
-             _presentationModel = value;
 -			var beadMod:IBead = getBeadByType(IDataGridPresentationModel);
 -			var presModel:IDataGridPresentationModel;
 -			
 -			if (beadMod == null) {
 -				presModel = new DataGridPresentationModel();
 -				addBead(presModel);
 -			} else {
 -				presModel = beadMod as IDataGridPresentationModel;
++			if (_presentationModel == null) {
++				var c:Class = ValuesManager.valuesImpl.getValue(this, "iDataGridPresentationModel");
++				if (c) {
++					var presModel:Object = new c();
++					_presentationModel = presModel as IDataGridPresentationModel;
++					if (_presentationModel != null) {
++						addBead(_presentationModel as IBead);
++					}
++				}
+ 			}
 -			return presModel;
++			
++			return _presentationModel;
++		}
++		public function set presentationModel(value:IDataGridPresentationModel):void
++		{
++			_presentationModel = value;
  		}
  				
  		/**

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateChooser.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateChooser.as
index 4f0bdfe,62b5a3e..971ed75
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateChooser.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DateChooser.as
@@@ -19,7 -19,7 +19,7 @@@
  package org.apache.flex.html
  {
  	import org.apache.flex.core.IDateChooserModel;
--	import org.apache.flex.core.UIBase;
++	import org.apache.flex.html.Group;
  
  	/**
  	 * The change event is dispatched when the selectedDate is changed.
@@@ -29,12 -29,12 +29,13 @@@
  	/**
  	 *  The DateChooser class is a component that displays a calendar.
  	 *
++     *  @toplevel
  	 *  @langversion 3.0
  	 *  @playerversion Flash 10.2
  	 *  @playerversion AIR 2.6
  	 *  @productversion FlexJS 0.0
  	 */
--	public class DateChooser extends UIBase
++	public class DateChooser extends Group
  	{
  		/**
  		 *  constructor.
@@@ -47,14 -47,11 +48,9 @@@
  		public function DateChooser()
  		{
  			super();
 -			className = "DateChooser";
--
--			// fix the DateChooser's size
--			width = 280;
--			height = 240;
-             
-             // default to today
-             selectedDate = new Date();
- 
++			
++			// default to today
++			selectedDate = new Date();
  		}
  
  		/**

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DropDownList.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DropDownList.as
index dd069b2,dd069b2..d547f27
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DropDownList.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/DropDownList.as
@@@ -23,24 -23,24 +23,25 @@@ package org.apache.flex.htm
      COMPILE::JS
      {
          import goog.events;
--        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
          import org.apache.flex.html.beads.models.ArraySelectionModel;
      }
--    
++
      //--------------------------------------
      //  Events
      //--------------------------------------
--    
++
      /**
       *  Dispatched when the user selects an item.
--     *  
++     *
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
      [Event(name="change", type="org.apache.flex.events.Event")]
--    
++
      /**
       *  The DropDownList class implements the basic equivalent of
       *  the <code>&lt;select&gt;</code> tag in HTML.
@@@ -48,23 -48,23 +49,23 @@@
       *  choose from an array of strings.  More complex controls
       *  would display icons as well as strings, or colors instead
       *  of strings or just about anything.
--     * 
--     *  The default behavior only lets the user choose one and 
++     *
++     *  The default behavior only lets the user choose one and
       *  only one item.  More complex controls would allow
       *  mutiple selection by not dismissing the dropdown as soon
       *  as a selection is made.
--     * 
--     *  
++     *
++     *
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
--     */    
++     */
  	public class DropDownList extends Button
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -77,12 -77,12 +78,12 @@@
                  model = new ArraySelectionModel();
              }
  		}
--		
++
          /**
           *  The data set to be displayed.  Usually a simple
           *  array of strings.  A more complex component
           *  would allow more complex data and data sets.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -108,14 -108,14 +109,14 @@@
                  var n:int;
                  var opt:HTMLOptionElement;
                  var dd:HTMLSelectElement = element as HTMLSelectElement;
--                
++
                  model.dataProvider = value;
                  dp = dd.options;
                  n = dp.length;
                  for (i = 0; i < n; i++) {
                      dd.remove(0);
                  }
--                
++
                  var lf:String = labelField;
                  n = value.length;
                  for (i = 0; i < n; i++) {
@@@ -129,11 -129,11 +130,11 @@@
  
              }
          }
--        
++
          [Bindable("change")]
          /**
           *  @copy org.apache.flex.core.ISelectionModel#selectedIndex
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -156,12 -156,12 +157,12 @@@
                  (element as HTMLSelectElement).selectedIndex = ISelectionModel(model).selectedIndex;
              }
          }
--        
++
  
          [Bindable("change")]
          /**
           *  @copy org.apache.flex.core.ISelectionModel#selectedItem
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -184,7 -184,7 +185,7 @@@
                  (element as HTMLSelectElement).selectedIndex = ISelectionModel(model).selectedIndex;
              }
          }
--                        
++
          /**
           *  The name of field within the data used for display. Each item of the
           *  data should have a property with this name.
@@@ -202,7 -202,7 +203,7 @@@
          {
              ISelectionModel(model).labelField = value;
          }
--        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           * @flexjsignorecoercion HTMLSelectElement
@@@ -214,15 -214,15 +215,15 @@@
              (element as HTMLSelectElement).size = 1;
              goog.events.listen(element, 'change',
                  changeHandler);
--            
++
              positioner = element;
--            positioner.style.position = 'relative';
--            
++            //positioner.style.position = 'relative';
++
              element.flexjs_wrapper = this;
--            
++
              return element;
--        } 
--        
++        }
++
          /**
           * @flexjsignorecoercion HTMLSelectElement
           */

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as
index d7b0459,d7b0459..96fe42a
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Form.as
@@@ -18,28 -18,28 +18,29 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html
  {
--    import org.apache.flex.core.ContainerBase;
--    
++    import org.apache.flex.html.Container;
++
      COMPILE::JS
      {
          import org.apache.flex.core.WrappedHTMLElement;
      }
--    
++
      [DefaultProperty("mxmlContent")]
  
      /**
       *  The Form class is a simple form.
--     *  
++     *
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */
--    public class Form extends ContainerBase
++    public class Form extends Container
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -49,23 -49,23 +50,23 @@@
          {
              super();
          }
--        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
          COMPILE::JS
          override protected function createElement():WrappedHTMLElement
--        {HTMLFormElement
++        {
              element = document.createElement('form') as WrappedHTMLElement;
--             
++
              positioner = element;
--             
--            positioner.style.position = 'relative';
++
++            //positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
              return element;
          }
  
--        
++
          private var _action:String = "#";
  
          [Bindable("actionChange")]
@@@ -95,5 -95,5 +96,5 @@@
                  this.dispatchEvent('actionChange');
              }
          }
--    }        
--}
++    }
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Group.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Group.as
index 0000000,0000000..2b3ddb9
new file mode 100644
--- /dev/null
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Group.as
@@@ -1,0 -1,0 +1,145 @@@
++////////////////////////////////////////////////////////////////////////////////
++//
++//  Licensed to the Apache Software Foundation (ASF) under one or more
++//  contributor license agreements.  See the NOTICE file distributed with
++//  this work for additional information regarding copyright ownership.
++//  The ASF licenses this file to You under the Apache License, Version 2.0
++//  (the "License"); you may not use this file except in compliance with
++//  the License.  You may obtain a copy of the License at
++//
++//      http://www.apache.org/licenses/LICENSE-2.0
++//
++//  Unless required by applicable law or agreed to in writing, software
++//  distributed under the License is distributed on an "AS IS" BASIS,
++//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
++//  See the License for the specific language governing permissions and
++//  limitations under the License.
++//
++////////////////////////////////////////////////////////////////////////////////
++package org.apache.flex.html
++{
++	import org.apache.flex.core.IMXMLDocument;
++	import org.apache.flex.core.GroupBase;
++	import org.apache.flex.core.ValuesManager;
++	import org.apache.flex.events.Event;
++	import org.apache.flex.utils.MXMLDataInterpreter;
++
++	/**
++	 *  Indicates that the children of the container is have been added.
++	 *
++	 *  @langversion 3.0
++	 *  @playerversion Flash 10.2
++	 *  @playerversion AIR 2.6
++	 *  @productversion FlexJS 0.8
++	 */
++	[Event(name="childrenAdded", type="org.apache.flex.events.Event")]
++	
++	/**
++	 * The default property uses when additional MXML content appears within an element's
++	 * definition in an MXML file.
++	 */
++	[DefaultProperty("mxmlContent")]
++
++    /**
++     *  The Group class provides a light-weight container for visual elements. By default
++	 *  the Group does not have a layout, allowing its children to be sized and positioned
++	 *  using styles or CSS.
++     *
++     *  @toplevel
++     *  @see org.apache.flex.html.beads.layout
++     *  @see org.apache.flex.html.supportClasses.ScrollingViewport
++     *  @langversion 3.0
++     *  @playerversion Flash 10.2
++     *  @playerversion AIR 2.6
++     *  @productversion FlexJS 0.8
++     */
++	public class Group extends GroupBase implements IMXMLDocument
++	{
++        /**
++         *  Constructor.
++         *
++         *  @langversion 3.0
++         *  @playerversion Flash 10.2
++         *  @playerversion AIR 2.6
++         *  @productversion FlexJS 0.8
++         */
++		public function Group()
++		{
++			super();
++		}
++		
++		private var _mxmlDescriptor:Array;
++		private var _mxmlDocument:Object = this;
++		private var _initialized:Boolean;
++		
++		/**
++		 * @private
++		 */
++		override public function addedToParent():void
++		{
++			if (!_initialized)
++			{
++				// each MXML file can also have styles in fx:Style block
++				ValuesManager.valuesImpl.init(this);
++			}
++			
++			super.addedToParent();
++			
++			if (!_initialized)
++			{
++				MXMLDataInterpreter.generateMXMLInstances(_mxmlDocument, this, MXMLDescriptor);
++				
++				dispatchEvent(new Event("initBindings"));
++				dispatchEvent(new Event("initComplete"));
++				_initialized = true;
++				
++				//?? why was this added here? childrenAdded(); //?? Is this needed since MXMLDataInterpreter will already have called it
++			}
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.Application#MXMLDescriptor
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function get MXMLDescriptor():Array
++		{
++			return _mxmlDescriptor;
++		}
++		
++		/**
++		 *  @private
++		 */
++		public function setMXMLDescriptor(document:Object, value:Array):void
++		{
++			_mxmlDocument = document;
++			_mxmlDescriptor = value;
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.Application#generateMXMLAttributes()
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public function generateMXMLAttributes(data:Array):void
++		{
++			MXMLDataInterpreter.generateMXMLProperties(this, data);
++		}
++		
++		/**
++		 *  @copy org.apache.flex.core.ItemRendererClassFactory#mxmlContent
++		 *  
++		 *  @langversion 3.0
++		 *  @playerversion Flash 10.2
++		 *  @playerversion AIR 2.6
++		 *  @productversion FlexJS 0.8
++		 */
++		public var mxmlContent:Array;
++	}
++}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HContainer.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HContainer.as
index 9f38883,9f38883..2a19648
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HContainer.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HContainer.as
@@@ -38,12 -38,12 +38,13 @@@ package org.apache.flex.htm
       *  </basic:Container>
       *  </code>
       *  
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
       */    
--	public class HContainer extends Container implements IContainer
++	public class HContainer extends Container
  	{
          /**
           *  Constructor.

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HRule.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HRule.as
index 7c2fb2f,7c2fb2f..3017a34
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HRule.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/HRule.as
@@@ -17,26 -17,26 +17,27 @@@
  //
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html
--{	
++{
  	import org.apache.flex.core.UIBase;
      COMPILE::JS
      {
--        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
      }
--	
++
      /**
       *  The HRule class displays a horizontal line
       *
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
--     */    
++     */
  	public class HRule extends UIBase
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -46,7 -46,7 +47,7 @@@
  		{
  			super();
          }
--        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
@@@ -55,9 -55,9 +56,9 @@@
          {
              element = document.createElement('hr') as WrappedHTMLElement;
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
              return element;
--        }        
++        }
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Image.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Image.as
index dc53a51,9268f9d..6b206c1
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Image.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/Image.as
@@@ -18,27 -18,28 +18,23 @@@
  ////////////////////////////////////////////////////////////////////////////////
  package org.apache.flex.html
  {
-     import org.apache.flex.core.ImageBase;
 -	import org.apache.flex.core.IImageModel;
 -	import org.apache.flex.core.UIBase;
++	import org.apache.flex.core.ImageBase;
++
      COMPILE::JS
      {
--        import org.apache.flex.core.WrappedHTMLElement;            
--        import org.apache.flex.html.beads.models.ImageModel;
--        import org.apache.flex.html.beads.ImageView;
++        import org.apache.flex.core.WrappedHTMLElement;
      }
--	
--	/**
--	 *  The Image class is a component that displays a bitmap. The Image uses
--	 *  the following beads:
--	 * 
--	 *  org.apache.flex.core.IBeadModel: the data model for the Image, including the source property.
--	 *  org.apache.flex.core.IBeadView: constructs the visual elements of the component.
--	 *  
--	 *  @langversion 3.0
--	 *  @playerversion Flash 10.2
--	 *  @playerversion AIR 2.6
--	 *  @productversion FlexJS 0.0
--	 */
 -	public class Image extends UIBase
++
++	  /**
++	   *  Load Images.
++	   *
++	   *  @toplevel
++	   *  @langversion 3.0
++	   *  @playerversion Flash 10.2
++	   *  @playerversion AIR 2.6
++	   *  @productversion FlexJS 0.0
++	   */
 +	public class Image extends ImageBase
  	{
  		/**
  		 *  constructor.
@@@ -52,7 -53,25 +48,7 @@@
  		{
  			super();
  		}
--		
 -		/**
 -		 *  The location of the bitmap, usually a URL.
 -		 *
 -		 *  @langversion 3.0
 -		 *  @playerversion Flash 10.2
 -		 *  @playerversion AIR 2.6
 -		 *  @productversion FlexJS 0.0
 -         *  @flexjsignorecoercion org.apache.flex.core.IImageModel
 -		 */
 -		public function get src():String
 -		{
 -			return (model as IImageModel).url;
 -		}
 -		public function set src(value:String):void
 -		{
 -			(model as IImageModel).url = value;
 -		}
 -        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
@@@ -62,26 -81,13 +58,25 @@@
              element = document.createElement('img') as WrappedHTMLElement;
              element.className = 'Image';
              typeNames = 'Image';
--            
++
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
--         
-             return element;
-         }
-         
-         COMPILE::JS
-         override public function get imageElement():Element
-         {
++
              return element;
 -        }        
 +        }
-         
-         COMPILE::JS
-         override public function applyImageData(binaryDataAsString:String):void
-         {
-             (element as HTMLImageElement).src = binaryDataAsString;
-         }
 +
++		COMPILE::JS
++		override public function get imageElement():Element
++		{
++			return element;
++		}
++
++		COMPILE::JS
++		override public function applyImageData(binaryDataAsString:String):void
++		{
++			(element as HTMLImageElement).src = binaryDataAsString;
++		}
  
  	}
  }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9fd9b78b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ImageAndTextButton.as
----------------------------------------------------------------------
diff --cc frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ImageAndTextButton.as
index 8bdcc6a,8bdcc6a..ccdbc3b
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ImageAndTextButton.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/ImageAndTextButton.as
@@@ -22,23 -22,23 +22,24 @@@ package org.apache.flex.htm
      import org.apache.flex.html.beads.models.ImageAndTextModel;
      COMPILE::JS
      {
--        import org.apache.flex.core.WrappedHTMLElement;            
++        import org.apache.flex.core.WrappedHTMLElement;
      }
--	
++
      /**
       *  The ImageTextButton class implements a basic button that
       *  displays and image and text.
--     *  
++     *
++     *  @toplevel
       *  @langversion 3.0
       *  @playerversion Flash 10.2
       *  @playerversion AIR 2.6
       *  @productversion FlexJS 0.0
--     */    
++     */
  	public class ImageAndTextButton extends TextButton
  	{
          /**
           *  Constructor.
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -48,7 -48,7 +49,7 @@@
  		{
  			super();
  		}
--		
++
          /**
           *  @private
           */
@@@ -57,7 -57,7 +58,7 @@@
          {
              return ImageAndTextModel(model).text;
          }
--        
++
          /**
           *  @private
           */
@@@ -67,13 -67,13 +68,13 @@@
              ImageAndTextModel(model).text = value;
              COMPILE::JS
              {
--                setInnerHTML();                    
++                setInnerHTML();
              }
          }
--        
++
          /**
           *  The URL of an icon to use in the button
--         *  
++         *
           *  @langversion 3.0
           *  @playerversion Flash 10.2
           *  @playerversion AIR 2.6
@@@ -83,7 -83,7 +84,7 @@@
          {
              return ImageAndTextModel(model).image;
          }
--        
++
          /**
           *  @private
           */
@@@ -92,10 -92,10 +93,10 @@@
              ImageAndTextModel(model).image = value;
              COMPILE::JS
              {
--                setInnerHTML();                    
++                setInnerHTML();
              }
          }
--        
++
          /**
           * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
           */
@@@ -104,13 -104,13 +105,13 @@@
          {
              element = document.createElement('button') as WrappedHTMLElement;
              element.setAttribute('type', 'button');
--            
++
              positioner = element;
--            positioner.style.position = 'relative';
++            //positioner.style.position = 'relative';
              element.flexjs_wrapper = this;
--            
++
              return element;
--        }        
++        }
  
          /**
           */


[32/50] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - - Fixed the assembly descriptor to correctly package the html module

Posted by ah...@apache.org.
- Fixed the assembly descriptor to correctly package the html module


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/7ffe9dd2
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/7ffe9dd2
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/7ffe9dd2

Branch: refs/heads/develop
Commit: 7ffe9dd23e2d8e57e4e357cab0d358adb04b2937
Parents: 5d6519a
Author: Christofer Dutz <ch...@codecentric.de>
Authored: Tue Apr 25 22:31:52 2017 +0200
Committer: Christofer Dutz <ch...@codecentric.de>
Committed: Tue Apr 25 22:31:52 2017 +0200

----------------------------------------------------------------------
 distribution/src/main/assembly/component.xml | 5 -----
 1 file changed, 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/7ffe9dd2/distribution/src/main/assembly/component.xml
----------------------------------------------------------------------
diff --git a/distribution/src/main/assembly/component.xml b/distribution/src/main/assembly/component.xml
index a27dc15..8a81182 100644
--- a/distribution/src/main/assembly/component.xml
+++ b/distribution/src/main/assembly/component.xml
@@ -264,11 +264,6 @@ under the License.
       <destName>svg-manifest-graphics.xml</destName>
     </file>
     <file>
-      <source>../frameworks/projects/HTML/src/main/resources/basic-as-manifest.xml</source>
-      <outputDirectory>frameworks/manifests</outputDirectory>
-      <destName>basic-as-manifest-html.xml</destName>
-    </file>
-    <file>
       <source>../frameworks/projects/HTML/src/main/resources/basic-manifest.xml</source>
       <outputDirectory>frameworks/manifests</outputDirectory>
       <destName>basic-manifest-html.xml</destName>