Modified: trunk/Source/WebCore/style/PropertyCascade.cpp (285394 => 285395)
--- trunk/Source/WebCore/style/PropertyCascade.cpp 2021-11-07 21:13:20 UTC (rev 285394)
+++ trunk/Source/WebCore/style/PropertyCascade.cpp 2021-11-07 21:29:11 UTC (rev 285395)
@@ -107,21 +107,21 @@
}
}
-void PropertyCascade::setPropertyInternal(Property& property, CSSPropertyID id, CSSValue& cssValue, unsigned linkMatchType, CascadeLevel cascadeLevel, ScopeOrdinal styleScopeOrdinal)
+void PropertyCascade::setPropertyInternal(Property& property, CSSPropertyID id, CSSValue& cssValue, const MatchedProperties& matchedProperties, CascadeLevel cascadeLevel)
{
- ASSERT(linkMatchType <= SelectorChecker::MatchAll);
+ ASSERT(matchedProperties.linkMatchType <= SelectorChecker::MatchAll);
property.id = id;
property.level = cascadeLevel;
- property.styleScopeOrdinal = styleScopeOrdinal;
- if (linkMatchType == SelectorChecker::MatchAll) {
+ property.styleScopeOrdinal = matchedProperties.styleScopeOrdinal;
+ if (matchedProperties.linkMatchType == SelectorChecker::MatchAll) {
property.cssValue[0] = &cssValue;
property.cssValue[SelectorChecker::MatchLink] = &cssValue;
property.cssValue[SelectorChecker::MatchVisited] = &cssValue;
} else
- property.cssValue[linkMatchType] = &cssValue;
+ property.cssValue[matchedProperties.linkMatchType] = &cssValue;
}
-void PropertyCascade::set(CSSPropertyID id, CSSValue& cssValue, unsigned linkMatchType, CascadeLevel cascadeLevel, ScopeOrdinal styleScopeOrdinal)
+void PropertyCascade::set(CSSPropertyID id, CSSValue& cssValue, const MatchedProperties& matchedProperties, CascadeLevel cascadeLevel)
{
if (CSSProperty::isDirectionAwareProperty(id)) {
auto direction = this->direction();
@@ -140,11 +140,11 @@
Property property;
property.id = id;
memset(property.cssValue, 0, sizeof(property.cssValue));
- setPropertyInternal(property, id, cssValue, linkMatchType, cascadeLevel, styleScopeOrdinal);
+ setPropertyInternal(property, id, cssValue, matchedProperties, cascadeLevel);
m_customProperties.set(customValue.name(), property);
} else {
Property property = customProperty(customValue.name());
- setPropertyInternal(property, id, cssValue, linkMatchType, cascadeLevel, styleScopeOrdinal);
+ setPropertyInternal(property, id, cssValue, matchedProperties, cascadeLevel);
m_customProperties.set(customValue.name(), property);
}
return;
@@ -153,10 +153,10 @@
if (!m_propertyIsPresent[id])
memset(property.cssValue, 0, sizeof(property.cssValue));
m_propertyIsPresent.set(id);
- setPropertyInternal(property, id, cssValue, linkMatchType, cascadeLevel, styleScopeOrdinal);
+ setPropertyInternal(property, id, cssValue, matchedProperties, cascadeLevel);
}
-void PropertyCascade::setDeferred(CSSPropertyID id, CSSValue& cssValue, unsigned linkMatchType, CascadeLevel cascadeLevel, ScopeOrdinal styleScopeOrdinal)
+void PropertyCascade::setDeferred(CSSPropertyID id, CSSValue& cssValue, const MatchedProperties& matchedProperties, CascadeLevel cascadeLevel)
{
ASSERT(!CSSProperty::isDirectionAwareProperty(id));
ASSERT(shouldApplyPropertyInParseOrder(id));
@@ -163,7 +163,7 @@
Property property;
memset(property.cssValue, 0, sizeof(property.cssValue));
- setPropertyInternal(property, id, cssValue, linkMatchType, cascadeLevel, styleScopeOrdinal);
+ setPropertyInternal(property, id, cssValue, matchedProperties, cascadeLevel);
m_deferredProperties.append(property);
}
@@ -198,9 +198,9 @@
continue;
if (shouldApplyPropertyInParseOrder(propertyID))
- setDeferred(propertyID, *current.value(), matchedProperties.linkMatchType, cascadeLevel, matchedProperties.styleScopeOrdinal);
+ setDeferred(propertyID, *current.value(), matchedProperties, cascadeLevel);
else
- set(propertyID, *current.value(), matchedProperties.linkMatchType, cascadeLevel, matchedProperties.styleScopeOrdinal);
+ set(propertyID, *current.value(), matchedProperties, cascadeLevel);
}
return hasImportantProperties;
Modified: trunk/Source/WebCore/style/PropertyCascade.h (285394 => 285395)
--- trunk/Source/WebCore/style/PropertyCascade.h 2021-11-07 21:13:20 UTC (rev 285394)
+++ trunk/Source/WebCore/style/PropertyCascade.h 2021-11-07 21:29:11 UTC (rev 285395)
@@ -77,9 +77,9 @@
void addImportantMatches(CascadeLevel);
bool addMatch(const MatchedProperties&, CascadeLevel, bool important);
- void set(CSSPropertyID, CSSValue&, unsigned linkMatchType, CascadeLevel, ScopeOrdinal);
- void setDeferred(CSSPropertyID, CSSValue&, unsigned linkMatchType, CascadeLevel, ScopeOrdinal);
- static void setPropertyInternal(Property&, CSSPropertyID, CSSValue&, unsigned linkMatchType, CascadeLevel, ScopeOrdinal);
+ void set(CSSPropertyID, CSSValue&, const MatchedProperties&, CascadeLevel);
+ void setDeferred(CSSPropertyID, CSSValue&, const MatchedProperties&, CascadeLevel);
+ static void setPropertyInternal(Property&, CSSPropertyID, CSSValue&, const MatchedProperties&, CascadeLevel);
Direction resolveDirectionAndWritingMode(Direction inheritedDirection) const;