Android: Clear the back stack

前端 未结 30 2194
被撕碎了的回忆
被撕碎了的回忆 2020-11-22 06:47

In Android I have some activities, let\'s say A, B, C.

In A, I use this code to open B:

Intent intent = new Intent(this, B.class);
startActivity(inte         


        
30条回答
  •  执笔经年
    2020-11-22 07:24

    What about adding in manifests file for related activity :

    android:noHistory="true"
    

    to the activity definition of B and C ? They will not be added to the backstack. Not sure if that is what you want.

提交回复
热议问题