Search code examples
objective-ccocos2d-iphoneios8

iOS app with iphone target only (non-universal) renders fine on ipad iOS7 but not on ipad iOS8


When I run my targeted iphone app on an ipad with iOS7, it renders in iphone mode and this is exactly what I want. In fact, when I print the size of the window bounds, it correctly prints out 320 x 480. However, when I run the same app on an ipad with iOS8, the app goes into full screen mode as the window bounds are now 1024 x 768.

Do you know how I can restrict the iOS8 ipad to render the app as an iphone only app and not a full screen ipad app?

NOTE: I did my testing on the same iPad device before and after the upgrade from iOS7 to iOS8. I'm also consistently able to repro this with the ipad simulators


Solution

  • This might be caused from a known bug in XCODE-6 that is fixed in XCODE-6.1 beta. If you are using the storyboard launch file, the iOS 8 iPad will not be scaled from iPhone mode, but will be treated as an actual iPad. To fix the bug, use static launch images by hitting use asset catalog on the following screen in the target options, general tab: picture of use asset catalog button

    After this, make sure to have your static launch images uploaded to the .xcassets, or update to xcode 6.1 beta to fix the issue.