tuyafeng / Via

Via is a simple browser, and this repository is set for localization.
3.09k stars 327 forks source link

[Bug]未处理的 `intent:` 和 `android-app://` 链接 (Unhandled `intent:` and `android-app://` links) #1165

Open AyakaAgo opened 2 years ago

AyakaAgo commented 2 years ago

未处理的 intent: 链接

某些网站使用 intent:android-app:// 链接跳转到自己的应用,比如 Google 账号

Google 账号

点击“让您的账号安全无虞”,将跳转到类似如下的 intent: 链接:

intent:#Intent;package=com.google.android.gms;action=com.google.android.gms.accountsettings.action.BROWSE_SETTINGS;end

另外是 android-app:// 的说明:Intent#URI_ANDROID_APP_SCHEME(包括一些 intent: 链接的说明)。

我们可以使用 Intent#parseUri(String uri, int flags) 来解析这两种链接。


Unhandled intent: url

Some sites use intent: or android-app:// links to jump to their apps, such as Google Accounts.

Google Account

Clicking on "Your Account is protected" will take you to an intent: link similar to the following:

intent:#Intent;package=com.google.android.gms;action=com.google.android.gms.accountsettings.action.BROWSE_SETTINGS;end

The other is android-app://: Intent#URI_ANDROID_APP_SCHEME (including some intent: description)

We can use Intent#parseUri(String uri, int flags) to parse these links.

tuyafeng commented 1 year ago

十分感谢你的指正,后续会优化该部分。