简体   繁体   中英

iOS - 3.5“ layout instead of 4” layout on device - works fine on simulator

I have XCode 6 project built with target OS as iOS 8.1 (I don't see earlier target in XCode).

All my view controllers are designed for iPhone 4 inch size. I see correct size when I launch my app on simulator (iOS 8).

However I get iPhone 3.5 inch layout on my iPhone 5C (4") - running iOS 7.1.1 - no matter what changes I make to storyboard. I tried changing storyboard settings like IB version to iOS 7.1 and later and so on, but to no avail.

The app runs totally fine, except that the top & bottom spaces appear black on my device - total height = 480 instead of 568.

What can be the reason?

The solution - as suggested by a kindred spirit on Apple forum:

  • Include a 4" launch image to the asset catalog
  • Clean up the project, delete derived data, delete the app from device
  • Re-Run the app on device.
  • 320 X 568 screen is there...woohoo....

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM