[webkit-reviews] review granted: [Bug 208079] AnimationTimeline should not have multiple HashMaps with raw Element* keys : [Attachment 393252] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Mar 11 13:15:30 PDT 2020


Ryosuke Niwa <rniwa at webkit.org> has granted Antoine Quint
<graouts at webkit.org>'s request for review:
Bug 208079: AnimationTimeline should not have multiple HashMaps with raw
Element* keys
https://bugs.webkit.org/show_bug.cgi?id=208079

Attachment 393252: Patch

https://bugs.webkit.org/attachment.cgi?id=393252&action=review




--- Comment #13 from Ryosuke Niwa <rniwa at webkit.org> ---
Comment on attachment 393252
  --> https://bugs.webkit.org/attachment.cgi?id=393252
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=393252&action=review

> Source/WebCore/animation/AnimationTimeline.cpp:105
> +    if (is<CSSTransition>(animation) &&
downcast<CSSTransition>(animation).owningElement())
> +	   element.transitions().add(&animation);

Should we check that the owning element is same as element here??

> Source/WebCore/animation/AnimationTimeline.cpp:107
> +    else if (is<CSSAnimation>(animation) &&
downcast<CSSAnimation>(animation).owningElement())
> +	   element.cssAnimations().add(&animation);

Ditto.

> Source/WebCore/animation/ElementAnimationRareData.h:38
> +    WTF_MAKE_FAST_ALLOCATED;

Make this not copyable?

> Source/WebCore/dom/Element.h:496
> +    AnimationCollection& webAnimations();

Should we also forward declare AnimationCollection & CSSAnimationCollection?


More information about the webkit-reviews mailing list