OLD | NEW |
| (Empty) |
1 // Copyright 2017 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 #ifndef HTMLMediaElementControlsList_h | |
6 #define HTMLMediaElementControlsList_h | |
7 | |
8 #include "core/dom/DOMTokenList.h" | |
9 #include "platform/heap/Handle.h" | |
10 | |
11 namespace blink { | |
12 | |
13 class HTMLMediaElement; | |
14 | |
15 class HTMLMediaElementControlsList final : public DOMTokenList, | |
16 public DOMTokenListObserver { | |
17 USING_GARBAGE_COLLECTED_MIXIN(HTMLMediaElementControlsList); | |
18 | |
19 public: | |
20 static HTMLMediaElementControlsList* create(HTMLMediaElement* element) { | |
21 return new HTMLMediaElementControlsList(element); | |
22 } | |
23 | |
24 ~HTMLMediaElementControlsList() override; | |
25 | |
26 DECLARE_VIRTUAL_TRACE(); | |
27 | |
28 // Whether the list dictates to hide a certain control. | |
29 bool shouldHideDownload() const; | |
30 bool shouldHideFullscreen() const; | |
31 bool shouldHideRemotePlayback() const; | |
32 | |
33 private: | |
34 explicit HTMLMediaElementControlsList(HTMLMediaElement*); | |
35 bool validateTokenValue(const AtomicString&, ExceptionState&) const override; | |
36 | |
37 // DOMTokenListObserver. | |
38 void valueWasSet() override; | |
39 | |
40 Member<HTMLMediaElement> m_element; | |
41 }; | |
42 | |
43 } // namespace blink | |
44 | |
45 #endif | |
OLD | NEW |