Diff
Modified: trunk/LayoutTests/imported/w3c/ChangeLog (291160 => 291161)
--- trunk/LayoutTests/imported/w3c/ChangeLog 2022-03-11 14:08:29 UTC (rev 291160)
+++ trunk/LayoutTests/imported/w3c/ChangeLog 2022-03-11 14:17:13 UTC (rev 291161)
@@ -1,5 +1,16 @@
2022-03-11 Antoine Quint <[email protected]>
+ [web-animations] mask-repeat should support discrete animation
+ https://bugs.webkit.org/show_bug.cgi?id=237771
+
+ Reviewed by Antti Koivisto.
+
+ * web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-002-expected.txt:
+ * web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-002-expected.txt:
+ * web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-002-expected.txt:
+
+2022-03-11 Antoine Quint <[email protected]>
+
[web-animations] mask-mode should support discrete animation
https://bugs.webkit.org/show_bug.cgi?id=237770
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-002-expected.txt (291160 => 291161)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-002-expected.txt 2022-03-11 14:08:29 UTC (rev 291160)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-002-expected.txt 2022-03-11 14:17:13 UTC (rev 291161)
@@ -49,6 +49,9 @@
PASS mask-origin (type: discrete) has testAccumulation function
PASS mask-origin: "border-box" onto "content-box"
PASS mask-origin: "content-box" onto "border-box"
+PASS mask-repeat (type: discrete) has testAccumulation function
+PASS mask-repeat: "round" onto "space"
+PASS mask-repeat: "space" onto "round"
PASS mask-type (type: discrete) has testAccumulation function
PASS mask-type: "luminance" onto "alpha"
PASS mask-type: "alpha" onto "luminance"
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-002-expected.txt (291160 => 291161)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-002-expected.txt 2022-03-11 14:08:29 UTC (rev 291160)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-002-expected.txt 2022-03-11 14:17:13 UTC (rev 291161)
@@ -49,6 +49,9 @@
PASS mask-origin (type: discrete) has testAddition function
PASS mask-origin: "border-box" onto "content-box"
PASS mask-origin: "content-box" onto "border-box"
+PASS mask-repeat (type: discrete) has testAddition function
+PASS mask-repeat: "round" onto "space"
+PASS mask-repeat: "space" onto "round"
PASS mask-type (type: discrete) has testAddition function
PASS mask-type: "luminance" onto "alpha"
PASS mask-type: "alpha" onto "luminance"
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-002-expected.txt (291160 => 291161)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-002-expected.txt 2022-03-11 14:08:29 UTC (rev 291160)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-002-expected.txt 2022-03-11 14:17:13 UTC (rev 291161)
@@ -62,6 +62,10 @@
PASS mask-origin uses discrete animation when animating between "content-box" and "border-box" with linear easing
PASS mask-origin uses discrete animation when animating between "content-box" and "border-box" with effect easing
PASS mask-origin uses discrete animation when animating between "content-box" and "border-box" with keyframe easing
+PASS mask-repeat (type: discrete) has testInterpolation function
+PASS mask-repeat uses discrete animation when animating between "space" and "round" with linear easing
+PASS mask-repeat uses discrete animation when animating between "space" and "round" with effect easing
+PASS mask-repeat uses discrete animation when animating between "space" and "round" with keyframe easing
PASS mask-type (type: discrete) has testInterpolation function
PASS mask-type uses discrete animation when animating between "alpha" and "luminance" with linear easing
PASS mask-type uses discrete animation when animating between "alpha" and "luminance" with effect easing
Modified: trunk/Source/WebCore/ChangeLog (291160 => 291161)
--- trunk/Source/WebCore/ChangeLog 2022-03-11 14:08:29 UTC (rev 291160)
+++ trunk/Source/WebCore/ChangeLog 2022-03-11 14:17:13 UTC (rev 291161)
@@ -1,5 +1,18 @@
2022-03-11 Antoine Quint <[email protected]>
+ [web-animations] mask-repeat should support discrete animation
+ https://bugs.webkit.org/show_bug.cgi?id=237771
+
+ Reviewed by Antti Koivisto.
+
+ * animation/CSSPropertyAnimation.cpp:
+ (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
+ * rendering/style/RenderStyle.h:
+ (WebCore::RenderStyle::setMaskRepeatX):
+ (WebCore::RenderStyle::setMaskRepeatY):
+
+2022-03-11 Antoine Quint <[email protected]>
+
[web-animations] mask-mode should support discrete animation
https://bugs.webkit.org/show_bug.cgi?id=237770
Modified: trunk/Source/WebCore/animation/CSSPropertyAnimation.cpp (291160 => 291161)
--- trunk/Source/WebCore/animation/CSSPropertyAnimation.cpp 2022-03-11 14:08:29 UTC (rev 291160)
+++ trunk/Source/WebCore/animation/CSSPropertyAnimation.cpp 2022-03-11 14:17:13 UTC (rev 291161)
@@ -3023,6 +3023,9 @@
new FillLayersPropertyWrapper(CSSPropertyWebkitMaskPositionY, &RenderStyle::maskLayers, &RenderStyle::ensureMaskLayers),
new FillLayersPropertyWrapper(CSSPropertyMaskSize, &RenderStyle::maskLayers, &RenderStyle::ensureMaskLayers),
+ new DiscretePropertyWrapper<FillRepeat>(CSSPropertyMaskRepeatX, &RenderStyle::maskRepeatX, &RenderStyle::setMaskRepeatX),
+ new DiscretePropertyWrapper<FillRepeat>(CSSPropertyMaskRepeatY, &RenderStyle::maskRepeatY, &RenderStyle::setMaskRepeatY),
+
new LengthPointPropertyWrapper(CSSPropertyObjectPosition, &RenderStyle::objectPosition, &RenderStyle::setObjectPosition),
new PropertyWrapper<float>(CSSPropertyFontSize, &RenderStyle::computedFontSize, &RenderStyle::setFontSize),
@@ -3271,6 +3274,7 @@
CSSPropertyWebkitMask, // for mask-position
CSSPropertyMaskPosition,
CSSPropertyWebkitMaskPosition,
+ CSSPropertyMaskRepeat,
CSSPropertyBorderTop, CSSPropertyBorderRight, CSSPropertyBorderBottom, CSSPropertyBorderLeft,
CSSPropertyBorderColor,
CSSPropertyBorderRadius,
Modified: trunk/Source/WebCore/rendering/style/RenderStyle.h (291160 => 291161)
--- trunk/Source/WebCore/rendering/style/RenderStyle.h 2022-03-11 14:08:29 UTC (rev 291160)
+++ trunk/Source/WebCore/rendering/style/RenderStyle.h 2022-03-11 14:17:13 UTC (rev 291161)
@@ -1056,6 +1056,9 @@
void setMaskBoxImageSource(RefPtr<StyleImage>&& v) { m_rareNonInheritedData.access().maskBoxImage.setImage(WTFMove(v)); }
void setMaskXPosition(Length&& length) { SET_NESTED_VAR(m_rareNonInheritedData, mask, m_xPosition, WTFMove(length)); }
void setMaskYPosition(Length&& length) { SET_NESTED_VAR(m_rareNonInheritedData, mask, m_yPosition, WTFMove(length)); }
+ void setMaskRepeatX(FillRepeat fillRepeat) { SET_NESTED_VAR(m_rareNonInheritedData, mask, m_repeatX, static_cast<unsigned>(fillRepeat)); SET_NESTED_VAR(m_rareNonInheritedData, mask, m_repeatXSet, true); }
+ void setMaskRepeatY(FillRepeat fillRepeat) { SET_NESTED_VAR(m_rareNonInheritedData, mask, m_repeatY, static_cast<unsigned>(fillRepeat)); SET_NESTED_VAR(m_rareNonInheritedData, mask, m_repeatYSet, true); }
+
void setMaskSize(LengthSize size) { SET_NESTED_VAR(m_rareNonInheritedData, mask, m_sizeLength, WTFMove(size)); }
void setBorderCollapse(BorderCollapse collapse) { m_inheritedFlags.borderCollapse = static_cast<unsigned>(collapse); }