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 "device/vr/vr_device.h" | 5 #include "device/vr/vr_device.h" |
6 #include "device/vr/vr_device_provider.h" | 6 #include "device/vr/vr_device_provider.h" |
7 #include "device/vr/vr_display_impl.h" | 7 #include "device/vr/vr_display_impl.h" |
8 | 8 |
9 namespace device { | 9 namespace device { |
10 | 10 |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 void VRDevice::OnBlur() { | 62 void VRDevice::OnBlur() { |
63 for (auto* display : displays_) | 63 for (auto* display : displays_) |
64 display->OnBlur(); | 64 display->OnBlur(); |
65 } | 65 } |
66 | 66 |
67 void VRDevice::OnFocus() { | 67 void VRDevice::OnFocus() { |
68 for (auto* display : displays_) | 68 for (auto* display : displays_) |
69 display->OnFocus(); | 69 display->OnFocus(); |
70 } | 70 } |
71 | 71 |
72 void VRDevice::OnActivate(mojom::VRDisplayEventReason reason) { | 72 void VRDevice::OnActivate(mojom::VRDisplayEventReason reason, |
| 73 const base::Callback<void(bool)>& on_handled) { |
73 for (auto* display : displays_) | 74 for (auto* display : displays_) |
74 display->OnActivate(reason); | 75 display->OnActivate(reason, on_handled); |
75 } | 76 } |
76 | 77 |
77 void VRDevice::OnDeactivate(mojom::VRDisplayEventReason reason) { | 78 void VRDevice::OnDeactivate(mojom::VRDisplayEventReason reason) { |
78 for (auto* display : displays_) | 79 for (auto* display : displays_) |
79 display->OnDeactivate(reason); | 80 display->OnDeactivate(reason); |
80 } | 81 } |
81 | 82 |
82 void VRDevice::SetPresentingDisplay(VRDisplayImpl* display) { | 83 void VRDevice::SetPresentingDisplay(VRDisplayImpl* display) { |
83 presenting_display_ = display; | 84 presenting_display_ = display; |
84 } | 85 } |
85 | 86 |
86 } // namespace device | 87 } // namespace device |
OLD | NEW |