Bug 124872 - Remote Layer Tree: Hook up setLayerTreeStateIsFrozen
Summary: Remote Layer Tree: Hook up setLayerTreeStateIsFrozen
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Tim Horton
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-25 17:12 PST by Tim Horton
Modified: 2013-12-02 12:55 PST (History)
4 users (show)

See Also:


Attachments
patch (4.76 KB, patch)
2013-11-25 17:14 PST, Tim Horton
bfulgham: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Horton 2013-11-25 17:12:51 PST
To make printing not kill the main page.

We can just keep deferring the flush until we get unfrozen; all of the property changes will just keep accumulating.
Comment 1 Tim Horton 2013-11-25 17:14:58 PST
Created attachment 217849 [details]
patch
Comment 2 Brent Fulgham 2013-11-26 19:18:45 PST
Comment on attachment 217849 [details]
patch

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

r=me. But please consider whether the "optimization" or "flush avoidance" I suggested makes any sense.

> Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeContext.mm:145
> +    if (!m_isFlushingSuspended && m_hasDeferredFlush) {

Should we bother checking if our original state was already "!m_isFlushingSuspended" and only schedule the layer flush for the case where state is changing?

I.e.:

if (m_isFlushingSuspended == isFrozen)
    return;

... before doing the rest of your code?
Comment 3 Tim Horton 2013-12-02 12:55:38 PST
http://trac.webkit.org/changeset/159956