OLD | NEW |
(Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "modules/vr/VRDisplayEvent.h" |
| 6 |
| 7 namespace blink { |
| 8 |
| 9 VRDisplayEvent::VRDisplayEvent() |
| 10 { |
| 11 } |
| 12 |
| 13 VRDisplayEvent::VRDisplayEvent(const AtomicString& type, bool canBubble, bool ca
ncelable, VRDisplay* display, String reason) |
| 14 : Event(type, canBubble, cancelable) |
| 15 , m_display(display) |
| 16 , m_reason(reason) |
| 17 { |
| 18 } |
| 19 |
| 20 VRDisplayEvent::VRDisplayEvent(const AtomicString& type, const VRDisplayEventIni
t& initializer) |
| 21 : Event(type, initializer) |
| 22 { |
| 23 if (initializer.hasDisplay()) |
| 24 m_display = initializer.display(); |
| 25 |
| 26 if (initializer.hasReason()) |
| 27 m_reason = initializer.reason(); |
| 28 } |
| 29 |
| 30 VRDisplayEvent::~VRDisplayEvent() |
| 31 { |
| 32 } |
| 33 |
| 34 const AtomicString& VRDisplayEvent::interfaceName() const |
| 35 { |
| 36 return EventNames::VRDisplayEvent; |
| 37 } |
| 38 |
| 39 DEFINE_TRACE(VRDisplayEvent) |
| 40 { |
| 41 visitor->trace(m_display); |
| 42 Event::trace(visitor); |
| 43 } |
| 44 |
| 45 } // namespace blink |
OLD | NEW |