flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmcl...@apache.org
Subject [14/24] git commit: [flex-sdk] [refs/heads/develop] - Added support for 480 dpi
Date Sun, 12 May 2013 10:49:20 GMT
Added support for 480 dpi


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

Branch: refs/heads/develop
Commit: d26f25b820e95b7d28ae484d4f67611cce14439c
Parents: f3482b2
Author: Justin Mclean <jmclean@apache.org>
Authored: Thu Apr 25 13:06:23 2013 +1000
Committer: Justin Mclean <jmclean@apache.org>
Committed: Thu Apr 25 13:06:23 2013 +1000

----------------------------------------------------------------------
 mustella/java/src/mustella/MobileConfigWriter.java |    2 +-
 mustella/java/src/utils/MobileUtil.java            |    6 ++++++
 2 files changed, 7 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/d26f25b8/mustella/java/src/mustella/MobileConfigWriter.java
----------------------------------------------------------------------
diff --git a/mustella/java/src/mustella/MobileConfigWriter.java b/mustella/java/src/mustella/MobileConfigWriter.java
index 451c948..192eb54 100644
--- a/mustella/java/src/mustella/MobileConfigWriter.java
+++ b/mustella/java/src/mustella/MobileConfigWriter.java
@@ -162,7 +162,7 @@ public class MobileConfigWriter {
 				ret += "		UnitTester.cv.targetOS = \"" + target_os + "\";\n";
 				ret += "		UnitTester.cv.osVersion = \"" + os_version + "\";\n";
 				
-				// If device, get the proper dpi bucket (160/240/320) for the device.
+				// If device, get the proper dpi bucket (160/240/320/480) for the device.
 				if( (target_os.compareToIgnoreCase(MobileUtil.MAC) == 0) || (target_os.compareToIgnoreCase(MobileUtil.WIN)
== 0) ){
 					if( adl_extras_XscreenDPI == -1 ){
 						ret += "		UnitTester.cv.deviceDensity = flash.system.Capabilities.screenDPI;\n";

http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/d26f25b8/mustella/java/src/utils/MobileUtil.java
----------------------------------------------------------------------
diff --git a/mustella/java/src/utils/MobileUtil.java b/mustella/java/src/utils/MobileUtil.java
index ab8d6be..bf522a2 100644
--- a/mustella/java/src/utils/MobileUtil.java
+++ b/mustella/java/src/utils/MobileUtil.java
@@ -70,6 +70,7 @@ public class MobileUtil {
     public static final String[] DEVICES_AROUND_160PPI = {WIN, DROID_PRO, ANDROID_TABLET,
XOOM, IPOD_TOUCH_3GS, IPAD, IPAD2, PLAYBOOK};
 	public static final String[] DEVICES_AROUND_240PPI = {ANDROID, ANDROID2, DESIRE, DROID,
DROID_2, DROID_X, NEXUS_ONE, EVO, INCREDIBLE};
 	public static final String[] DEVICES_AROUND_320PPI = {WIN, IPOD_TOUCH_4G, IPOD_TOUCH_5G,
IPAD3, IPAD4};
+	public static final String[] DEVICES_AROUND_480PPI = {};
 
 	// Other
 	public static final String MOBILE_FRAMEWORK_DIR = "MobileConfig";
@@ -300,6 +301,11 @@ public class MobileUtil {
 			if( deviceId.compareToIgnoreCase( DEVICES_AROUND_320PPI[ i ] ) == 0 )
 				ret = 320;
 		}
+		
+		for( i = 0; i < Array.getLength( DEVICES_AROUND_480PPI ); ++i ){
+			if( deviceId.compareToIgnoreCase( DEVICES_AROUND_480PPI[ i ] ) == 0 )
+				ret = 480;
+		}
 
 		return ret;
 		/**


Mime
View raw message