Index: third_party/WebKit/Source/core/css/SelectorChecker.cpp |
diff --git a/third_party/WebKit/Source/core/css/SelectorChecker.cpp b/third_party/WebKit/Source/core/css/SelectorChecker.cpp |
index c5d4b4d515eda624e7418022b8cb6f4f8eaf742e..5cc7f0fcfee067de6833d291f67f2f2dec7c83ea 100644 |
--- a/third_party/WebKit/Source/core/css/SelectorChecker.cpp |
+++ b/third_party/WebKit/Source/core/css/SelectorChecker.cpp |
@@ -823,11 +823,7 @@ bool SelectorChecker::checkPseudoClass(const SelectorCheckingContext& context, M |
return true; |
return element.active(); |
case CSSSelector::PseudoEnabled: |
- if (element.isFormControlElement() || isHTMLOptionElement(element) || isHTMLOptGroupElement(element)) |
- return !element.isDisabledFormControl(); |
- if (isHTMLAnchorElement(element) || isHTMLAreaElement(element)) |
- return element.isLink(); |
- break; |
+ return element.matchesEnabledPseudoClass(); |
case CSSSelector::PseudoFullPageMedia: |
return element.document().isMediaDocument(); |
case CSSSelector::PseudoDefault: |