问题
I have got an app developed for iPhone family only, and I used to run it on iPad to test how it will look on iPhone 4s (since it launched with iPhone 4s resolution, size, and else '2x' round button for fullscreen support). However, now when I run it on my iPad with iOS 8, Xcode ignores all build settings and runs it as for iPad. My storyboard constraints were not projected for iPad screen.
I have:
Devicesoption set toiPhoneon General tab in project settingsMain storyboard file nameandMain storyboard file nameare removed fromInfo-plist- All App Icons and Launch Images for iPad are deleted
- In
Launch Screen Filethe optionUse Size Classesset toNO, and the assets are generated for iPhone only
Is that a normal behavior? I want to use my iPad as before to test iPhone 4s resolution. I am sure that my app won't become universal because of that, but nevertheless I think this is a problem.
回答1:
The use of Launch Screen File in iOS 8.0, 8.0.1 and 8.0.2 will make you universal.
This is a know bug and fixed in iOS 8.1, for you only option is to use assets catalog with a launch images.
Or you can add the device modifier in the Launch file name, like <launchNib>~iphone.nib
来源:https://stackoverflow.com/questions/26280652/iphone-app-compiled-with-xcode-6-on-runs-as-universal-on-ipad