iPhone landscape-only no launch image for iOS7 R4 image asset

19,186

Solution 1

My Solution is Don't use asset catalogs and provide
Default.png (320x480)
[email protected] (640x960)
[email protected] (640x1136)
as bundle in project and iOS will automatically found them
(Apple doesn't have landscape launch image for iPhone or iPod, so we need to provide rotated 90 degree of landscape image)

You may need
Default-Landscape@2x~ipad.png
Default-Landscape~ipad.png
if you do iPad too.

Don't forget to delete fixed launch images name in your Project-Info.plist if you have

Solution 2

The solution that we have found is to update the asset catalog and target only iOS 6 and Prior.

How to do it. Go to the asset catalog. And on the top right corner click on the 'Attribute Inspector' icon. Here you can set the Target OS for the Launch Images. Uncheck the iOS 7 check boxes for iPhone. Now you should be able to see the launch images for these devices.

Solution 3

Not enough rep to add a comment, so I'll post an answer to clarify a couple of things.

I wouldn't recommend remudada's answer as it is a workaround that may not be compatible for future releases, and, it does contain that black border problem. Generally warning are there for a reason.

NAlexN's answer works as it addresses the problem - iOS is looking for a portrait splash screen, but if the portrait button is off - problem. So, keep the portrait button on and add to your viewcontroller the following:

- (NSUInteger)supportedInterfaceOrientations {
    return UIInterfaceOrientationMaskLandscape;
}

Solution 4

I ran into the same problem with my landscape - only application, and here is how I solved it:

  1. Navigate to General tab in your project settings, iPhone Device Orientation section and deselect checkboxes beside Landscape Left and Landscape Right, and select Portrait orientation.
  2. Run the app on iPhone 3.5 or 4 iOS 7 simulator with this settings. The app could crash if you have hardcoded Landscape masks somewhere in your app's view controllers, but it does not matter.
  3. Put checkmarks back for Landscape Left and Landscape Right, but leave Portrait orientation allowed as well. That is you should allow Portrait and both Landscape orientations for iPhone.

Solution 5

I solved it this way: Go to the project settings and select "Don't use Asset Catalog" in the launch images section. Now you can add the launch images the traditional way. You can still use the asset catalog for the app icons and other images

Share:
19,186
Ben Flynn
Author by

Ben Flynn

"I mean, James, the Internet is a place where absolutely nothing happens. You need to take advantage of that." - Strong Bad

Updated on June 02, 2022

Comments

  • Ben Flynn
    Ben Flynn about 2 years

    I'm fairly certain this is a bug, but in case anyone has found a way around this, let me know.

    I've set up an asset catalog in Xcode-5 of launch images. If I set an iOS 7 R4 image it is only used if my app supports portrait orientation. My app is landscape-right only and I do not see the launch image.

    The iOS 5,6 images work just fine, and the R4 iOS 5,6 image will actually load "correctly" if I leave out the iOS 7 R4 image.

    Has anyone been able to get this to work?

    Update

    I've found that I can get iOS 7 landscape images to appear, but only if I remove the default (iOS6) images, which doesn't really help me. If you edit the info.plist and change the image orientation to "Landscape (right home button)" (for example), then provide a horizontal image, it will actually show it on iOS 7 at launch. Unfortunately, if you include an iOS 6 image, it shows that instead. Also, you will not see the iOS 7 image listed in the "General" tab of your target if the orientation is anything other than Portrait. This is with Xcode 5.0 and iOS 7.0.2.