WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
222816
Improve blending of Length and other Length-related types
https://bugs.webkit.org/show_bug.cgi?id=222816
Summary
Improve blending of Length and other Length-related types
Antoine Quint
Reported
2021-03-05 12:25:32 PST
Improve blending of Length and other Length-related types
Attachments
Patch for EWS
(222.49 KB, patch)
2021-03-05 12:25 PST
,
Antoine Quint
no flags
Details
Formatted Diff
Diff
Patch for EWS
(228.83 KB, patch)
2021-03-06 03:30 PST
,
Antoine Quint
no flags
Details
Formatted Diff
Diff
Patch
(240.98 KB, patch)
2021-03-06 06:32 PST
,
Antoine Quint
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Antoine Quint
Comment 1
2021-03-05 12:25:58 PST
Created
attachment 422394
[details]
Patch for EWS
Antoine Quint
Comment 2
2021-03-06 03:30:53 PST
Created
attachment 422482
[details]
Patch for EWS
Antoine Quint
Comment 3
2021-03-06 06:32:14 PST
Created
attachment 422490
[details]
Patch
Antoine Quint
Comment 4
2021-03-06 06:33:15 PST
***
Bug 222514
has been marked as a duplicate of this bug. ***
Antti Koivisto
Comment 5
2021-03-06 07:05:46 PST
Comment on
attachment 422490
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=422490&action=review
> Source/WebCore/animation/CSSPropertyAnimation.cpp:703 > class LengthPropertyWrapper : public PropertyWrapperGetter<const Length&> { > WTF_MAKE_FAST_ALLOCATED; > public: > - LengthPropertyWrapper(CSSPropertyID prop, const Length& (RenderStyle::*getter)() const, void (RenderStyle::*setter)(Length&&)) > + enum class Flags { > + IsLengthPercentage = 1 << 0, > + NegativeLengthsAreInvalid = 1 << 1, > + }; > + LengthPropertyWrapper(CSSPropertyID prop, const Length& (RenderStyle::*getter)() const, void (RenderStyle::*setter)(Length&&), OptionSet<Flags> flags = { })
I think you could make the flags a template argument instead as they are fixed for a given property type. Not sure if this has much practical significance though and could be done separately.
> Source/WebCore/animation/CSSPropertyAnimation.cpp:712 > - return !this->value(a).isAuto() && !this->value(b).isAuto(); > + return canInterpolateLengths(this->value(a), this->value(b), m_flags.contains(Flags::IsLengthPercentage));
Then canInterpolateLengths would also take IsLengthPercentage as template argument.
EWS
Comment 6
2021-03-06 08:28:32 PST
Committed
r274038
: <
https://commits.webkit.org/r274038
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 422490
[details]
.
Radar WebKit Bug Importer
Comment 7
2021-03-06 08:29:17 PST
<
rdar://problem/75133641
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug