Title: [176250] trunk/Source/WebCore
Revision
176250
Author
[email protected]
Date
2014-11-17 20:30:08 -0800 (Mon, 17 Nov 2014)

Log Message

Fix two bad function names of HTMLFormControlElement
https://bugs.webkit.org/show_bug.cgi?id=138790

Reviewed by Andreas Kling.

Darin suggested some name improvements in https://bugs.webkit.org/show_bug.cgi?id=138769

* dom/CheckedRadioButtons.cpp:
(WebCore::RadioButtonGroup::add):
(WebCore::RadioButtonGroup::updateCheckedState):
(WebCore::RadioButtonGroup::requiredAttributeChanged):
(WebCore::RadioButtonGroup::remove):
(WebCore::RadioButtonGroup::updateValidityForAllButtons):
(WebCore::RadioButtonGroup::setNeedsValidityCheckForAllButtons): Deleted.
* html/FileInputType.cpp:
(WebCore::FileInputType::setFiles):
* html/HTMLButtonElement.cpp:
(WebCore::HTMLButtonElement::computeWillValidate):
(WebCore::HTMLButtonElement::recalcWillValidate): Deleted.
* html/HTMLButtonElement.h:
* html/HTMLFieldSetElement.h:
* html/HTMLFormControlElement.cpp:
(WebCore::HTMLFormControlElement::requiredAttributeChanged):
(WebCore::HTMLFormControlElement::computeWillValidate):
(WebCore::HTMLFormControlElement::willValidate):
(WebCore::HTMLFormControlElement::setNeedsWillValidateCheck):
(WebCore::HTMLFormControlElement::isValidFormControlElement):
(WebCore::HTMLFormControlElement::updateValidity):
(WebCore::HTMLFormControlElement::setCustomValidity):
(WebCore::HTMLFormControlElement::recalcWillValidate): Deleted.
(WebCore::HTMLFormControlElement::setNeedsValidityCheck): Deleted.
* html/HTMLFormControlElement.h:
* html/HTMLInputElement.cpp:
(WebCore::HTMLInputElement::runPostTypeUpdateTasks):
(WebCore::HTMLInputElement::parseAttribute):
(WebCore::HTMLInputElement::setChecked):
(WebCore::HTMLInputElement::setValueInternal):
(WebCore::HTMLInputElement::setValueFromRenderer):
(WebCore::HTMLInputElement::computeWillValidate):
(WebCore::HTMLInputElement::parseMaxLengthAttribute):
(WebCore::HTMLInputElement::recalcWillValidate): Deleted.
* html/HTMLInputElement.h:
* html/HTMLKeygenElement.h:
* html/HTMLOutputElement.h:
* html/HTMLSelectElement.cpp:
(WebCore::HTMLSelectElement::deselectItems):
(WebCore::HTMLSelectElement::optionSelectedByUser):
(WebCore::HTMLSelectElement::listBoxSelectItem):
(WebCore::HTMLSelectElement::add):
(WebCore::HTMLSelectElement::parseAttribute):
(WebCore::HTMLSelectElement::childrenChanged):
(WebCore::HTMLSelectElement::optionElementChildrenChanged):
(WebCore::HTMLSelectElement::setLength):
(WebCore::HTMLSelectElement::selectAll):
(WebCore::HTMLSelectElement::updateListBoxSelection):
(WebCore::HTMLSelectElement::selectOption):
(WebCore::HTMLSelectElement::restoreFormControlState):
(WebCore::HTMLSelectElement::parseMultipleAttribute):
(WebCore::HTMLSelectElement::reset):
* html/HTMLTextAreaElement.cpp:
(WebCore::HTMLTextAreaElement::parseAttribute):
(WebCore::HTMLTextAreaElement::subtreeHasChanged):
(WebCore::HTMLTextAreaElement::setValue):
(WebCore::HTMLTextAreaElement::setNonDirtyValue):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (176249 => 176250)


--- trunk/Source/WebCore/ChangeLog	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/ChangeLog	2014-11-18 04:30:08 UTC (rev 176250)
@@ -1,3 +1,70 @@
+2014-11-17  Benjamin Poulain  <[email protected]>
+
+        Fix two bad function names of HTMLFormControlElement
+        https://bugs.webkit.org/show_bug.cgi?id=138790
+
+        Reviewed by Andreas Kling.
+
+        Darin suggested some name improvements in https://bugs.webkit.org/show_bug.cgi?id=138769
+
+        * dom/CheckedRadioButtons.cpp:
+        (WebCore::RadioButtonGroup::add):
+        (WebCore::RadioButtonGroup::updateCheckedState):
+        (WebCore::RadioButtonGroup::requiredAttributeChanged):
+        (WebCore::RadioButtonGroup::remove):
+        (WebCore::RadioButtonGroup::updateValidityForAllButtons):
+        (WebCore::RadioButtonGroup::setNeedsValidityCheckForAllButtons): Deleted.
+        * html/FileInputType.cpp:
+        (WebCore::FileInputType::setFiles):
+        * html/HTMLButtonElement.cpp:
+        (WebCore::HTMLButtonElement::computeWillValidate):
+        (WebCore::HTMLButtonElement::recalcWillValidate): Deleted.
+        * html/HTMLButtonElement.h:
+        * html/HTMLFieldSetElement.h:
+        * html/HTMLFormControlElement.cpp:
+        (WebCore::HTMLFormControlElement::requiredAttributeChanged):
+        (WebCore::HTMLFormControlElement::computeWillValidate):
+        (WebCore::HTMLFormControlElement::willValidate):
+        (WebCore::HTMLFormControlElement::setNeedsWillValidateCheck):
+        (WebCore::HTMLFormControlElement::isValidFormControlElement):
+        (WebCore::HTMLFormControlElement::updateValidity):
+        (WebCore::HTMLFormControlElement::setCustomValidity):
+        (WebCore::HTMLFormControlElement::recalcWillValidate): Deleted.
+        (WebCore::HTMLFormControlElement::setNeedsValidityCheck): Deleted.
+        * html/HTMLFormControlElement.h:
+        * html/HTMLInputElement.cpp:
+        (WebCore::HTMLInputElement::runPostTypeUpdateTasks):
+        (WebCore::HTMLInputElement::parseAttribute):
+        (WebCore::HTMLInputElement::setChecked):
+        (WebCore::HTMLInputElement::setValueInternal):
+        (WebCore::HTMLInputElement::setValueFromRenderer):
+        (WebCore::HTMLInputElement::computeWillValidate):
+        (WebCore::HTMLInputElement::parseMaxLengthAttribute):
+        (WebCore::HTMLInputElement::recalcWillValidate): Deleted.
+        * html/HTMLInputElement.h:
+        * html/HTMLKeygenElement.h:
+        * html/HTMLOutputElement.h:
+        * html/HTMLSelectElement.cpp:
+        (WebCore::HTMLSelectElement::deselectItems):
+        (WebCore::HTMLSelectElement::optionSelectedByUser):
+        (WebCore::HTMLSelectElement::listBoxSelectItem):
+        (WebCore::HTMLSelectElement::add):
+        (WebCore::HTMLSelectElement::parseAttribute):
+        (WebCore::HTMLSelectElement::childrenChanged):
+        (WebCore::HTMLSelectElement::optionElementChildrenChanged):
+        (WebCore::HTMLSelectElement::setLength):
+        (WebCore::HTMLSelectElement::selectAll):
+        (WebCore::HTMLSelectElement::updateListBoxSelection):
+        (WebCore::HTMLSelectElement::selectOption):
+        (WebCore::HTMLSelectElement::restoreFormControlState):
+        (WebCore::HTMLSelectElement::parseMultipleAttribute):
+        (WebCore::HTMLSelectElement::reset):
+        * html/HTMLTextAreaElement.cpp:
+        (WebCore::HTMLTextAreaElement::parseAttribute):
+        (WebCore::HTMLTextAreaElement::subtreeHasChanged):
+        (WebCore::HTMLTextAreaElement::setValue):
+        (WebCore::HTMLTextAreaElement::setNonDirtyValue):
+
 2014-11-17  Sukolsak Sakshuwong  <[email protected]>
 
         Add parsing for :role()

Modified: trunk/Source/WebCore/dom/CheckedRadioButtons.cpp (176249 => 176250)


--- trunk/Source/WebCore/dom/CheckedRadioButtons.cpp	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/dom/CheckedRadioButtons.cpp	2014-11-18 04:30:08 UTC (rev 176250)
@@ -40,7 +40,7 @@
     bool contains(HTMLInputElement*) const;
 
 private:
-    void setNeedsValidityCheckForAllButtons();
+    void updateValidityForAllButtons();
     bool isValid() const;
     void setCheckedButton(HTMLInputElement*);
 
@@ -83,11 +83,11 @@
 
     bool groupIsValid = isValid();
     if (groupWasValid != groupIsValid)
-        setNeedsValidityCheckForAllButtons();
+        updateValidityForAllButtons();
     else if (!groupIsValid) {
         // A radio button not in a group is always valid. We need to make it
         // invalid only if the group is invalid.
-        button->setNeedsValidityCheck();
+        button->updateValidity();
     }
 }
 
@@ -103,7 +103,7 @@
             m_checkedButton = 0;
     }
     if (wasValid != isValid())
-        setNeedsValidityCheckForAllButtons();
+        updateValidityForAllButtons();
 }
 
 void RadioButtonGroup::requiredAttributeChanged(HTMLInputElement* button)
@@ -118,7 +118,7 @@
         --m_requiredCount;
     }
     if (wasValid != isValid())
-        setNeedsValidityCheckForAllButtons();
+        updateValidityForAllButtons();
 }
 
 void RadioButtonGroup::remove(HTMLInputElement* button)
@@ -140,22 +140,22 @@
         ASSERT(!m_requiredCount);
         ASSERT(!m_checkedButton);
     } else if (wasValid != isValid())
-        setNeedsValidityCheckForAllButtons();
+        updateValidityForAllButtons();
     if (!wasValid) {
         // A radio button not in a group is always valid. We need to make it
         // valid only if the group was invalid.
-        button->setNeedsValidityCheck();
+        button->updateValidity();
     }
 }
 
-void RadioButtonGroup::setNeedsValidityCheckForAllButtons()
+void RadioButtonGroup::updateValidityForAllButtons()
 {
     typedef HashSet<HTMLInputElement*>::const_iterator Iterator;
     Iterator end = m_members.end();
     for (Iterator it = m_members.begin(); it != end; ++it) {
         HTMLInputElement* button = *it;
         ASSERT(button->isRadioButton());
-        button->setNeedsValidityCheck();
+        button->updateValidity();
     }
 }
 

Modified: trunk/Source/WebCore/html/FileInputType.cpp (176249 => 176250)


--- trunk/Source/WebCore/html/FileInputType.cpp	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/FileInputType.cpp	2014-11-18 04:30:08 UTC (rev 176250)
@@ -341,7 +341,7 @@
     m_fileList = files;
 
     input->setFormControlValueMatchesRenderer(true);
-    input->setNeedsValidityCheck();
+    input->updateValidity();
 
     Vector<String> paths;
     for (unsigned i = 0; i < m_fileList->length(); ++i)

Modified: trunk/Source/WebCore/html/HTMLButtonElement.cpp (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLButtonElement.cpp	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLButtonElement.cpp	2014-11-18 04:30:08 UTC (rev 176250)
@@ -200,9 +200,9 @@
     return fastGetAttribute(valueAttr);
 }
 
-bool HTMLButtonElement::recalcWillValidate() const
+bool HTMLButtonElement::computeWillValidate() const
 {
-    return m_type == SUBMIT && HTMLFormControlElement::recalcWillValidate();
+    return m_type == SUBMIT && HTMLFormControlElement::computeWillValidate();
 }
 
 } // namespace

Modified: trunk/Source/WebCore/html/HTMLButtonElement.h (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLButtonElement.h	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLButtonElement.h	2014-11-18 04:30:08 UTC (rev 176250)
@@ -69,7 +69,7 @@
     virtual bool canStartSelection() const override { return false; }
 
     virtual bool isOptionalFormControl() const override { return true; }
-    virtual bool recalcWillValidate() const override;
+    virtual bool computeWillValidate() const override;
 
     Type m_type;
     bool m_isActivatedSubmit;

Modified: trunk/Source/WebCore/html/HTMLFieldSetElement.h (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLFieldSetElement.h	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLFieldSetElement.h	2014-11-18 04:30:08 UTC (rev 176250)
@@ -53,7 +53,7 @@
     virtual bool supportsFocus() const override;
     virtual RenderPtr<RenderElement> createElementRenderer(PassRef<RenderStyle>) override;
     virtual const AtomicString& formControlType() const override;
-    virtual bool recalcWillValidate() const override { return false; }
+    virtual bool computeWillValidate() const override { return false; }
     virtual void disabledAttributeChanged() override;
     virtual void disabledStateChanged() override;
     virtual void childrenChanged(const ChildChange&) override;

Modified: trunk/Source/WebCore/html/HTMLFormControlElement.cpp (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLFormControlElement.cpp	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLFormControlElement.cpp	2014-11-18 04:30:08 UTC (rev 176250)
@@ -167,7 +167,7 @@
 
 void HTMLFormControlElement::requiredAttributeChanged()
 {
-    setNeedsValidityCheck();
+    updateValidity();
     // Style recalculation is needed because style selectors may include
     // :required and :optional pseudo-classes.
     setNeedsStyleRecalc();
@@ -373,7 +373,7 @@
     return Element::tabIndex();
 }
 
-bool HTMLFormControlElement::recalcWillValidate() const
+bool HTMLFormControlElement::computeWillValidate() const
 {
     if (m_dataListAncestorState == Unknown) {
         for (ContainerNode* ancestor = parentNode(); ancestor; ancestor = ancestor->parentNode()) {
@@ -392,14 +392,14 @@
 {
     if (!m_willValidateInitialized || m_dataListAncestorState == Unknown) {
         m_willValidateInitialized = true;
-        bool newWillValidate = recalcWillValidate();
+        bool newWillValidate = computeWillValidate();
         if (m_willValidate != newWillValidate)
             m_willValidate = newWillValidate;
     } else {
         // If the following assertion fails, setNeedsWillValidateCheck() is not
-        // called correctly when something which changes recalcWillValidate() result
+        // called correctly when something which changes computeWillValidate() result
         // is updated.
-        ASSERT(m_willValidate == recalcWillValidate());
+        ASSERT(m_willValidate == computeWillValidate());
     }
     return m_willValidate;
 }
@@ -407,7 +407,7 @@
 void HTMLFormControlElement::setNeedsWillValidateCheck()
 {
     // We need to recalculate willValidate immediately because willValidate change can causes style change.
-    bool newWillValidate = recalcWillValidate();
+    bool newWillValidate = computeWillValidate();
     if (m_willValidateInitialized && m_willValidate == newWillValidate)
         return;
 
@@ -416,7 +416,7 @@
     m_willValidateInitialized = true;
     m_willValidate = newWillValidate;
 
-    setNeedsValidityCheck();
+    updateValidity();
     setNeedsStyleRecalc();
 
     if (!m_willValidate && !wasValid)
@@ -460,13 +460,13 @@
 
 inline bool HTMLFormControlElement::isValidFormControlElement() const
 {
-    // If the following assertion fails, setNeedsValidityCheck() is not called
+    // If the following assertion fails, updateValidity() is not called
     // correctly when something which changes validity is updated.
     ASSERT(m_isValid == valid());
     return m_isValid;
 }
 
-void HTMLFormControlElement::setNeedsValidityCheck()
+void HTMLFormControlElement::updateValidity()
 {
     bool willValidate = this->willValidate();
     bool wasValid = m_isValid;
@@ -494,7 +494,7 @@
 void HTMLFormControlElement::setCustomValidity(const String& error)
 {
     FormAssociatedElement::setCustomValidity(error);
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 bool HTMLFormControlElement::validationMessageShadowTreeContains(const Node& node) const

Modified: trunk/Source/WebCore/html/HTMLFormControlElement.h (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLFormControlElement.h	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLFormControlElement.h	2014-11-18 04:30:08 UTC (rev 176250)
@@ -103,7 +103,7 @@
     void hideVisibleValidationMessage();
     bool checkValidity(Vector<RefPtr<FormAssociatedElement>>* unhandledInvalidControls = 0);
     // This must be called when a validation constraint or control value is changed.
-    void setNeedsValidityCheck();
+    void updateValidity();
     virtual void setCustomValidity(const String&) override;
 
     bool isReadOnly() const { return m_isReadOnly; }
@@ -142,7 +142,7 @@
 
     // This must be called any time the result of willValidate() has changed.
     void setNeedsWillValidateCheck();
-    virtual bool recalcWillValidate() const;
+    virtual bool computeWillValidate() const;
 
     bool validationMessageShadowTreeContains(const Node&) const;
 

Modified: trunk/Source/WebCore/html/HTMLInputElement.cpp (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLInputElement.cpp	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLInputElement.cpp	2014-11-18 04:30:08 UTC (rev 176250)
@@ -527,7 +527,7 @@
 
     addToRadioButtonGroup();
 
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLInputElement::subtreeHasChanged()
@@ -665,7 +665,7 @@
             setNeedsStyleRecalc();
         }
         setFormControlValueMatchesRenderer(false);
-        setNeedsValidityCheck();
+        updateValidity();
         m_valueAttributeWasUpdatedAfterParsing = !m_parsingInProgress;
     } else if (name == checkedAttr) {
         // Another radio button in the same group might be checked by state
@@ -702,20 +702,20 @@
         setNeedsStyleRecalc();
     } else if (name == minAttr) {
         m_inputType->minOrMaxAttributeChanged();
-        setNeedsValidityCheck();
+        updateValidity();
     } else if (name == maxAttr) {
         m_inputType->minOrMaxAttributeChanged();
-        setNeedsValidityCheck();
+        updateValidity();
     } else if (name == multipleAttr) {
         m_inputType->multipleAttributeChanged();
-        setNeedsValidityCheck();
+        updateValidity();
     } else if (name == stepAttr) {
         m_inputType->stepAttributeChanged();
-        setNeedsValidityCheck();
+        updateValidity();
     } else if (name == patternAttr) {
-        setNeedsValidityCheck();
+        updateValidity();
     } else if (name == precisionAttr) {
-        setNeedsValidityCheck();
+        updateValidity();
     } else if (name == disabledAttr) {
         HTMLTextFormControlElement::parseAttribute(name, value);
         m_inputType->disabledAttributeChanged();
@@ -859,7 +859,7 @@
             buttons->updateCheckedState(this);
     if (renderer() && renderer()->style().hasAppearance())
         renderer()->theme().stateChanged(*renderer(), ControlStates::CheckedState);
-    setNeedsValidityCheck();
+    updateValidity();
 
     // Ideally we'd do this from the render tree (matching
     // RenderTextView), but it's not possible to do it at the moment
@@ -1003,7 +1003,7 @@
 {
     m_valueIfDirty = sanitizedValue;
     m_wasModifiedByUser = eventBehavior != DispatchNoEvent;
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 double HTMLInputElement::valueAsDate() const
@@ -1050,7 +1050,7 @@
     if (!isTextField())
         dispatchInputEvent();
 
-    setNeedsValidityCheck();
+    updateValidity();
 
     // Clear autofill flag (and yellow background) on user edit.
     setAutofilled(false);
@@ -1509,9 +1509,9 @@
     addSubresourceURL(urls, src());
 }
 
-bool HTMLInputElement::recalcWillValidate() const
+bool HTMLInputElement::computeWillValidate() const
 {
-    return m_inputType->supportsValidation() && HTMLTextFormControlElement::recalcWillValidate();
+    return m_inputType->supportsValidation() && HTMLTextFormControlElement::computeWillValidate();
 }
 
 void HTMLInputElement::requiredAttributeChanged()
@@ -1732,7 +1732,7 @@
     if (oldMaxLength != maxLength)
         updateValueIfNeeded();
     setNeedsStyleRecalc();
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLInputElement::updateValueIfNeeded()

Modified: trunk/Source/WebCore/html/HTMLInputElement.h (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLInputElement.h	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLInputElement.h	2014-11-18 04:30:08 UTC (rev 176250)
@@ -396,7 +396,7 @@
 
     virtual bool isOptionalFormControl() const override final { return !isRequiredFormControl(); }
     virtual bool isRequiredFormControl() const override final;
-    virtual bool recalcWillValidate() const override final;
+    virtual bool computeWillValidate() const override final;
     virtual void requiredAttributeChanged() override final;
 
     void initializeInputType();

Modified: trunk/Source/WebCore/html/HTMLKeygenElement.h (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLKeygenElement.h	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLKeygenElement.h	2014-11-18 04:30:08 UTC (rev 176250)
@@ -37,7 +37,7 @@
 private:
     HTMLKeygenElement(const QualifiedName&, Document&, HTMLFormElement*);
 
-    virtual bool recalcWillValidate() const override { return false; }
+    virtual bool computeWillValidate() const override { return false; }
     virtual bool canStartSelection() const override { return false; }
 
     virtual void parseAttribute(const QualifiedName&, const AtomicString&) override;

Modified: trunk/Source/WebCore/html/HTMLOutputElement.h (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLOutputElement.h	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLOutputElement.h	2014-11-18 04:30:08 UTC (rev 176250)
@@ -52,7 +52,7 @@
 private:
     HTMLOutputElement(const QualifiedName&, Document&, HTMLFormElement*);
 
-    virtual bool recalcWillValidate() const override { return false; }
+    virtual bool computeWillValidate() const override { return false; }
     virtual void parseAttribute(const QualifiedName&, const AtomicString&) override;
     virtual const AtomicString& formControlType() const override;
     virtual bool isEnumeratable() const override { return true; }

Modified: trunk/Source/WebCore/html/HTMLSelectElement.cpp (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLSelectElement.cpp	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLSelectElement.cpp	2014-11-18 04:30:08 UTC (rev 176250)
@@ -104,7 +104,7 @@
 void HTMLSelectElement::deselectItems(HTMLOptionElement* excludeElement)
 {
     deselectItemsWithoutValidation(excludeElement);
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLSelectElement::optionSelectedByUser(int optionIndex, bool fireOnChangeNow, bool allowMultipleSelection)
@@ -113,7 +113,7 @@
     // This produces that same behavior for changes triggered by other code running on behalf of the user.
     if (!usesMenuList()) {
         updateSelectedState(optionToListIndex(optionIndex), allowMultipleSelection, false);
-        setNeedsValidityCheck();
+        updateValidity();
         if (fireOnChangeNow)
             listBoxOnChange();
         return;
@@ -184,7 +184,7 @@
         optionSelectedByUser(listToOptionIndex(listIndex), fireOnChangeNow, false);
     else {
         updateSelectedState(listIndex, allowMultiplySelections, shift);
-        setNeedsValidityCheck();
+        updateValidity();
         if (fireOnChangeNow)
             listBoxOnChange();
     }
@@ -227,7 +227,7 @@
     Ref<HTMLElement> protectNewChild(*element);
 
     insertBefore(element, before, ec);
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLSelectElement::removeByIndex(int optionIndex)
@@ -313,7 +313,7 @@
             updateListItemSelectedStates();
 
         m_size = size;
-        setNeedsValidityCheck();
+        updateValidity();
         if (m_size != oldSize) {
             setNeedsStyleRecalc(ReconstructRenderTree);
             setRecalcListItems();
@@ -387,7 +387,7 @@
 void HTMLSelectElement::childrenChanged(const ChildChange& change)
 {
     setRecalcListItems();
-    setNeedsValidityCheck();
+    updateValidity();
     m_lastOnChangeSelection.clear();
 
     HTMLFormControlElementWithState::childrenChanged(change);
@@ -396,7 +396,7 @@
 void HTMLSelectElement::optionElementChildrenChanged()
 {
     setRecalcListItems();
-    setNeedsValidityCheck();
+    updateValidity();
 
     if (renderer()) {
         if (AXObjectCache* cache = renderer()->document().existingAXObjectCache())
@@ -494,7 +494,7 @@
                 item->parentNode()->removeChild(item.get(), ec);
         }
     }
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 bool HTMLSelectElement::isRequiredFormControl() const
@@ -591,7 +591,7 @@
 
     updateListBoxSelection(false);
     listBoxOnChange();
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLSelectElement::saveLastSelection()
@@ -656,7 +656,7 @@
     }
 
     scrollToSelection();
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLSelectElement::listBoxOnChange()
@@ -907,7 +907,7 @@
         }
     }
 
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 int HTMLSelectElement::optionToListIndex(int optionIndex) const
@@ -1039,14 +1039,14 @@
     }
 
     setOptionsChangedOnRenderer();
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLSelectElement::parseMultipleAttribute(const AtomicString& value)
 {
     bool oldUsesMenuList = usesMenuList();
     m_multiple = !value.isNull();
-    setNeedsValidityCheck();
+    updateValidity();
     if (oldUsesMenuList != usesMenuList())
         setNeedsStyleRecalc(ReconstructRenderTree);
 }
@@ -1103,7 +1103,7 @@
 
     setOptionsChangedOnRenderer();
     setNeedsStyleRecalc();
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 #if !PLATFORM(WIN)

Modified: trunk/Source/WebCore/html/HTMLTextAreaElement.cpp (176249 => 176250)


--- trunk/Source/WebCore/html/HTMLTextAreaElement.cpp	2014-11-18 04:13:01 UTC (rev 176249)
+++ trunk/Source/WebCore/html/HTMLTextAreaElement.cpp	2014-11-18 04:30:08 UTC (rev 176250)
@@ -205,7 +205,7 @@
     } else if (name == accesskeyAttr) {
         // ignore for the moment
     } else if (name == maxlengthAttr)
-        setNeedsValidityCheck();
+        updateValidity();
     else
         HTMLTextFormControlElement::parseAttribute(name, value);
 }
@@ -280,7 +280,7 @@
 {
     setChangedSinceLastFormControlChangeEvent(true);
     setFormControlValueMatchesRenderer(false);
-    setNeedsValidityCheck();
+    updateValidity();
 
     if (!focused())
         return;
@@ -357,14 +357,14 @@
 {
     setValueCommon(value);
     m_isDirty = true;
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLTextAreaElement::setNonDirtyValue(const String& value)
 {
     setValueCommon(value);
     m_isDirty = false;
-    setNeedsValidityCheck();
+    updateValidity();
 }
 
 void HTMLTextAreaElement::setValueCommon(const String& newValue)
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to