flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yish...@apache.org
Subject [1/2] git commit: [flex-asjs] [refs/heads/develop] - Fix scrolling runtime error on combobox.
Date Mon, 07 Nov 2016 11:05:20 GMT
Repository: flex-asjs
Updated Branches:
  refs/heads/develop cf4fd2d81 -> d99854c2f


Fix scrolling runtime error on combobox.


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

Branch: refs/heads/develop
Commit: 2a06fe6ef55a9749a609bc449b9fb53c1b9414b3
Parents: ec60f6a
Author: yishayw <yishayjobs@hotmail.com>
Authored: Mon Nov 7 13:02:11 2016 +0200
Committer: yishayw <yishayjobs@hotmail.com>
Committed: Mon Nov 7 13:02:11 2016 +0200

----------------------------------------------------------------------
 .../flex/org/apache/flex/core/CSSTextField.as    | 19 +++++++++++++------
 .../flex/org/apache/flex/utils/PointUtils.as     |  5 +++++
 .../controllers/ScrollBarMouseControllerBase.as  |  6 +++---
 .../html/supportClasses/TextFieldItemRenderer.as |  6 ------
 4 files changed, 21 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/2a06fe6e/frameworks/projects/Core/src/main/flex/org/apache/flex/core/CSSTextField.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/CSSTextField.as b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/CSSTextField.as
index 6ec8158..68a8bf3 100644
--- a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/CSSTextField.as
+++ b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/CSSTextField.as
@@ -20,10 +20,11 @@ package org.apache.flex.core
 {
 	COMPILE::SWF {
         import flash.display.DisplayObject;
-		import flash.text.TextField;
-		import flash.text.TextFieldAutoSize;
-		import flash.text.TextFormat;
-        import org.apache.flex.events.Event;        
+        import flash.text.TextField;
+        import flash.text.TextFieldAutoSize;
+        import flash.text.TextFormat;
+        
+        import org.apache.flex.events.Event;
         import org.apache.flex.events.EventDispatcher;
 	}
 
@@ -41,7 +42,7 @@ package org.apache.flex.core
      *  @productversion FlexJS 0.0
      */
     COMPILE::SWF
-	public class CSSTextField extends TextField
+	public class CSSTextField extends TextField implements IRenderedObject
 	{
         /**
          *  Constructor.
@@ -157,7 +158,13 @@ package org.apache.flex.core
             // force styles to be re-calculated
             this.text = text;
         }
-
+		
+		COMPILE::SWF
+		public function get $displayObject():DisplayObject
+		{
+			return this;
+		}
+		
 	}
 
 	COMPILE::JS

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/2a06fe6e/frameworks/projects/Core/src/main/flex/org/apache/flex/utils/PointUtils.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Core/src/main/flex/org/apache/flex/utils/PointUtils.as b/frameworks/projects/Core/src/main/flex/org/apache/flex/utils/PointUtils.as
index c00bfa7..8b7b9e2 100644
--- a/frameworks/projects/Core/src/main/flex/org/apache/flex/utils/PointUtils.as
+++ b/frameworks/projects/Core/src/main/flex/org/apache/flex/utils/PointUtils.as
@@ -26,6 +26,7 @@ package org.apache.flex.utils
     
     import org.apache.flex.core.IUIBase;
     import org.apache.flex.geom.Point;
+    import flash.display.Stage;
 
 	/**
 	 *  The PointUtils class is a collection of static functions that convert
@@ -103,6 +104,10 @@ package org.apache.flex.utils
         {
             COMPILE::SWF
             {
+				if (local is Stage)
+				{
+					return pt;
+				}
                 var fpt:flash.geom.Point = DisplayObject(local.$displayObject).localToGlobal(new
flash.geom.Point(pt.x,pt.y));
                 return new org.apache.flex.geom.Point(fpt.x, fpt.y);
             }

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/2a06fe6e/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/controllers/ScrollBarMouseControllerBase.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/controllers/ScrollBarMouseControllerBase.as
b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/controllers/ScrollBarMouseControllerBase.as
index 8d9d27b..eea9234 100644
--- a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/controllers/ScrollBarMouseControllerBase.as
+++ b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/controllers/ScrollBarMouseControllerBase.as
@@ -23,7 +23,7 @@ package org.apache.flex.html.beads.controllers
 	import org.apache.flex.core.IStrand;
 	import org.apache.flex.events.Event;
 	import org.apache.flex.events.IEventDispatcher;
-    import org.apache.flex.events.MouseEvent;
+	import org.apache.flex.events.MouseEvent;
 	import org.apache.flex.html.beads.IScrollBarView;
 
     /**
@@ -135,7 +135,7 @@ package org.apache.flex.html.beads.controllers
          *  @playerversion AIR 2.6
          *  @productversion FlexJS 0.0
          */	
-		protected function decrementClickHandler(event:Event):void
+		protected function decrementClickHandler(event:Object):void
 		{
 			sbModel.value = snap(Math.max(sbModel.minimum, sbModel.value - sbModel.stepSize));
 			IEventDispatcher(_strand).dispatchEvent(new Event("scroll"));
@@ -149,7 +149,7 @@ package org.apache.flex.html.beads.controllers
          *  @playerversion AIR 2.6
          *  @productversion FlexJS 0.0
          */	
-		protected function incrementClickHandler(event:Event):void
+		protected function incrementClickHandler(event:Object):void
 		{
 			sbModel.value = snap(Math.min(sbModel.maximum - sbModel.pageSize, sbModel.value + sbModel.stepSize));

 			IEventDispatcher(_strand).dispatchEvent(new Event("scroll"));

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/2a06fe6e/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/TextFieldItemRenderer.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/TextFieldItemRenderer.as
b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/TextFieldItemRenderer.as
index 1b2bb6f..5965a17 100644
--- a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/TextFieldItemRenderer.as
+++ b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/supportClasses/TextFieldItemRenderer.as
@@ -550,12 +550,6 @@ package org.apache.flex.html.supportClasses
                 return null;
             return IUIBase(parent).topMostEventDispatcher;
         }
-
-		COMPILE::SWF
-        public function get $displayObject():DisplayObject
-        {
-            return this;
-        }
         
     }
 }


Mime
View raw message