问题
My Device and Simulator seem to be caching the launch screen for my app!
I have deleted the original Launch Screen.storyboard and created my own XIB and swift files called "StartingPointView.xib" and "StartingPointView.Swift". The XIB file contains a view with Blue background color. It is also linked in the Xcode project settings under app icon and launch images.
So far everything seems fine, but when I change the color of the StartingPointView's view to say Yellow, the app continues to launch with a Blue screen and then flash a yellow screen.
Where is the blue coming from? (Note: I have no other blue screens in any of my UI and I tried running clean and clean build folder)
回答1:
This issue is directly related to rdar://24618582 "Xcode 7.2.1: Cached Launch Screen Does Not Update" which has existed since iOS 9.
The only workaround that I've found is to completely remove and re-install your application. I know this isn't really viable solution, but is the best that I can provide (besides restarting the device) until Apple fixes this runtime issue.
来源:https://stackoverflow.com/questions/39500354/ios-10-launch-screen-bug