Diff
Modified: branches/safari-603-branch/LayoutTests/ChangeLog (212489 => 212490)
--- branches/safari-603-branch/LayoutTests/ChangeLog 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/LayoutTests/ChangeLog 2017-02-17 00:55:59 UTC (rev 212490)
@@ -72,6 +72,97 @@
2017-02-16 Matthew Hanson <[email protected]>
+ Merge r211683. rdar://problem/30467272
+
+ 2017-02-04 Simon Fraser <[email protected]>
+
+ Clean up how GraphicsLayer's "inWindow" state is set, and fix some issues with Page Overlays
+ https://bugs.webkit.org/show_bug.cgi?id=167850
+
+ Reviewed by Tim Horton.
+
+ * pageoverlay/overlay-large-document-expected.txt:
+ * pageoverlay/overlay-large-document-scrolled-expected.txt:
+ * pageoverlay/overlay-remove-reinsert-view-expected.txt: Added.
+ * pageoverlay/overlay-remove-reinsert-view.html: Added.
+ * platform/ios-simulator-wk2/pageoverlay/overlay-remove-reinsert-view-expected.txt: Added.
+ * platform/mac-wk1/pageoverlay/overlay-remove-reinsert-view-expected.txt: Added.
+ * tiled-drawing/tiled-backing-in-window-expected.txt:
+
+2017-02-16 Matthew Hanson <[email protected]>
+
+ Merge r211662. rdar://problem/30467322
+
+ 2017-02-03 Simon Fraser <[email protected]>
+
+ Correctly set the "inWindow" flag for TileControllers that aren't the page tiles, and clarify "usingTiledBacking" logic
+ https://bugs.webkit.org/show_bug.cgi?id=167774
+
+ Reviewed by Tim Horton.
+
+ Rebase to include the "in window" output.
+
+ tiled-drawing/background-transparency-toggle.html was sensitive to the length of the output, so give the body
+ a fixed size.
+
+ * compositing/tiling/offscreen-tiled-layer-expected.txt:
+ * compositing/tiling/transform-origin-tiled-expected.txt:
+ * platform/mac-wk1/compositing/tiling/offscreen-tiled-layer-expected.txt:
+ * platform/mac-wk1/compositing/tiling/transform-origin-tiled-expected.txt:
+ * platform/mac-wk2/compositing/tiling/rotated-tiled-clamped-expected.txt:
+ * platform/mac-wk2/compositing/tiling/rotated-tiled-preserve3d-clamped-expected.txt:
+ * platform/mac-wk2/compositing/tiling/tile-cache-zoomed-expected.txt:
+ * platform/mac-wk2/compositing/tiling/tiled-layer-resize-expected.txt:
+ * platform/mac/compositing/tiling/rotated-tiled-clamped-expected.txt:
+ * platform/mac/compositing/tiling/rotated-tiled-preserve3d-clamped-expected.txt:
+ * platform/mac/compositing/tiling/tiled-layer-resize-expected.txt:
+ * tiled-drawing/background-transparency-toggle-expected.txt:
+ * tiled-drawing/background-transparency-toggle.html:
+ * tiled-drawing/scrolling/fast-scroll-div-latched-div-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-div-latched-div-with-handler-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-div-latched-mainframe-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-div-latched-mainframe-with-handler-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-iframe-latched-iframe-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-iframe-latched-iframe-with-handler-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-iframe-latched-mainframe-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-iframe-latched-mainframe-with-handler-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-select-latched-mainframe-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-select-latched-mainframe-with-handler-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-select-latched-select-expected.txt:
+ * tiled-drawing/scrolling/fast-scroll-select-latched-select-with-handler-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-background-no-image-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-body-background-body-layer-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-body-background-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-body-background-opacity-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-body-background-positioned-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-body-background-transformed-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-body-background-zoomed-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-html-background-expected.txt:
+ * tiled-drawing/scrolling/fixed-background/fixed-non-propagated-body-background-expected.txt:
+ * tiled-drawing/scrolling/fixed/four-bars-zoomed-expected.txt:
+ * tiled-drawing/simple-document-with-margin-tiles-expected.txt:
+ * tiled-drawing/tile-coverage-after-scroll-expected.txt:
+ * tiled-drawing/tile-coverage-after-scroll-speculative-expected.txt:
+ * tiled-drawing/tile-coverage-scroll-to-bottom-expected.txt:
+ * tiled-drawing/tile-coverage-slow-scrolling-expected.txt:
+ * tiled-drawing/tile-coverage-speculative-expected.txt:
+ * tiled-drawing/tile-coverage-view-exposed-rect-expected.txt:
+ * tiled-drawing/tile-size-both-scrollable-expected.txt:
+ * tiled-drawing/tile-size-horizontally-scrollable-expected.txt:
+ * tiled-drawing/tile-size-slow-zoomed-expected.txt:
+ * tiled-drawing/tile-size-unscrollable-expected.txt:
+ * tiled-drawing/tile-size-vertically-scrollable-expected.txt:
+ * tiled-drawing/tile-size-view-exposed-rect-expected.txt:
+ * tiled-drawing/tiled-backing-in-window-expected.txt: Added.
+ * tiled-drawing/tiled-backing-in-window.html: Added.
+ * tiled-drawing/tiled-drawing-scroll-position-page-cache-restoration-expected.txt:
+ * tiled-drawing/tiled-drawing-zoom-expected.txt:
+ * tiled-drawing/tiled-drawing-zoom-scrolled-expected.txt:
+ * tiled-drawing/use-tiled-drawing-expected.txt:
+ * tiled-drawing/visible-rect-content-inset-expected.txt:
+
+2017-02-16 Matthew Hanson <[email protected]>
+
Merge r211501. rdar://problem/29904368
2017-02-01 Antoine Quint <[email protected]>
Modified: branches/safari-603-branch/LayoutTests/pageoverlay/overlay-large-document-expected.txt (212489 => 212490)
--- branches/safari-603-branch/LayoutTests/pageoverlay/overlay-large-document-expected.txt 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/LayoutTests/pageoverlay/overlay-large-document-expected.txt 2017-02-17 00:55:59 UTC (rev 212490)
@@ -8,7 +8,7 @@
(children 1
(GraphicsLayer
(anchor 0.00 0.00)
- (bounds 785.00 585.00)
+ (bounds 800.00 600.00)
(drawsContent 1)
(backgroundColor #00000000)
)
Modified: branches/safari-603-branch/LayoutTests/pageoverlay/overlay-large-document-scrolled-expected.txt (212489 => 212490)
--- branches/safari-603-branch/LayoutTests/pageoverlay/overlay-large-document-scrolled-expected.txt 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/LayoutTests/pageoverlay/overlay-large-document-scrolled-expected.txt 2017-02-17 00:55:59 UTC (rev 212490)
@@ -8,7 +8,7 @@
(children 1
(GraphicsLayer
(anchor 0.00 0.00)
- (bounds 785.00 585.00)
+ (bounds 800.00 600.00)
(drawsContent 1)
(backgroundColor #00000000)
)
Added: branches/safari-603-branch/LayoutTests/pageoverlay/overlay-remove-reinsert-view-expected.txt (0 => 212490)
--- branches/safari-603-branch/LayoutTests/pageoverlay/overlay-remove-reinsert-view-expected.txt (rev 0)
+++ branches/safari-603-branch/LayoutTests/pageoverlay/overlay-remove-reinsert-view-expected.txt 2017-02-17 00:55:59 UTC (rev 212490)
@@ -0,0 +1,76 @@
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 785, 585)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (512, 512, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 512, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (512, 0, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 785, 585)
+Initial layers
+
+View-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 800.00 600.00)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ )
+ )
+)
+
+
+Document-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 5008.00 5016.00)
+ (usingTiledLayer 1)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ (tile cache coverage 0, 0 1024 x 1024)
+ (tile size 512 x 512)
+ (top left tile 0, 0 tiles grid 2 x 2)
+ (in window 1)
+ )
+ )
+)
+Layers after removal
+
+View-relative:
+(no view-relative overlay root)
+
+Document-relative:
+(no document-relative overlay root)
+Layers after re-insertion
+
+View-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 785.00 585.00)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ )
+ )
+)
+
+
+Document-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 5008.00 5016.00)
+ (usingTiledLayer 1)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ (tile cache coverage 0, 0 1024 x 1024)
+ (tile size 512 x 512)
+ (top left tile 0, 0 tiles grid 2 x 2)
+ (in window 1)
+ )
+ )
+)
+
Added: branches/safari-603-branch/LayoutTests/pageoverlay/overlay-remove-reinsert-view.html (0 => 212490)
--- branches/safari-603-branch/LayoutTests/pageoverlay/overlay-remove-reinsert-view.html (rev 0)
+++ branches/safari-603-branch/LayoutTests/pageoverlay/overlay-remove-reinsert-view.html 2017-02-17 00:55:59 UTC (rev 212490)
@@ -0,0 +1,87 @@
+<html>
+<style>
+body {
+ height: 5000px;
+ width: 5000px;
+}
+</style>
+<script>
+ if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.waitUntilDone();
+ }
+
+ function getWaitForPresentationUpdateUIScript()
+ {
+ return `
+ (function() {
+ uiController.doAfterPresentationUpdate(function() {
+ uiController.uiScriptComplete('');
+ });
+ })();`
+ }
+
+ function getUnparentUIScript()
+ {
+ return `
+ (function() {
+ uiController.removeViewFromWindow(function() {
+ uiController.uiScriptComplete('');
+ });
+ })();`
+ }
+
+ function getReinsertUIScript()
+ {
+ return `
+ (function() {
+ uiController.addViewToWindow(function() {
+ uiController.uiScriptComplete('');
+ });
+ })();`
+ }
+
+ function dumpLayers(outputId)
+ {
+ if (window.internals) {
+ document.getElementById(outputId).innerText = window.internals.pageOverlayLayerTreeAsText(internals.LAYER_TREE_INCLUDES_TILE_CACHES);
+ }
+ }
+
+ function doTest()
+ {
+ if (!window.testRunner || !testRunner.runUIScript)
+ return;
+
+ internals.installMockPageOverlay("document");
+ internals.installMockPageOverlay("view");
+
+ // Waiting for a presentation update is needed to get the document overlay to become tiled.
+ testRunner.runUIScript(getWaitForPresentationUpdateUIScript(), function(result) {
+ dumpLayers('before-layers');
+
+ testRunner.runUIScript(getUnparentUIScript(), function(result) {
+ dumpLayers('view-removed-layers');
+
+ testRunner.runUIScript(getReinsertUIScript(), function(result) {
+ dumpLayers('view-reinsertion-layers');
+ if (window.testRunner)
+ testRunner.notifyDone();
+ });
+ });
+ });
+ }
+
+ window.addEventListener('load', doTest, false);
+</script>
+<body>
+ <h2>Initial layers</h2>
+ <pre id="before-layers">Layer tree goes here</pre>
+
+ <h2>Layers after removal</h2>
+ <pre id="view-removed-layers">Layer tree goes here</pre>
+
+ <h2>Layers after re-insertion</h2>
+ <pre id="view-reinsertion-layers">Layer tree goes here</pre>
+</body>
+</html>
\ No newline at end of file
Added: branches/safari-603-branch/LayoutTests/platform/ios-simulator-wk2/pageoverlay/overlay-remove-reinsert-view-expected.txt (0 => 212490)
--- branches/safari-603-branch/LayoutTests/platform/ios-simulator-wk2/pageoverlay/overlay-remove-reinsert-view-expected.txt (rev 0)
+++ branches/safari-603-branch/LayoutTests/platform/ios-simulator-wk2/pageoverlay/overlay-remove-reinsert-view-expected.txt 2017-02-17 00:55:59 UTC (rev 212490)
@@ -0,0 +1,100 @@
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (512, 0, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 512, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (512, 512, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 800, 600)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 800, 600)
+Initial layers
+
+View-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 800.00 600.00)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ )
+ )
+)
+
+
+Document-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 5008.00 5016.00)
+ (usingTiledLayer 1)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ (tile cache coverage 0, 0 1024 x 1024)
+ (tile size 512 x 512)
+ (top left tile 0, 0 tiles grid 2 x 2)
+ (in window 1)
+ )
+ )
+)
+Layers after removal
+
+View-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 800.00 600.00)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ )
+ )
+)
+
+
+Document-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 5008.00 5016.00)
+ (usingTiledLayer 1)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ (tile cache coverage 0, 0 1024 x 1024)
+ (tile size 512 x 512)
+ (top left tile 0, 0 tiles grid 2 x 2)
+ (in window 1)
+ )
+ )
+)
+Layers after re-insertion
+
+View-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 800.00 600.00)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ )
+ )
+)
+
+
+Document-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 5008.00 5016.00)
+ (usingTiledLayer 1)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ (tile cache coverage 0, 0 1024 x 1024)
+ (tile size 512 x 512)
+ (top left tile 0, 0 tiles grid 2 x 2)
+ (in window 1)
+ )
+ )
+)
+
Modified: branches/safari-603-branch/LayoutTests/platform/mac-wk1/TestExpectations (212489 => 212490)
--- branches/safari-603-branch/LayoutTests/platform/mac-wk1/TestExpectations 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/LayoutTests/platform/mac-wk1/TestExpectations 2017-02-17 00:55:59 UTC (rev 212490)
@@ -295,3 +295,5 @@
webkit.org/b/165589 pointer-lock/lock-lost-on-esc-in-fullscreen.html [ Skip ]
webkit.org/b/167127 pointer-lock/locked-element-removed-from-dom.html
+
+webkit.org/b/167857 pageoverlay/overlay-remove-reinsert-view.html [ Skip ]
Added: branches/safari-603-branch/LayoutTests/platform/mac-wk1/pageoverlay/overlay-remove-reinsert-view-expected.txt (0 => 212490)
--- branches/safari-603-branch/LayoutTests/platform/mac-wk1/pageoverlay/overlay-remove-reinsert-view-expected.txt (rev 0)
+++ branches/safari-603-branch/LayoutTests/platform/mac-wk1/pageoverlay/overlay-remove-reinsert-view-expected.txt 2017-02-17 00:55:59 UTC (rev 212490)
@@ -0,0 +1,74 @@
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (512, 512, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 512, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (512, 0, 512, 512)
+CONSOLE MESSAGE: MockPageOverlayClient::drawRect dirtyRect (0, 0, 512, 512)
+Initial layers
+
+View-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 800.00 600.00)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ )
+ )
+)
+
+
+Document-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 5008.00 5016.00)
+ (usingTiledLayer 1)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ (tile cache coverage 0, 0 1024 x 1024)
+ (tile size 512 x 512)
+ (top left tile 0, 0 tiles grid 2 x 2)
+ (in window 1)
+ )
+ )
+)
+Layers after removal
+
+View-relative:
+(no view-relative overlay root)
+
+Document-relative:
+(no document-relative overlay root)
+Layers after re-insertion
+
+View-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 800.00 600.00)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ )
+ )
+)
+
+
+Document-relative:
+(GraphicsLayer
+ (children 1
+ (GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 5008.00 5016.00)
+ (usingTiledLayer 1)
+ (drawsContent 1)
+ (backgroundColor #00000000)
+ (tile cache coverage 0, 0 1024 x 1024)
+ (tile size 512 x 512)
+ (top left tile 0, 0 tiles grid 2 x 2)
+ (in window 1)
+ )
+ )
+)
+
Modified: branches/safari-603-branch/LayoutTests/tiled-drawing/tiled-backing-in-window-expected.txt (212489 => 212490)
--- branches/safari-603-branch/LayoutTests/tiled-drawing/tiled-backing-in-window-expected.txt 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/LayoutTests/tiled-drawing/tiled-backing-in-window-expected.txt 2017-02-17 00:55:59 UTC (rev 212490)
@@ -55,7 +55,11 @@
(tile cache coverage 0, 0 1024 x 1016)
(tile size 512 x 512)
(top left tile 0, 0 tiles grid 2 x 2)
+<<<<<<< Updated upstream
(in window 0)
+=======
+ (in window 1)
+>>>>>>> Stashed changes
(children 1
(GraphicsLayer
(position 8.00 8.00)
Modified: branches/safari-603-branch/Source/WebCore/ChangeLog (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/ChangeLog 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/ChangeLog 2017-02-17 00:55:59 UTC (rev 212490)
@@ -48,6 +48,116 @@
2017-02-16 Matthew Hanson <[email protected]>
+ Merge r211683. rdar://problem/30467272
+
+ 2017-02-04 Simon Fraser <[email protected]>
+
+ Clean up how GraphicsLayer's "inWindow" state is set, and fix some issues with Page Overlays
+ https://bugs.webkit.org/show_bug.cgi?id=167850
+
+ Reviewed by Tim Horton.
+
+ RenderLayerCompositor::setIsInWindowForLayerIncludingDescendants() walked the RenderLayer
+ tree to set the GraphicsLayer's "inWindow" state. This had the problem of skipping non-primary
+ GraphicsLayers. We also never did this work for page overlay layers.
+
+ Fix by giving GraphicsLayers a recursive function that sets the inWindow state, and call that
+ from RenderLayerCompositor::setIsInWindow() and PageOverlayController.
+
+ PageOverlayController also needs to implement tiledBackingUsageChanged so that tiled backings
+ created dynamically get the correct in-window state.
+
+ Page overlays also had some serious issues in MiniBrowser, in that they disappeared on reload,
+ and on hide/show web view. This was because the overlay root layers were re-parented, but
+ addChild() for each overlay's layer wasn't called. Clean up by replacing willAttachRootLayer() followed
+ by viewOverlayRootLayer()/documentOverlayRootLayer() with single calls that set up the layers,
+ update the inWindow state, and return the layer.
+
+ Make it possible to dump tile caches in page overlay tests.
+
+ Make showGraphicsLayers() always dump page overlay layers (source of much confusion).
+
+ Test: pageoverlay/overlay-remove-reinsert-view.html
+
+ * page/PageOverlayController.cpp:
+ (WebCore::PageOverlayController::documentOverlayRootLayer):
+ (WebCore::PageOverlayController::viewOverlayRootLayer):
+ (WebCore::PageOverlayController::layerWithDocumentOverlays):
+ (WebCore::PageOverlayController::layerWithViewOverlays):
+ (WebCore::PageOverlayController::tiledBackingUsageChanged):
+ (WebCore::PageOverlayController::willAttachRootLayer): Deleted.
+ * page/PageOverlayController.h:
+ * platform/graphics/GraphicsLayer.cpp:
+ (WebCore::GraphicsLayer::setIsInWindowIncludingDescendants):
+ (WebCore::dumpChildren):
+ * platform/graphics/GraphicsLayer.h:
+ * rendering/RenderLayerCompositor.cpp:
+ (WebCore::RenderLayerCompositor::appendDocumentOverlayLayers):
+ (WebCore::RenderLayerCompositor::setIsInWindow):
+ (WebCore::RenderLayerCompositor::attachRootLayer):
+ (WebCore::RenderLayerCompositor::rootLayerAttachmentChanged):
+ (WebCore::RenderLayerCompositor::setIsInWindowForLayerIncludingDescendants): Deleted.
+ * rendering/RenderLayerCompositor.h:
+ * testing/Internals.cpp:
+ (WebCore::toLayerTreeFlags):
+ (WebCore::Internals::layerTreeAsText):
+ (WebCore::Internals::pageOverlayLayerTreeAsText):
+ * testing/Internals.h:
+ * testing/Internals.idl:
+ * testing/MockPageOverlayClient.cpp:
+ (WebCore::MockPageOverlayClient::layerTreeAsText):
+ * testing/MockPageOverlayClient.h:
+
+2017-02-16 Matthew Hanson <[email protected]>
+
+ Merge r211662. rdar://problem/30467322
+
+ 2017-02-03 Simon Fraser <[email protected]>
+
+ Correctly set the "inWindow" flag for TileControllers that aren't the page tiles, and clarify "usingTiledBacking" logic
+ https://bugs.webkit.org/show_bug.cgi?id=167774
+
+ Reviewed by Tim Horton.
+
+ RenderLayerBacking had some very confusing "usingTiledCacheLayer" uses.
+
+ Its member variable, m_usingTiledCacheLayer, really meant "m_isMainFrameLayerWithTiledBacking" so make it so.
+ It had a usingTiledBacking(), which returned the same thing, which this patch replaces with isMainFrameLayerWithTiledBacking().
+
+ The fact that usingTiledBacking() was only true for the page tiled layer tripped up
+ RenderLayerCompositor::setIsInWindowForLayerIncludingDescendants(), which would only ever call setIsInWindow()
+ on the page tiled layer. These changes fix that.
+
+ Also make a way for tests to unparent the web view via UIScriptController, and dump out the "in window"
+ status of TileBackings when dumping tile caches.
+
+ Test: tiled-drawing/tiled-backing-in-window.html
+
+ * platform/graphics/TiledBacking.h:
+ * platform/graphics/ca/GraphicsLayerCA.cpp:
+ (WebCore::GraphicsLayerCA::dumpAdditionalProperties):
+ * platform/graphics/ca/TileController.h:
+ * rendering/RenderLayerBacking.cpp:
+ (WebCore::RenderLayerBacking::RenderLayerBacking):
+ (WebCore::computePageTiledBackingCoverage):
+ (WebCore::RenderLayerBacking::adjustTiledBackingCoverage):
+ (WebCore::RenderLayerBacking::setTiledBackingHasMargins):
+ (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
+ (WebCore::RenderLayerBacking::shouldClipCompositedBounds):
+ (WebCore::RenderLayerBacking::updateDescendantClippingLayer):
+ (WebCore::RenderLayerBacking::updateRootLayerConfiguration):
+ (WebCore::RenderLayerBacking::paintsIntoWindow):
+ (WebCore::computeTileCoverage): Deleted.
+ * rendering/RenderLayerBacking.h:
+ * rendering/RenderLayerCompositor.cpp:
+ (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
+ (WebCore::RenderLayerCompositor::rootFixedBackgroundsChanged):
+ (WebCore::RenderLayerCompositor::setIsInWindowForLayerIncludingDescendants):
+ (WebCore::RenderLayerCompositor::supportsFixedRootBackgroundCompositing):
+ (WebCore::RenderLayerCompositor::documentUsesTiledBacking):
+
+2017-02-16 Matthew Hanson <[email protected]>
+
Merge r211501. rdar://problem/29904368
2017-02-01 Antoine Quint <[email protected]>
Modified: branches/safari-603-branch/Source/WebCore/page/PageOverlayController.cpp (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/page/PageOverlayController.cpp 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/page/PageOverlayController.cpp 2017-02-17 00:55:59 UTC (rev 212490)
@@ -72,16 +72,14 @@
#endif
}
-GraphicsLayer& PageOverlayController::documentOverlayRootLayer()
+GraphicsLayer* PageOverlayController::documentOverlayRootLayer() const
{
- createRootLayersIfNeeded();
- return *m_documentOverlayRootLayer;
+ return m_documentOverlayRootLayer.get();
}
-GraphicsLayer& PageOverlayController::viewOverlayRootLayer()
+GraphicsLayer* PageOverlayController::viewOverlayRootLayer() const
{
- createRootLayersIfNeeded();
- return *m_viewOverlayRootLayer;
+ return m_viewOverlayRootLayer.get();
}
static void updateOverlayGeometry(PageOverlay& overlay, GraphicsLayer& graphicsLayer)
@@ -95,6 +93,50 @@
graphicsLayer.setSize(overlayFrame.size());
}
+GraphicsLayer& PageOverlayController::layerWithDocumentOverlays()
+{
+ createRootLayersIfNeeded();
+
+ bool inWindow = m_mainFrame.page() ? m_mainFrame.page()->isInWindow() : false;
+
+ for (auto& overlayAndLayer : m_overlayGraphicsLayers) {
+ PageOverlay& overlay = *overlayAndLayer.key;
+ if (overlay.overlayType() != PageOverlay::OverlayType::Document)
+ continue;
+
+ GraphicsLayer& layer = *overlayAndLayer.value;
+ layer.setIsInWindowIncludingDescendants(inWindow);
+ updateOverlayGeometry(overlay, layer);
+
+ if (!layer.parent())
+ m_documentOverlayRootLayer->addChild(&layer);
+ }
+
+ return *m_documentOverlayRootLayer;
+}
+
+GraphicsLayer& PageOverlayController::layerWithViewOverlays()
+{
+ createRootLayersIfNeeded();
+
+ bool inWindow = m_mainFrame.page() ? m_mainFrame.page()->isInWindow() : false;
+
+ for (auto& overlayAndLayer : m_overlayGraphicsLayers) {
+ PageOverlay& overlay = *overlayAndLayer.key;
+ if (overlay.overlayType() != PageOverlay::OverlayType::View)
+ continue;
+
+ GraphicsLayer& layer = *overlayAndLayer.value;
+ layer.setIsInWindowIncludingDescendants(inWindow);
+ updateOverlayGeometry(overlay, layer);
+
+ if (!layer.parent())
+ m_viewOverlayRootLayer->addChild(&layer);
+ }
+
+ return *m_viewOverlayRootLayer;
+}
+
void PageOverlayController::installPageOverlay(PassRefPtr<PageOverlay> pageOverlay, PageOverlay::FadeMode fadeMode)
{
createRootLayersIfNeeded();
@@ -203,12 +245,6 @@
return *m_overlayGraphicsLayers.get(&overlay);
}
-void PageOverlayController::willAttachRootLayer()
-{
- for (auto& overlayAndLayer : m_overlayGraphicsLayers)
- updateOverlayGeometry(*overlayAndLayer.key, *overlayAndLayer.value);
-}
-
void PageOverlayController::didChangeViewSize()
{
for (auto& overlayAndLayer : m_overlayGraphicsLayers) {
@@ -362,4 +398,10 @@
return !(behavior & LayerTreeAsTextIncludePageOverlayLayers);
}
+void PageOverlayController::tiledBackingUsageChanged(const GraphicsLayer* graphicsLayer, bool usingTiledBacking)
+{
+ if (usingTiledBacking)
+ graphicsLayer->tiledBacking()->setIsInWindow(m_mainFrame.page()->isInWindow());
+}
+
} // namespace WebKit
Modified: branches/safari-603-branch/Source/WebCore/page/PageOverlayController.h (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/page/PageOverlayController.h 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/page/PageOverlayController.h 2017-02-17 00:55:59 UTC (rev 212490)
@@ -45,9 +45,12 @@
PageOverlayController(MainFrame&);
virtual ~PageOverlayController();
- WEBCORE_EXPORT GraphicsLayer& documentOverlayRootLayer();
- WEBCORE_EXPORT GraphicsLayer& viewOverlayRootLayer();
+ GraphicsLayer& layerWithDocumentOverlays();
+ GraphicsLayer& layerWithViewOverlays();
+ WEBCORE_EXPORT GraphicsLayer* documentOverlayRootLayer() const;
+ WEBCORE_EXPORT GraphicsLayer* viewOverlayRootLayer() const;
+
const Vector<RefPtr<PageOverlay>>& pageOverlays() const { return m_pageOverlays; }
WEBCORE_EXPORT void installPageOverlay(PassRefPtr<PageOverlay>, PageOverlay::FadeMode);
@@ -58,8 +61,6 @@
void clearPageOverlay(PageOverlay&);
GraphicsLayer& layerForOverlay(PageOverlay&) const;
- void willAttachRootLayer();
-
void didChangeViewSize();
void didChangeDocumentSize();
void didChangeSettings();
@@ -89,6 +90,7 @@
void paintContents(const GraphicsLayer*, GraphicsContext&, GraphicsLayerPaintingPhase, const FloatRect& clipRect) override;
float deviceScaleFactor() const override;
bool shouldSkipLayerInDump(const GraphicsLayer*, LayerTreeAsTextBehavior) const override;
+ void tiledBackingUsageChanged(const GraphicsLayer*, bool) override;
std::unique_ptr<GraphicsLayer> m_documentOverlayRootLayer;
std::unique_ptr<GraphicsLayer> m_viewOverlayRootLayer;
Modified: branches/safari-603-branch/Source/WebCore/platform/graphics/GraphicsLayer.cpp (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/platform/graphics/GraphicsLayer.cpp 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/platform/graphics/GraphicsLayer.cpp 2017-02-17 00:55:59 UTC (rev 212490)
@@ -364,6 +364,15 @@
childLayers[i]->noteDeviceOrPageScaleFactorChangedIncludingDescendants();
}
+void GraphicsLayer::setIsInWindowIncludingDescendants(bool inWindow)
+{
+ if (usingTiledBacking())
+ tiledBacking()->setIsInWindow(inWindow);
+
+ for (auto* childLayer : children())
+ childLayer->setIsInWindowIncludingDescendants(inWindow);
+}
+
void GraphicsLayer::setReplicatedByLayer(GraphicsLayer* layer)
{
if (m_replicaLayer == layer)
@@ -680,7 +689,7 @@
{
totalChildCount += children.size();
for (auto* child : children) {
- if (!child->client().shouldSkipLayerInDump(child, behavior)) {
+ if ((behavior & LayerTreeAsTextDebug) || !child->client().shouldSkipLayerInDump(child, behavior)) {
child->dumpLayer(ts, indent + 2, behavior);
continue;
}
Modified: branches/safari-603-branch/Source/WebCore/platform/graphics/GraphicsLayer.h (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/platform/graphics/GraphicsLayer.h 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/platform/graphics/GraphicsLayer.h 2017-02-17 00:55:59 UTC (rev 212490)
@@ -514,6 +514,8 @@
virtual void deviceOrPageScaleFactorChanged() { }
WEBCORE_EXPORT void noteDeviceOrPageScaleFactorChangedIncludingDescendants();
+ void setIsInWindowIncludingDescendants(bool);
+
// Some compositing systems may do internal batching to synchronize compositing updates
// with updates drawn into the window. These methods flush internal batched state on this layer
// and descendant layers, and this layer only.
Modified: branches/safari-603-branch/Source/WebCore/rendering/RenderLayerCompositor.cpp (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/rendering/RenderLayerCompositor.cpp 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/rendering/RenderLayerCompositor.cpp 2017-02-17 00:55:59 UTC (rev 212490)
@@ -805,9 +805,7 @@
if (!page)
return;
- PageOverlayController& pageOverlayController = frame.mainFrame().pageOverlayController();
- pageOverlayController.willAttachRootLayer();
- childList.append(&pageOverlayController.documentOverlayRootLayer());
+ childList.append(&frame.mainFrame().pageOverlayController().layerWithDocumentOverlays());
}
void RenderLayerCompositor::layerBecameNonComposited(const RenderLayer& layer)
@@ -2060,28 +2058,14 @@
}
#endif
-void RenderLayerCompositor::setIsInWindowForLayerIncludingDescendants(RenderLayer& layer, bool isInWindow)
-{
- if (layer.isComposited()) {
- if (auto* backing = layer.backing()->tiledBacking())
- backing->setIsInWindow(isInWindow);
- }
-
- // No need to recurse if we don't have any other tiled layers.
- if (!hasNonMainLayersWithTiledBacking())
- return;
-
- for (RenderLayer* childLayer = layer.firstChild(); childLayer; childLayer = childLayer->nextSibling())
- setIsInWindowForLayerIncludingDescendants(*childLayer, isInWindow);
-}
-
void RenderLayerCompositor::setIsInWindow(bool isInWindow)
{
- setIsInWindowForLayerIncludingDescendants(*m_renderView.layer(), isInWindow);
-
if (!inCompositingMode())
return;
+ if (GraphicsLayer* rootLayer = rootGraphicsLayer())
+ rootLayer->setIsInWindowIncludingDescendants(isInWindow);
+
if (isInWindow) {
if (m_rootLayerAttachment != RootLayerUnattached)
return;
@@ -3513,11 +3497,8 @@
return;
page->chrome().client().attachRootGraphicsLayer(&frame, rootGraphicsLayer());
- if (frame.isMainFrame()) {
- PageOverlayController& pageOverlayController = frame.mainFrame().pageOverlayController();
- pageOverlayController.willAttachRootLayer();
- page->chrome().client().attachViewOverlayGraphicsLayer(&frame, &pageOverlayController.viewOverlayRootLayer());
- }
+ if (frame.isMainFrame())
+ page->chrome().client().attachViewOverlayGraphicsLayer(&frame, &frame.mainFrame().pageOverlayController().layerWithViewOverlays());
break;
}
case RootLayerAttachedViaEnclosingFrame: {
@@ -3602,9 +3583,7 @@
if (!frame.isMainFrame())
return;
- PageOverlayController& pageOverlayController = frame.mainFrame().pageOverlayController();
- pageOverlayController.willAttachRootLayer();
- m_rootContentLayer->addChild(&pageOverlayController.documentOverlayRootLayer());
+ m_rootContentLayer->addChild(&frame.mainFrame().pageOverlayController().layerWithDocumentOverlays());
}
void RenderLayerCompositor::notifyIFramesOfCompositingChange()
Modified: branches/safari-603-branch/Source/WebCore/rendering/RenderLayerCompositor.h (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/rendering/RenderLayerCompositor.h 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/rendering/RenderLayerCompositor.h 2017-02-17 00:55:59 UTC (rev 212490)
@@ -350,7 +350,6 @@
bool updateBacking(RenderLayer&, CompositingChangeRepaint shouldRepaint, BackingRequired = BackingRequired::Unknown);
void clearBackingForLayerIncludingDescendants(RenderLayer&);
- void setIsInWindowForLayerIncludingDescendants(RenderLayer&, bool isInWindow);
// Repaint this and its child layers.
void recursiveRepaintLayer(RenderLayer&);
Modified: branches/safari-603-branch/Source/WebCore/testing/Internals.cpp (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/testing/Internals.cpp 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/testing/Internals.cpp 2017-02-17 00:55:59 UTC (rev 212490)
@@ -1997,6 +1997,23 @@
return document->isPageBoxVisible(pageNumber);
}
+static LayerTreeFlags toLayerTreeFlags(unsigned short flags)
+{
+ LayerTreeFlags layerTreeFlags = 0;
+ if (flags & Internals::LAYER_TREE_INCLUDES_VISIBLE_RECTS)
+ layerTreeFlags |= LayerTreeFlagsIncludeVisibleRects;
+ if (flags & Internals::LAYER_TREE_INCLUDES_TILE_CACHES)
+ layerTreeFlags |= LayerTreeFlagsIncludeTileCaches;
+ if (flags & Internals::LAYER_TREE_INCLUDES_REPAINT_RECTS)
+ layerTreeFlags |= LayerTreeFlagsIncludeRepaintRects;
+ if (flags & Internals::LAYER_TREE_INCLUDES_PAINTING_PHASES)
+ layerTreeFlags |= LayerTreeFlagsIncludePaintingPhases;
+ if (flags & Internals::LAYER_TREE_INCLUDES_CONTENT_LAYERS)
+ layerTreeFlags |= LayerTreeFlagsIncludeContentLayers;
+
+ return layerTreeFlags;
+}
+
// FIXME: Remove the document argument. It is almost always the same as
// contextDocument(), with the exception of a few tests that pass a
// different document, and could just make the call through another Internals
@@ -2007,20 +2024,20 @@
return Exception { INVALID_ACCESS_ERR };
LayerTreeFlags layerTreeFlags = 0;
- if (flags & LAYER_TREE_INCLUDES_VISIBLE_RECTS)
+ if (flags & Internals::LAYER_TREE_INCLUDES_VISIBLE_RECTS)
layerTreeFlags |= LayerTreeFlagsIncludeVisibleRects;
- if (flags & LAYER_TREE_INCLUDES_TILE_CACHES)
+ if (flags & Internals::LAYER_TREE_INCLUDES_TILE_CACHES)
layerTreeFlags |= LayerTreeFlagsIncludeTileCaches;
- if (flags & LAYER_TREE_INCLUDES_REPAINT_RECTS)
+ if (flags & Internals::LAYER_TREE_INCLUDES_REPAINT_RECTS)
layerTreeFlags |= LayerTreeFlagsIncludeRepaintRects;
- if (flags & LAYER_TREE_INCLUDES_PAINTING_PHASES)
+ if (flags & Internals::LAYER_TREE_INCLUDES_PAINTING_PHASES)
layerTreeFlags |= LayerTreeFlagsIncludePaintingPhases;
- if (flags & LAYER_TREE_INCLUDES_CONTENT_LAYERS)
+ if (flags & Internals::LAYER_TREE_INCLUDES_CONTENT_LAYERS)
layerTreeFlags |= LayerTreeFlagsIncludeContentLayers;
- if (flags & LAYER_TREE_INCLUDES_ACCELERATES_DRAWING)
+ if (flags & Internals::LAYER_TREE_INCLUDES_ACCELERATES_DRAWING)
layerTreeFlags |= LayerTreeFlagsIncludeAcceleratesDrawing;
- return document.frame()->layerTreeAsText(layerTreeFlags);
+ return document.frame()->layerTreeAsText(toLayerTreeFlags(flags));
}
ExceptionOr<String> Internals::repaintRectsAsText() const
@@ -3231,7 +3248,7 @@
return MockPageOverlayClient::singleton().installOverlay(document->frame()->mainFrame(), type == PageOverlayType::View ? PageOverlay::OverlayType::View : PageOverlay::OverlayType::Document);
}
-ExceptionOr<String> Internals::pageOverlayLayerTreeAsText() const
+ExceptionOr<String> Internals::pageOverlayLayerTreeAsText(unsigned short flags) const
{
Document* document = contextDocument();
if (!document || !document->frame())
@@ -3239,7 +3256,7 @@
document->updateLayout();
- return MockPageOverlayClient::singleton().layerTreeAsText(document->frame()->mainFrame());
+ return MockPageOverlayClient::singleton().layerTreeAsText(document->frame()->mainFrame(), toLayerTreeFlags(flags));
}
void Internals::setPageMuted(const String& states)
Modified: branches/safari-603-branch/Source/WebCore/testing/Internals.h (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/testing/Internals.h 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/testing/Internals.h 2017-02-17 00:55:59 UTC (rev 212490)
@@ -464,7 +464,7 @@
enum class PageOverlayType { View, Document };
ExceptionOr<Ref<MockPageOverlay>> installMockPageOverlay(PageOverlayType);
- ExceptionOr<String> pageOverlayLayerTreeAsText() const;
+ ExceptionOr<String> pageOverlayLayerTreeAsText(unsigned short flags) const;
void setPageMuted(const String&);
String pageMediaState();
Modified: branches/safari-603-branch/Source/WebCore/testing/Internals.idl (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/testing/Internals.idl 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/testing/Internals.idl 2017-02-17 00:55:59 UTC (rev 212490)
@@ -442,7 +442,7 @@
[Conditional=VIDEO] boolean elementIsBlockingDisplaySleep(HTMLMediaElement element);
[MayThrowException] MockPageOverlay installMockPageOverlay(PageOverlayType type);
- [MayThrowException] DOMString pageOverlayLayerTreeAsText();
+ [MayThrowException] DOMString pageOverlayLayerTreeAsText(optional unsigned short flags = 0);
void setPageMuted(DOMString mutedState);
DOMString pageMediaState();
Modified: branches/safari-603-branch/Source/WebCore/testing/MockPageOverlayClient.cpp (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/testing/MockPageOverlayClient.cpp 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/testing/MockPageOverlayClient.cpp 2017-02-17 00:55:59 UTC (rev 212490)
@@ -69,9 +69,13 @@
}
}
-String MockPageOverlayClient::layerTreeAsText(MainFrame& mainFrame)
+String MockPageOverlayClient::layerTreeAsText(MainFrame& mainFrame, LayerTreeFlags flags)
{
- return "View-relative:\n" + mainFrame.pageOverlayController().viewOverlayRootLayer().layerTreeAsText(LayerTreeAsTextIncludePageOverlayLayers) + "\n\nDocument-relative:\n" + mainFrame.pageOverlayController().documentOverlayRootLayer().layerTreeAsText(LayerTreeAsTextIncludePageOverlayLayers);
+ GraphicsLayer* viewOverlayRoot = mainFrame.pageOverlayController().viewOverlayRootLayer();
+ GraphicsLayer* documentOverlayRoot = mainFrame.pageOverlayController().documentOverlayRootLayer();
+
+ return "View-relative:\n" + (viewOverlayRoot ? viewOverlayRoot->layerTreeAsText(flags | LayerTreeAsTextIncludePageOverlayLayers) : "(no view-relative overlay root)")
+ + "\n\nDocument-relative:\n" + (documentOverlayRoot ? documentOverlayRoot->layerTreeAsText(flags | LayerTreeAsTextIncludePageOverlayLayers) : "(no document-relative overlay root)");
}
void MockPageOverlayClient::willMoveToPage(PageOverlay&, Page*)
Modified: branches/safari-603-branch/Source/WebCore/testing/MockPageOverlayClient.h (212489 => 212490)
--- branches/safari-603-branch/Source/WebCore/testing/MockPageOverlayClient.h 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Source/WebCore/testing/MockPageOverlayClient.h 2017-02-17 00:55:59 UTC (rev 212490)
@@ -25,6 +25,7 @@
#pragma once
+#include "Frame.h"
#include "MockPageOverlay.h"
#include "PageOverlay.h"
#include <wtf/HashSet.h>
@@ -43,7 +44,7 @@
Ref<MockPageOverlay> installOverlay(MainFrame&, PageOverlay::OverlayType);
void uninstallAllOverlays();
- String layerTreeAsText(MainFrame&);
+ String layerTreeAsText(MainFrame&, LayerTreeFlags);
virtual ~MockPageOverlayClient() { }
Modified: branches/safari-603-branch/Tools/ChangeLog (212489 => 212490)
--- branches/safari-603-branch/Tools/ChangeLog 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Tools/ChangeLog 2017-02-17 00:55:59 UTC (rev 212490)
@@ -1,5 +1,19 @@
2017-02-16 Matthew Hanson <[email protected]>
+ Merge r211683. rdar://problem/30467272
+
+ 2017-02-04 Simon Fraser <[email protected]>
+
+ Clean up how GraphicsLayer's "inWindow" state is set, and fix some issues with Page Overlays
+ https://bugs.webkit.org/show_bug.cgi?id=167850
+
+ Reviewed by Tim Horton.
+
+ * DumpRenderTree/TestRunner.cpp:
+ (TestRunner::uiScriptDidComplete): Fix an assertion that fires for non-16-bit strings.
+
+2017-02-16 Matthew Hanson <[email protected]>
+
Merge r211662. rdar://problem/30467322
2017-02-03 Simon Fraser <[email protected]>
@@ -44,6 +58,52 @@
(WTR::UIScriptController::removeViewFromWindow):
(WTR::UIScriptController::addViewToWindow):
+2017-02-16 Matthew Hanson <[email protected]>
+
+ Merge r211662. rdar://problem/30467322
+
+ 2017-02-03 Simon Fraser <[email protected]>
+
+ Correctly set the "inWindow" flag for TileControllers that aren't the page tiles, and clarify "usingTiledBacking" logic
+ https://bugs.webkit.org/show_bug.cgi?id=167774
+
+ Reviewed by Tim Horton.
+
+ Implement UIScriptController removeViewFromWindow() and addViewToWindow(), and hook
+ up for Mac WK1 and WK2, and iOS WK2. It takes a callback because view state updates to the
+ web process are async, so the callback fires after the web process gets the new state.
+
+ * DumpRenderTree/ios/UIScriptControllerIOS.mm:
+ (WTR::UIScriptController::removeViewFromWindow):
+ (WTR::UIScriptController::addViewToWindow):
+ * DumpRenderTree/mac/DumpRenderTree.mm:
+ (createWebViewAndOffscreenWindow):
+ (resetWebViewToConsistentStateBeforeTesting):
+ * DumpRenderTree/mac/DumpRenderTreeMac.h:
+ * DumpRenderTree/mac/UIScriptControllerMac.mm:
+ (WTR::UIScriptController::removeViewFromWindow):
+ (WTR::UIScriptController::addViewToWindow):
+ * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
+ * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
+ (WTR::UIScriptController::removeViewFromWindow):
+ (WTR::UIScriptController::addViewToWindow):
+ * TestRunnerShared/UIScriptContext/UIScriptController.h:
+ * WebKitTestRunner/PlatformWebView.h:
+ * WebKitTestRunner/TestController.cpp:
+ (WTR::TestController::resetStateToConsistentValues):
+ * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
+ (WTR::PlatformWebView::removeFromWindow):
+ (WTR::PlatformWebView::addToWindow):
+ * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
+ (WTR::UIScriptController::removeViewFromWindow):
+ (WTR::UIScriptController::addViewToWindow):
+ * WebKitTestRunner/mac/PlatformWebViewMac.mm:
+ (WTR::PlatformWebView::removeFromWindow):
+ (WTR::PlatformWebView::addToWindow):
+ * WebKitTestRunner/mac/UIScriptControllerMac.mm:
+ (WTR::UIScriptController::removeViewFromWindow):
+ (WTR::UIScriptController::addViewToWindow):
+
2017-02-10 Matthew Hanson <[email protected]>
Merge r211910. rdar://problem/30358835
Modified: branches/safari-603-branch/Tools/DumpRenderTree/TestRunner.cpp (212489 => 212490)
--- branches/safari-603-branch/Tools/DumpRenderTree/TestRunner.cpp 2017-02-17 00:55:51 UTC (rev 212489)
+++ branches/safari-603-branch/Tools/DumpRenderTree/TestRunner.cpp 2017-02-17 00:55:59 UTC (rev 212490)
@@ -2415,7 +2415,7 @@
void TestRunner::uiScriptDidComplete(const String& result, unsigned callbackID)
{
- JSRetainPtr<JSStringRef> stringRef(Adopt, JSStringCreateWithCharacters(result.characters16(), result.length()));
+ JSRetainPtr<JSStringRef> stringRef(Adopt, JSStringCreateWithUTF8CString(result.utf8().data()));
callUIScriptCallback(callbackID, stringRef.get());
}