Changeset 274383 in webkit
- Timestamp:
- Mar 13, 2021 2:57:21 AM (16 months ago)
- Location:
- trunk
- Files:
-
- 6 added
- 3 edited
-
LayoutTests/imported/w3c/ChangeLog (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-break (added)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-break/animation (added)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-break/animation/orphans-interpolation-expected.txt (added)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-break/animation/orphans-interpolation.html (added)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-break/animation/widows-interpolation-expected.txt (added)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-break/animation/widows-interpolation.html (added)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/animation/CSSPropertyAnimation.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/imported/w3c/ChangeLog
r274379 r274383 1 2021-03-12 Antoine Quint <graouts@webkit.org> 2 3 Fix interpolation of orphans and widows CSS properties 4 https://bugs.webkit.org/show_bug.cgi?id=223124 5 6 Reviewed by Darin Adler. 7 8 Import interpolation tests for orphans and widows. These tests pass completely 9 weith 44 PASS results compared to prior to the source changes. 10 11 * web-platform-tests/css/css-break/animation/orphans-interpolation-expected.txt: Added. 12 * web-platform-tests/css/css-break/animation/orphans-interpolation.html: Added. 13 * web-platform-tests/css/css-break/animation/widows-interpolation-expected.txt: Added. 14 * web-platform-tests/css/css-break/animation/widows-interpolation.html: Added. 15 1 16 2021-03-13 Alexey Shvayka <shvaikalesh@gmail.com> 2 17 -
trunk/Source/WebCore/ChangeLog
r274382 r274383 1 2021-03-12 Antoine Quint <graouts@webkit.org> 2 3 Fix interpolation of orphans and widows CSS properties 4 https://bugs.webkit.org/show_bug.cgi?id=223124 5 6 Reviewed by Darin Adler. 7 8 The orphans and widows properties must be positive integers, so we add a dedicated 9 wrapper for these properties. 10 11 Tests: imported/w3c/web-platform-tests/css/css-break/animation/orphans-interpolation.html 12 imported/w3c/web-platform-tests/css/css-break/animation/widows-interpolation.html 13 14 * animation/CSSPropertyAnimation.cpp: 15 (WebCore::PositivePropertyWrapper::PositivePropertyWrapper): 16 (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap): 17 1 18 2021-03-13 Fujii Hironori <Hironori.Fujii@sony.com> 2 19 -
trunk/Source/WebCore/animation/CSSPropertyAnimation.cpp
r274355 r274383 640 640 641 641 template <typename T> 642 class PositivePropertyWrapper final : public PropertyWrapper<T> { 643 WTF_MAKE_FAST_ALLOCATED; 644 public: 645 PositivePropertyWrapper(CSSPropertyID property, T (RenderStyle::*getter)() const, void (RenderStyle::*setter)(T)) 646 : PropertyWrapper<T>(property, getter, setter) 647 { 648 } 649 650 private: 651 652 void blend(const CSSPropertyBlendingClient* client, RenderStyle* destination, const RenderStyle* from, const RenderStyle* to, double progress) const final 653 { 654 auto blendedValue = blendFunc(client, this->value(from), this->value(to), progress); 655 (destination->*this->m_setter)(blendedValue > 1 ? blendedValue : 1); 656 } 657 }; 658 659 template <typename T> 642 660 class DiscretePropertyWrapper : public PropertyWrapperGetter<T> { 643 661 WTF_MAKE_FAST_ALLOCATED; … … 1947 1965 new PropertyWrapper<float>(CSSPropertyWebkitBorderVerticalSpacing, &RenderStyle::verticalBorderSpacing, &RenderStyle::setVerticalBorderSpacing), 1948 1966 new AutoPropertyWrapper<int>(CSSPropertyZIndex, &RenderStyle::specifiedZIndex, &RenderStyle::setSpecifiedZIndex, &RenderStyle::hasAutoSpecifiedZIndex, &RenderStyle::setHasAutoSpecifiedZIndex), 1949 new P ropertyWrapper<unsigned short>(CSSPropertyOrphans, &RenderStyle::orphans, &RenderStyle::setOrphans),1950 new P ropertyWrapper<unsigned short>(CSSPropertyWidows, &RenderStyle::widows, &RenderStyle::setWidows),1967 new PositivePropertyWrapper<unsigned short>(CSSPropertyOrphans, &RenderStyle::orphans, &RenderStyle::setOrphans), 1968 new PositivePropertyWrapper<unsigned short>(CSSPropertyWidows, &RenderStyle::widows, &RenderStyle::setWidows), 1951 1969 new LengthPropertyWrapper(CSSPropertyLineHeight, &RenderStyle::specifiedLineHeight, &RenderStyle::setLineHeight), 1952 1970 new PropertyWrapper<float>(CSSPropertyOutlineOffset, &RenderStyle::outlineOffset, &RenderStyle::setOutlineOffset),
Note: See TracChangeset
for help on using the changeset viewer.