Remove shadowPseudoId() override from the shadow media controls
authorbenjamin@webkit.org <benjamin@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 1 Aug 2014 03:42:47 +0000 (03:42 +0000)
committerbenjamin@webkit.org <benjamin@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 1 Aug 2014 03:42:47 +0000 (03:42 +0000)
https://bugs.webkit.org/show_bug.cgi?id=135474

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-07-31
Reviewed by Eric Carlson.

Small cleanup.

* html/shadow/MediaControlElementTypes.h:
* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlPanelElement::MediaControlPanelElement):
(WebCore::MediaControlPanelEnclosureElement::MediaControlPanelEnclosureElement):
(WebCore::MediaControlOverlayEnclosureElement::MediaControlOverlayEnclosureElement):
(WebCore::MediaControlTimelineContainerElement::MediaControlTimelineContainerElement):
(WebCore::MediaControlVolumeSliderContainerElement::MediaControlVolumeSliderContainerElement):
(WebCore::MediaControlStatusDisplayElement::MediaControlStatusDisplayElement):
(WebCore::MediaControlPanelMuteButtonElement::MediaControlPanelMuteButtonElement):
(WebCore::MediaControlVolumeSliderMuteButtonElement::MediaControlVolumeSliderMuteButtonElement):
(WebCore::MediaControlPlayButtonElement::MediaControlPlayButtonElement):
(WebCore::MediaControlOverlayPlayButtonElement::MediaControlOverlayPlayButtonElement):
(WebCore::MediaControlSeekForwardButtonElement::MediaControlSeekForwardButtonElement):
(WebCore::MediaControlSeekBackButtonElement::MediaControlSeekBackButtonElement):
(WebCore::MediaControlRewindButtonElement::MediaControlRewindButtonElement):
(WebCore::MediaControlReturnToRealtimeButtonElement::MediaControlReturnToRealtimeButtonElement):
(WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
(WebCore::MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement):
(WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement):
(WebCore::MediaControlTimelineElement::MediaControlTimelineElement):
(WebCore::MediaControlPanelVolumeSliderElement::MediaControlPanelVolumeSliderElement):
(WebCore::MediaControlFullscreenVolumeSliderElement::MediaControlFullscreenVolumeSliderElement):
(WebCore::MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement):
(WebCore::MediaControlFullscreenVolumeMinButtonElement::MediaControlFullscreenVolumeMinButtonElement):
(WebCore::MediaControlFullscreenVolumeMaxButtonElement::MediaControlFullscreenVolumeMaxButtonElement):
(WebCore::MediaControlTimeRemainingDisplayElement::MediaControlTimeRemainingDisplayElement):
(WebCore::MediaControlCurrentTimeDisplayElement::MediaControlCurrentTimeDisplayElement):
(WebCore::MediaControlTextTrackContainerElement::MediaControlTextTrackContainerElement):
(WebCore::MediaControlPanelElement::shadowPseudoId): Deleted.
(WebCore::MediaControlPanelEnclosureElement::shadowPseudoId): Deleted.
(WebCore::MediaControlOverlayEnclosureElement::shadowPseudoId): Deleted.
(WebCore::MediaControlTimelineContainerElement::shadowPseudoId): Deleted.
(WebCore::MediaControlVolumeSliderContainerElement::shadowPseudoId): Deleted.
(WebCore::MediaControlStatusDisplayElement::shadowPseudoId): Deleted.
(WebCore::MediaControlPanelMuteButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlVolumeSliderMuteButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlPlayButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlOverlayPlayButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlSeekForwardButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlSeekBackButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlRewindButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlReturnToRealtimeButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlClosedCaptionsContainerElement::shadowPseudoId): Deleted.
(WebCore::MediaControlClosedCaptionsTrackListElement::shadowPseudoId): Deleted.
(WebCore::MediaControlTimelineElement::shadowPseudoId): Deleted.
(WebCore::MediaControlPanelVolumeSliderElement::shadowPseudoId): Deleted.
(WebCore::MediaControlFullscreenVolumeSliderElement::shadowPseudoId): Deleted.
(WebCore::MediaControlFullscreenButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlFullscreenVolumeMinButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlFullscreenVolumeMaxButtonElement::shadowPseudoId): Deleted.
(WebCore::MediaControlTimeRemainingDisplayElement::shadowPseudoId): Deleted.
(WebCore::MediaControlCurrentTimeDisplayElement::shadowPseudoId): Deleted.
(WebCore::MediaControlTextTrackContainerElement::textTrackContainerElementShadowPseudoId): Deleted.
(WebCore::MediaControlTextTrackContainerElement::shadowPseudoId): Deleted.
* html/shadow/MediaControlElements.h:
* html/shadow/MediaControls.cpp:
(WebCore::MediaControls::MediaControls):
(WebCore::MediaControls::shadowPseudoId): Deleted.
* html/shadow/MediaControls.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@171907 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/html/shadow/MediaControlElementTypes.h
Source/WebCore/html/shadow/MediaControlElements.cpp
Source/WebCore/html/shadow/MediaControlElements.h
Source/WebCore/html/shadow/MediaControls.cpp
Source/WebCore/html/shadow/MediaControls.h

index 26ea87c..40a21bb 100644 (file)
@@ -1,3 +1,73 @@
+2014-07-31  Benjamin Poulain  <bpoulain@apple.com>
+
+        Remove shadowPseudoId() override from the shadow media controls
+        https://bugs.webkit.org/show_bug.cgi?id=135474
+
+        Reviewed by Eric Carlson.
+
+        Small cleanup.
+
+        * html/shadow/MediaControlElementTypes.h:
+        * html/shadow/MediaControlElements.cpp:
+        (WebCore::MediaControlPanelElement::MediaControlPanelElement):
+        (WebCore::MediaControlPanelEnclosureElement::MediaControlPanelEnclosureElement):
+        (WebCore::MediaControlOverlayEnclosureElement::MediaControlOverlayEnclosureElement):
+        (WebCore::MediaControlTimelineContainerElement::MediaControlTimelineContainerElement):
+        (WebCore::MediaControlVolumeSliderContainerElement::MediaControlVolumeSliderContainerElement):
+        (WebCore::MediaControlStatusDisplayElement::MediaControlStatusDisplayElement):
+        (WebCore::MediaControlPanelMuteButtonElement::MediaControlPanelMuteButtonElement):
+        (WebCore::MediaControlVolumeSliderMuteButtonElement::MediaControlVolumeSliderMuteButtonElement):
+        (WebCore::MediaControlPlayButtonElement::MediaControlPlayButtonElement):
+        (WebCore::MediaControlOverlayPlayButtonElement::MediaControlOverlayPlayButtonElement):
+        (WebCore::MediaControlSeekForwardButtonElement::MediaControlSeekForwardButtonElement):
+        (WebCore::MediaControlSeekBackButtonElement::MediaControlSeekBackButtonElement):
+        (WebCore::MediaControlRewindButtonElement::MediaControlRewindButtonElement):
+        (WebCore::MediaControlReturnToRealtimeButtonElement::MediaControlReturnToRealtimeButtonElement):
+        (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
+        (WebCore::MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement):
+        (WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement):
+        (WebCore::MediaControlTimelineElement::MediaControlTimelineElement):
+        (WebCore::MediaControlPanelVolumeSliderElement::MediaControlPanelVolumeSliderElement):
+        (WebCore::MediaControlFullscreenVolumeSliderElement::MediaControlFullscreenVolumeSliderElement):
+        (WebCore::MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement):
+        (WebCore::MediaControlFullscreenVolumeMinButtonElement::MediaControlFullscreenVolumeMinButtonElement):
+        (WebCore::MediaControlFullscreenVolumeMaxButtonElement::MediaControlFullscreenVolumeMaxButtonElement):
+        (WebCore::MediaControlTimeRemainingDisplayElement::MediaControlTimeRemainingDisplayElement):
+        (WebCore::MediaControlCurrentTimeDisplayElement::MediaControlCurrentTimeDisplayElement):
+        (WebCore::MediaControlTextTrackContainerElement::MediaControlTextTrackContainerElement):
+        (WebCore::MediaControlPanelElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlPanelEnclosureElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlOverlayEnclosureElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlTimelineContainerElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlVolumeSliderContainerElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlStatusDisplayElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlPanelMuteButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlVolumeSliderMuteButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlPlayButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlOverlayPlayButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlSeekForwardButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlSeekBackButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlRewindButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlReturnToRealtimeButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlClosedCaptionsContainerElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlClosedCaptionsTrackListElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlTimelineElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlPanelVolumeSliderElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlFullscreenVolumeSliderElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlFullscreenButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlFullscreenVolumeMinButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlFullscreenVolumeMaxButtonElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlTimeRemainingDisplayElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlCurrentTimeDisplayElement::shadowPseudoId): Deleted.
+        (WebCore::MediaControlTextTrackContainerElement::textTrackContainerElementShadowPseudoId): Deleted.
+        (WebCore::MediaControlTextTrackContainerElement::shadowPseudoId): Deleted.
+        * html/shadow/MediaControlElements.h:
+        * html/shadow/MediaControls.cpp:
+        (WebCore::MediaControls::MediaControls):
+        (WebCore::MediaControls::shadowPseudoId): Deleted.
+        * html/shadow/MediaControls.h:
+
 2014-07-31  Timothy Horton  <timothy_horton@apple.com>
 
         Build fix for platforms where we should have automaticallyAdjustsContentInsets but it isn't public yet
index 5cce669..a35b450 100644 (file)
@@ -88,7 +88,6 @@ public:
     virtual bool isShowing() const;
 
     virtual MediaControlElementType displayType() { return m_displayType; }
-    virtual const AtomicString& shadowPseudoId() const = 0;
 
     virtual void setMediaController(MediaControllerInterface* controller) { m_mediaController = controller; }
     virtual MediaControllerInterface* mediaController() const { return m_mediaController; }
index 559201a..7583518 100644 (file)
@@ -75,7 +75,7 @@ MediaControlPanelElement::MediaControlPanelElement(Document& document)
     , m_opaque(true)
     , m_transitionTimer(this, &MediaControlPanelElement::transitionTimerFired)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-panel", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlPanelElement> MediaControlPanelElement::create(Document& document)
@@ -83,12 +83,6 @@ PassRefPtr<MediaControlPanelElement> MediaControlPanelElement::create(Document&
     return adoptRef(new MediaControlPanelElement(document));
 }
 
-const AtomicString& MediaControlPanelElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-panel", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 void MediaControlPanelElement::startDrag(const LayoutPoint& eventLocation)
 {
     if (!m_canBeDragged)
@@ -263,7 +257,7 @@ MediaControlPanelEnclosureElement::MediaControlPanelEnclosureElement(Document& d
     // Mapping onto same MediaControlElementType as panel element, since it has similar properties.
     : MediaControlDivElement(document, MediaControlsPanel)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-enclosure", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlPanelEnclosureElement> MediaControlPanelEnclosureElement::create(Document& document)
@@ -271,18 +265,13 @@ PassRefPtr<MediaControlPanelEnclosureElement> MediaControlPanelEnclosureElement:
     return adoptRef(new MediaControlPanelEnclosureElement(document));
 }
 
-const AtomicString& MediaControlPanelEnclosureElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-enclosure", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlOverlayEnclosureElement::MediaControlOverlayEnclosureElement(Document& document)
     // Mapping onto same MediaControlElementType as panel element, since it has similar properties.
     : MediaControlDivElement(document, MediaControlsPanel)
 {
+    setPseudo(AtomicString("-webkit-media-controls-overlay-enclosure", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlOverlayEnclosureElement> MediaControlOverlayEnclosureElement::create(Document& document)
@@ -290,18 +279,12 @@ PassRefPtr<MediaControlOverlayEnclosureElement> MediaControlOverlayEnclosureElem
     return adoptRef(new MediaControlOverlayEnclosureElement(document));
 }
 
-const AtomicString& MediaControlOverlayEnclosureElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-overlay-enclosure", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlTimelineContainerElement::MediaControlTimelineContainerElement(Document& document)
     : MediaControlDivElement(document, MediaTimelineContainer)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-timeline-container", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlTimelineContainerElement> MediaControlTimelineContainerElement::create(Document& document)
@@ -311,12 +294,6 @@ PassRefPtr<MediaControlTimelineContainerElement> MediaControlTimelineContainerEl
     return element.release();
 }
 
-const AtomicString& MediaControlTimelineContainerElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-timeline-container", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 void MediaControlTimelineContainerElement::setTimeDisplaysHidden(bool hidden)
 {
     for (unsigned i = 0; i < childNodeCount(); ++i) {
@@ -346,7 +323,7 @@ RenderPtr<RenderElement> MediaControlTimelineContainerElement::createElementRend
 MediaControlVolumeSliderContainerElement::MediaControlVolumeSliderContainerElement(Document& document)
     : MediaControlDivElement(document, MediaVolumeSliderContainer)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-volume-slider-container", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlVolumeSliderContainerElement> MediaControlVolumeSliderContainerElement::create(Document& document)
@@ -378,19 +355,13 @@ void MediaControlVolumeSliderContainerElement::defaultEventHandler(Event* event)
     hide();
 }
 
-const AtomicString& MediaControlVolumeSliderContainerElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-volume-slider-container", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlStatusDisplayElement::MediaControlStatusDisplayElement(Document& document)
     : MediaControlDivElement(document, MediaStatusDisplay)
     , m_stateBeingDisplayed(Nothing)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-status-display", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlStatusDisplayElement> MediaControlStatusDisplayElement::create(Document& document)
@@ -433,20 +404,13 @@ void MediaControlStatusDisplayElement::update()
     }
 }
 
-const AtomicString& MediaControlStatusDisplayElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-status-display", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
-
 // ----------------------------
 
 MediaControlPanelMuteButtonElement::MediaControlPanelMuteButtonElement(Document& document, MediaControls* controls)
     : MediaControlMuteButtonElement(document, MediaMuteButton)
     , m_controls(controls)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-mute-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlPanelMuteButtonElement> MediaControlPanelMuteButtonElement::create(Document& document, MediaControls* controls)
@@ -467,18 +431,12 @@ void MediaControlPanelMuteButtonElement::defaultEventHandler(Event* event)
     MediaControlMuteButtonElement::defaultEventHandler(event);
 }
 
-const AtomicString& MediaControlPanelMuteButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-mute-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlVolumeSliderMuteButtonElement::MediaControlVolumeSliderMuteButtonElement(Document& document)
     : MediaControlMuteButtonElement(document, MediaMuteButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-volume-slider-mute-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlVolumeSliderMuteButtonElement> MediaControlVolumeSliderMuteButtonElement::create(Document& document)
@@ -489,18 +447,12 @@ PassRefPtr<MediaControlVolumeSliderMuteButtonElement> MediaControlVolumeSliderMu
     return button.release();
 }
 
-const AtomicString& MediaControlVolumeSliderMuteButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-volume-slider-mute-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlPlayButtonElement::MediaControlPlayButtonElement(Document& document)
     : MediaControlInputElement(document, MediaPlayButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-play-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlPlayButtonElement> MediaControlPlayButtonElement::create(Document& document)
@@ -529,18 +481,12 @@ void MediaControlPlayButtonElement::updateDisplayType()
     setDisplayType(mediaController()->canPlay() ? MediaPlayButton : MediaPauseButton);
 }
 
-const AtomicString& MediaControlPlayButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-play-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlOverlayPlayButtonElement::MediaControlOverlayPlayButtonElement(Document& document)
     : MediaControlInputElement(document, MediaOverlayPlayButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-overlay-play-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlOverlayPlayButtonElement> MediaControlOverlayPlayButtonElement::create(Document& document)
@@ -569,19 +515,12 @@ void MediaControlOverlayPlayButtonElement::updateDisplayType()
         hide();
 }
 
-const AtomicString& MediaControlOverlayPlayButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-overlay-play-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
-
 // ----------------------------
 
 MediaControlSeekForwardButtonElement::MediaControlSeekForwardButtonElement(Document& document)
     : MediaControlSeekButtonElement(document, MediaSeekForwardButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-seek-forward-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlSeekForwardButtonElement> MediaControlSeekForwardButtonElement::create(Document& document)
@@ -592,18 +531,12 @@ PassRefPtr<MediaControlSeekForwardButtonElement> MediaControlSeekForwardButtonEl
     return button.release();
 }
 
-const AtomicString& MediaControlSeekForwardButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-seek-forward-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlSeekBackButtonElement::MediaControlSeekBackButtonElement(Document& document)
     : MediaControlSeekButtonElement(document, MediaSeekBackButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-seek-back-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlSeekBackButtonElement> MediaControlSeekBackButtonElement::create(Document& document)
@@ -614,18 +547,12 @@ PassRefPtr<MediaControlSeekBackButtonElement> MediaControlSeekBackButtonElement:
     return button.release();
 }
 
-const AtomicString& MediaControlSeekBackButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-seek-back-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlRewindButtonElement::MediaControlRewindButtonElement(Document& document)
     : MediaControlInputElement(document, MediaRewindButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-rewind-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlRewindButtonElement> MediaControlRewindButtonElement::create(Document& document)
@@ -645,18 +572,12 @@ void MediaControlRewindButtonElement::defaultEventHandler(Event* event)
     HTMLInputElement::defaultEventHandler(event);
 }
 
-const AtomicString& MediaControlRewindButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-rewind-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlReturnToRealtimeButtonElement::MediaControlReturnToRealtimeButtonElement(Document& document)
     : MediaControlInputElement(document, MediaReturnToRealtimeButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-return-to-realtime-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlReturnToRealtimeButtonElement> MediaControlReturnToRealtimeButtonElement::create(Document& document)
@@ -677,12 +598,6 @@ void MediaControlReturnToRealtimeButtonElement::defaultEventHandler(Event* event
     HTMLInputElement::defaultEventHandler(event);
 }
 
-const AtomicString& MediaControlReturnToRealtimeButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-return-to-realtime-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement(Document& document, MediaControls* controls)
@@ -694,7 +609,7 @@ MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsB
 #if !PLATFORM(COCOA) && !PLATFORM(WIN) || !PLATFORM(GTK)
     UNUSED_PARAM(controls);
 #endif
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-toggle-closed-captions-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlToggleClosedCaptionsButtonElement> MediaControlToggleClosedCaptionsButtonElement::create(Document& document, MediaControls* controls)
@@ -735,18 +650,12 @@ void MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler(Event* e
     HTMLInputElement::defaultEventHandler(event);
 }
 
-const AtomicString& MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-toggle-closed-captions-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement(Document& document)
     : MediaControlDivElement(document, MediaClosedCaptionsContainer)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-closed-captions-container", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlClosedCaptionsContainerElement> MediaControlClosedCaptionsContainerElement::create(Document& document)
@@ -757,12 +666,6 @@ PassRefPtr<MediaControlClosedCaptionsContainerElement> MediaControlClosedCaption
     return element.release();
 }
 
-const AtomicString& MediaControlClosedCaptionsContainerElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-closed-captions-container", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement(Document& document, MediaControls* controls)
@@ -774,7 +677,7 @@ MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListE
 #if !ENABLE(VIDEO_TRACK)
     UNUSED_PARAM(controls);
 #endif
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-closed-captions-track-list", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlClosedCaptionsTrackListElement> MediaControlClosedCaptionsTrackListElement::create(Document& document, MediaControls* controls)
@@ -821,12 +724,6 @@ void MediaControlClosedCaptionsTrackListElement::defaultEventHandler(Event* even
 #endif
 }
 
-const AtomicString& MediaControlClosedCaptionsTrackListElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-closed-captions-track-list", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 void MediaControlClosedCaptionsTrackListElement::updateDisplay()
 {
 #if ENABLE(VIDEO_TRACK)
@@ -940,7 +837,7 @@ MediaControlTimelineElement::MediaControlTimelineElement(Document& document, Med
     : MediaControlInputElement(document, MediaSlider)
     , m_controls(controls)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-timeline", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlTimelineElement> MediaControlTimelineElement::create(Document& document, MediaControls* controls)
@@ -1003,19 +900,12 @@ void MediaControlTimelineElement::setDuration(double duration)
     setAttribute(maxAttr, AtomicString::number(std::isfinite(duration) ? duration : 0));
 }
 
-
-const AtomicString& MediaControlTimelineElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-timeline", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlPanelVolumeSliderElement::MediaControlPanelVolumeSliderElement(Document& document)
     : MediaControlVolumeSliderElement(document)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-volume-slider", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlPanelVolumeSliderElement> MediaControlPanelVolumeSliderElement::create(Document& document)
@@ -1028,18 +918,12 @@ PassRefPtr<MediaControlPanelVolumeSliderElement> MediaControlPanelVolumeSliderEl
     return slider.release();
 }
 
-const AtomicString& MediaControlPanelVolumeSliderElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-volume-slider", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlFullscreenVolumeSliderElement::MediaControlFullscreenVolumeSliderElement(Document& document)
     : MediaControlVolumeSliderElement(document)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-fullscreen-volume-slider", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlFullscreenVolumeSliderElement> MediaControlFullscreenVolumeSliderElement::create(Document& document)
@@ -1052,18 +936,12 @@ PassRefPtr<MediaControlFullscreenVolumeSliderElement> MediaControlFullscreenVolu
     return slider.release();
 }
 
-const AtomicString& MediaControlFullscreenVolumeSliderElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-fullscreen-volume-slider", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement(Document& document)
     : MediaControlInputElement(document, MediaEnterFullscreenButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-fullscreen-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlFullscreenButtonElement> MediaControlFullscreenButtonElement::create(Document& document)
@@ -1097,12 +975,6 @@ void MediaControlFullscreenButtonElement::defaultEventHandler(Event* event)
     HTMLInputElement::defaultEventHandler(event);
 }
 
-const AtomicString& MediaControlFullscreenButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-fullscreen-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 void MediaControlFullscreenButtonElement::setIsFullscreen(bool isFullscreen)
 {
     setDisplayType(isFullscreen ? MediaExitFullscreenButton : MediaEnterFullscreenButton);
@@ -1113,7 +985,7 @@ void MediaControlFullscreenButtonElement::setIsFullscreen(bool isFullscreen)
 MediaControlFullscreenVolumeMinButtonElement::MediaControlFullscreenVolumeMinButtonElement(Document& document)
     : MediaControlInputElement(document, MediaUnMuteButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-fullscreen-volume-min-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlFullscreenVolumeMinButtonElement> MediaControlFullscreenVolumeMinButtonElement::create(Document& document)
@@ -1134,18 +1006,12 @@ void MediaControlFullscreenVolumeMinButtonElement::defaultEventHandler(Event* ev
     HTMLInputElement::defaultEventHandler(event);
 }
 
-const AtomicString& MediaControlFullscreenVolumeMinButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-fullscreen-volume-min-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlFullscreenVolumeMaxButtonElement::MediaControlFullscreenVolumeMaxButtonElement(Document& document)
 : MediaControlInputElement(document, MediaMuteButton)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-controls-fullscreen-volume-max-button", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlFullscreenVolumeMaxButtonElement> MediaControlFullscreenVolumeMaxButtonElement::create(Document& document)
@@ -1166,18 +1032,12 @@ void MediaControlFullscreenVolumeMaxButtonElement::defaultEventHandler(Event* ev
     HTMLInputElement::defaultEventHandler(event);
 }
 
-const AtomicString& MediaControlFullscreenVolumeMaxButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls-fullscreen-volume-max-button", AtomicString::ConstructFromLiteral));
-    return id;
-}
-
 // ----------------------------
 
 MediaControlTimeRemainingDisplayElement::MediaControlTimeRemainingDisplayElement(Document& document)
     : MediaControlTimeDisplayElement(document, MediaTimeRemainingDisplay)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(getMediaControlTimeRemainingDisplayElementShadowPseudoId());
 }
 
 PassRefPtr<MediaControlTimeRemainingDisplayElement> MediaControlTimeRemainingDisplayElement::create(Document& document)
@@ -1191,17 +1051,12 @@ static const AtomicString& getMediaControlTimeRemainingDisplayElementShadowPseud
     return id;
 }
 
-const AtomicString& MediaControlTimeRemainingDisplayElement::shadowPseudoId() const
-{
-    return getMediaControlTimeRemainingDisplayElementShadowPseudoId();
-}
-
 // ----------------------------
 
 MediaControlCurrentTimeDisplayElement::MediaControlCurrentTimeDisplayElement(Document& document)
     : MediaControlTimeDisplayElement(document, MediaCurrentTimeDisplay)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(getMediaControlCurrentTimeDisplayElementShadowPseudoId());
 }
 
 PassRefPtr<MediaControlCurrentTimeDisplayElement> MediaControlCurrentTimeDisplayElement::create(Document& document)
@@ -1215,11 +1070,6 @@ static const AtomicString& getMediaControlCurrentTimeDisplayElementShadowPseudoI
     return id;
 }
 
-const AtomicString& MediaControlCurrentTimeDisplayElement::shadowPseudoId() const
-{
-    return getMediaControlCurrentTimeDisplayElementShadowPseudoId();
-}
-
 // ----------------------------
 
 #if ENABLE(VIDEO_TRACK)
@@ -1231,7 +1081,7 @@ MediaControlTextTrackContainerElement::MediaControlTextTrackContainerElement(Doc
     , m_fontSizeIsImportant(false)
     , m_updateTextTrackRepresentationStyle(false)
 {
-    setPseudo(shadowPseudoId());
+    setPseudo(AtomicString("-webkit-media-text-track-container", AtomicString::ConstructFromLiteral));
 }
 
 PassRefPtr<MediaControlTextTrackContainerElement> MediaControlTextTrackContainerElement::create(Document& document)
@@ -1246,17 +1096,6 @@ RenderPtr<RenderElement> MediaControlTextTrackContainerElement::createElementRen
     return createRenderer<RenderTextTrackContainerElement>(*this, WTF::move(style));
 }
 
-const AtomicString& MediaControlTextTrackContainerElement::textTrackContainerElementShadowPseudoId()
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-text-track-container", AtomicString::ConstructFromLiteral));
-    return id;
-}
-    
-const AtomicString& MediaControlTextTrackContainerElement::shadowPseudoId() const
-{
-    return textTrackContainerElementShadowPseudoId();
-}
-
 void MediaControlTextTrackContainerElement::updateDisplay()
 {
     if (!mediaController()->closedCaptionsVisible())
index c24d3e1..1a32d6f 100644 (file)
@@ -57,7 +57,6 @@ public:
 private:
     explicit MediaControlPanelElement(Document&);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 
     void startDrag(const LayoutPoint& eventLocation);
@@ -88,7 +87,6 @@ public:
 
 private:
     explicit MediaControlPanelEnclosureElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 
 // ----------------------------
@@ -99,7 +97,6 @@ public:
 
 private:
     explicit MediaControlOverlayEnclosureElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 
 // ----------------------------
@@ -112,7 +109,6 @@ public:
 
 private:
     explicit MediaControlTimelineContainerElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 
     virtual RenderPtr<RenderElement> createElementRenderer(PassRef<RenderStyle>) override;
 };
@@ -130,7 +126,6 @@ public:
 private:
     explicit MediaControlVolumeSliderContainerElement(Document&);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 
     virtual RenderPtr<RenderElement> createElementRenderer(PassRef<RenderStyle>) override;
@@ -146,7 +141,6 @@ public:
 
 private:
     explicit MediaControlStatusDisplayElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 
     enum StateBeingDisplayed { Nothing, Loading, LiveBroadcast };
     StateBeingDisplayed m_stateBeingDisplayed;
@@ -165,7 +159,6 @@ public:
 private:
     explicit MediaControlPanelMuteButtonElement(Document&, MediaControls*);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 
     MediaControls* m_controls;
@@ -179,7 +172,6 @@ public:
 
 private:
     explicit MediaControlVolumeSliderMuteButtonElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 
 
@@ -198,7 +190,6 @@ public:
 private:
     explicit MediaControlPlayButtonElement(Document&);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 };
 
@@ -213,7 +204,6 @@ public:
 private:
     explicit MediaControlOverlayPlayButtonElement(Document&);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 };
 
@@ -225,7 +215,6 @@ public:
 
 private:
     explicit MediaControlSeekForwardButtonElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 
     virtual bool isForwardButton() const override { return true; }
 };
@@ -238,7 +227,6 @@ public:
 
 private:
     explicit MediaControlSeekBackButtonElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 
     virtual bool isForwardButton() const override { return false; }
 };
@@ -256,7 +244,6 @@ public:
 private:
     explicit MediaControlRewindButtonElement(Document&);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 };
 
@@ -273,7 +260,6 @@ public:
 private:
     explicit MediaControlReturnToRealtimeButtonElement(Document&);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 };
 
@@ -292,7 +278,6 @@ public:
 private:
     explicit MediaControlToggleClosedCaptionsButtonElement(Document&, MediaControls*);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 
 #if PLATFORM(COCOA) || PLATFORM(WIN) || PLATFORM(GTK)
@@ -312,7 +297,6 @@ public:
 
 private:
     MediaControlClosedCaptionsContainerElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 
 // ----------------------------
@@ -332,7 +316,6 @@ private:
 
     void rebuildTrackListMenu();
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 
     typedef Vector<RefPtr<Element>> TrackMenuItems;
@@ -360,7 +343,6 @@ public:
 private:
     explicit MediaControlTimelineElement(Document&, MediaControls*);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 
     MediaControls* m_controls;
@@ -381,7 +363,6 @@ public:
 private:
     explicit MediaControlFullscreenButtonElement(Document&);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 };
 
@@ -393,7 +374,6 @@ public:
 
 private:
     explicit MediaControlPanelVolumeSliderElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 // ----------------------------
 
@@ -403,7 +383,6 @@ public:
 
 private:
     explicit MediaControlFullscreenVolumeSliderElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 
 // ----------------------------
@@ -418,7 +397,6 @@ public:
 
 private:
     explicit MediaControlFullscreenVolumeMinButtonElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 };
 
@@ -435,7 +413,6 @@ public:
 private:
     explicit MediaControlFullscreenVolumeMaxButtonElement(Document&);
 
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void defaultEventHandler(Event*) override;
 };
 
@@ -448,7 +425,6 @@ public:
 
 private:
     explicit MediaControlTimeRemainingDisplayElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 
 // ----------------------------
@@ -459,7 +435,6 @@ public:
 
 private:
     explicit MediaControlCurrentTimeDisplayElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 
 // ----------------------------
@@ -474,14 +449,12 @@ public:
     void updateSizes(bool forceUpdate = false);
     void enteredFullscreen();
     void exitedFullscreen();
-    static const AtomicString& textTrackContainerElementShadowPseudoId();
 
 private:
     void updateTimerFired(Timer<MediaControlTextTrackContainerElement>&);
     void updateActiveCuesFontSize();
 
     explicit MediaControlTextTrackContainerElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
 
     virtual RenderPtr<RenderElement> createElementRenderer(PassRef<RenderStyle>) override;
 
index 3bc7b8f..fa1bebf 100644 (file)
@@ -52,6 +52,7 @@ MediaControls::MediaControls(Document& document)
     , m_isFullscreen(false)
     , m_isMouseOverControls(false)
 {
+    setPseudo(AtomicString("-webkit-media-controls", AtomicString::ConstructFromLiteral));
 }
 
 void MediaControls::setMediaController(MediaControllerInterface* controller)
@@ -363,12 +364,6 @@ void MediaControls::stopHideFullscreenControlsTimer()
     m_hideFullscreenControlsTimer.stop();
 }
 
-const AtomicString& MediaControls::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, id, ("-webkit-media-controls"));
-    return id;
-}
-
 bool MediaControls::containsRelatedTarget(Event* event)
 {
     if (!event->isMouseEvent())
index a4ab1b4..ad21605 100644 (file)
@@ -143,8 +143,6 @@ protected:
 
 private:
     virtual bool isMediaControls() const override { return true; }
-
-    virtual const AtomicString& shadowPseudoId() const override;
 };
 
 inline MediaControls* toMediaControls(Node* node)