Remove shadowPseudoId() from InputFieldSpeechButtonElement and SearchFieldCancelButto...
authorbenjamin@webkit.org <benjamin@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 31 Jul 2014 03:14:11 +0000 (03:14 +0000)
committerbenjamin@webkit.org <benjamin@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 31 Jul 2014 03:14:11 +0000 (03:14 +0000)
https://bugs.webkit.org/show_bug.cgi?id=135438

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-07-30
Reviewed by Andreas Kling.

Use the generic path.

* html/shadow/TextControlInnerElements.cpp:
(WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
(WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
(WebCore::SearchFieldCancelButtonElement::shadowPseudoId): Deleted.
(WebCore::InputFieldSpeechButtonElement::shadowPseudoId): Deleted.
* html/shadow/TextControlInnerElements.h:

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

Source/WebCore/ChangeLog
Source/WebCore/html/shadow/TextControlInnerElements.cpp
Source/WebCore/html/shadow/TextControlInnerElements.h

index 3dd74ad..9263245 100644 (file)
@@ -1,3 +1,19 @@
+2014-07-30  Benjamin Poulain  <bpoulain@apple.com>
+
+        Remove shadowPseudoId() from InputFieldSpeechButtonElement and SearchFieldCancelButtonElement
+        https://bugs.webkit.org/show_bug.cgi?id=135438
+
+        Reviewed by Andreas Kling.
+
+        Use the generic path.
+
+        * html/shadow/TextControlInnerElements.cpp:
+        (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
+        (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
+        (WebCore::SearchFieldCancelButtonElement::shadowPseudoId): Deleted.
+        (WebCore::InputFieldSpeechButtonElement::shadowPseudoId): Deleted.
+        * html/shadow/TextControlInnerElements.h:
+
 2014-07-30  Andy Estes  <aestes@apple.com>
 
         USE(CONTENT_FILTERING) should be ENABLE(CONTENT_FILTERING)
index 401032a..7573516 100644 (file)
@@ -192,6 +192,7 @@ inline SearchFieldCancelButtonElement::SearchFieldCancelButtonElement(Document&
     : HTMLDivElement(divTag, document)
     , m_capturing(false)
 {
+    setPseudo(AtomicString("-webkit-search-cancel-button", AtomicString::ConstructFromLiteral));
     setHasCustomStyleResolveCallbacks();
 }
 
@@ -200,12 +201,6 @@ PassRefPtr<SearchFieldCancelButtonElement> SearchFieldCancelButtonElement::creat
     return adoptRef(new SearchFieldCancelButtonElement(document));
 }
 
-const AtomicString& SearchFieldCancelButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, pseudoId, ("-webkit-search-cancel-button", AtomicString::ConstructFromLiteral));
-    return pseudoId;
-}
-
 void SearchFieldCancelButtonElement::willDetachRenderers()
 {
     if (m_capturing) {
@@ -275,6 +270,7 @@ inline InputFieldSpeechButtonElement::InputFieldSpeechButtonElement(Document& do
     , m_state(Idle)
     , m_listenerId(0)
 {
+    setPseudo(AtomicString("-webkit-input-speech-button", AtomicString::ConstructFromLiteral));
     setHasCustomStyleResolveCallbacks();
 }
 
@@ -459,12 +455,6 @@ void InputFieldSpeechButtonElement::stopSpeechInput()
         speechInput()->stopRecording(m_listenerId);
 }
 
-const AtomicString& InputFieldSpeechButtonElement::shadowPseudoId() const
-{
-    DEPRECATED_DEFINE_STATIC_LOCAL(AtomicString, pseudoId, ("-webkit-input-speech-button", AtomicString::ConstructFromLiteral));
-    return pseudoId;
-}
-
 #endif // ENABLE(INPUT_SPEECH)
 
 }
index b9b720e..54da6b7 100644 (file)
@@ -103,7 +103,6 @@ public:
 
 private:
     SearchFieldCancelButtonElement(Document&);
-    virtual const AtomicString& shadowPseudoId() const override;
     virtual void willDetachRenderers() override;
     virtual bool isMouseFocusable() const override { return false; }
 
@@ -143,7 +142,6 @@ private:
     InputFieldSpeechButtonElement(Document&);
     SpeechInput* speechInput();
     void setState(SpeechInputState state);
-    virtual const AtomicString& shadowPseudoId() const;
     virtual bool isMouseFocusable() const override { return false; }
     virtual void willAttachRenderers() override;
     virtual void willDetachRenderers() override;