[Webkit-unassigned] [Bug 248311] New: Reuse the StylePropertyShorthand in StyleProperties::getPropertyValue()
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Nov 24 09:04:27 PST 2022
https://bugs.webkit.org/show_bug.cgi?id=248311
Bug ID: 248311
Summary: Reuse the StylePropertyShorthand in
StyleProperties::getPropertyValue()
Product: WebKit
Version: WebKit Nightly Build
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: CSS
Assignee: webkit-unassigned at lists.webkit.org
Reporter: obrufau at igalia.com
StyleProperties::getPropertyValue() has a big switch like this:
switch (propertyID) {
case CSSPropertyAll:
return getCommonValue(allShorthand());
case CSSPropertyAnimation:
return getLayeredShorthandValue(animationShorthand());
case CSSPropertyBorderSpacing:
return borderSpacingValue(borderSpacingShorthand());
case CSSPropertyBackgroundPosition:
return getLayeredShorthandValue(backgroundPositionShorthand());
case CSSPropertyBackground:
return getLayeredShorthandValue(backgroundShorthand());
...
Most shorthands need to get the StylePropertyShorthand using allShorthand(), animationShorthand(), ...
But before the switch it calls commonShorthandChecks(), which uses shorthandForProperty(propertyID) to get the StylePropertyShorthand.
So this StylePropertyShorthand can be reused.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20221124/354b7e8a/attachment-0001.htm>
More information about the webkit-unassigned
mailing list