You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by jm...@apache.org on 2014/03/07 02:05:57 UTC

[47/50] git commit: [flex-sdk] [refs/heads/master] - changed back to IOS as isIPad returns false in the simulator

changed back to IOS as isIPad returns false in the simulator


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

Branch: refs/heads/master
Commit: 6e87e4c2f09a4e6c6e93a2185a0045570a577ae5
Parents: 470705c
Author: Justin Mclean <jm...@apache.org>
Authored: Mon Mar 3 10:11:23 2014 +1100
Committer: Justin Mclean <jm...@apache.org>
Committed: Mon Mar 3 10:11:23 2014 +1100

----------------------------------------------------------------------
 .../projects/framework/src/mx/core/RuntimeDPIProvider.as       | 6 +++---
 frameworks/projects/framework/src/mx/utils/Platform.as         | 1 +
 2 files changed, 4 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/6e87e4c2/frameworks/projects/framework/src/mx/core/RuntimeDPIProvider.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/framework/src/mx/core/RuntimeDPIProvider.as b/frameworks/projects/framework/src/mx/core/RuntimeDPIProvider.as
index 48d9ee9..7ce8cc7 100644
--- a/frameworks/projects/framework/src/mx/core/RuntimeDPIProvider.as
+++ b/frameworks/projects/framework/src/mx/core/RuntimeDPIProvider.as
@@ -119,10 +119,10 @@ public class RuntimeDPIProvider
 
     public function get runtimeDPI():Number
     {
-        var isIPad:Boolean = Platform.isIPad;
+        var isIOS:Boolean = Platform.isIOS;
         var screenDPI:Number = Capabilities.screenDPI;
 
-        if (isIPad)
+        if (isIOS) // as isIPad returns false in the simulator
 		{
             var root:DisplayObject = SystemManager.getSWFRoot(this);
             if (root != null )  {
@@ -130,7 +130,7 @@ public class RuntimeDPIProvider
                 if (stage != null){
                     var scX:Number = stage.fullScreenWidth;
                     var scY:Number = stage.fullScreenHeight;
-                    /*  as of Dec 2013,  iPad (resp. iPad retina)   are the only iOS devices to have 1024 (resp. 2048) screen width or height
+                    /*  as of Dec 2013,  iPad (resp. iPad retina) are the only iOS devices to have 1024 (resp. 2048) screen width or height
                      cf http://en.wikipedia.org/wiki/List_of_displays_by_pixel_density#Apple
                      * */
                     if ((scX == IPAD_RETINA_MAX_EXTENT || scY == IPAD_RETINA_MAX_EXTENT))

http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/6e87e4c2/frameworks/projects/framework/src/mx/utils/Platform.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/framework/src/mx/utils/Platform.as b/frameworks/projects/framework/src/mx/utils/Platform.as
index 6c89078..494b83c 100644
--- a/frameworks/projects/framework/src/mx/utils/Platform.as
+++ b/frameworks/projects/framework/src/mx/utils/Platform.as
@@ -65,6 +65,7 @@ public class Platform
 	
 	/**
 	 *  Returns true if the applciation is runing on an iPad.
+	 *  Note this returns false in the mobile device simulator.
 	 *
 	 *  @langversion 3.0
 	 *  @playerversion Flash 10