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 2016/09/21 22:23:18 UTC

[1/7] git commit: [flex-asjs] [refs/heads/spark] - add reminder to update JIRA

Repository: flex-asjs
Updated Branches:
  refs/heads/spark 2a0ed13a8 -> 24dc2663c


add reminder to update JIRA


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

Branch: refs/heads/spark
Commit: 773987e1e3987eff2081493bd680da05be8cbd9e
Parents: c9b2a02
Author: Alex Harui <ah...@apache.org>
Authored: Tue Sep 13 08:03:06 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Sep 14 14:19:59 2016 -0700

----------------------------------------------------------------------
 build.xml | 1 +
 1 file changed, 1 insertion(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/773987e1/build.xml
----------------------------------------------------------------------
diff --git a/build.xml b/build.xml
index 997fb8d..f5ab8c5 100644
--- a/build.xml
+++ b/build.xml
@@ -972,6 +972,7 @@
             value="&lt;versionNumber&gt;${new-version}&lt;/versionNumber&gt;" >
             <include name="**/*-app.xml"/>
         </replace>
+        <echo>Don't forget to update JIRA to indicate current version is released and add new version</echo>
     </target>
     
 	<!--


[3/7] git commit: [flex-asjs] [refs/heads/spark] - Merge branch 'develop' into spark

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


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

Branch: refs/heads/spark
Commit: 5f15c1bae3be00dc8826fca579673052449a12b7
Parents: 2a0ed13 8226d2f
Author: Alex Harui <ah...@apache.org>
Authored: Wed Sep 14 22:42:35 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Sep 14 22:42:35 2016 -0700

----------------------------------------------------------------------
 build.xml                                          |  1 +
 .../org/apache/flex/core/SimpleCSSValuesImpl.as    | 17 ++++++++---------
 2 files changed, 9 insertions(+), 9 deletions(-)
----------------------------------------------------------------------



[6/7] git commit: [flex-asjs] [refs/heads/spark] - changes to get hello world to launch without errors although no text appears

Posted by ah...@apache.org.
changes to get hello world to launch without errors although no text appears


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

Branch: refs/heads/spark
Commit: a936d77ac9d26136166f813723ab4348e7feea12
Parents: f1ff5f1
Author: Alex Harui <ah...@apache.org>
Authored: Fri Sep 16 11:21:41 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Sep 16 11:21:41 2016 -0700

----------------------------------------------------------------------
 .../MX/src/main/flex/flex/display/Sprite.as     | 24 ++++++++++++--------
 .../MX/src/main/flex/mx/core/Application.as     |  2 +-
 .../src/main/flex/mx/managers/SystemManager.as  |  3 +++
 .../src/main/flex/mx/styles/StyleProtoChain.as  | 23 ++++++++++++++++---
 .../MX/src/main/flex/mx/utils/OrderedObject.as  |  2 +-
 5 files changed, 40 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a936d77a/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as b/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as
index 7ba75dc..64815a3 100644
--- a/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as
+++ b/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as
@@ -56,7 +56,7 @@ package flex.display
 		COMPILE::JS
 		public function getChildAt(index:int):DisplayObject
 		{
-			return getElementAt(index) as DisplayObject;
+			return super.getElementAt(index) as DisplayObject;
 		}
 		
 		COMPILE::JS
@@ -73,42 +73,48 @@ package flex.display
 		COMPILE::JS
 		public function getChildIndex(child:DisplayObject):int
 		{
-			return getElementIndex(child);
+			return super.getElementIndex(child);
 		}
 		
 		COMPILE::JS
 		public function setChildIndex(child:DisplayObject, index:int):void
 		{
-			removeElement(child);
-			addElementAt(child, index);
+			super.removeElement(child);
+			super.addElementAt(child, index);
 		}
 		
 		COMPILE::JS
 		public function addChild(child:DisplayObject):DisplayObject
 		{
-			addElement(child);
+			super.addElement(child);
 			return child;
 		}
 		
 		COMPILE::JS
 		public function addChildAt(child:DisplayObject, index:int):DisplayObject
 		{
-			addElementAt(child, index);
+            if (index >= super.numElements)
+            {
+                super.addElement(child);
+                return child;
+            }
+                
+			super.addElementAt(child, index);
 			return child;
 		}
 		
 		COMPILE::JS
 		public function removeChild(child:DisplayObject):DisplayObject
 		{
-			removeElement(child);
+			super.removeElement(child);
 			return child;
 		}
 		
 		COMPILE::JS
 		public function removeChildAt(index:int):DisplayObject
 		{
-			var child:DisplayObject = getChildAt(index);
-			removeElement(child);
+			var child:DisplayObject = super.getChildAt(index);
+			super.removeElement(child);
 			return child;
 		}
 		

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a936d77a/frameworks/projects/MX/src/main/flex/mx/core/Application.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/core/Application.as b/frameworks/projects/MX/src/main/flex/mx/core/Application.as
index 9142894..04fd0a6 100644
--- a/frameworks/projects/MX/src/main/flex/mx/core/Application.as
+++ b/frameworks/projects/MX/src/main/flex/mx/core/Application.as
@@ -1490,7 +1490,7 @@ public class Application extends LayoutContainer
         {
             focusManager = new FocusManager(this);
             var awm:IActiveWindowManager = 
-                IActiveWindowManager(sm.getImplementation("mx.managers::IActiveWindowManager"));
+                sm.getImplementation("mx.managers::IActiveWindowManager") as IActiveWindowManager;
             if (awm)
                 awm.activate(this);
             else

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a936d77a/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as b/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as
index e6fc5b2..e682777 100644
--- a/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as
+++ b/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as
@@ -2137,6 +2137,9 @@ public class SystemManager extends MovieClip
     {
         var mainClassName:String = info()["mainClassName"];
 
+        if (params && params.length > 0)
+            mainClassName = params[0];
+        
 		COMPILE::SWF
 		{
 			if (mainClassName == null)

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a936d77a/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as b/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as
index ba6ea3f..ec4467b 100644
--- a/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as
+++ b/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as
@@ -54,10 +54,13 @@ import mx.core.UIComponent;
 import mx.core.mx_internal;
 import mx.utils.NameUtil;
 import mx.utils.OrderedObject;
+COMPILE::SWF
+{
 import mx.utils.object_proxy;
+use namespace object_proxy;
+}
 
 use namespace mx_internal;
-use namespace object_proxy;
 
 [ExcludeClass]
 
@@ -809,7 +812,14 @@ public class StyleProtoChain
         var styleManager:IStyleManager2 = getStyleManager(object);
         var qualified:Boolean = styleManager.qualifiedTypeSelectors;
         var typeHierarchy:OrderedObject = getTypeHierarchy(object, styleManager, qualified);
-        return typeHierarchy.object_proxy::getObjectProperty(cssType) != null;
+        COMPILE::SWF
+        {
+            return typeHierarchy.object_proxy::getObjectProperty(cssType) != null;
+        }
+        COMPILE::JS
+        {
+            return typeHierarchy[cssType] != null;
+        }
     }
 
     /**
@@ -898,7 +908,14 @@ public class StyleProtoChain
                     else
                         type = NameUtil.getUnqualifiedClassName(className);
 
-                    hierarchy.object_proxy::setObjectProperty(type, true);
+                    COMPILE::SWF
+                    {
+                        hierarchy.object_proxy::setObjectProperty(type, true);
+                    }
+                    COMPILE::JS
+                    {
+                        hierarchy[type] = true;
+                    }
                     className = getQualifiedSuperclassName(
                         myApplicationDomain.getDefinition(className));
                 }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a936d77a/frameworks/projects/MX/src/main/flex/mx/utils/OrderedObject.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/utils/OrderedObject.as b/frameworks/projects/MX/src/main/flex/mx/utils/OrderedObject.as
index b20c30e..5048fb3 100644
--- a/frameworks/projects/MX/src/main/flex/mx/utils/OrderedObject.as
+++ b/frameworks/projects/MX/src/main/flex/mx/utils/OrderedObject.as
@@ -80,7 +80,7 @@ public dynamic class OrderedObject extends Proxy
 	COMPILE::SWF
     object_proxy var propertyList:Array;
 	COMPILE::JS
-	protected var propertyList:Array;
+	public var propertyList:Array;
 
     //--------------------------------------------------------------------------
     //


[5/7] git commit: [flex-asjs] [refs/heads/spark] - tweak dependencies at startup

Posted by ah...@apache.org.
tweak dependencies at startup


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

Branch: refs/heads/spark
Commit: f1ff5f15f4df0524a468c2dfce49d50446c06513
Parents: 08903ca
Author: Alex Harui <ah...@apache.org>
Authored: Thu Sep 15 22:05:15 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Sep 15 22:05:15 2016 -0700

----------------------------------------------------------------------
 .../MX/src/main/flex/mx/core/Application.as       | 18 ++++++++++--------
 1 file changed, 10 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f1ff5f15/frameworks/projects/MX/src/main/flex/mx/core/Application.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/core/Application.as b/frameworks/projects/MX/src/main/flex/mx/core/Application.as
index fc33350..9142894 100644
--- a/frameworks/projects/MX/src/main/flex/mx/core/Application.as
+++ b/frameworks/projects/MX/src/main/flex/mx/core/Application.as
@@ -46,22 +46,20 @@ COMPILE::JS
 }
 
 import mx.containers.utilityClasses.ApplicationLayout;
+import mx.core.TextFieldFactory;
 import mx.effects.EffectManager;
 import mx.events.FlexEvent;
 import mx.managers.FocusManager;
 import mx.managers.IActiveWindowManager;
 import mx.managers.ILayoutManager;
 import mx.managers.ISystemManager;
-// force-link this here. In flex-sdk, it gets dragged in by Effect.
-import mx.managers.LayoutManager; // LayoutManager; force-link syntax not supported by FalconJX 
-// force-link this here. In flex-sdk, it gets injected somehow.
-import mx.core.TextFieldFactory; // TextFieldFactory; force-link syntax not supported by FalconJX 
-// force-link this here. In flex-sdk, it gets injected in generated code.
-import mx.styles.StyleManagerImpl; // StyleManagerImpl; force-link syntax not supported by FalconJX 
+import mx.managers.LayoutManager;
 import mx.styles.CSSStyleDeclaration;
 import mx.styles.IStyleClient;
+import mx.styles.StyleManagerImpl;
 import mx.utils.LoaderUtil;
 import mx.utils.Platform;
+
 import org.apache.flex.core.SimpleCSSValuesImpl;
 import org.apache.flex.core.ValuesManager;
 import org.apache.flex.utils.MixinManager;
@@ -377,6 +375,7 @@ public class Application extends LayoutContainer
         
         COMPILE::JS
         {
+            UIComponentGlobals.layoutManager = LayoutManager.getInstance();
             // this is a hack until we get falconjx to put the info on the factory
             SystemManager.setInfo(this["info"]());
             var sm:SystemManager = new SystemManager();
@@ -387,8 +386,11 @@ public class Application extends LayoutContainer
             sm.kickOff();
         }
                 
-        UIComponentGlobals.layoutManager = ILayoutManager(
-            Singleton.getInstance("mx.managers::ILayoutManager"));
+        COMPILE::SWF
+        {
+            UIComponentGlobals.layoutManager = ILayoutManager(
+                Singleton.getInstance("mx.managers::ILayoutManager"));
+        }
         UIComponentGlobals.layoutManager.usePhasedInstantiation = true;
 
         if (!FlexGlobals.topLevelApplication)


[2/7] git commit: [flex-asjs] [refs/heads/spark] - change JS CSS encoding

Posted by ah...@apache.org.
change JS CSS encoding


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

Branch: refs/heads/spark
Commit: 8226d2fc7c28022de9ca5eede142723744db6689
Parents: 773987e
Author: Alex Harui <ah...@apache.org>
Authored: Wed Sep 14 17:17:29 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Sep 14 17:17:29 2016 -0700

----------------------------------------------------------------------
 .../org/apache/flex/core/SimpleCSSValuesImpl.as    | 17 ++++++++---------
 1 file changed, 8 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/8226d2fc/frameworks/projects/Core/src/main/flex/org/apache/flex/core/SimpleCSSValuesImpl.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/SimpleCSSValuesImpl.as b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/SimpleCSSValuesImpl.as
index 7afd2ff..29ba5e9 100644
--- a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/SimpleCSSValuesImpl.as
+++ b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/SimpleCSSValuesImpl.as
@@ -125,21 +125,20 @@ package org.apache.flex.core
                         i += numMQ;
                     }
                     var numSel:int = cssData[i++];
-                    var props:Object = {};
+                    var propFn:Function = cssData[i + numSel];
+                    var props:Object;
                     for (var j:int = 0; j < numSel; j++)
                     {
                         var selName:String = cssData[i++];
                         if (values[selName])
+                        {
                             props = values[selName];
-                        values[selName] = props;
-                    }
-                    var numProps:int = cssData[i++];
-                    for (j = 0; j < numProps; j++)
-                    {
-                        var propName:String = cssData[i++];
-                        var propValue:Object = cssData[i++];
-                        props[propName] = propValue;
+                            propFn.prototype = props;
+                        }
+                        values[selName] = new propFn();
                     }
+                    // skip the propFn
+                    props = cssData[i++];
                 }
             }
             


[4/7] git commit: [flex-asjs] [refs/heads/spark] - switch to new CSS format

Posted by ah...@apache.org.
switch to new CSS format


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

Branch: refs/heads/spark
Commit: 08903caef5859ee1867a5577f04506eb6c8b6b22
Parents: 5f15c1b
Author: Alex Harui <ah...@apache.org>
Authored: Thu Sep 15 22:04:26 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Sep 15 22:04:26 2016 -0700

----------------------------------------------------------------------
 .../src/main/flex/mx/styles/StyleManagerImpl.as | 20 +++++---------------
 1 file changed, 5 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/08903cae/frameworks/projects/MX/src/main/flex/mx/styles/StyleManagerImpl.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/styles/StyleManagerImpl.as b/frameworks/projects/MX/src/main/flex/mx/styles/StyleManagerImpl.as
index d3c2148..30b8ca1 100644
--- a/frameworks/projects/MX/src/main/flex/mx/styles/StyleManagerImpl.as
+++ b/frameworks/projects/MX/src/main/flex/mx/styles/StyleManagerImpl.as
@@ -143,23 +143,13 @@ public class StyleManagerImpl extends EventDispatcher implements IStyleManager2
                         var selName:String = cssData[i++];
                         decls.push(new CSSStyleDeclaration(selName));
                     }
-                    var numProps:int = cssData[i++];
-                    for (j = 0; j < numProps; j++)
-                    {
-                        var propName:String = cssData[i++];
-                        var propValue:Object = cssData[i++];
-                        props[propName] = propValue;
-                    }
+                    var propFn:Function = cssData[i++];
                     for each (var decl:CSSStyleDeclaration in decls)
                     {
-                        var factoryFunction:String = "(function factoryFunction() {";
-                        for (var p:String in props)
-                        {
-                            factoryFunction += "this." + p + " = " + props[p] + ";";
-                        }
-                        factoryFunction += "})";
-                        var f:Function = eval(factoryFunction);
-                        decl.defaultFactory = f;
+                        if (decl.defaultFactory == null)
+                            decl.defaultFactory = propFn;
+                        else
+                            decl.factory = propFn;
                     }
                 }
             }


[7/7] git commit: [flex-asjs] [refs/heads/spark] - enough changes that something showed up in JS

Posted by ah...@apache.org.
enough changes that something showed up 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/24dc2663
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/24dc2663
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/24dc2663

Branch: refs/heads/spark
Commit: 24dc2663cba4aa60c1f559fcf3f770c84783cb1a
Parents: a936d77
Author: Alex Harui <ah...@apache.org>
Authored: Wed Sep 21 15:23:00 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Sep 21 15:23:00 2016 -0700

----------------------------------------------------------------------
 .../main/flex/org/apache/flex/core/UIBase.as    |  7 +++-
 .../main/flex/org/apache/flex/utils/Language.as |  2 +
 .../MX/src/main/flex/flex/display/Sprite.as     | 14 +++++--
 .../MX/src/main/flex/flex/events/Event.as       |  1 +
 .../MX/src/main/flex/flex/text/TextField.as     |  4 +-
 .../MX/src/main/flex/mx/controls/Label.as       |  3 ++
 .../MX/src/main/flex/mx/core/Application.as     |  5 ++-
 .../MX/src/main/flex/mx/core/Container.as       |  2 +-
 .../MX/src/main/flex/mx/core/UIComponent.as     | 11 ++++++
 .../src/main/flex/mx/managers/SystemManager.as  | 41 ++++++++++++++++++--
 .../src/main/flex/mx/styles/StyleProtoChain.as  |  3 ++
 .../MX/src/test/flex/src/TestCompile.mxml       |  1 +
 12 files changed, 81 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/Core/src/main/flex/org/apache/flex/core/UIBase.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/UIBase.as b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/UIBase.as
index dcbac3a..8ff5bc2 100644
--- a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/UIBase.as
+++ b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/UIBase.as
@@ -1201,6 +1201,7 @@ package org.apache.flex.core
          *  @playerversion AIR 2.6
          *  @productversion FlexJS 0.0
 		 *  @flexjsignorecoercion org.apache.flex.core.IUIBase
+		 *  @flexjsignorecoercion String
          */
         public function getElementIndex(c:IVisualElement):int
         {
@@ -1213,13 +1214,17 @@ package org.apache.flex.core
             }
             COMPILE::JS
             {
+                var index:int = -1;
                 var children:Array = internalChildren();
                 var n:int = children.length;
 				var ui:IUIBase = c as IUIBase;
                 for (var i:int = 0; i < n; i++)
                 {
+                    var nodeName:String = children[i]["nodeName"] as String;
+                    if (children[i]["nodeType"] == 1 && nodeName.toUpperCase() != "SCRIPT")
+                        index++;
                     if (children[i] == ui.element)
-                        return i;
+                        return index;
                 }
                 return -1;                
             }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/Language/src/main/flex/org/apache/flex/utils/Language.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Language/src/main/flex/org/apache/flex/utils/Language.as b/frameworks/projects/Language/src/main/flex/org/apache/flex/utils/Language.as
index 9ddc0d7..63e0425 100644
--- a/frameworks/projects/Language/src/main/flex/org/apache/flex/utils/Language.as
+++ b/frameworks/projects/Language/src/main/flex/org/apache/flex/utils/Language.as
@@ -72,6 +72,8 @@ package org.apache.flex.utils
 
 			coercion = (coercion !== undefined) ? coercion : false;
 
+            if (coercion && leftOperand == null) return null;
+            
 			itIs = Language.is(leftOperand, rightOperand);
 
 			if (!itIs && coercion)

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as b/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as
index 64815a3..b68a871 100644
--- a/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as
+++ b/frameworks/projects/MX/src/main/flex/flex/display/Sprite.as
@@ -19,6 +19,7 @@
 
 package flex.display
 {	
+    import org.apache.flex.core.UIBase;
 	import org.apache.flex.svg.CompoundGraphic;
 	import org.apache.flex.geom.Point;
 	import org.apache.flex.utils.PointUtils;
@@ -32,7 +33,7 @@ package flex.display
         import flex.events.IEventDispatcher;
     }
     
-	public class Sprite extends CompoundGraphic implements DisplayObjectContainer, IEventDispatcher
+	public class Sprite extends UIBase implements DisplayObjectContainer, IEventDispatcher
 	{
 		COMPILE::JS
 		private var _name:String;
@@ -153,6 +154,9 @@ package flex.display
 		COMPILE::JS
 		private var _graphics:Graphics;
 		
+        COMPILE::JS
+        private var _graphicsHost:CompoundGraphic;
+        
 		COMPILE::JS
 		/**
 		 *  @flexjsignorecoercion flex.display.DisplayObject
@@ -160,8 +164,12 @@ package flex.display
 		public function get graphics():Graphics
 		{
 			if (!_graphics)
-				_graphics = new Graphics(this);
-			return _graphics
+            {
+                _graphicsHost = new CompoundGraphic();
+                super.addElement(_graphicsHost);
+				_graphics = new Graphics(_graphicsHost);
+            }
+			return _graphics;
 		}
 
 		COMPILE::JS

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/flex/events/Event.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/flex/events/Event.as b/frameworks/projects/MX/src/main/flex/flex/events/Event.as
index fa60732..72237a2 100644
--- a/frameworks/projects/MX/src/main/flex/flex/events/Event.as
+++ b/frameworks/projects/MX/src/main/flex/flex/events/Event.as
@@ -18,6 +18,7 @@ package flex.events
 		public static const ENTER_FRAME:String = "enterFrame";
 		public static const REMOVED:String = "removed";
 		public static const REMOVED_FROM_STAGE:String = "removedFromStage";
+        public static const RENDER:String = "render";
 		public static const RESIZE:String = "resize";
 	}
 }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/flex/text/TextField.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/flex/text/TextField.as b/frameworks/projects/MX/src/main/flex/flex/text/TextField.as
index 3e97256..2036aff 100644
--- a/frameworks/projects/MX/src/main/flex/flex/text/TextField.as
+++ b/frameworks/projects/MX/src/main/flex/flex/text/TextField.as
@@ -539,8 +539,8 @@ public class TextField extends Label
 	
 	public function getLineMetrics(index:int):TextLineMetrics
 	{
-		trace("TextField.getLineMetrics not implemented");
-		return null;
+		
+		return new TextLineMetrics(0, element.offsetWidth, element.offsetHeight, 0, 0, 0);
 	}
 	
 	public function getLineOffset(index:int):int

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/mx/controls/Label.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/controls/Label.as b/frameworks/projects/MX/src/main/flex/mx/controls/Label.as
index f8b46f6..3b3f3e4 100644
--- a/frameworks/projects/MX/src/main/flex/mx/controls/Label.as
+++ b/frameworks/projects/MX/src/main/flex/mx/controls/Label.as
@@ -1502,10 +1502,13 @@ public class Label extends UIComponent
                 truncated = textField.truncateToFit();
             }
 
+            COMPILE::LATER
+            {    
             // If no explicit tooltip has been set,
             // implicitly set or clear a "truncation tip".
             if (!toolTipSet)
                 super.toolTip = truncated ? text : null;
+            }
         }
         
     }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/mx/core/Application.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/core/Application.as b/frameworks/projects/MX/src/main/flex/mx/core/Application.as
index 04fd0a6..de72b11 100644
--- a/frameworks/projects/MX/src/main/flex/mx/core/Application.as
+++ b/frameworks/projects/MX/src/main/flex/mx/core/Application.as
@@ -354,7 +354,6 @@ public class Application extends LayoutContainer
      */
     public function Application()
     {
-        start();
     }
     
     /**
@@ -375,14 +374,16 @@ public class Application extends LayoutContainer
         
         COMPILE::JS
         {
-            UIComponentGlobals.layoutManager = LayoutManager.getInstance();
             // this is a hack until we get falconjx to put the info on the factory
             SystemManager.setInfo(this["info"]());
             var sm:SystemManager = new SystemManager();
             sm.document = this;
             sm.info()["cssData"] = this["cssData"];
             systemManager = sm;
+            UIComponentGlobals.layoutManager = LayoutManager.getInstance();
             new ChildManager(sm);
+            sm.width = width;
+            sm.height = height;
             sm.kickOff();
         }
                 

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/mx/core/Container.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/core/Container.as b/frameworks/projects/MX/src/main/flex/mx/core/Container.as
index ed2c0b5..ec23148 100644
--- a/frameworks/projects/MX/src/main/flex/mx/core/Container.as
+++ b/frameworks/projects/MX/src/main/flex/mx/core/Container.as
@@ -3143,7 +3143,7 @@ public class Container extends UIComponent
      *  @playerversion AIR 1.5
      *  @productversion Flex 4
      */
-    override public function removeAllElements():void
+    public function removeAllElements():void
     {
         for (var i:int = numElements - 1; i >= 0; i--)
         {

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/mx/core/UIComponent.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/core/UIComponent.as b/frameworks/projects/MX/src/main/flex/mx/core/UIComponent.as
index ea50d16..e93a5b6 100644
--- a/frameworks/projects/MX/src/main/flex/mx/core/UIComponent.as
+++ b/frameworks/projects/MX/src/main/flex/mx/core/UIComponent.as
@@ -1784,6 +1784,13 @@ public class UIComponent extends Sprite
         _width = super.width;
         _height = super.height;
         
+        COMPILE::JS
+        {
+            // UIComponent is born invisible and won't be layed out by
+            // FlexJS layout so needs a default display style
+            setDisplayStyleForLayout("block");        
+        }
+        
     }
 
     //--------------------------------------------------------------------------
@@ -13704,6 +13711,8 @@ public class UIComponent extends Sprite
         if (!hasFontContextBeenSaved)
             return false;
 
+        COMPILE::LATER
+        {
         // Check if the module factory has changed.
         var fontName:String =
             StringUtil.trimArrayElements(getStyle("fontFamily"), ",");
@@ -13716,6 +13725,8 @@ public class UIComponent extends Sprite
                 fontName, bold, italic, this, moduleFactory,
                 systemManager);
         return fontContext != oldEmbeddedFontContext;
+        }
+        return false;
     }
 
     /**

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as b/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as
index e682777..9f09d53 100644
--- a/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as
+++ b/frameworks/projects/MX/src/main/flex/mx/managers/SystemManager.as
@@ -63,16 +63,17 @@ COMPILE::JS
 	import org.apache.flex.events.MouseEvent;
 	import org.apache.flex.geom.Point;
 }
-import org.apache.flex.utils.Timer;
-import flex.system.DefinitionManager;
-import org.apache.flex.reflection.getQualifiedClassName;
-
 import mx.core.IChildList;
 import mx.core.IFlexDisplayObject;
 import mx.core.IFlexModuleFactory;
 import mx.core.IInvalidating;
 import mx.core.IRawChildrenContainer;
 import mx.core.IUIComponent;
+
+import flex.system.DefinitionManager;
+
+import org.apache.flex.reflection.getQualifiedClassName;
+import org.apache.flex.utils.Timer;
 COMPILE::LATER
 {
 import mx.core.RSLData;
@@ -1806,6 +1807,38 @@ public class SystemManager extends MovieClip
 		trace(e.type, e.target);
 	}
 	
+    COMPILE::JS
+    public var frameRate:Number = 166;
+    
+    COMPILE::JS
+    private var frameInterval:Number = -1;
+    
+    COMPILE::JS
+    override public function addEventListener(type:String, listener:Function,
+                                              useCapture:Boolean = false, opt_handlerScope:Object = null):void
+    {
+        if (type == FlexEvent.RENDER)
+            type = Event.RENDER;
+        else
+            type = Event.ENTER_FRAME;
+        
+        // TODO (aharui): figure out when to stop the interval
+        if (type == Event.RENDER || type == Event.ENTER_FRAME)
+        {
+            if (frameInterval == -1)
+                frameInterval = setInterval(frameCallback, frameRate);
+        }    
+        super.addEventListener(type, listener, useCapture);
+    }
+    
+    COMPILE::JS
+    private function frameCallback():void
+    {
+        dispatchEvent(new Event(Event.ENTER_FRAME));
+        dispatchEvent(new Event(Event.RENDER));
+    }
+            
+    
     /**
      *  @private
      */

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as b/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as
index ec4467b..d0479d9 100644
--- a/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as
+++ b/frameworks/projects/MX/src/main/flex/mx/styles/StyleProtoChain.as
@@ -779,6 +779,8 @@ public class StyleProtoChain
             object.invalidateSize();
         }
 
+        COMPILE::LATER
+        {
         // TODO (gosmith): Should initThemeColor() be in some interface?
         if (!styleProp || 
             styleProp == "styleName" ||
@@ -787,6 +789,7 @@ public class StyleProtoChain
         	if (object is IUIComponent)
                 object["initThemeColor"]();
         }
+        }
         
         object.invalidateDisplayList();
         

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/24dc2663/frameworks/projects/MX/src/test/flex/src/TestCompile.mxml
----------------------------------------------------------------------
diff --git a/frameworks/projects/MX/src/test/flex/src/TestCompile.mxml b/frameworks/projects/MX/src/test/flex/src/TestCompile.mxml
index 427952f..bd6cbb4 100644
--- a/frameworks/projects/MX/src/test/flex/src/TestCompile.mxml
+++ b/frameworks/projects/MX/src/test/flex/src/TestCompile.mxml
@@ -22,6 +22,7 @@ limitations under the License.
 				xmlns:mx="library://ns.apache.org/flexjs/mx"
 				xmlns:js="library://ns.apache.org/flexjs/basic" 
                    applicationComplete="runTests()"
+                   width="500" height="375"
                    usePreloader="false"
                    preloader="mx.preloaders.DownloadProgressBar"
                    >