Android - 设置应用的默认“打开支持的链接”选项

问题描述

如何将我的 Android 应用程序的Open supported links 控制为 Ask every timeOpen in this app?它是否发生在清单中?

我有两个应用尝试接受相同的通用链接方案,理想的行为是让用户在点击链接时决定打开哪个应用。但是,似乎第一个应用程序正确地将设置中的 Open supported links 设置为 Ask every time,而另一个应用程序将 Open supported links 设置为 Open in this app。因此,当两个应用程序都安装时,只会立即打开第二个应用程序,而第一个应用程序甚至不会提示

两个 AndroidManifest.xml 文件中接受通用链接的部分几乎相同。

<intent-filter android:autoVerify="true">
    <action android:name="android.intent.action.VIEW" />
    <category android:name="android.intent.category.DEFAULT" />
    <category android:name="android.intent.category.broWSABLE" />
    <data android:host="foo.bar.com" android:pathPrefix="/action/" android:scheme="https" />
</intent-filter>

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)