Commit 9b3eab8e authored by Michael Thiessen's avatar Michael Thiessen Committed by Commit Bot

Revert "Hide VR Intent Dispatcher from Android Default Browser list."

This reverts commit 3bb7dfb7.

Reason for revert: Breaks other chromium-based browsers.

Original change's description:
> Hide VR Intent Dispatcher from Android Default Browser list.
>
> The Android platform's Default Browser code has a bug where it allows
> the same package to show up multiple times despite not being able to
> differentiate between the multiple components within the package that
> caused it to detect multiple browsers within the package.
>
> We can trick it into thinking the VR intent handling code isn't default
> browser material by providing a wildcard host, making Android think
> the intent handler uses a URI authority when it really doesn't.
>
> Bug: 847921
> Change-Id: I2b271fc1c99495a0e80e301ff432690dd5a2d0a6
> Reviewed-on: https://chromium-review.googlesource.com/1079261
> Reviewed-by: Yaron Friedman <yfriedman@chromium.org>
> Reviewed-by: Ted Choc <tedchoc@chromium.org>
> Commit-Queue: Michael Thiessen <mthiesse@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#574281}

TBR=yfriedman@chromium.org,mthiesse@chromium.org,tedchoc@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: 847921, 867583
Change-Id: I5580c3d43444a177e99f5f57fa93ca725312261d
Reviewed-on: https://chromium-review.googlesource.com/1155068
Commit-Queue: Michael Thiessen <mthiesse@chromium.org>
Reviewed-by: default avatarMichael Thiessen <mthiesse@chromium.org>
Cr-Commit-Position: refs/heads/master@{#579045}
parent dd23bda7
......@@ -434,14 +434,10 @@ by a child template that "extends" this file.
<intent-filter android:priority="-1">
<category android:name="com.google.intent.category.DAYDREAM" />
<!-- Trick Android into thinking this intent filter contains data authorities, and
so cannot serve as the default browser. crbug.com/847921 -->
<data android:host="*" />
{{ self.common_view_intent_shared_filter_body() }}
</intent-filter>
<intent-filter android:priority="-1">
<category android:name="com.google.intent.category.DAYDREAM" />
<data android:host="*" />
{{ self.common_view_intent_shared_filter_with_mime_body() }}
</intent-filter>
<intent-filter android:priority="-1">
......
......@@ -775,7 +775,7 @@ public class ExternalNavigationHandler {
return false;
}
return ExternalNavigationDelegateImpl
.getSpecializedHandlersWithFilter(handlers, appId, intent)
.getSpecializedHandlersWithFilter(handlers, appId, null)
.size()
> 0;
}
......
......@@ -83,7 +83,7 @@ public class WebappTabDelegate extends TabDelegate {
boolean foundSpecializedHandler = false;
for (String result : ExternalNavigationDelegateImpl.getSpecializedHandlersWithFilter(
handlers, null, intent)) {
handlers, null, null)) {
if (result.equals(mApkPackageName)) {
// Current webapk matches, don't intercept so that we can launch a cct. See
// http://crbug.com/831806 for more context.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment