Chromium Code Reviews| Index: Source/core/html/shadow/MediaControlElementTypes.h |
| diff --git a/Source/core/html/shadow/MediaControlElementTypes.h b/Source/core/html/shadow/MediaControlElementTypes.h |
| index d44f5bc89b903b27e18ef0d998c7f1e8a0470833..dc56cac60caa1edb8622b4ed37e4b681359ab2aa 100644 |
| --- a/Source/core/html/shadow/MediaControlElementTypes.h |
| +++ b/Source/core/html/shadow/MediaControlElementTypes.h |
| @@ -33,11 +33,13 @@ |
| #include "core/html/HTMLDivElement.h" |
| #include "core/html/HTMLInputElement.h" |
| #include "core/html/HTMLMediaElement.h" |
| -#include "core/html/MediaControllerInterface.h" |
| #include "core/rendering/RenderBlock.h" |
| namespace WebCore { |
| +class HTMLMediaElement; |
| +class MediaControllerInterface; |
| + |
| enum MediaControlElementType { |
| MediaEnterFullscreenButton = 0, |
| MediaMuteButton, |
| @@ -78,17 +80,17 @@ public: |
| MediaControlElementType displayType() { return m_displayType; } |
| - void setMediaController(MediaControllerInterface* controller) { m_mediaController = controller; } |
| - MediaControllerInterface* mediaController() const { return m_mediaController; } |
| - |
| protected: |
| - explicit MediaControlElement(MediaControlElementType, HTMLElement*); |
| + explicit MediaControlElement(HTMLMediaElement&, MediaControlElementType, HTMLElement*); |
|
acolwell GONE FROM CHROMIUM
2014/03/12 00:22:32
Drop explicit since this isn't a 1 arg constructor
philipj_slow
2014/03/12 04:30:11
Done.
|
| ~MediaControlElement() { } |
| void setDisplayType(MediaControlElementType); |
| + MediaControllerInterface& mediaControllerInterface() const; |
| + |
| + HTMLMediaElement& m_mediaElement; |
|
acolwell GONE FROM CHROMIUM
2014/03/12 00:22:32
Why does this need to be protected instead of priv
philipj_slow
2014/03/12 04:30:11
Oops, that was needed for a following patch, but I
|
| + |
| private: |
| - MediaControllerInterface* m_mediaController; |
| MediaControlElementType m_displayType; |
| HTMLElement* m_element; |
| }; |
| @@ -98,7 +100,7 @@ private: |
| class MediaControlDivElement : public HTMLDivElement, public MediaControlElement { |
| protected: |
| virtual bool isMediaControlElement() const OVERRIDE FINAL { return true; } |
| - explicit MediaControlDivElement(Document&, MediaControlElementType); |
| + explicit MediaControlDivElement(HTMLMediaElement&, MediaControlElementType); |
|
acolwell GONE FROM CHROMIUM
2014/03/12 00:22:32
nit: drop explicit here and other cases of non-sin
philipj_slow
2014/03/12 04:30:11
Done.
|
| }; |
| // ---------------------------- |
| @@ -106,7 +108,7 @@ protected: |
| class MediaControlInputElement : public HTMLInputElement, public MediaControlElement { |
| protected: |
| virtual bool isMediaControlElement() const OVERRIDE FINAL { return true; } |
| - explicit MediaControlInputElement(Document&, MediaControlElementType); |
| + explicit MediaControlInputElement(HTMLMediaElement&, MediaControlElementType); |
| private: |
| virtual void updateDisplayType() { } |
| @@ -121,7 +123,7 @@ public: |
| double currentValue() const { return m_currentValue; } |
| protected: |
| - explicit MediaControlTimeDisplayElement(Document&, MediaControlElementType); |
| + explicit MediaControlTimeDisplayElement(HTMLMediaElement&, MediaControlElementType); |
| private: |
| double m_currentValue; |