Bug 226313

Summary: Sampled Page Top Color: allow snapshotting of elements with CSS animations/transitions if they're paused
Product: WebKit Reporter: Devin Rousso <hi>
Component: New BugsAssignee: Devin Rousso <hi>
Status: RESOLVED FIXED    
Severity: Normal CC: bdakin, darin, hi, thorton, webkit-bug-importer, wenson_hsieh
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=225338
Attachments:
Description Flags
Patch
none
Patch none

Description Devin Rousso 2021-05-26 20:23:47 PDT
.
Comment 1 Devin Rousso 2021-05-26 20:24:01 PDT
<rdar://problem/78534076>
Comment 2 Devin Rousso 2021-05-26 20:30:38 PDT
Created attachment 429836 [details]
Patch
Comment 3 Tim Horton 2021-05-27 11:58:21 PDT
Comment on attachment 429836 [details]
Patch

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

> Source/WebCore/ChangeLog:12
> +        animation/transition is. This is only really an issue for CSS animations/transitions that
> +        are actively running, not ones that have yet to run or have finished.

Kinda weird logic? It's a race; if the animation wins the race all the way, you're treating it like the race never happened?

(if you snapshot the same page twice, and catch it in the animation the first time, and after the animation is done the second time, you'll get two different colors after your patch where you would have gotten the same color before it?)

(I also don't know that any of this is at all important)
Comment 4 Devin Rousso 2021-05-27 17:48:17 PDT
Created attachment 429967 [details]
Patch
Comment 5 EWS 2021-05-27 22:02:57 PDT
Committed r278189 (238232@main): <https://commits.webkit.org/238232@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 429967 [details].
Comment 6 Darin Adler 2021-06-01 14:47:15 PDT
Comment on attachment 429967 [details]
Patch

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

> Source/WebCore/page/PageColorSampler.cpp:31
> +#include "Element.h"

This should not be needed. HTMLCanvasElement and HTMLIFrameElement are both derived from Element, so there would be no need to include the "grand-base" class too.