flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aha...@apache.org
Subject [04/16] git commit: [flex-asjs] [refs/heads/develop] - use screenXY and clientXY
Date Mon, 05 Jan 2015 23:21:23 GMT
use screenXY and clientXY


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

Branch: refs/heads/develop
Commit: 17da25b19b681a992fe74030f2d133914a172757
Parents: 828d0b4
Author: Alex Harui <aharui@apache.org>
Authored: Mon Jan 5 10:11:32 2015 -0800
Committer: Alex Harui <aharui@apache.org>
Committed: Mon Jan 5 15:21:00 2015 -0800

----------------------------------------------------------------------
 .../FlexJSUI/src/org/apache/flex/events/MouseEvent.as     | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/17da25b1/frameworks/as/projects/FlexJSUI/src/org/apache/flex/events/MouseEvent.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/events/MouseEvent.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/events/MouseEvent.as
index dabdf35..ad54ddf 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/events/MouseEvent.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/events/MouseEvent.as
@@ -85,6 +85,7 @@ package org.apache.flex.events
         public function set localX(value:Number):void
         {
             _localX = value;
+            clientX = value;
             _stagePoint = null;
         }
         
@@ -96,6 +97,7 @@ package org.apache.flex.events
         public function set localY(value:Number):void
         {
             _localY = value;
+            clientY = value;
             _stagePoint = null;
         }
         
@@ -109,9 +111,13 @@ package org.apache.flex.events
         public var controlKey:Boolean;
         public var clickCount:int;
         
+        // these map directly to JS MouseEvent fields.
+        public var clientX:Number;
+        public var clientY:Number;
+        
         private var _stagePoint:Point;
         
-        public function get stageX():Number
+        public function get screenX():Number
         {
             if (!target) return localX;
             if (!_stagePoint)
@@ -122,7 +128,7 @@ package org.apache.flex.events
             return _stagePoint.x;
         }
         
-        public function get stageY():Number
+        public function get screenY():Number
         {
             if (!target) return localY;
             if (!_stagePoint)


Mime
View raw message