OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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/media_controls/MediaControlsWindowEventListener.h" | 5 #include "modules/media_controls/MediaControlsWindowEventListener.h" |
6 | 6 |
7 #include "core/events/Event.h" | 7 #include "core/events/Event.h" |
8 #include "core/frame/LocalDOMWindow.h" | 8 #include "core/frame/LocalDOMWindow.h" |
9 #include "core/html/shadow/MediaControlElements.h" | |
10 #include "modules/media_controls/MediaControlsImpl.h" | 9 #include "modules/media_controls/MediaControlsImpl.h" |
11 #include "modules/media_controls/elements/MediaControlCastButtonElement.h" | 10 #include "modules/media_controls/elements/MediaControlCastButtonElement.h" |
12 #include "modules/media_controls/elements/MediaControlPanelElement.h" | 11 #include "modules/media_controls/elements/MediaControlPanelElement.h" |
13 #include "modules/media_controls/elements/MediaControlTimelineElement.h" | 12 #include "modules/media_controls/elements/MediaControlTimelineElement.h" |
| 13 #include "modules/media_controls/elements/MediaControlVolumeSliderElement.h" |
14 | 14 |
15 namespace blink { | 15 namespace blink { |
16 | 16 |
17 namespace { | 17 namespace { |
18 | 18 |
19 // Helper returning the top DOMWindow as a LocalDOMWindow. Returns nullptr if it | 19 // Helper returning the top DOMWindow as a LocalDOMWindow. Returns nullptr if it |
20 // is not a LocalDOMWindow. | 20 // is not a LocalDOMWindow. |
21 // This does not work with OOPIF. | 21 // This does not work with OOPIF. |
22 LocalDOMWindow* GetTopLocalDOMWindow(LocalDOMWindow* window) { | 22 LocalDOMWindow* GetTopLocalDOMWindow(LocalDOMWindow* window) { |
23 if (!window->top() || !window->top()->IsLocalDOMWindow()) | 23 if (!window->top() || !window->top()->IsLocalDOMWindow()) |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
114 return; | 114 return; |
115 (*callback_.get())(); | 115 (*callback_.get())(); |
116 } | 116 } |
117 | 117 |
118 DEFINE_TRACE(MediaControlsWindowEventListener) { | 118 DEFINE_TRACE(MediaControlsWindowEventListener) { |
119 EventListener::Trace(visitor); | 119 EventListener::Trace(visitor); |
120 visitor->Trace(media_controls_); | 120 visitor->Trace(media_controls_); |
121 } | 121 } |
122 | 122 |
123 } // namespace blink | 123 } // namespace blink |
OLD | NEW |