1

他の誰かがこの問題に遭遇したのではないかと思います。ここで、適切な命名とplistへのキーの追加についていくつかのスレッドを読みました。これは、iPhoneとiPadの両方のシミュレーターと、実際のiPhoneデバイスで機能させることができますが、iPadでは機能しません。

これが私が持っているものです:

iPhoneLaunchImage~iPhone.png
iPhoneLaunchImage@2x~iPhone.png

iPadLaunchImage-Portrait~iPad.png
iPadLaunchImage-Portrait@2x~iPad.png
iPadLaunchImage-Landscape~iPad.png
iPadLaunchImage-Landscape@2x~iPad.png

私のMyApp-Info.plistには、次のようなものがあります。

<key>UILaunchImageFile~ipad</key>
<array>
    <string>iPadLaunchImage-Portrait~iPad.png</string>
    <string>iPadLaunchImage-Portrait@2x~iPad.png</string>
    <string>iPadLaunchImage-Landscape~iPad.png</string>
    <string>iPadLaunchImage-Landscape@2x~iPad.png</string>
</array>
<key>UILaunchImageFile~iphone</key>
<string>iPhoneLaunchImage~iPhone.png</string>

また、配列の代わりにiPadの文字列値のみを使用してこれを実行し、

<string>iPadLaunchImage</string>

また、シミュレーターでは機能しましたが、実際のiPadでは機能しませんでした。

助けていただければ幸いです。

4

2 に答える 2

3

In case someone runs across this issue and is as challenged as I was, this is actually very simple. I can't believe I made it so difficult. I simply needed to read carefully the documentation and do exactly as it says.

Create your launch images, as of iOS 5, at least four for the iPad and two for the iPhone. Name your images as follows: (The name I am using is only an example, you can use any you want.)

iPadLaunchImage-Portrait.png
iPadLaunchImage-Portrait@2x.png
iPadLaunchImage-Landscape.png
iPadLaunchImage-Landscape@2x.png

iPhoneLaunchImage.png
iPhoneLaunchImage@2x.png

Make sure you use a distinct name for each device. You have more options available for the iPad, which you can read about in the documentation. Link is provided in the other answer.

Place all of these images in the top of your app's bundle directory. Then all you do is add two keys to YourApp-Info.plist.

Launch Image(iPad) string iPadLaunchImage
Launch Image(iPhone) string iPhoneLaunchImage

That's it. Images will load properly for both devices. Note that in the Info-plist file you don't put the .png, only the base name you used for your images.

于 2012-07-28T01:07:49.117 に答える
1

the following link may be help you

http://developer.apple.com/library/ios/#DOCUMENTATION/iPhone/Conceptual/iPhoneOSProgrammingGuide/App-RelatedResources/App-RelatedResources.html

于 2012-07-26T04:38:22.030 に答える