Bug 162359

Summary: [macOS] Upon layout, _webView:renderingProgressDidChange: fires before the intrinsic content size is updated
Product: WebKit Reporter: mitz
Component: WebKit2Assignee: mitz
Status: RESOLVED FIXED    
Severity: Normal CC: buildbot, commit-queue, rniwa, thorton
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Defer sending layout milestones to flushLayers()
thorton: review+, buildbot: commit-queue-
Archive of layout-test-results from ews105 for mac-yosemite-wk2 none

Description mitz 2016-09-21 14:05:38 PDT
<rdar://problem/27776454>

On macOS, when a layout milestone is reported to the navigation delegate, it is before the WKWebView’s intrinsic size had a chance to update to reflect the new layout.
Comment 1 mitz 2016-09-21 20:16:06 PDT
Created attachment 289509 [details]
Defer sending layout milestones to flushLayers()
Comment 2 WebKit Commit Bot 2016-09-21 20:17:58 PDT
Attachment 289509 [details] did not pass style-queue:


ERROR: Tools/TestWebKitAPI/Tests/WebKit2Cocoa/AutoLayoutIntegration.mm:163:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
ERROR: Tools/TestWebKitAPI/Tests/WebKit2Cocoa/AutoLayoutIntegration.mm:167:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
Total errors found: 2 in 6 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Build Bot 2016-09-21 21:39:33 PDT
Comment on attachment 289509 [details]
Defer sending layout milestones to flushLayers()

Attachment 289509 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.webkit.org/results/2122849

New failing tests:
fast/images/mask-box-image-crash.html
Comment 4 Build Bot 2016-09-21 21:39:37 PDT
Created attachment 289518 [details]
Archive of layout-test-results from ews105 for mac-yosemite-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews105  Port: mac-yosemite-wk2  Platform: Mac OS X 10.10.5
Comment 5 Tim Horton 2016-09-21 21:59:37 PDT
Comment on attachment 289509 [details]
Defer sending layout milestones to flushLayers()

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

> Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:166
> +    WebCore::LayoutMilestones m_pendingNewlyReachedLayoutMilestones { 0 };

😳
Comment 6 mitz 2016-09-21 22:05:27 PDT
Fixed in <https://trac.webkit.org/r206247>.
Comment 7 mitz 2016-11-02 14:02:29 PDT
(In reply to comment #6)
> Fixed in <https://trac.webkit.org/r206247>.

This caused bug 164340.