-
删除旧的LaunchImage
1.将其中一张启动图先丢到Assets.xcassets
中,删除Assets.xcassets
中的LaunchImage
文件夹;
2.TARGETS -> General -> App Icons and Launch Images -> Launch Screen File -> LaunchScreen
;
3.Build Settings -> Asset Catalog Launch Image Set Name
删除LaunchImage
。
-
LaunchScreen.storyboard设置
1.在view
上添加UIImageView
2.给UIImageView
添加image
,并将Content mode
设置为Aspect Fill
3.设置UIImageView
布局
4.如果你发现启动时启动图没有占到状态栏,那么左侧选中View Controller Scene
,把Extend Edges
-> Under Top Bars
勾选去掉,Transition Style
设置为Cover Vertical
,Presentation
设置为Full Screen