I need the following problem to be resolved:
From the UnityPlayerNativeActivity
I am starting a standard Android activity (may be mine, may be with an ad from the ad network - nevermind). When the game is being hidden with this activity on top (not the Unity one) by pressing the home
button, as a user I have two ways of restoring it:
- from the
Recently used apps
screen - the app is being restored to the same state, when it was minimized (that is what I expect to happen); - from the launcher, what causes the game's
UnityPlayerNativeActivity
is being restored with losing all other activities, that have been opened on top of it.
These activities are lost somehow (in a way I don't exactly know, what has happened with them). My game's logic depends on the result of the processes happening there, ie. I need to know, that this particular activity has been exited in any specific way (give a callback for example).
Do you know how I can bring this Unity activity back from launcher with all activities above it, as it was while minimizing it?
I want to understand the difference between the ways of restoring the app from Recently used screen
and the launcher. I guess it is related to the intent-filter section within AndroidManifest.xml
file, which is included within UnityPlayerNativeActivity
entry.