问题描述:

Fellow SO'ers,

I'm using the Xcode Assets file for handling my splash screens and icons. The assets file has a way of organising iOS version specific splash screens. I designed a different splash screen for iOS 7 in retina and 4" retina so that it corresponds well with the views that come after the splash.

However, I'm using a UIImageView to the splash screen displaying a tad longer because the app will download some files from the internet. Whenever I use

[UIImage imageNamed:]

it returns the iOS 5/6 version of the image when ran on the iOS 7 simulator. How can I make sure that whenever I select an image like this from the Assets file that it returns the right version of the image?

Thanks in advance!

网友答案:

There's no way to automatically specify some identifier for iOS 6/7. Your best bet is to check which version you're on at runtime and load differently named images, based on that.

相关阅读:
Top