Bug 204828 - Flash of white when loading QQ
Summary: Flash of white when loading QQ
Status: RESOLVED DUPLICATE of bug 207516
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-12-03 17:30 PST by Ben Nham
Modified: 2020-02-13 13:15 PST (History)
8 users (show)

See Also:


Attachments
qq page loading transition (2.09 MB, video/quicktime)
2019-12-03 17:30 PST, Ben Nham
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ben Nham 2019-12-03 17:30:20 PST
Created attachment 384772 [details]
qq page loading transition

When I visit qq.com, I see a flash of white before the actual content fills in. See the 3 second mark in the attached video, which I took on a recent trunk release build of Safari.

This may be because we complete the page transition (which unfreezes the layer tree) on the first layout rather than the first visually-non-empty layout. There's a comment about this in WebFrameLoaderClient::dispatchDidReachLayoutMilestone:

    if (milestones & DidFirstLayout) {
        // ...

    #if PLATFORM(MAC)
        // FIXME: Do this on DidFirstVisuallyNonEmptyLayout when Mac Safari is able to handle it (<rdar://problem/17580021>)
        if (m_frame->isMainFrame() && !m_didCompletePageTransition && !webPage->corePage()->settings().suppressesIncrementalRendering()) {
            RELEASE_LOG(Layout, "%p - WebFrameLoaderClient::dispatchDidReachLayoutMilestone: dispatching didCompletePageTransition, page = %p", this, webPage);
            webPage->didCompletePageTransition();
            m_didCompletePageTransition = true;
        }
    #endif
Comment 1 Radar WebKit Bug Importer 2019-12-03 17:31:47 PST
<rdar://problem/57609711>
Comment 2 Maciej Stachowiak 2019-12-05 13:07:19 PST
I noticed that this happens when navigating to qq.com via the location field, but *not* when clicking a link to qq.com, or navigating there via JavaScript in a page. Perhaps the white flash is an artifact of WebView swapping (which Safari does for location field navigation and favorites, but not for in-page links)?

I think other pages white-flash too, possibly for similar reasons.
Comment 3 Ben Nham 2020-02-13 13:15:13 PST
This particular flash of white looks more like a Safari-specific issue in the way navbar loads are handled, which we are tracking in <rdar://problem/58936254>.

There is another issue in WebKit that can cause certain websites (but not QQ) to flash white when an early layout occurs, which we're tracking in https://bugs.webkit.org/show_bug.cgi?id=207516.

*** This bug has been marked as a duplicate of bug 207516 ***