Refactoring: Replace Element::disabled and isEnabledFormControl with isDisabledFormCo...
[WebKit-https.git] / Source / WebCore / html / HTMLFormControlElement.cpp
index 155de4f..50d8f5d 100644 (file)
@@ -113,7 +113,7 @@ void HTMLFormControlElement::updateAncestorDisabledState() const
             break;
         }
     }
-    m_ancestorDisabledState = (fieldSetAncestor && fieldSetAncestor->disabled() && !(legendAncestor && legendAncestor == fieldSetAncestor->legend())) ? AncestorDisabledStateDisabled : AncestorDisabledStateEnabled;
+    m_ancestorDisabledState = (fieldSetAncestor && fieldSetAncestor->isDisabledFormControl() && !(legendAncestor && legendAncestor == fieldSetAncestor->legend())) ? AncestorDisabledStateDisabled : AncestorDisabledStateEnabled;
 }
 
 void HTMLFormControlElement::ancestorDisabledStateWasChanged()
@@ -274,7 +274,7 @@ void HTMLFormControlElement::dispatchFormControlInputEvent()
     HTMLElement::dispatchInputEvent();
 }
 
-bool HTMLFormControlElement::disabled() const
+bool HTMLFormControlElement::isDisabledFormControl() const
 {
     if (m_disabled)
         return true;
@@ -283,7 +283,7 @@ bool HTMLFormControlElement::disabled() const
         updateAncestorDisabledState();
     if (m_ancestorDisabledState == AncestorDisabledStateDisabled)
         return true;
-    return HTMLElement::disabled();
+    return HTMLElement::isDisabledFormControl();
 }
 
 bool HTMLFormControlElement::isRequired() const
@@ -309,7 +309,7 @@ void HTMLFormControlElement::didRecalcStyle(StyleChange)
 
 bool HTMLFormControlElement::supportsFocus() const
 {
-    return !disabled();
+    return !isDisabledFormControl();
 }
 
 bool HTMLFormControlElement::isFocusable() const