You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by sh...@apache.org on 2012/09/19 23:10:43 UTC

ios commit: For JIRA CB-1482: Add splash screen image for iPhone 5's 4" display.

Updated Branches:
  refs/heads/master 2d4251745 -> ca705097d


For JIRA CB-1482: Add splash screen image for iPhone 5's 4" display.

Created by stretching the gradient portions of the 3.5" image; takes more space than it should.

Opened/saved the XCode project in XCode 4.5; note that XCode also added quotes in various places.


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/commit/ca705097
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/tree/ca705097
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/diff/ca705097

Branch: refs/heads/master
Commit: ca705097d8b299d2d45814f19defa626c991d0bf
Parents: 2d42517
Author: Brion Vibber <br...@pobox.com>
Authored: Mon Sep 17 15:46:36 2012 -0700
Committer: Shazron Abdullah <sh...@apache.org>
Committed: Wed Sep 19 14:08:47 2012 -0700

----------------------------------------------------------------------
 CordovaLib/Classes/CDVViewController.m             |    9 +++++-
 .../project/__TESTING__.xcodeproj/project.pbxproj  |   22 +++++++++------
 .../Resources/splash/Default-568h@2x~iphone.png    |  Bin 0 -> 351931 bytes
 3 files changed, 20 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/blob/ca705097/CordovaLib/Classes/CDVViewController.m
----------------------------------------------------------------------
diff --git a/CordovaLib/Classes/CDVViewController.m b/CordovaLib/Classes/CDVViewController.m
index e03bbf2..cf4dfd8 100644
--- a/CordovaLib/Classes/CDVViewController.m
+++ b/CordovaLib/Classes/CDVViewController.m
@@ -660,15 +660,20 @@
 
 - (void) showSplashScreen
 {
+    CGRect screenBounds = [[UIScreen mainScreen] bounds];
     NSString* launchImageFile = [[NSBundle mainBundle] objectForInfoDictionaryKey:@"UILaunchImageFile"];
     if (launchImageFile == nil) { // fallback if no launch image was specified
-        launchImageFile = @"Default"; 
+        if (screenBounds.size.height == 568) {
+            // iPhone 5 or iPod Touch 6th-gen
+            launchImageFile = @"Default-568h";
+        } else {
+            launchImageFile = @"Default"; 
+        }
     }
     
     NSString* orientedLaunchImageFile = nil;    
     CGAffineTransform startupImageTransform = CGAffineTransformIdentity;
     UIDeviceOrientation deviceOrientation = [UIDevice currentDevice].orientation;
-    CGRect screenBounds = [[UIScreen mainScreen] bounds];
     CGRect statusBarFrame = [UIApplication sharedApplication].statusBarFrame;
     UIInterfaceOrientation statusBarOrientation = [UIApplication sharedApplication].statusBarOrientation;
     UIImage* launchImage = nil;

http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/blob/ca705097/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj b/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj
index 87f95e8..ea223a1 100755
--- a/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj
+++ b/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj
@@ -60,6 +60,7 @@
 		30A0434914DC770100060A13 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = 30A0434614DC770100060A13 /* Localizable.strings */; };
 		30E1352710E2C1420031B30D /* Cordova.plist in Resources */ = {isa = PBXBuildFile; fileRef = 30E1352610E2C1420031B30D /* Cordova.plist */; };
 		30E5649213A7FCAF007403D8 /* CoreMedia.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 30E5649113A7FCAF007403D8 /* CoreMedia.framework */; settings = {ATTRIBUTES = (Weak, ); }; };
+		D4A0D8761607E02300AEF8BB /* Default-568h@2x~iphone.png in Resources */ = {isa = PBXBuildFile; fileRef = D4A0D8751607E02300AEF8BB /* Default-568h@2x~iphone.png */; };
 /* End PBXBuildFile section */
 
 /* Begin PBXContainerItemProxy section */
@@ -97,7 +98,7 @@
 		1D30AB110D05D00D00671497 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
 		1D3623240D0F684500981E51 /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
 		1D3623250D0F684500981E51 /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
-		1D6058910D05DD3D006BFB54 /* __TESTING__.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "__TESTING__.app"; sourceTree = BUILT_PRODUCTS_DIR; };
+		1D6058910D05DD3D006BFB54 /* __TESTING__.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = __TESTING__.app; sourceTree = BUILT_PRODUCTS_DIR; };
 		1DF5F4DF0D08C38300B7A737 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
 		1F766FDD13BBADB100FB74C0 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = Localizable.strings; sourceTree = "<group>"; };
 		1F766FE013BBADB100FB74C0 /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = Localizable.strings; sourceTree = "<group>"; };
@@ -135,6 +136,7 @@
 		30E5649113A7FCAF007403D8 /* CoreMedia.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreMedia.framework; path = System/Library/Frameworks/CoreMedia.framework; sourceTree = SDKROOT; };
 		32CA4F630368D1EE00C91783 /* __TESTING__-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "__TESTING__-Prefix.pch"; sourceTree = "<group>"; };
 		8D1107310486CEB800E47090 /* __TESTING__-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "__TESTING__-Info.plist"; path = "../__TESTING__-Info.plist"; plistStructureDefinitionIdentifier = "com.apple.xcode.plist.structure-definition.iphone.info-plist"; sourceTree = "<group>"; };
+		D4A0D8751607E02300AEF8BB /* Default-568h@2x~iphone.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x~iphone.png"; sourceTree = "<group>"; };
 /* End PBXFileReference section */
 
 /* Begin PBXFrameworksBuildPhase section */
@@ -173,7 +175,7 @@
 				1D3623250D0F684500981E51 /* AppDelegate.m */,
 			);
 			name = Classes;
-			path = "__TESTING__/Classes";
+			path = __TESTING__/Classes;
 			sourceTree = SOURCE_ROOT;
 		};
 		19C28FACFE9D520D11CA2CBB /* Products */ = {
@@ -222,7 +224,7 @@
 				29B97316FDCFA39411CA2CEA /* main.m */,
 			);
 			name = "Other Sources";
-			path = "__TESTING__";
+			path = __TESTING__;
 			sourceTree = "<group>";
 		};
 		29B97317FDCFA39411CA2CEA /* Resources */ = {
@@ -240,7 +242,7 @@
 				307D28A1123043350040C0FA /* CordovaBuildSettings.xcconfig */,
 			);
 			name = Resources;
-			path = "__TESTING__/Resources";
+			path = __TESTING__/Resources;
 			sourceTree = "<group>";
 		};
 		29B97323FDCFA39411CA2CEA /* Frameworks */ = {
@@ -279,7 +281,7 @@
 			children = (
 			);
 			name = Plugins;
-			path = "__TESTING__/Plugins";
+			path = __TESTING__/Plugins;
 			sourceTree = SOURCE_ROOT;
 		};
 		308D052D1370CCF300D202BF /* icons */ = {
@@ -295,6 +297,7 @@
 		308D05311370CCF300D202BF /* splash */ = {
 			isa = PBXGroup;
 			children = (
+				D4A0D8751607E02300AEF8BB /* Default-568h@2x~iphone.png */,
 				3088BBB7154F3926009F9C59 /* Default-Landscape@2x~ipad.png */,
 				3088BBB8154F3926009F9C59 /* Default-Landscape~ipad.png */,
 				3088BBB9154F3926009F9C59 /* Default-Portrait@2x~ipad.png */,
@@ -338,8 +341,8 @@
 			dependencies = (
 				301BF551109A68C00062928A /* PBXTargetDependency */,
 			);
-			name = "__TESTING__";
-			productName = "__TESTING__";
+			name = __TESTING__;
+			productName = __TESTING__;
 			productReference = 1D6058910D05DD3D006BFB54 /* __TESTING__.app */;
 			productType = "com.apple.product-type.application";
 		};
@@ -426,6 +429,7 @@
 				3088BBC0154F3926009F9C59 /* Default-Portrait~ipad.png in Resources */,
 				3088BBC1154F3926009F9C59 /* Default@2x~iphone.png in Resources */,
 				3088BBC2154F3926009F9C59 /* Default~iphone.png in Resources */,
+				D4A0D8761607E02300AEF8BB /* Default-568h@2x~iphone.png in Resources */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};
@@ -520,7 +524,7 @@
 				GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
 				INFOPLIST_FILE = "__TESTING__/__TESTING__-Info.plist";
 				IPHONEOS_DEPLOYMENT_TARGET = 4.2;
-				PRODUCT_NAME = "__TESTING__";
+				PRODUCT_NAME = __TESTING__;
 				TARGETED_DEVICE_FAMILY = "1,2";
 			};
 			name = Debug;
@@ -538,7 +542,7 @@
 				GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
 				INFOPLIST_FILE = "__TESTING__/__TESTING__-Info.plist";
 				IPHONEOS_DEPLOYMENT_TARGET = 4.2;
-				PRODUCT_NAME = "__TESTING__";
+				PRODUCT_NAME = __TESTING__;
 				TARGETED_DEVICE_FAMILY = "1,2";
 			};
 			name = Release;

http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/blob/ca705097/bin/templates/project/__TESTING__/Resources/splash/Default-568h@2x~iphone.png
----------------------------------------------------------------------
diff --git a/bin/templates/project/__TESTING__/Resources/splash/Default-568h@2x~iphone.png b/bin/templates/project/__TESTING__/Resources/splash/Default-568h@2x~iphone.png
new file mode 100644
index 0000000..aec2d8c
Binary files /dev/null and b/bin/templates/project/__TESTING__/Resources/splash/Default-568h@2x~iphone.png differ