I am launching my Android app, which in turn initializes some state on the first screen. The application has many screens, and after accidentally navigating through some screens I will hide the application using the "Home key". Now, after launching some other applications from the phone, the OS decides that he needs to free my application and, therefore, kill it.
Now, when I click the application icon again, the OS remembers the history and tries to return to the screen, from where I minimized the application. But the problem is that the OS somehow canceled my application, all my states are lost, and the screen may not have any significance.
How do i solve this? How to ensure that the OS calls the launch screen if it has been cleared before and not Activity in the history?
source
share