Index: device/vr/android/gvr/gvr_device_provider.cc |
diff --git a/device/vr/android/gvr/gvr_device_provider.cc b/device/vr/android/gvr/gvr_device_provider.cc |
index cf94fb2d5228869c8cb40c50568a19dd4ca68944..ca9e6973cbe7b1b28bc5bad6e6531459d786890e 100644 |
--- a/device/vr/android/gvr/gvr_device_provider.cc |
+++ b/device/vr/android/gvr/gvr_device_provider.cc |
@@ -56,14 +56,16 @@ void GvrDeviceProvider::Initialize() { |
} |
} |
-bool GvrDeviceProvider::RequestPresent() { |
+void GvrDeviceProvider::RequestPresent( |
+ const base::Callback<void(bool)>& callback) { |
device::GvrDelegateProvider* delegate_provider = |
device::GvrDelegateProvider::GetInstance(); |
if (!delegate_provider) |
- return false; |
+ return callback.Run(false); |
// RequestWebVRPresent is async as a render thread may be created. |
- return delegate_provider->RequestWebVRPresent(weak_ptr_factory_.GetWeakPtr()); |
+ delegate_provider->RequestWebVRPresent(weak_ptr_factory_.GetWeakPtr(), |
+ callback); |
} |
// VR presentation exit requested by the API. |