为iPad / iPhone加载不同的启动屏幕

时间:2021-03-29 22:51:37

i want to load different launch screen storyboard for iPad and iPhone & for that i add new entry in info.plist like below

我想为iPad和iPhone加载不同的启动画面故事板,为此我在info.plist中添加新条目,如下所示

为iPad / iPhone加载不同的启动屏幕

but it load only iPhone launch screen.

但它只加载iPhone启动画面。

any help will be appreciated. thanks in advance.

任何帮助将不胜感激。提前致谢。

1 个解决方案

#1


22  

Way 1: You have to use two xib's for this. One for iPad and the other one for iPhone. You have to name it as follows,

方式1:你必须使用两个xib。一个用于iPad,另一个用于iPhone。你必须按如下方式命名,

iPhone- LaunchScreen2~iphone.xib

iPad - LaunchScreen2~ipad.xib

iPad - LaunchScreen2~ipad.xib

or

Way2: Open your Info.plist file. Create another entry as UILaunchStoryboardName~ipad and set it to your LaunchScreeniPad.xib.

方式2:打开Info.plist文件。创建另一个条目作为UILaunchStoryboardName~ipad并将其设置为LaunchScreeniPad.xib。

Revert back in case if you face any difficulties

如果您遇到任何困难,请退回

#1


22  

Way 1: You have to use two xib's for this. One for iPad and the other one for iPhone. You have to name it as follows,

方式1:你必须使用两个xib。一个用于iPad,另一个用于iPhone。你必须按如下方式命名,

iPhone- LaunchScreen2~iphone.xib

iPad - LaunchScreen2~ipad.xib

iPad - LaunchScreen2~ipad.xib

or

Way2: Open your Info.plist file. Create another entry as UILaunchStoryboardName~ipad and set it to your LaunchScreeniPad.xib.

方式2:打开Info.plist文件。创建另一个条目作为UILaunchStoryboardName~ipad并将其设置为LaunchScreeniPad.xib。

Revert back in case if you face any difficulties

如果您遇到任何困难,请退回