search

Home  >  Q&A  >  body text

用Android Studio Monitor 终止app为什么会返回上一个Activity

我有两个Activity,Activity1 通过Intent启动Activity2,当在Activity2的时候,我用Android Studio Monitor终止这个app,为什么app没有退出,反而是重新打开了Activity1?谢谢

巴扎黑巴扎黑2888 days ago620

reply all(2)I'll reply

  • 天蓬老师

    天蓬老师2017-04-17 17:37:02

    How to terminate the app in Android Studio Monitor? You should just end the current activity. If you want to terminate the app, there are many ways
    Inherit baseActivity, collect avtivity in baseactivity and then end it all
    Or use android.os.Process.killProcess(android.os.Process.myPid());
    or System.exit(0) ;

    reply
    0
  • 巴扎黑

    巴扎黑2017-04-17 17:37:02

    It is estimated that this is an abnormal end and we will help you restart the application

    reply
    0
  • Cancelreply