| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "modules/vr/NavigatorVR.h" | 5 #include "modules/vr/NavigatorVR.h" |
| 6 | 6 |
| 7 #include "bindings/core/v8/ScriptPromiseResolver.h" | 7 #include "bindings/core/v8/ScriptPromiseResolver.h" |
| 8 #include "core/dom/DOMException.h" | 8 #include "core/dom/DOMException.h" |
| 9 #include "core/dom/Document.h" | 9 #include "core/dom/Document.h" |
| 10 #include "core/dom/ExceptionCode.h" | 10 #include "core/dom/ExceptionCode.h" |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 101 } | 101 } |
| 102 | 102 |
| 103 void NavigatorVR::fireVRDisplayPresentChange(VRDisplay* display) | 103 void NavigatorVR::fireVRDisplayPresentChange(VRDisplay* display) |
| 104 { | 104 { |
| 105 if (m_frame && m_frame->localDOMWindow()) { | 105 if (m_frame && m_frame->localDOMWindow()) { |
| 106 m_frame->localDOMWindow()->enqueueWindowEvent( | 106 m_frame->localDOMWindow()->enqueueWindowEvent( |
| 107 VRDisplayEvent::create(EventTypeNames::vrdisplaypresentchange, true,
false, display, "")); | 107 VRDisplayEvent::create(EventTypeNames::vrdisplaypresentchange, true,
false, display, "")); |
| 108 } | 108 } |
| 109 } | 109 } |
| 110 | 110 |
| 111 void NavigatorVR::fireVREvent(VRDisplayEvent* event) |
| 112 { |
| 113 if (m_frame && m_frame->localDOMWindow()) { |
| 114 m_frame->localDOMWindow()->enqueueWindowEvent(event); |
| 115 } |
| 116 } |
| 117 |
| 111 } // namespace blink | 118 } // namespace blink |
| OLD | NEW |