Hi Rob,
hm, it seems I just cannot get the problem across, maybe the language barrier, I’m German after all.
I just try to use different arguments:
- Why it seemed to work for you
I think it worked for you when you wrote the tutorial, but when you tested it I guess you still had the “UILaunchImages” in your build.settings - you only removed this one day later after some comments to the tutorial.
And because of the “UILaunchImages” where you referenced “Splash.png”, “Splash@2x.png” and “Splash@3x.png” these images were shown on your devices. But the information to display these splash screens were NOT taken from the .nib file, because in there no reference to these files is set.
- Developer feedback
I’m not the only one in this threat encountering this, look at the postings from newbieLUA, Studycat, hgbrian…
- Cold logic
Assumptions:
* You want to use “Splash.png”, “Splash@2x.png” and “Splash@3x.png” as your splash screens
* You do NOT set “UILaunchImages” in your build.settings - so there is NO reference in build.settings to these files in your project
* The only things you’ll finally copy into your app project folder are the mentioned splash screens and the LaunchScreen.nib file
So, cold logic dictates that in the LaunchScreen.nib file there HAS to be a reference to the splash screens “Splash.png” etc. inside, otherwise iOS 8 can not know that these images should be used. Agreed?
The LaunchScreen.nib file is compiled using ibtool --compile LaunchScreen.nib LaunchScreen.xib - this will do nothing else but take the LaunchScreen.xib file and convert it to a file that can be loaded at runtime, NOTHING IS ADDED, only the format is changed.
Deduction:
If you need to have a reference to the splash screens “Splash.png” etc. this reference HAS to be in the LaunchScreen.xib file.
Now have a look at the tutorial and create a LaunchScreen.xib file just as it is described there, and concentrate especially on these steps:
- Create three images which will be centered on the screen of various devices. You’ll need a 1×, 2×, and 3× version — these images don’t need to match specific sizes, but they will be shrunk or stretched to fit the UIImageView while maintaining the original aspect ratio.
- In the central pane, look for the AppIcon entry, right-click it, and choose New Image Set.
- From the Finder, drag the file for your 1× splash image to the 1× slot, your 2× splash image file to the 2× slot and your 3× splash image file to the 3× slot.
By doing this you create a new image set called “Image” and use it in the following steps.
Now look at the LaunchScreen.xib file that is created at the end, e.g. open it in “Sublime 2”:
_There are only two references to the “Image” image set inside, but there is absolutely NO reference to the “Splash” images in the XML. _Interface Builder did not care to write the names of the files “Splash.png”, “Splash@2x.png” and “Splash@3x.png” you dragged into the project into the LaunchScreen.xib file.
So in the end you do NOT have a reference to your splash screen files in the LaunchScreen.xib file, and in the compiled LaunchScreen.nib file therefore there won’t be a reference inside, too, and the result is that iOS 8 will not know that the splash images based on “Splash.png” should be displayed.
But the solution is easy as I pointed out a two postings above:
Just rename the image set “Image” in IB to “Splash” and the use “Splash” in step 10 of the tutorial.
After this you have the reference “Splash” in the LaunchScreen.xib file and everything will work, the files “Splash.png”, “Splash@2x.png” and “Splash@3x.png” will be displayed on launch.
I hope this gives a clearer picture,
best,
Andreas