add deeplink to rpi information screen

CCTG could use this when interacting with external microG. Instead of
directly embedding the fragment through the bottomNavigationBar we can
at least jump to the correct target location. Doing this through an
implicit deeplink intent seems easiest as an explicit intent adds all
the top level nav elements to the backstack
(see: https://developer.android.com/guide/navigation/navigation-deep-link).

Tested and this works pretty nicely :).
This commit is contained in:
Marcus Hoffmann 2021-03-08 00:46:53 +01:00 committed by Marvin W
parent c9e09e9714
commit ff1f879ab6
2 changed files with 12 additions and 1 deletions

View File

@ -448,6 +448,13 @@
android:label="@string/gms_settings_name"
android:process=":ui"
android:roundIcon="@mipmap/ic_microg_settings">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<data
android:host="exposure-notifications-rpis"
android:scheme="x-gms-settings" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />

View File

@ -26,7 +26,11 @@
<fragment
android:id="@+id/exposureNotificationsRpisFragment"
android:name="org.microg.gms.nearby.core.ui.ExposureNotificationsRpisFragment"
android:label="@string/pref_exposure_collected_rpis_title" />
android:label="@string/pref_exposure_collected_rpis_title">
<deepLink
app:action="ACTION_VIEW"
app:uri="x-gms-settings://exposure-notifications-rpis" />
</fragment>
<fragment
android:id="@+id/exposureNotificationsAppFragment"