Bug 90401

Summary: Compositing layer sync should cause deferred repaints to be fired immediately
Product: WebKit Reporter: Tim Horton <thorton>
Component: Layout and RenderingAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: koivisto, simon.fraser, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
patch koivisto: review+, simon.fraser: commit-queue-

Description Tim Horton 2012-07-02 14:19:54 PDT
When we sync compositing layer state, we need to paint immediately, no matter what; otherwise we might see a visible flash before painting occurs.
Comment 1 Radar WebKit Bug Importer 2012-07-02 14:20:32 PDT
<rdar://problem/11792028>
Comment 2 Tim Horton 2012-07-02 14:30:09 PDT
Created attachment 150475 [details]
patch
Comment 3 Simon Fraser (smfr) 2012-07-02 14:51:42 PDT
Comment on attachment 150475 [details]
patch

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

> Source/WebCore/page/FrameView.cpp:752
>      root->compositor()->flushPendingLayerChanges(rootFrameForSync == m_frame);
>  
> +    // If we sync compositing layers and allow the repaint to be deferred, there is time for a
> +    // visible flash to occur. Instead, stop the deferred repaint timer and repaint immediately.
> +    stopDelayingDeferredRepaints();

I think we should swap these around.

If deferred repaints at some point affects compositing layers (it does not yet), then we'd want those repaints to get flushed.
Comment 4 Antti Koivisto 2012-07-02 15:00:44 PDT
Comment on attachment 150475 [details]
patch

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

> Source/WebCore/page/FrameView.cpp:1948
> +    if (!m_deferredRepaintTimer.isActive())
> +        return;
> +
>      m_deferredRepaintTimer.stop();

This does not make any sense.
Comment 5 Antti Koivisto 2012-07-02 15:03:07 PDT
Comment on attachment 150475 [details]
patch

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

>> Source/WebCore/page/FrameView.cpp:1948
>>      m_deferredRepaintTimer.stop();
> 
> This does not make any sense.

Actually it does, I misread!
Comment 6 Tim Horton 2012-07-02 15:15:23 PDT
http://trac.webkit.org/changeset/121708