Chromium Code Reviews| Index: third_party/WebKit/Source/modules/mediasession/NavigatorMediaSession.h |
| diff --git a/third_party/WebKit/Source/modules/mediasession/NavigatorMediaSession.h b/third_party/WebKit/Source/modules/mediasession/NavigatorMediaSession.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..e7656a1e877a0094337bfa73faad61580b982c52 |
| --- /dev/null |
| +++ b/third_party/WebKit/Source/modules/mediasession/NavigatorMediaSession.h |
| @@ -0,0 +1,37 @@ |
| +// Copyright 2016 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef NavigatorMediaSession_h |
| +#define NavigatorMediaSession_h |
| + |
| +#include "core/frame/DOMWindowProperty.h" |
|
mlamouri (slow - plz ping)
2016/10/10 20:30:35
Do you need this include?
Zhiqiang Zhang (Slow)
2016/10/11 10:56:04
Removed.
|
| +#include "core/frame/Navigator.h" |
| +#include "modules/mediasession/MediaSession.h" |
| +#include "platform/Supplementable.h" |
| + |
| +namespace blink { |
| + |
| +class Navigator; |
| + |
| +class NavigatorMediaSession final |
|
whywhat
2016/10/10 20:45:10
nit: don't forget to write comments to new classes
Zhiqiang Zhang (Slow)
2016/10/11 10:56:04
Done.
|
| + : public GarbageCollected<NavigatorMediaSession>, |
| + public Supplement<Navigator> { |
| + USING_GARBAGE_COLLECTED_MIXIN(NavigatorMediaSession); |
| + |
| + public: |
| + static NavigatorMediaSession& from(Navigator&); |
| + static MediaSession* mediaSession(Navigator&); |
| + |
| + DECLARE_TRACE(); |
| + |
| + private: |
| + NavigatorMediaSession(Navigator&); |
| + static const char* supplementName(); |
| + |
| + Member<MediaSession> m_session; |
| +}; |
| + |
| +} // namespace blink |
| + |
| +#endif // NavigatorMediaSession_h |