#ifndef MediaControlElements_h
#define MediaControlElements_h
#include "core/html/shadow/MediaControlElementTypes.h"
namespace WebCore {
class MediaControlPanelElement FINAL : public MediaControlDivElement {
public:
static PassRefPtr<MediaControlPanelElement> create(MediaControls&);
void setIsDisplayed(bool);
void makeOpaque();
void makeTransparent();
private:
explicit MediaControlPanelElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
virtual void defaultEventHandler(Event*) OVERRIDE;
void startTimer();
void stopTimer();
void transitionTimerFired(Timer<MediaControlPanelElement>*);
bool m_isDisplayed;
bool m_opaque;
Timer<MediaControlPanelElement> m_transitionTimer;
};
class MediaControlPanelEnclosureElement FINAL : public MediaControlDivElement {
public:
static PassRefPtr<MediaControlPanelEnclosureElement> create(MediaControls&);
private:
explicit MediaControlPanelEnclosureElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
};
class MediaControlOverlayEnclosureElement FINAL : public MediaControlDivElement {
public:
static PassRefPtr<MediaControlOverlayEnclosureElement> create(MediaControls&);
private:
explicit MediaControlOverlayEnclosureElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
};
class MediaControlMuteButtonElement FINAL : public MediaControlInputElement {
public:
static PassRefPtr<MediaControlMuteButtonElement> create(MediaControls&);
virtual bool willRespondToMouseClickEvents() OVERRIDE { return true; }
virtual void updateDisplayType() OVERRIDE;
private:
explicit MediaControlMuteButtonElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
virtual void defaultEventHandler(Event*) OVERRIDE;
};
class MediaControlPlayButtonElement FINAL : public MediaControlInputElement {
public:
static PassRefPtr<MediaControlPlayButtonElement> create(MediaControls&);
virtual bool willRespondToMouseClickEvents() OVERRIDE { return true; }
virtual void updateDisplayType() OVERRIDE;
private:
explicit MediaControlPlayButtonElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
virtual void defaultEventHandler(Event*) OVERRIDE;
};
class MediaControlOverlayPlayButtonElement FINAL : public MediaControlInputElement {
public:
static PassRefPtr<MediaControlOverlayPlayButtonElement> create(MediaControls&);
virtual void updateDisplayType() OVERRIDE;
private:
explicit MediaControlOverlayPlayButtonElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
};
class MediaControlToggleClosedCaptionsButtonElement FINAL : public MediaControlInputElement {
public:
static PassRefPtr<MediaControlToggleClosedCaptionsButtonElement> create(MediaControls&);
virtual bool willRespondToMouseClickEvents() OVERRIDE { return true; }
virtual void updateDisplayType() OVERRIDE;
private:
explicit MediaControlToggleClosedCaptionsButtonElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
virtual void defaultEventHandler(Event*) OVERRIDE;
};
class MediaControlTimelineElement FINAL : public MediaControlInputElement {
public:
static PassRefPtr<MediaControlTimelineElement> create(MediaControls&);
virtual bool willRespondToMouseClickEvents() OVERRIDE;
void setPosition(double);
void setDuration(double);
private:
explicit MediaControlTimelineElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
virtual void defaultEventHandler(Event*) OVERRIDE;
};
class MediaControlFullscreenButtonElement FINAL : public MediaControlInputElement {
public:
static PassRefPtr<MediaControlFullscreenButtonElement> create(MediaControls&);
virtual bool willRespondToMouseClickEvents() OVERRIDE { return true; }
void setIsFullscreen(bool);
private:
explicit MediaControlFullscreenButtonElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
virtual void defaultEventHandler(Event*) OVERRIDE;
};
class MediaControlVolumeSliderElement FINAL : public MediaControlInputElement {
public:
static PassRefPtr<MediaControlVolumeSliderElement> create(MediaControls&);
virtual bool willRespondToMouseMoveEvents() OVERRIDE;
virtual bool willRespondToMouseClickEvents() OVERRIDE;
void setVolume(double);
private:
explicit MediaControlVolumeSliderElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
virtual void defaultEventHandler(Event*) OVERRIDE;
};
class MediaControlTimeRemainingDisplayElement FINAL : public MediaControlTimeDisplayElement {
public:
static PassRefPtr<MediaControlTimeRemainingDisplayElement> create(MediaControls&);
private:
explicit MediaControlTimeRemainingDisplayElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
};
class MediaControlCurrentTimeDisplayElement FINAL : public MediaControlTimeDisplayElement {
public:
static PassRefPtr<MediaControlCurrentTimeDisplayElement> create(MediaControls&);
private:
explicit MediaControlCurrentTimeDisplayElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
};
class MediaControlTextTrackContainerElement FINAL : public MediaControlDivElement {
public:
static PassRefPtr<MediaControlTextTrackContainerElement> create(MediaControls&);
void updateDisplay();
void updateSizes();
static const AtomicString& textTrackContainerElementShadowPseudoId();
private:
explicit MediaControlTextTrackContainerElement(MediaControls&);
virtual const AtomicString& shadowPseudoId() const OVERRIDE;
virtual RenderObject* createRenderer(RenderStyle*) OVERRIDE;
IntRect m_videoDisplaySize;
float m_fontSize;
};
}
#endif