DescriptionRework timeline/frame scheduling logic for SVGImage
This CL provides the SVGImage/SVGImageChromeClient complex with the
capability of suspending and resuming the frame/animation tick.
This gives us the mechanism required to respond to
ImageObserver::shouldPauseAnimation, as well as stopping the animation
timer from running after the animation has been reset (via
Image::resetAnimation.)
In the context of the bug referenced this means an animating SVG image
will no longer cause wakeups because of (unnecessary) timer activity,
saving power (and CPU time.)
Implement willRenderImage() for the CrossfadeSubimageObserverProxy of
CSSCrossfadeValue so that it will not (falsely) claim that it won't
render its images.
While doing this, try to make a decent functional split between SVGImage
and the associated SVGImageChromeClient by putting all timeline/frame tick
related code in the latter, while keeping code related to the actual
animation/document lifecycle update in the former.
BUG=612540
Committed: https://crrev.com/5ad4faa93d2554ffab7f72a992adbeffa8796f94
Cr-Commit-Position: refs/heads/master@{#396009}
Patch Set 1 #Patch Set 2 : Undo removal of SVGImageChromeClient::image() #Patch Set 3 : Touch up some comments #Patch Set 4 : More comment touchups #Patch Set 5 : Make initial timeline state be 'running' #Patch Set 6 : CSSCrossfadeValue needs to reply truthfully to willRenderImage. #
Total comments: 6
Patch Set 7 : Attempt to simplify #Patch Set 8 : Add unittest #
Total comments: 3
Messages
Total messages: 20 (5 generated)
|