Mismatch attribute noHistory in Android 4.0.3

I use the noHistory = true attribute for actions that I do not want to store on the stack. It works fine on Android 2.3.3, but there is a weird behavior on 4.0.3. When the screen goes to sleep and I woke it up, activity with noHistory = true is gone!

What's going on here? Does the action take place when the screen wakes up? Am I using noHistory incorrectly?

+3
source share
2 answers

I had the same problem today and I found a solution here:

Android: how to return to Activity with the "noHistory" attribute after onStop?

, noHistory true, , , .

noHistory = true xml finish(), :

Intent intent = new Intent();
intent.setClass(this, MainActivity.class);
this.startActivity(intent);
finish();

! , "".

, Android 2.x, , Android v2.x Android v4.x

+2

- , onPause() , .

0

All Articles