I am having a problem where the back stack is lost after you background an activity. I am already using "android:alwaysRetainTaskState="true" but that doesn't seem to fix my problem.
MainActivity->SomeActivity.
Send SomeActivity to background. Select SomeActivity from window list.
Back button does not go to MainActivity. It goes to the home screen.
How do I make it go back to MainActivity?
Intent i = new Intent(self, SomeActivity.class);
i.putExtra("launch", 1);
startActivity(i);
It will go back to MainActivity if the application is never background-ed.