Bug 146765

Summary: [Cocoa] Report the first paint after committing a load as a rendering progress event
Product: WebKit Reporter: mitz
Component: WebKit2Assignee: mitz
Status: RESOLVED FIXED    
Severity: Normal CC: andersca, simon.fraser, thorton
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Add _WKRenderingProgressEventFirstPaint thorton: review+

Description mitz 2015-07-08 17:41:15 PDT
Allow clients to synchronize changes to their UI with the committed page painting for the first time (replacing the previous page) by reporting this as a rendering progress event.
Comment 1 mitz 2015-07-08 17:44:30 PDT
Created attachment 256441 [details]
Add _WKRenderingProgressEventFirstPaint
Comment 2 Tim Horton 2015-07-08 18:15:14 PDT
Comment on attachment 256441 [details]
Add _WKRenderingProgressEventFirstPaint

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

> Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:975
> +            _navigationState->didFirstPaint();

Will _needsResetViewStateAfterCommitLoadForMainFrame always be true in the necessary cases?
Comment 3 mitz 2015-07-08 20:11:17 PDT
Comment on attachment 256441 [details]
Add _WKRenderingProgressEventFirstPaint

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

>> Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:975
>> +            _navigationState->didFirstPaint();
> 
> Will _needsResetViewStateAfterCommitLoadForMainFrame always be true in the necessary cases?

I think so? It gets set to YES when the load is committed. Do you have a specific concern?
Comment 4 Tim Horton 2015-07-08 23:04:46 PDT
Comment on attachment 256441 [details]
Add _WKRenderingProgressEventFirstPaint

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

>>> Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:975
>>> +            _navigationState->didFirstPaint();
>> 
>> Will _needsResetViewStateAfterCommitLoadForMainFrame always be true in the necessary cases?
> 
> I think so? It gets set to YES when the load is committed. Do you have a specific concern?

Not at all, just couldn't check at the time and the name is not quite so definitive. Sounds good to me!
Comment 5 mitz 2015-07-09 00:03:05 PDT
Committed <http://trac.webkit.org/r186586>.