WAPG3 Xcode 7.2的启动页设置(LaunchScreen.storyboard)

记得上一个版本,我只添加了一个Image set,名为LaunchImage,然后往里面添加了对应尺寸的启动图,现在在Xcode 7.2下好像不行了,添加后然后在设置里设置了APP启动也没啥用,我的测试机是iPhone 6 plus,iOS 9.2的系统


后来查获得了如下信息:

“开发过程中遇到同样的问题,研究了一下苹果文档 总结为如下:
1.旧方式:Launch Images Source 添加启动图,Launch Screen File 中删掉“LaunchScreen”,置为空;
2.新方式:Launch Images Source 中不需要添加启动图,Launch Screen File 为“ LaunchScreen”(默认),LaunchScreen.storyboard添加imageView,imageView上放图片,工程中要有对应的 750*1334 的@2x图,1242 * 2208的@3x图 ”

照着做确实能显示启动图片,不过这就有个问题了,为什么苹果要搞两种方式设置启动图,到底用哪个?其实不止我一个人有这个问题,老外也有:

“Unfortunately, if your app is also targeting older versions of iOS (even iOS 7), you'll have no other option than also including launch images for all iPhone devices (except iPhone 6, which doesn't run these versions of iOS, obviously). This is a pain, but Apple made the right move by providing this new feature for future developments.”

也就是说如果你要支持iOS 8.0以前的版本,比如iOS 7.1,那就必须包含LaunchImage Asset,否则,只需要像在APP中使用图片一样,添加一个2x和3x图片在LaunchScreen.storyboard添加的imageView中展示就可以。

希望理解没有偏差


参考资料:

1.主题 : Xcode7中如何使用LaunchScreen.storyboard:http://www.cocoachina.com/bbs/read.php?tid-326916.html

2.Launch image or launch xib / storyboard?:http://stackoverflow.com/questions/27998284/launch-image-or-launch-xib-storyboard

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值