Chromium Code Reviews| Index: chrome/android/java/AndroidManifest.xml |
| diff --git a/chrome/android/java/AndroidManifest.xml b/chrome/android/java/AndroidManifest.xml |
| index 189d816d37a066dbb3b6143fceb8c3c1d05817e7..ec4c1eb91404dd3d6afc71924d2fef98de15acde 100644 |
| --- a/chrome/android/java/AndroidManifest.xml |
| +++ b/chrome/android/java/AndroidManifest.xml |
| @@ -53,7 +53,8 @@ by a child template that "extends" this file. |
| <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> |
| <uses-permission android:name="android.permission.WRITE_SYNC_SETTINGS"/> |
| {% set enable_vr_shell = enable_vr_shell|default(0) %} |
| - {% if enable_vr_shell == "true" %} |
| + {% set enable_webvr = enable_webvr|default(0) %} |
| + {% if enable_vr_shell == "true" or enable_webvr == "true" %} |
| <!-- Required to read the paired viewer's distortion parameters. --> |
| <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/> |
| <!-- Indicates use of Android's VR-mode, available only on Android N+. --> |
| @@ -347,29 +348,48 @@ by a child template that "extends" this file. |
| <!-- ChromeTabbedActivity related --> |
| <activity android:name="org.chromium.chrome.browser.ChromeTabbedActivity" |
| - android:theme="@style/TabbedModeTheme" |
| - android:exported="false" |
| - android:windowSoftInputMode="adjustResize" |
| - android:launchMode="singleTask" |
| - android:configChanges="orientation|keyboardHidden|keyboard|screenSize|mcc|mnc|screenLayout|smallestScreenSize" |
| - android:hardwareAccelerated="false"> |
| - {% set enable_webvr = enable_webvr|default(0) %} |
| - {% if enable_vr_shell == "true" or enable_webvr == "true" %} |
| + android:theme="@style/TabbedModeTheme" |
| + android:exported="false" |
| + android:windowSoftInputMode="adjustResize" |
| + android:launchMode="singleTask" |
| + android:configChanges="orientation|keyboardHidden|keyboard|screenSize|mcc|mnc|screenLayout|smallestScreenSize" |
| + android:hardwareAccelerated="false"> |
| + <!-- |
| + See the VRChromeTabbedActivity alias below for an explanation of this dummy intent |
| + filter. We need to add these filters here as well, or non-presenting webVR pages will |
| + trigger a daydream incompatible app message. |
| + --> |
| <intent-filter> |
| - <!-- Add a dummy action to match intent without any action. --> |
| <action android:name="org.chromium.chrome.browser.dummy.action" /> |
| - <!-- |
| - Daydream api categorizes an activity to three categories: Cardboard only, hybrid |
| - or Daydream. It does so by testing if intents can be resolved by the activity |
| - that requests it. |
| - In Chrome, CTA is the activity that uses Daydream api and we want to be in hybrid |
| - category. So add an intent filter that could pass Daydream tests here. |
| - --> |
| <category android:name="com.google.intent.category.DAYDREAM" /> |
| <category android:name="com.google.intent.category.CARDBOARD" /> |
| </intent-filter> |
| - {% endif %} |
| </activity> |
| + |
| + {% if enable_vr_shell == "true" or enable_webvr == "true" %} |
| + <!-- |
| + TODO(mthiesse): Temporarily skip ChromeLauncherActivity when returning from Daydream |
| + DON flow to avoid polluting metrics. |
| + --> |
| + <activity-alias android:name="org.chromium.chrome.browser.VRChromeTabbedActivity" |
| + android:targetActivity="org.chromium.chrome.browser.ChromeTabbedActivity" |
| + android:exported="true" |
|
Ted C
2016/11/16 18:07:00
Sorry, but I don't think we can/should do this.
B
mthiesse
2016/11/16 18:45:12
Ah, yes thanks for pointing that out. I've switche
|
| + android:enableVrMode="@string/gvr_vr_mode_component"> |
| + <!-- |
| + Daydream api categorizes an activity to three categories: Cardboard only, hybrid |
| + or Daydream. It does so by testing if intents can be resolved by the activity |
| + that requests it. |
| + In Chrome, CTA is the activity that uses Daydream api and we want to be in hybrid |
| + category. So add an intent filter that could pass Daydream tests here. |
| + --> |
| + <intent-filter> |
| + <action android:name="org.chromium.chrome.browser.dummy.action" /> |
| + <category android:name="com.google.intent.category.DAYDREAM" /> |
| + <category android:name="com.google.intent.category.CARDBOARD" /> |
| + </intent-filter> |
| + </activity-alias> |
| + {% endif %} |
| + |
| <activity android:name="org.chromium.chrome.browser.ChromeTabbedActivity2" |
| android:theme="@style/TabbedModeTheme" |
| android:exported="false" |