Wednesday, February 18, 2015

handling back on notification activities

below is right thing to do:
You need to add the parent stack for the activity you're launching, not the parent of it.
Replace:
stackBuilder.addParentStack(MainActivity.class);
with:
stackBuilder.addParentStack( MatchActivity.class );
This assumes that you've defined the parent in your Manifest (API 16+):
<activity android:name=".MatchActivity"
    android:parentActivityName=".MainActivity"
    ... />

No comments:

Post a Comment