Android - Build a notification, TaskStackBuilder.addParentStack not working

前端 未结 11 2638
说谎
说谎 2020-11-28 06:23

I\'m trying to launch an activity from a notification like the Android docs explain, but when I open the notification and then press the back button, the HomeActivity (paren

11条回答
  •  情书的邮戳
    2020-11-28 06:44

    Have you looked in the Android documentation, specifically the Notifications API guide. It describes how to do this in detail.

    Notice that if the Activity you start from the notification is not part of the normal Activity flow, then it should not go to the start page of the app; instead, it should go to the Home screen.

提交回复
热议问题