Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS App Launch Image After a Kill

When I kill my iPhone app and relaunch it I have an image of the app's previous state instead of the launch image. How can I force iOS to always show the launch image?

like image 896
DataZombies Avatar asked Jan 04 '14 23:01

DataZombies


1 Answers

To force iOS to launch an app with its default image, call [[UIApplication sharedApplication] ignoreSnapshotOnNextApplicationLaunch]; where you implement state preservation.

From the documentation:

When your app is relaunched, the system displays this snapshot image in place of your app’s default launch image to preserve the notion that your app was still running. If you feel that the snapshot cannot correctly reflect your app’s user interface when your app is relaunched, you can call this method to prevent that snapshot image from being taken. If you do, UIKit uses your app’s default launch image instead.

Also look at this question for more details.

like image 108
Matt Avatar answered Oct 07 '22 02:10

Matt