I successfully use the android: parentActivityName attribute in the manifest to set the parent activity (activity A) when, for example, another action (activity B) is triggered using a push notification. Then, if I return, I will move on to activity A.
However, it does not work with implicit intentions. I have an intent filter declared in the manifest for activity B. When action B is run from outside the application, it does not seem to affect the android: parentActivityName attribute (or the android.support.PARENT_ACTIVITY metadata with lower APIs).
How can I set parent activity in this case?
Manifest block:
<activity
android:name="com.domain.app.activities.ActivityB"
android:screenOrientation="portrait"
android:windowSoftInputMode="stateUnchanged"
android:parentActivityName="com.domain.app.activities.ActivityA" >
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="com.domain.app.activities.ActivityA" />
<intent-filter>
<category android:name="android.intent.category.DEFAULT" />
<action android:name="android.intent.action.VIEW" />
<data android:scheme="http" android:host="domain.com" android:pathPattern=".*" />
</intent-filter>
</activity>
Any help is appreciated.
Thank!