[webkit-reviews] review granted: [Bug 128632] GIF animations should be suspended when outside of viewport : [Attachment 223923] patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Feb 11 17:50:22 PST 2014
Andreas Kling <akling at apple.com> has granted Antti Koivisto <koivisto at iki.fi>'s
request for review:
Bug 128632: GIF animations should be suspended when outside of viewport
https://bugs.webkit.org/show_bug.cgi?id=128632
Attachment 223923: patch
https://bugs.webkit.org/attachment.cgi?id=223923&action=review
------- Additional Comments from Andreas Kling <akling at apple.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=223923&action=review
r=me
> Source/WebCore/page/Page.cpp:1149
> + if (frame->contentRenderer())
> + frame->contentRenderer()->resumePausedImageAnimationsIfNeeded();
I'd put the renderer in a local.
> Source/WebCore/rendering/RenderElement.cpp:1287
> + if (document.view()->isOffscreen())
> + return false;
renderer.frameView().isOffscreen()
> Source/WebCore/rendering/RenderElement.cpp:1290
> + if (document.frame()->timersPaused())
> + return false;
renderer.frame().timersPaused()
> Source/WebCore/rendering/RenderElement.cpp:1304
> + auto visibleRect = document().view()->visibleContentRect();
frameView().visibleContentRect()
> Source/WebCore/rendering/RenderElement.h:206
> + virtual void newImageAnimationFrameAvailable(CachedImage&) override;
This should be final, too!
> Source/WebCore/rendering/RenderView.cpp:1181
> +void RenderView::addRendererWithPausedImageAnimations( RenderElement&
renderer)
Weird space here!
> Source/WebCore/rendering/RenderView.cpp:1203
> + Vector<RenderElement*> toRemove;
I'd give this some token inline capacity.
More information about the webkit-reviews
mailing list