summaryrefslogtreecommitdiffstats
path: root/mkspecs/macx-ios-clang
diff options
context:
space:
mode:
authorRichard Moe Gustavsen <richard.gustavsen@digia.com>2014-11-03 11:23:05 +0100
committerJani Heikkinen <jani.heikkinen@theqtcompany.com>2014-11-11 20:43:05 +0100
commitd4fcf2ca40e635cc0f198afe6e17e88ba098835b (patch)
tree62f20505099769e868a6ae0ab26c93c076db3783 /mkspecs/macx-ios-clang
parent0c2f7388a89a9d8ae24379cdbee11a9f85304d19 (diff)
iOS: let qmake generate default LaunchScreen.xib
iOS8 will check if the app has a LaunchScreen.xib to determine if it supports iPhone6/6+ (scale factor and resolution). So we follow the same pattern as we do with the launch image for iPhone5, and generate a default LaunchScreen.xib. The xib file in this patch is a copy of a default file generated by a native Xcode project (with quotes escaped), but with the text label set to be $$TARGET. Change-Id: I163ab48b6f4edea4cc1f6840a1f3d8b3cc0326db Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
Diffstat (limited to 'mkspecs/macx-ios-clang')
-rwxr-xr-xmkspecs/macx-ios-clang/Info.plist.app2
-rw-r--r--mkspecs/macx-ios-clang/LaunchScreen.xib45
-rw-r--r--mkspecs/macx-ios-clang/features/default_post.prf8
3 files changed, 55 insertions, 0 deletions
diff --git a/mkspecs/macx-ios-clang/Info.plist.app b/mkspecs/macx-ios-clang/Info.plist.app
index 2987804e33..623ed496c5 100755
--- a/mkspecs/macx-ios-clang/Info.plist.app
+++ b/mkspecs/macx-ios-clang/Info.plist.app
@@ -24,6 +24,8 @@
<string>1.0</string>
<key>LSRequiresIPhoneOS</key>
<true/>
+ <key>UILaunchStoryboardName</key>
+ <string>LaunchScreen</string>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
diff --git a/mkspecs/macx-ios-clang/LaunchScreen.xib b/mkspecs/macx-ios-clang/LaunchScreen.xib
new file mode 100644
index 0000000000..d28c06b375
--- /dev/null
+++ b/mkspecs/macx-ios-clang/LaunchScreen.xib
@@ -0,0 +1,45 @@
+<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>
+<document type=\"com.apple.InterfaceBuilder3.CocoaTouch.XIB\" version=\"3.0\" toolsVersion=\"6250\" systemVersion=\"14A343f\" targetRuntime=\"iOS.CocoaTouch\" propertyAccessControl=\"none\" useAutolayout=\"YES\" launchScreen=\"YES\" useTraitCollections=\"YES\">
+ <dependencies>
+ <plugIn identifier=\"com.apple.InterfaceBuilder.IBCocoaTouchPlugin\" version=\"6244\"/>
+ <capability name=\"Constraints with non-1.0 multipliers\" minToolsVersion=\"5.1\"/>
+ </dependencies>
+ <objects>
+ <placeholder placeholderIdentifier=\"IBFilesOwner\" id=\"-1\" userLabel=\"File\'s Owner\"/>
+ <placeholder placeholderIdentifier=\"IBFirstResponder\" id=\"-2\" customClass=\"UIResponder\"/>
+ <view contentMode=\"scaleToFill\" id=\"iN0-l3-epB\">
+ <rect key=\"frame\" x=\"0.0\" y=\"0.0\" width=\"480\" height=\"480\"/>
+ <autoresizingMask key=\"autoresizingMask\" widthSizable=\"YES\" heightSizable=\"YES\"/>
+ <subviews>
+ <label opaque=\"NO\" clipsSubviews=\"YES\" userInteractionEnabled=\"NO\" contentMode=\"left\" horizontalHuggingPriority=\"251\" verticalHuggingPriority=\"251\" misplaced=\"YES\" text=\"\" textAlignment=\"center\" lineBreakMode=\"tailTruncation\" baselineAdjustment=\"alignBaselines\" minimumFontSize=\"9\" translatesAutoresizingMaskIntoConstraints=\"NO\" id=\"8ie-xW-0ye\">
+ <rect key=\"frame\" x=\"20\" y=\"439\" width=\"441\" height=\"21\"/>
+ <fontDescription key=\"fontDescription\" type=\"system\" pointSize=\"17\"/>
+ <color key=\"textColor\" cocoaTouchSystemColor=\"darkTextColor\"/>
+ <nil key=\"highlightedColor\"/>
+ <variation key=\"widthClass=compact\">
+ <fontDescription key=\"fontDescription\" type=\"system\" pointSize=\"11\"/>
+ </variation>
+ </label>
+ <label opaque=\"NO\" clipsSubviews=\"YES\" userInteractionEnabled=\"NO\" contentMode=\"left\" horizontalHuggingPriority=\"251\" verticalHuggingPriority=\"251\" text=\"$$TARGET\"
+ textAlignment=\"center\" lineBreakMode=\"middleTruncation\" baselineAdjustment=\"alignBaselines\" minimumFontSize=\"18\" translatesAutoresizingMaskIntoConstraints=\"NO\" id=\"kId-c2-rCX\">
+ <rect key=\"frame\" x=\"20\" y=\"140\" width=\"441\" height=\"43\"/>
+ <fontDescription key=\"fontDescription\" type=\"boldSystem\" pointSize=\"36\"/>
+ <color key=\"textColor\" cocoaTouchSystemColor=\"darkTextColor\"/>
+ <nil key=\"highlightedColor\"/>
+ </label>
+ </subviews>
+ <color key=\"backgroundColor\" white=\"1\" alpha=\"1\" colorSpace=\"custom\" customColorSpace=\"calibratedWhite\"/>
+ <constraints>
+ <constraint firstItem=\"kId-c2-rCX\" firstAttribute=\"centerY\" secondItem=\"iN0-l3-epB\" secondAttribute=\"bottom\" multiplier=\"1/3\" constant=\"1\" id=\"Kid-kn-2rF\"/>
+ <constraint firstAttribute=\"centerX\" secondItem=\"kId-c2-rCX\" secondAttribute=\"centerX\" id=\"Koa-jz-hwk\"/>
+ <constraint firstAttribute=\"bottom\" secondItem=\"8ie-xW-0ye\" secondAttribute=\"bottom\" constant=\"20\" id=\"Kzo-t9-V3l\"/>
+ <constraint firstItem=\"8ie-xW-0ye\" firstAttribute=\"leading\" secondItem=\"iN0-l3-epB\" secondAttribute=\"leading\" constant=\"20\" symbolic=\"YES\" id=\"MfP-vx-nX0\"/>
+ <constraint firstAttribute=\"centerX\" secondItem=\"8ie-xW-0ye\" secondAttribute=\"centerX\" id=\"ZEH-qu-HZ9\"/>
+ <constraint firstItem=\"kId-c2-rCX\" firstAttribute=\"leading\" secondItem=\"iN0-l3-epB\" secondAttribute=\"leading\" constant=\"20\" symbolic=\"YES\" id=\"fvb-Df-36g\"/>
+ </constraints>
+ <nil key=\"simulatedStatusBarMetrics\"/>
+ <freeformSimulatedSizeMetrics key=\"simulatedDestinationMetrics\"/>
+ <point key=\"canvasLocation\" x=\"404\" y=\"445\"/>
+ </view>
+ </objects>
+</document>
diff --git a/mkspecs/macx-ios-clang/features/default_post.prf b/mkspecs/macx-ios-clang/features/default_post.prf
index 2001f53ec4..51a87e3eab 100644
--- a/mkspecs/macx-ios-clang/features/default_post.prf
+++ b/mkspecs/macx-ios-clang/features/default_post.prf
@@ -184,6 +184,14 @@ macx-xcode {
QMAKE_SUBSTITUTES += copy_image
launch_images.files = $$copy_image.output
QMAKE_BUNDLE_DATA += launch_images
+
+ # Set up default LaunchScreen to support iPhone6/6+
+ launch_screen = LaunchScreen.xib
+ copy_launch_screen.input = $$QMAKESPEC/$$launch_screen
+ copy_launch_screen.output = $$OUT_PWD/$${TARGET}.xcodeproj/$$launch_screen
+ QMAKE_SUBSTITUTES += copy_launch_screen
+ launch_screens.files = $$copy_launch_screen.output
+ QMAKE_BUNDLE_DATA += launch_screens
}
macx-xcode {