muzei-api / com.google.android.apps.muzei.api / MuzeiContract / Sources / createChooseProviderIntent

createChooseProviderIntent

@JvmStatic fun createChooseProviderIntent(authority: String): Intent

Deep link into Muzei's Sources screen, automatically scrolling to the com.google.android.apps.muzei.api.provider.MuzeiArtProvider associated with the given authority. If Muzei is not yet activated, users will be asked to activate Muzei before continuing onto the Sources screen.

Note that users must still manually select your MuzeiArtProvider.

It is strongly recommended in cases where you receive an android.content.ActivityNotFoundException (due to the user having an older version of Muzei installed or if Muzei is not installed at all) to fall back on:

  1. android.content.pm.PackageManager.getLaunchIntentForPackage with Muzei's package name, net.nurik.roman.muzei to open Muzei and navigate to the Sources screen themselves.
  2. A link to the Google Play Store with Muzei's package name so that user can install Muzei.