| Index: chrome/android/java/src/org/chromium/chrome/browser/vr_shell/VrShellImpl.java
|
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/vr_shell/VrShellImpl.java b/chrome/android/java/src/org/chromium/chrome/browser/vr_shell/VrShellImpl.java
|
| index a6c2d012f4ba28074bfba281d279e47433fcfe0a..f10b515b47eebd54744b2b5f0af976b2f39a58be 100644
|
| --- a/chrome/android/java/src/org/chromium/chrome/browser/vr_shell/VrShellImpl.java
|
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/vr_shell/VrShellImpl.java
|
| @@ -19,7 +19,6 @@ import android.view.SurfaceView;
|
| import android.view.View;
|
| import android.view.ViewTreeObserver.OnPreDrawListener;
|
| import android.widget.FrameLayout;
|
| -import android.widget.FrameLayout.LayoutParams;
|
|
|
| import com.google.vr.ndk.base.AndroidCompat;
|
| import com.google.vr.ndk.base.GvrLayout;
|
| @@ -130,6 +129,11 @@ public class VrShellImpl
|
| mDelegate = delegate;
|
| mTabModelSelector = tabModelSelector;
|
|
|
| + // This overrides the default intent created by GVR to return to Chrome when the DON flow
|
| + // is triggered by resuming the GvrLayout, which is the usual way Daydream apps enter VR.
|
| + // See VrShellDelegate#getEnterVrPendingIntent for why we need to do this.
|
| + setReentryIntent(VrShellDelegate.getEnterVrPendingIntent(activity));
|
| +
|
| mReprojectedRendering = setAsyncReprojectionEnabled(true);
|
| if (mReprojectedRendering) {
|
| // No need render to a Surface if we're reprojected. We'll be rendering with surfaceless
|
| @@ -725,9 +729,9 @@ public class VrShellImpl
|
| public void removeWindowAndroidChangedObserver(WindowAndroidChangedObserver observer) {}
|
|
|
| /**
|
| - * Sets the runnable that will be run when VrShellImpl's dispatchTouchEvent
|
| + * Sets the callback that will be run when VrShellImpl's dispatchTouchEvent
|
| * is run and the parent consumed the event.
|
| - * @param runnable The Runnable that will be run
|
| + * @param callback The Callback to be run.
|
| */
|
| @VisibleForTesting
|
| public void setOnDispatchTouchEventForTesting(OnDispatchTouchEventCallback callback) {
|
|
|