Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(348)

Unified Diff: third_party/WebKit/Source/modules/vr/VRDisplay.cpp

Issue 2317483002: Add support of vrdisplayconnect and vrdisplaydisconnect event (Closed)
Patch Set: Address most comments from bajones@ Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/vr/VRDisplay.cpp
diff --git a/third_party/WebKit/Source/modules/vr/VRDisplay.cpp b/third_party/WebKit/Source/modules/vr/VRDisplay.cpp
index 8ad6ddf665e090a0d4c501baf0322865d6d83a12..c9efd8b7fc0b45bb19d6fa148b231a1a303c5b21 100644
--- a/third_party/WebKit/Source/modules/vr/VRDisplay.cpp
+++ b/third_party/WebKit/Source/modules/vr/VRDisplay.cpp
@@ -79,6 +79,12 @@ void VRDisplay::update(const device::blink::VRDisplayPtr& display)
}
}
+void VRDisplay::disconnected()
+{
+ if (m_isConnected)
+ m_isConnected = !m_isConnected;
+}
+
VRPose* VRDisplay::getPose()
{
if (m_canUpdateFramePose) {

Powered by Google App Engine
This is Rietveld 408576698