What exactly do you want to leave from the application?
Scenario 1. If the user completely uninstalled the application from the latest applications (it was interrupted), the next time the user opens the LAUNCHER application (see AndroidManifest.xml ). Therefore, you should make your activity SplashActivity a LAUNCHER .
Scenario 2: the user minimizes the onPause and onStop and possibly onDestroy methods for the current activity. After the user restores the application from retentates (if the action was destroyed, the first onCreate method will be called), then the onStart and onResume life cycle methods will be called. For more information on lifecycle methods, see the docs .
Showing the screen saver every time the user minimizes and restores the application from retentates is not a good idea, so I would recommend sticking to βScenario 1β and showing the screen saver only once β when the user starts the application. But if for some reason you want to show the screen saver every time after the user restores the application, you can check out this tutorial . This can be a bit complicated in Android, since you cannot show it simply onResume or onStart , since these methods will be called not only when restoring the application from retentates, but also when starting this operation.
source share