| Index: Source/core/dom/Element.cpp
|
| diff --git a/Source/core/dom/Element.cpp b/Source/core/dom/Element.cpp
|
| index 60bd7bfd4bb8ed75e61f876adb527bdc0f9522a8..8f6764547fc5b25184068533d342c119036a60ab 100644
|
| --- a/Source/core/dom/Element.cpp
|
| +++ b/Source/core/dom/Element.cpp
|
| @@ -2898,11 +2898,6 @@ void Element::updateLabel(TreeScope& scope, const AtomicString& oldForAttributeV
|
| scope.addLabel(newForAttributeValue, toHTMLLabelElement(this));
|
| }
|
|
|
| -static bool hasSelectorForAttribute(Document* document, const AtomicString& localName)
|
| -{
|
| - return document->ensureStyleResolver().ensureUpdatedRuleFeatureSet().hasSelectorForAttribute(localName);
|
| -}
|
| -
|
| void Element::willModifyAttribute(const QualifiedName& name, const AtomicString& oldValue, const AtomicString& newValue)
|
| {
|
| if (isIdAttributeName(name)) {
|
| @@ -2916,8 +2911,8 @@ void Element::willModifyAttribute(const QualifiedName& name, const AtomicString&
|
| }
|
|
|
| if (oldValue != newValue) {
|
| - if (inActiveDocument() && hasSelectorForAttribute(&document(), name.localName()))
|
| - setNeedsStyleRecalc(SubtreeStyleChange);
|
| + if (inActiveDocument())
|
| + document().ensureStyleResolver().ensureUpdatedRuleFeatureSet().scheduleStyleInvalidationForAttributeChange(name, this);
|
|
|
| if (isUpgradedCustomElement())
|
| CustomElement::attributeDidChange(this, name.localName(), oldValue, newValue);
|
|
|