Joao Birk
10/22/2020, 5:10 PM<navigation
xmlns:android="<http://schemas.android.com/apk/res/android>"
xmlns:app="<http://schemas.android.com/apk/res-auto>"
xmlns:tools="<http://schemas.android.com/tools>"
android:id="@+id/home"
app:startDestination="@id/home_tab">
All the <deeplinks>
are defined in the first navigation_home.xml tab and in the AndroidManifes.xml I have <nav-graph android:value="@navigation/navigation_home"/>
When I build a pendingIntent I do the following:
NavDeepLinkBuilder(context)
.setGraph(R.navigation.navigation_home)
.setDestination(<http://R.id.xxx|R.id.xxx>)
.setArguments(...)
.setComponentName(MainActivity::class.java)
.createPendingIntent()
When I trigger such event I get the following message in the stack:
NavController: Could not find destination xxx:id/home in the navigation graph, ignoring the deep link from Intent
But it does work...it shows the correct page, issue is that the startDestination
fragment gets instantiated TWICE. If I use the regular TaskStackBuilder.create(context)
it works without a problem.
Any hints?
Thank you