diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/images/imagemap-focus-ring-with-paint-root-offset-expected.png b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/images/imagemap-focus-ring-with-paint-root-offset-expected.png new file mode 100644 index 00000000000000..28fb45c0c18075 Binary files /dev/null and b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/images/imagemap-focus-ring-with-paint-root-offset-expected.png differ diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/block-layout-inline-children-replaced-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/block-layout-inline-children-replaced-expected.txt index 92df863bf0abc1..bc481cf1e8e161 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/block-layout-inline-children-replaced-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/block-layout-inline-children-replaced-expected.txt @@ -15,6 +15,11 @@ "object": "LayoutImage IMG", "rect": [151, 117, 100, 100], "reason": "appeared" + }, + { + "object": "LayoutImage IMG", + "rect": [151, 117, 100, 100], + "reason": "chunk appeared" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/box/box-inline-resize-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/box/box-inline-resize-expected.txt index 5b6271d6341cd1..124db376212228 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/box/box-inline-resize-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/box/box-inline-resize-expected.txt @@ -9,17 +9,22 @@ { "object": "InlineTextBox 'Chromium'", "rect": [40, 107, 113, 27], - "reason": "geometry" + "reason": "chunk appeared" }, { "object": "InlineTextBox 'Chromium'", "rect": [8, 107, 113, 27], - "reason": "geometry" + "reason": "disappeared" }, { "object": "LayoutImage IMG id='foo'", "rect": [8, 88, 32, 32], "reason": "appeared" + }, + { + "object": "LayoutImage IMG id='foo'", + "rect": [8, 88, 32, 32], + "reason": "chunk appeared" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/canvas-resize-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/canvas-resize-expected.txt index 6b8cf635d48cf7..27355c93526739 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/canvas-resize-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/canvas-resize-expected.txt @@ -8,8 +8,13 @@ "paintInvalidations": [ { "object": "LayoutHTMLCanvas (positioned) CANVAS id='canvas'", - "rect": [50, 50, 600, 500], + "rect": [50, 50, 500, 500], "reason": "geometry" + }, + { + "object": "LayoutHTMLCanvas (positioned) CANVAS id='canvas'", + "rect": [550, 50, 100, 500], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/canvas-resize-no-full-invalidation-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/canvas-resize-no-full-invalidation-expected.txt index 55868f55499be8..50388f62f2a2a1 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/canvas-resize-no-full-invalidation-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/canvas-resize-no-full-invalidation-expected.txt @@ -6,6 +6,11 @@ "contentsOpaque": true, "backgroundColor": "#FFFFFF", "paintInvalidations": [ + { + "object": "LayoutHTMLCanvas (positioned) CANVAS id='canvas'", + "rect": [550, 50, 100, 500], + "reason": "incremental" + }, { "object": "LayoutHTMLCanvas (positioned) CANVAS id='canvas'", "rect": [550, 50, 100, 500], diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/clip/clipped-relative-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/clip/clipped-relative-expected.txt index 508311129a2620..6212af9e90f862 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/clip/clipped-relative-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/clip/clipped-relative-expected.txt @@ -11,6 +11,11 @@ "rect": [8, 74, 204, 232], "reason": "geometry" }, + { + "object": "LayoutImage IMG", + "rect": [102, 74, 110, 232], + "reason": "incremental" + }, { "object": "LayoutImage IMG", "rect": [8, 74, 94, 232], diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/clip/replaced-clipped-positioned-not-wrong-incremental-repainting-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/clip/replaced-clipped-positioned-not-wrong-incremental-repainting-expected.txt index d06d0d71f33edb..07485121e26c9c 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/clip/replaced-clipped-positioned-not-wrong-incremental-repainting-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/clip/replaced-clipped-positioned-not-wrong-incremental-repainting-expected.txt @@ -15,6 +15,11 @@ "object": "LayoutImage IMG", "rect": [8, 8, 114, 232], "reason": "geometry" + }, + { + "object": "LayoutImage IMG", + "rect": [122, 8, 80, 232], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/iframe-display-block-to-display-none-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/iframe-display-block-to-display-none-expected.txt index ad626dd290f580..b37ed834b4e56b 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/iframe-display-block-to-display-none-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/iframe-display-block-to-display-none-expected.txt @@ -7,9 +7,14 @@ "backgroundColor": "#FFFFFF", "paintInvalidations": [ { - "object": "LayoutIFrame IFRAME id='iframe'", - "rect": [8, 72, 732, 94], - "reason": "disappeared" + "object": "LayoutBlockFlow HTML", + "rect": [8, 16, 751, 150], + "reason": "chunk disappeared" + }, + { + "object": "LayoutBlockFlow HTML", + "rect": [8, 16, 751, 39], + "reason": "chunk appeared" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/iframe-display-none-to-display-block-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/iframe-display-none-to-display-block-expected.txt index b03ea5f7b0bf4d..16e77e0a7d50bf 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/iframe-display-none-to-display-block-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/iframe-display-none-to-display-block-expected.txt @@ -7,9 +7,14 @@ "backgroundColor": "#FFFFFF", "paintInvalidations": [ { - "object": "LayoutIFrame IFRAME id='iframe'", - "rect": [8, 72, 732, 94], - "reason": "appeared" + "object": "LayoutBlockFlow HTML", + "rect": [8, 16, 751, 150], + "reason": "chunk appeared" + }, + { + "object": "LayoutBlockFlow HTML", + "rect": [8, 16, 751, 39], + "reason": "chunk disappeared" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/do-not-paint-below-image-baseline-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/do-not-paint-below-image-baseline-expected.txt index d9caeee3c16aa0..fbc6962a8ef673 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/do-not-paint-below-image-baseline-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/do-not-paint-below-image-baseline-expected.txt @@ -6,6 +6,11 @@ "contentsOpaque": true, "backgroundColor": "#FFFFFF", "paintInvalidations": [ + { + "object": "LayoutBlockFlow HTML", + "rect": [50, 50, 259, 194], + "reason": "chunk disappeared" + }, { "object": "LayoutImage IMG", "rect": [50, 50, 259, 194], diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/image-resize-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/image-resize-expected.txt index 0f315334d366c1..33d3e2fb7fce21 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/image-resize-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/image-resize-expected.txt @@ -8,13 +8,23 @@ "paintInvalidations": [ { "object": "LayoutImage (positioned) IMG", - "rect": [0, 50, 150, 150], + "rect": [0, 50, 100, 200], "reason": "geometry" }, { "object": "LayoutImage (positioned) IMG", - "rect": [0, 50, 100, 200], + "rect": [0, 50, 100, 150], "reason": "geometry" + }, + { + "object": "LayoutImage (positioned) IMG", + "rect": [0, 200, 100, 50], + "reason": "incremental" + }, + { + "object": "LayoutImage (positioned) IMG", + "rect": [100, 50, 50, 150], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/percent-size-image-resize-container-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/percent-size-image-resize-container-expected.txt index 0f315334d366c1..33d3e2fb7fce21 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/percent-size-image-resize-container-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/image/percent-size-image-resize-container-expected.txt @@ -8,13 +8,23 @@ "paintInvalidations": [ { "object": "LayoutImage (positioned) IMG", - "rect": [0, 50, 150, 150], + "rect": [0, 50, 100, 200], "reason": "geometry" }, { "object": "LayoutImage (positioned) IMG", - "rect": [0, 50, 100, 200], + "rect": [0, 50, 100, 150], "reason": "geometry" + }, + { + "object": "LayoutImage (positioned) IMG", + "rect": [0, 200, 100, 50], + "reason": "incremental" + }, + { + "object": "LayoutImage (positioned) IMG", + "rect": [100, 50, 50, 150], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/list-marker-2-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/list-marker-2-expected.txt index 2deb2638208d1b..eb3b86a614489c 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/list-marker-2-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/list-marker-2-expected.txt @@ -11,6 +11,11 @@ "rect": [48, 100, 100, 100], "reason": "geometry" }, + { + "object": "LayoutImage IMG id='target'", + "rect": [48, 150, 100, 50], + "reason": "incremental" + }, { "object": "LayoutListMarker (anonymous)", "rect": [30, 185, 7, 19], diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt index ab9069925db03f..4e124643fa66ac 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt @@ -15,6 +15,11 @@ "object": "LayoutImage IMG", "rect": [8, 64, 114, 232], "reason": "geometry" + }, + { + "object": "LayoutImage IMG", + "rect": [122, 64, 100, 232], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/selection/selected-replaced-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/selection/selected-replaced-expected.txt index d4b3f6d6d6f565..93683da31a6a78 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/selection/selected-replaced-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/selection/selected-replaced-expected.txt @@ -8,13 +8,23 @@ "paintInvalidations": [ { "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", - "rect": [8, 132, 214, 232], + "rect": [8, 52, 214, 232], "reason": "geometry" }, { "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", - "rect": [8, 52, 214, 232], + "rect": [8, 132, 214, 152], "reason": "geometry" + }, + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "rect": [8, 284, 214, 80], + "reason": "incremental" + }, + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "rect": [8, 52, 214, 80], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/selection/selection-clear-after-move-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/selection/selection-clear-after-move-expected.txt index efa22d999468e9..3df8e8711d714f 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/selection/selection-clear-after-move-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/selection/selection-clear-after-move-expected.txt @@ -10,6 +10,11 @@ "object": "LayoutImage IMG", "rect": [100, 300, 50, 50], "reason": "selection" + }, + { + "object": "LayoutImage IMG", + "rect": [100, 300, 50, 50], + "reason": "chunk disappeared" } ] } diff --git a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/transform/transform-replaced-shadows-expected.txt b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/transform/transform-replaced-shadows-expected.txt index 701b8811128fa6..440289bdc4ab8f 100644 --- a/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/transform/transform-replaced-shadows-expected.txt +++ b/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/paint/invalidation/transform/transform-replaced-shadows-expected.txt @@ -11,10 +11,20 @@ "rect": [0, 28, 266, 278], "reason": "paint property change" }, + { + "object": "LayoutImage IMG id='box' class='smaller'", + "rect": [28, 28, 200, 200], + "reason": "paint property change" + }, { "object": "LayoutImage IMG id='box' class='smaller'", "rect": [9, 28, 138, 139], "reason": "paint property change" + }, + { + "object": "LayoutImage IMG id='box' class='smaller'", + "rect": [28, 28, 100, 100], + "reason": "paint property change" } ] } diff --git a/third_party/WebKit/LayoutTests/http/tests/devtools/layers/layer-canvas-log-expected.txt b/third_party/WebKit/LayoutTests/http/tests/devtools/layers/layer-canvas-log-expected.txt index 3200056f3731ed..121af428d74ade 100644 --- a/third_party/WebKit/LayoutTests/http/tests/devtools/layers/layer-canvas-log-expected.txt +++ b/third_party/WebKit/LayoutTests/http/tests/devtools/layers/layer-canvas-log-expected.txt @@ -58,8 +58,32 @@ Canvas log: } } } + 10 : { + commandIndex : 10 + method : "restore" + params : undefined + } 2 : { commandIndex : 2 + method : "save" + params : undefined + } + 3 : { + commandIndex : 3 + method : "clipRect" + params : { + SkRegion::Op : "kIntersect_Op" + rect : { + bottom : 71 + left : 0 + right : 19 + top : 50 + } + softClipEdgeStyle : true + } + } + 4 : { + commandIndex : 4 method : "drawImageRect" params : { dst : { @@ -97,21 +121,26 @@ Canvas log: } } } - 3 : { - commandIndex : 3 + 5 : { + commandIndex : 5 + method : "restore" + params : undefined + } + 6 : { + commandIndex : 6 method : "save" params : undefined } - 4 : { - commandIndex : 4 + 7 : { + commandIndex : 7 method : "translate" params : { dx : 0 dy : 71 } } - 5 : { - commandIndex : 5 + 8 : { + commandIndex : 8 method : "clipRect" params : { SkRegion::Op : "kIntersect_Op" @@ -124,8 +153,8 @@ Canvas log: softClipEdgeStyle : true } } - 6 : { - commandIndex : 6 + 9 : { + commandIndex : 9 method : "drawRect" params : { paint : { @@ -152,10 +181,5 @@ Canvas log: } } } - 7 : { - commandIndex : 7 - method : "restore" - params : undefined - } } diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/block-layout-inline-children-replaced-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/block-layout-inline-children-replaced-expected.txt index 9341e623551e74..af9d49e7af28ca 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/block-layout-inline-children-replaced-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/block-layout-inline-children-replaced-expected.txt @@ -26,6 +26,11 @@ "object": "LayoutImage IMG", "rect": [151, 117, 100, 100], "reason": "appeared" + }, + { + "object": "LayoutImage IMG", + "rect": [151, 117, 100, 100], + "reason": "chunk appeared" } ] } diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/canvas-resize-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/canvas-resize-expected.txt index 44330626d59dcf..5f18316dd6f9b6 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/canvas-resize-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/canvas-resize-expected.txt @@ -19,8 +19,13 @@ "paintInvalidations": [ { "object": "LayoutHTMLCanvas (positioned) CANVAS id='canvas'", - "rect": [50, 50, 600, 500], + "rect": [50, 50, 500, 500], "reason": "geometry" + }, + { + "object": "LayoutHTMLCanvas (positioned) CANVAS id='canvas'", + "rect": [550, 50, 100, 500], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/canvas-resize-no-full-invalidation-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/canvas-resize-no-full-invalidation-expected.txt index a3132b97ac7489..d4cba972a41e5d 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/canvas-resize-no-full-invalidation-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/canvas-resize-no-full-invalidation-expected.txt @@ -17,6 +17,11 @@ "contentsOpaque": true, "backgroundColor": "#FFFFFF", "paintInvalidations": [ + { + "object": "LayoutHTMLCanvas (positioned) CANVAS id='canvas'", + "rect": [550, 50, 100, 500], + "reason": "incremental" + }, { "object": "LayoutHTMLCanvas (positioned) CANVAS id='canvas'", "rect": [550, 50, 100, 500], diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/clip/replaced-clipped-positioned-not-wrong-incremental-repainting-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/clip/replaced-clipped-positioned-not-wrong-incremental-repainting-expected.txt index 2203bb13c2a244..58396c36d2d774 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/clip/replaced-clipped-positioned-not-wrong-incremental-repainting-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/clip/replaced-clipped-positioned-not-wrong-incremental-repainting-expected.txt @@ -26,6 +26,11 @@ "object": "LayoutImage IMG", "rect": [8, 8, 114, 232], "reason": "geometry" + }, + { + "object": "LayoutImage IMG", + "rect": [122, 8, 80, 232], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/compositing/squash-partial-repaint-inside-squashed-layer-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/compositing/squash-partial-repaint-inside-squashed-layer-expected.txt index 84a2bcf1d55301..7ab9cdab2fba73 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/compositing/squash-partial-repaint-inside-squashed-layer-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/compositing/squash-partial-repaint-inside-squashed-layer-expected.txt @@ -33,6 +33,11 @@ "position": [180, 180], "bounds": [262, 200], "paintInvalidations": [ + { + "object": "LayoutImage (positioned) IMG id='repaintdiv' class='repaintdiv'", + "rect": [80, 80, 182, 29], + "reason": "style change" + }, { "object": "LayoutImage (positioned) IMG id='repaintdiv' class='repaintdiv'", "rect": [80, 80, 182, 29], diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/image/do-not-paint-below-image-baseline-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/image/do-not-paint-below-image-baseline-expected.txt index 978d42d295aee4..89d4aba26b27cd 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/image/do-not-paint-below-image-baseline-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/image/do-not-paint-below-image-baseline-expected.txt @@ -17,6 +17,11 @@ "contentsOpaque": true, "backgroundColor": "#FFFFFF", "paintInvalidations": [ + { + "object": "LayoutBlockFlow HTML", + "rect": [50, 50, 259, 194], + "reason": "chunk disappeared" + }, { "object": "LayoutImage IMG", "rect": [50, 50, 259, 194], diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/image/image-resize-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/image/image-resize-expected.txt index fd61bfe8e6a77f..8a2fbab9d4c475 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/image/image-resize-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/image/image-resize-expected.txt @@ -19,13 +19,23 @@ "paintInvalidations": [ { "object": "LayoutImage (positioned) IMG", - "rect": [0, 50, 150, 150], + "rect": [0, 50, 100, 200], "reason": "geometry" }, { "object": "LayoutImage (positioned) IMG", - "rect": [0, 50, 100, 200], + "rect": [0, 50, 100, 150], "reason": "geometry" + }, + { + "object": "LayoutImage (positioned) IMG", + "rect": [0, 200, 100, 50], + "reason": "incremental" + }, + { + "object": "LayoutImage (positioned) IMG", + "rect": [100, 50, 50, 150], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/image/percent-size-image-resize-container-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/image/percent-size-image-resize-container-expected.txt index fd61bfe8e6a77f..8a2fbab9d4c475 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/image/percent-size-image-resize-container-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/image/percent-size-image-resize-container-expected.txt @@ -19,13 +19,23 @@ "paintInvalidations": [ { "object": "LayoutImage (positioned) IMG", - "rect": [0, 50, 150, 150], + "rect": [0, 50, 100, 200], "reason": "geometry" }, { "object": "LayoutImage (positioned) IMG", - "rect": [0, 50, 100, 200], + "rect": [0, 50, 100, 150], "reason": "geometry" + }, + { + "object": "LayoutImage (positioned) IMG", + "rect": [0, 200, 100, 50], + "reason": "incremental" + }, + { + "object": "LayoutImage (positioned) IMG", + "rect": [100, 50, 50, 150], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-clear-after-move-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-clear-after-move-expected.txt index 1544eaa91c167c..5788d968042a71 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-clear-after-move-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-clear-after-move-expected.txt @@ -21,6 +21,11 @@ "object": "LayoutImage IMG", "rect": [100, 300, 50, 50], "reason": "selection" + }, + { + "object": "LayoutImage IMG", + "rect": [100, 300, 50, 50], + "reason": "chunk disappeared" } ] } diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/transform/transform-replaced-shadows-expected.txt b/third_party/WebKit/LayoutTests/paint/invalidation/transform/transform-replaced-shadows-expected.txt index 8361ae35d8647f..491b6d30c3dd0d 100644 --- a/third_party/WebKit/LayoutTests/paint/invalidation/transform/transform-replaced-shadows-expected.txt +++ b/third_party/WebKit/LayoutTests/paint/invalidation/transform/transform-replaced-shadows-expected.txt @@ -22,10 +22,20 @@ "rect": [0, 28, 266, 278], "reason": "paint property change" }, + { + "object": "LayoutImage IMG id='box' class='smaller'", + "rect": [28, 28, 200, 200], + "reason": "paint property change" + }, { "object": "LayoutImage IMG id='box' class='smaller'", "rect": [9, 28, 138, 139], "reason": "paint property change" + }, + { + "object": "LayoutImage IMG id='box' class='smaller'", + "rect": [28, 28, 100, 100], + "reason": "paint property change" } ] } diff --git a/third_party/WebKit/LayoutTests/platform/fuchsia/paint/invalidation/selection/selected-replaced-expected.txt b/third_party/WebKit/LayoutTests/platform/fuchsia/paint/invalidation/selection/selected-replaced-expected.txt new file mode 100644 index 00000000000000..377adb50b44dc8 --- /dev/null +++ b/third_party/WebKit/LayoutTests/platform/fuchsia/paint/invalidation/selection/selected-replaced-expected.txt @@ -0,0 +1,48 @@ +{ + "layers": [ + { + "name": "LayoutView #document", + "bounds": [800, 600], + "drawsContent": false, + "backgroundColor": "#FFFFFF" + }, + { + "name": "Scrolling Layer", + "bounds": [800, 600], + "drawsContent": false + }, + { + "name": "Scrolling Contents Layer", + "bounds": [800, 600], + "contentsOpaque": true, + "backgroundColor": "#FFFFFF", + "paintInvalidations": [ + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "rect": [8, 132, 214, 232], + "reason": "geometry" + }, + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "rect": [8, 52, 214, 232], + "reason": "geometry" + } + ] + } + ], + "objectPaintInvalidations": [ + { + "object": "LayoutBlockFlow (anonymous)", + "reason": "geometry" + }, + { + "object": "RootInlineBox", + "reason": "geometry" + }, + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "reason": "geometry" + } + ] +} + diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/selection-rect-transform-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/selection-rect-transform-expected.png index d768bd3addb8d5..8d781f22d24fb1 100644 Binary files a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/selection-rect-transform-expected.png and b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/selection-rect-transform-expected.png differ diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/box/box-inline-resize-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/box/box-inline-resize-expected.txt index cb6a48c2044951..ab1843a1b0f14f 100644 --- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/box/box-inline-resize-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/box/box-inline-resize-expected.txt @@ -20,17 +20,22 @@ { "object": "InlineTextBox 'Chromium'", "rect": [40, 107, 113, 27], - "reason": "geometry" + "reason": "chunk appeared" }, { "object": "InlineTextBox 'Chromium'", "rect": [8, 107, 113, 27], - "reason": "geometry" + "reason": "disappeared" }, { "object": "LayoutImage IMG id='foo'", "rect": [8, 88, 32, 32], "reason": "appeared" + }, + { + "object": "LayoutImage IMG id='foo'", + "rect": [8, 88, 32, 32], + "reason": "chunk appeared" } ] } diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt index e1089d7f83be2e..d4337316b255dc 100644 --- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt @@ -22,6 +22,16 @@ "rect": [571, 515, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='copyvideo'", + "rect": [571, 515, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopvideo'", + "rect": [571, 415, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-atopvideo'", "rect": [571, 415, 80, 40], @@ -32,11 +42,26 @@ "rect": [571, 315, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-invideo'", + "rect": [571, 315, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-outvideo'", "rect": [571, 165, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outvideo'", + "rect": [571, 165, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-invideo'", + "rect": [571, 115, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-invideo'", "rect": [571, 115, 80, 40], @@ -47,6 +72,16 @@ "rect": [429, 515, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='copycanvas'", + "rect": [429, 515, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopcanvas'", + "rect": [429, 415, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-atopcanvas'", "rect": [429, 415, 80, 40], @@ -57,6 +92,16 @@ "rect": [429, 315, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-incanvas'", + "rect": [429, 315, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outcanvas'", + "rect": [429, 165, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-outcanvas'", "rect": [429, 165, 80, 40], @@ -67,6 +112,16 @@ "rect": [429, 115, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-incanvas'", + "rect": [429, 115, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='copyimage'", + "rect": [287, 515, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='copyimage'", "rect": [287, 515, 80, 40], @@ -77,6 +132,16 @@ "rect": [287, 415, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopimage'", + "rect": [287, 415, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-inimage'", + "rect": [287, 315, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-inimage'", "rect": [287, 315, 80, 40], @@ -87,11 +152,26 @@ "rect": [287, 165, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outimage'", + "rect": [287, 165, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-inimage'", "rect": [287, 115, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-inimage'", + "rect": [287, 115, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='copysolid color'", + "rect": [145, 515, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='copysolid color'", "rect": [145, 515, 80, 40], @@ -102,6 +182,16 @@ "rect": [145, 415, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopsolid color'", + "rect": [145, 415, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-insolid color'", + "rect": [145, 315, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-insolid color'", "rect": [145, 315, 80, 40], @@ -112,6 +202,16 @@ "rect": [145, 165, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outsolid color'", + "rect": [145, 165, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-insolid color'", + "rect": [145, 115, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-insolid color'", "rect": [145, 115, 80, 40], @@ -122,6 +222,16 @@ "rect": [601, 565, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorvideo'", + "rect": [601, 565, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightervideo'", + "rect": [601, 465, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='lightervideo'", "rect": [601, 465, 50, 40], @@ -132,6 +242,16 @@ "rect": [601, 365, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outvideo'", + "rect": [601, 365, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overvideo'", + "rect": [601, 265, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-overvideo'", "rect": [601, 265, 50, 40], @@ -142,11 +262,26 @@ "rect": [601, 215, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopvideo'", + "rect": [601, 215, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-overvideo'", "rect": [601, 65, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overvideo'", + "rect": [601, 65, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorcanvas'", + "rect": [459, 565, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='xorcanvas'", "rect": [459, 565, 50, 40], @@ -157,6 +292,16 @@ "rect": [459, 465, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightercanvas'", + "rect": [459, 465, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outcanvas'", + "rect": [459, 365, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-outcanvas'", "rect": [459, 365, 50, 40], @@ -167,6 +312,16 @@ "rect": [459, 265, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overcanvas'", + "rect": [459, 265, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopcanvas'", + "rect": [459, 215, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-atopcanvas'", "rect": [459, 215, 50, 40], @@ -177,6 +332,16 @@ "rect": [459, 65, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overcanvas'", + "rect": [459, 65, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorimage'", + "rect": [317, 565, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='xorimage'", "rect": [317, 565, 50, 40], @@ -187,6 +352,16 @@ "rect": [317, 465, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='lighterimage'", + "rect": [317, 465, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outimage'", + "rect": [317, 365, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-outimage'", "rect": [317, 365, 50, 40], @@ -197,11 +372,26 @@ "rect": [317, 265, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overimage'", + "rect": [317, 265, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-atopimage'", "rect": [317, 215, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopimage'", + "rect": [317, 215, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overimage'", + "rect": [317, 65, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-overimage'", "rect": [317, 65, 50, 40], @@ -212,6 +402,16 @@ "rect": [175, 565, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorsolid color'", + "rect": [175, 565, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightersolid color'", + "rect": [175, 465, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='lightersolid color'", "rect": [175, 465, 50, 40], @@ -222,6 +422,16 @@ "rect": [175, 365, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outsolid color'", + "rect": [175, 365, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-oversolid color'", + "rect": [175, 265, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-oversolid color'", "rect": [175, 265, 50, 40], @@ -232,6 +442,16 @@ "rect": [175, 215, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopsolid color'", + "rect": [175, 215, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-oversolid color'", + "rect": [175, 65, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-oversolid color'", "rect": [175, 65, 50, 40], diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/overflow/overflow-update-transform-expected.png b/third_party/WebKit/LayoutTests/platform/mac/fast/overflow/overflow-update-transform-expected.png index 023d81179e3fe5..09d2264c62e89b 100644 Binary files a/third_party/WebKit/LayoutTests/platform/mac/fast/overflow/overflow-update-transform-expected.png and b/third_party/WebKit/LayoutTests/platform/mac/fast/overflow/overflow-update-transform-expected.png differ diff --git a/third_party/WebKit/LayoutTests/platform/mac/fast/replaced/selection-rect-transform-expected.png b/third_party/WebKit/LayoutTests/platform/mac/fast/replaced/selection-rect-transform-expected.png index 537ad07973c908..df00a174469da3 100644 Binary files a/third_party/WebKit/LayoutTests/platform/mac/fast/replaced/selection-rect-transform-expected.png and b/third_party/WebKit/LayoutTests/platform/mac/fast/replaced/selection-rect-transform-expected.png differ diff --git a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/box/box-inline-resize-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/box/box-inline-resize-expected.txt index e8f4906a186564..da53d2e2a6d752 100644 --- a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/box/box-inline-resize-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/box/box-inline-resize-expected.txt @@ -20,17 +20,22 @@ { "object": "InlineTextBox 'Chromium'", "rect": [40, 103, 113, 29], - "reason": "geometry" + "reason": "chunk appeared" }, { "object": "InlineTextBox 'Chromium'", "rect": [8, 103, 113, 29], - "reason": "geometry" + "reason": "disappeared" }, { "object": "LayoutImage IMG id='foo'", "rect": [8, 84, 32, 32], "reason": "appeared" + }, + { + "object": "LayoutImage IMG id='foo'", + "rect": [8, 84, 32, 32], + "reason": "chunk appeared" } ] } diff --git a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/clip/clipped-relative-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/clip/clipped-relative-expected.txt index 02c8c5ecc65ff2..176c7ca9e4dd3b 100644 --- a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/clip/clipped-relative-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/clip/clipped-relative-expected.txt @@ -22,6 +22,11 @@ "rect": [8, 70, 204, 232], "reason": "geometry" }, + { + "object": "LayoutImage IMG", + "rect": [102, 70, 110, 232], + "reason": "incremental" + }, { "object": "LayoutImage IMG", "rect": [8, 70, 94, 232], diff --git a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt index 2cd5739f960085..91442273a78ada 100644 --- a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt @@ -22,6 +22,16 @@ "rect": [571, 513, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='copyvideo'", + "rect": [571, 513, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopvideo'", + "rect": [571, 413, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-atopvideo'", "rect": [571, 413, 80, 40], @@ -32,11 +42,26 @@ "rect": [571, 313, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-invideo'", + "rect": [571, 313, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-outvideo'", "rect": [571, 163, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outvideo'", + "rect": [571, 163, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-invideo'", + "rect": [571, 113, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-invideo'", "rect": [571, 113, 80, 40], @@ -47,6 +72,16 @@ "rect": [429, 513, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='copycanvas'", + "rect": [429, 513, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopcanvas'", + "rect": [429, 413, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-atopcanvas'", "rect": [429, 413, 80, 40], @@ -57,6 +92,16 @@ "rect": [429, 313, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-incanvas'", + "rect": [429, 313, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outcanvas'", + "rect": [429, 163, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-outcanvas'", "rect": [429, 163, 80, 40], @@ -67,6 +112,16 @@ "rect": [429, 113, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-incanvas'", + "rect": [429, 113, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='copyimage'", + "rect": [287, 513, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='copyimage'", "rect": [287, 513, 80, 40], @@ -77,6 +132,16 @@ "rect": [287, 413, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopimage'", + "rect": [287, 413, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-inimage'", + "rect": [287, 313, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-inimage'", "rect": [287, 313, 80, 40], @@ -87,11 +152,26 @@ "rect": [287, 163, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outimage'", + "rect": [287, 163, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-inimage'", "rect": [287, 113, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-inimage'", + "rect": [287, 113, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='copysolid color'", + "rect": [145, 513, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='copysolid color'", "rect": [145, 513, 80, 40], @@ -102,6 +182,16 @@ "rect": [145, 413, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopsolid color'", + "rect": [145, 413, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-insolid color'", + "rect": [145, 313, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-insolid color'", "rect": [145, 313, 80, 40], @@ -112,6 +202,16 @@ "rect": [145, 163, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outsolid color'", + "rect": [145, 163, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-insolid color'", + "rect": [145, 113, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-insolid color'", "rect": [145, 113, 80, 40], @@ -122,6 +222,16 @@ "rect": [601, 563, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorvideo'", + "rect": [601, 563, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightervideo'", + "rect": [601, 463, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='lightervideo'", "rect": [601, 463, 50, 40], @@ -132,6 +242,16 @@ "rect": [601, 363, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outvideo'", + "rect": [601, 363, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overvideo'", + "rect": [601, 263, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-overvideo'", "rect": [601, 263, 50, 40], @@ -142,11 +262,26 @@ "rect": [601, 213, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopvideo'", + "rect": [601, 213, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-overvideo'", "rect": [601, 63, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overvideo'", + "rect": [601, 63, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorcanvas'", + "rect": [459, 563, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='xorcanvas'", "rect": [459, 563, 50, 40], @@ -157,6 +292,16 @@ "rect": [459, 463, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightercanvas'", + "rect": [459, 463, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outcanvas'", + "rect": [459, 363, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-outcanvas'", "rect": [459, 363, 50, 40], @@ -167,6 +312,16 @@ "rect": [459, 263, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overcanvas'", + "rect": [459, 263, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopcanvas'", + "rect": [459, 213, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-atopcanvas'", "rect": [459, 213, 50, 40], @@ -177,6 +332,16 @@ "rect": [459, 63, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overcanvas'", + "rect": [459, 63, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorimage'", + "rect": [317, 563, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='xorimage'", "rect": [317, 563, 50, 40], @@ -187,6 +352,16 @@ "rect": [317, 463, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='lighterimage'", + "rect": [317, 463, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outimage'", + "rect": [317, 363, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-outimage'", "rect": [317, 363, 50, 40], @@ -197,11 +372,26 @@ "rect": [317, 263, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overimage'", + "rect": [317, 263, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-atopimage'", "rect": [317, 213, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopimage'", + "rect": [317, 213, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overimage'", + "rect": [317, 63, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-overimage'", "rect": [317, 63, 50, 40], @@ -212,6 +402,16 @@ "rect": [175, 563, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorsolid color'", + "rect": [175, 563, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightersolid color'", + "rect": [175, 463, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='lightersolid color'", "rect": [175, 463, 50, 40], @@ -222,6 +422,16 @@ "rect": [175, 363, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outsolid color'", + "rect": [175, 363, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-oversolid color'", + "rect": [175, 263, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-oversolid color'", "rect": [175, 263, 50, 40], @@ -232,6 +442,16 @@ "rect": [175, 213, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopsolid color'", + "rect": [175, 213, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-oversolid color'", + "rect": [175, 63, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-oversolid color'", "rect": [175, 63, 50, 40], diff --git a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/list-marker-2-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/list-marker-2-expected.txt index 51c4890039f283..45e6d4137ae30e 100644 --- a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/list-marker-2-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/list-marker-2-expected.txt @@ -22,6 +22,11 @@ "rect": [48, 94, 100, 100], "reason": "geometry" }, + { + "object": "LayoutImage IMG id='target'", + "rect": [48, 144, 100, 50], + "reason": "incremental" + }, { "object": "LayoutListMarker (anonymous)", "rect": [31, 180, 7, 18], diff --git a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt index c09f6049553f80..97f2568232f45a 100644 --- a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt @@ -26,6 +26,11 @@ "object": "LayoutImage IMG", "rect": [8, 60, 114, 232], "reason": "geometry" + }, + { + "object": "LayoutImage IMG", + "rect": [122, 60, 100, 232], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/selection/selected-replaced-expected.txt b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/selection/selected-replaced-expected.txt index fce57f53a9f048..ba4e53fdc78af6 100644 --- a/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/selection/selected-replaced-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/mac/paint/invalidation/selection/selected-replaced-expected.txt @@ -19,13 +19,23 @@ "paintInvalidations": [ { "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", - "rect": [8, 148, 214, 232], + "rect": [8, 68, 214, 232], "reason": "geometry" }, { "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", - "rect": [8, 68, 214, 232], + "rect": [8, 148, 214, 152], "reason": "geometry" + }, + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "rect": [8, 300, 214, 80], + "reason": "incremental" + }, + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "rect": [8, 68, 214, 80], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/overflow/overflow-update-transform-expected.png b/third_party/WebKit/LayoutTests/platform/win/fast/overflow/overflow-update-transform-expected.png index 9c58860ecef3df..0b91d43f061ed0 100644 Binary files a/third_party/WebKit/LayoutTests/platform/win/fast/overflow/overflow-update-transform-expected.png and b/third_party/WebKit/LayoutTests/platform/win/fast/overflow/overflow-update-transform-expected.png differ diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/replaced/selection-rect-transform-expected.png b/third_party/WebKit/LayoutTests/platform/win/fast/replaced/selection-rect-transform-expected.png index 7bdc69e09a18e2..43ccfc4d8f8b80 100644 Binary files a/third_party/WebKit/LayoutTests/platform/win/fast/replaced/selection-rect-transform-expected.png and b/third_party/WebKit/LayoutTests/platform/win/fast/replaced/selection-rect-transform-expected.png differ diff --git a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/box/box-inline-resize-expected.txt b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/box/box-inline-resize-expected.txt index 43f833bb0d8c2c..898a81bdf695d5 100644 --- a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/box/box-inline-resize-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/box/box-inline-resize-expected.txt @@ -20,17 +20,22 @@ { "object": "InlineTextBox 'Chromium'", "rect": [40, 107, 111, 28], - "reason": "geometry" + "reason": "chunk appeared" }, { "object": "InlineTextBox 'Chromium'", "rect": [8, 107, 111, 28], - "reason": "geometry" + "reason": "disappeared" }, { "object": "LayoutImage IMG id='foo'", "rect": [8, 88, 32, 32], "reason": "appeared" + }, + { + "object": "LayoutImage IMG id='foo'", + "rect": [8, 88, 32, 32], + "reason": "chunk appeared" } ] } diff --git a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/clip/clipped-relative-expected.txt b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/clip/clipped-relative-expected.txt index 4ba8da10a263b2..f1221fa5ada273 100644 --- a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/clip/clipped-relative-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/clip/clipped-relative-expected.txt @@ -22,6 +22,11 @@ "rect": [8, 74, 204, 232], "reason": "geometry" }, + { + "object": "LayoutImage IMG", + "rect": [102, 74, 110, 232], + "reason": "incremental" + }, { "object": "LayoutImage IMG", "rect": [8, 74, 94, 232], diff --git a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt index e62a20cc4b3a5f..be9955c571af5a 100644 --- a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/image/canvas-composite-repaint-by-all-imagesource-expected.txt @@ -22,6 +22,16 @@ "rect": [569, 515, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='copyvideo'", + "rect": [569, 515, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopvideo'", + "rect": [569, 415, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-atopvideo'", "rect": [569, 415, 80, 40], @@ -32,11 +42,26 @@ "rect": [569, 315, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-invideo'", + "rect": [569, 315, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-outvideo'", "rect": [569, 165, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outvideo'", + "rect": [569, 165, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-invideo'", + "rect": [569, 115, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-invideo'", "rect": [569, 115, 80, 40], @@ -47,6 +72,16 @@ "rect": [427, 515, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='copycanvas'", + "rect": [427, 515, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopcanvas'", + "rect": [427, 415, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-atopcanvas'", "rect": [427, 415, 80, 40], @@ -57,6 +92,16 @@ "rect": [427, 315, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-incanvas'", + "rect": [427, 315, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outcanvas'", + "rect": [427, 165, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-outcanvas'", "rect": [427, 165, 80, 40], @@ -67,6 +112,16 @@ "rect": [427, 115, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-incanvas'", + "rect": [427, 115, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='copyimage'", + "rect": [285, 515, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='copyimage'", "rect": [285, 515, 80, 40], @@ -77,6 +132,16 @@ "rect": [285, 415, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopimage'", + "rect": [285, 415, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-inimage'", + "rect": [285, 315, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-inimage'", "rect": [285, 315, 80, 40], @@ -87,11 +152,26 @@ "rect": [285, 165, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outimage'", + "rect": [285, 165, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-inimage'", "rect": [285, 115, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-inimage'", + "rect": [285, 115, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='copysolid color'", + "rect": [143, 515, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='copysolid color'", "rect": [143, 515, 80, 40], @@ -102,6 +182,16 @@ "rect": [143, 415, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-atopsolid color'", + "rect": [143, 415, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-insolid color'", + "rect": [143, 315, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-insolid color'", "rect": [143, 315, 80, 40], @@ -112,6 +202,16 @@ "rect": [143, 165, 80, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-outsolid color'", + "rect": [143, 165, 80, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-insolid color'", + "rect": [143, 115, 80, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-insolid color'", "rect": [143, 115, 80, 40], @@ -122,6 +222,16 @@ "rect": [599, 565, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorvideo'", + "rect": [599, 565, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightervideo'", + "rect": [599, 465, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='lightervideo'", "rect": [599, 465, 50, 40], @@ -132,6 +242,16 @@ "rect": [599, 365, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outvideo'", + "rect": [599, 365, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overvideo'", + "rect": [599, 265, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-overvideo'", "rect": [599, 265, 50, 40], @@ -142,11 +262,26 @@ "rect": [599, 215, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopvideo'", + "rect": [599, 215, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-overvideo'", "rect": [599, 65, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overvideo'", + "rect": [599, 65, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorcanvas'", + "rect": [457, 565, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='xorcanvas'", "rect": [457, 565, 50, 40], @@ -157,6 +292,16 @@ "rect": [457, 465, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightercanvas'", + "rect": [457, 465, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outcanvas'", + "rect": [457, 365, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-outcanvas'", "rect": [457, 365, 50, 40], @@ -167,6 +312,16 @@ "rect": [457, 265, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overcanvas'", + "rect": [457, 265, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopcanvas'", + "rect": [457, 215, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-atopcanvas'", "rect": [457, 215, 50, 40], @@ -177,6 +332,16 @@ "rect": [457, 65, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overcanvas'", + "rect": [457, 65, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorimage'", + "rect": [315, 565, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='xorimage'", "rect": [315, 565, 50, 40], @@ -187,6 +352,16 @@ "rect": [315, 465, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='lighterimage'", + "rect": [315, 465, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outimage'", + "rect": [315, 365, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-outimage'", "rect": [315, 365, 50, 40], @@ -197,11 +372,26 @@ "rect": [315, 265, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-overimage'", + "rect": [315, 265, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-atopimage'", "rect": [315, 215, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopimage'", + "rect": [315, 215, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-overimage'", + "rect": [315, 65, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-overimage'", "rect": [315, 65, 50, 40], @@ -212,6 +402,16 @@ "rect": [173, 565, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='xorsolid color'", + "rect": [173, 565, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='lightersolid color'", + "rect": [173, 465, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='lightersolid color'", "rect": [173, 465, 50, 40], @@ -222,6 +422,16 @@ "rect": [173, 365, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-outsolid color'", + "rect": [173, 365, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='destination-oversolid color'", + "rect": [173, 265, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='destination-oversolid color'", "rect": [173, 265, 50, 40], @@ -232,6 +442,16 @@ "rect": [173, 215, 50, 40], "reason": "invalidate paint rectangle" }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-atopsolid color'", + "rect": [173, 215, 50, 40], + "reason": "invalidate paint rectangle" + }, + { + "object": "LayoutHTMLCanvas CANVAS id='source-oversolid color'", + "rect": [173, 65, 50, 40], + "reason": "invalidate paint rectangle" + }, { "object": "LayoutHTMLCanvas CANVAS id='source-oversolid color'", "rect": [173, 65, 50, 40], diff --git a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/list-marker-2-expected.txt b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/list-marker-2-expected.txt index e7355168c172fc..66306cabf8c335 100644 --- a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/list-marker-2-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/list-marker-2-expected.txt @@ -22,6 +22,11 @@ "rect": [48, 100, 100, 100], "reason": "geometry" }, + { + "object": "LayoutImage IMG id='target'", + "rect": [48, 150, 100, 50], + "reason": "incremental" + }, { "object": "LayoutListMarker (anonymous)", "rect": [30, 185, 7, 19], diff --git a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt index e319b61848bc4e..829cd3691b41f4 100644 --- a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/position/positioned-list-offset-change-repaint-expected.txt @@ -26,6 +26,11 @@ "object": "LayoutImage IMG", "rect": [8, 64, 114, 232], "reason": "geometry" + }, + { + "object": "LayoutImage IMG", + "rect": [122, 64, 100, 232], + "reason": "incremental" } ] } diff --git a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/selection/selected-replaced-expected.txt b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/selection/selected-replaced-expected.txt index 377adb50b44dc8..812b604d1995e1 100644 --- a/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/selection/selected-replaced-expected.txt +++ b/third_party/WebKit/LayoutTests/platform/win/paint/invalidation/selection/selected-replaced-expected.txt @@ -19,13 +19,23 @@ "paintInvalidations": [ { "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", - "rect": [8, 132, 214, 232], + "rect": [8, 52, 214, 232], "reason": "geometry" }, { "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", - "rect": [8, 52, 214, 232], + "rect": [8, 132, 214, 152], "reason": "geometry" + }, + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "rect": [8, 284, 214, 80], + "reason": "incremental" + }, + { + "object": "LayoutImage (relative positioned) IMG id='test' class='moved'", + "rect": [8, 52, 214, 80], + "reason": "incremental" } ] } diff --git a/third_party/blink/renderer/core/layout/layout_embedded_content.cc b/third_party/blink/renderer/core/layout/layout_embedded_content.cc index 9b1a6882638a89..b34ce05206b718 100644 --- a/third_party/blink/renderer/core/layout/layout_embedded_content.cc +++ b/third_party/blink/renderer/core/layout/layout_embedded_content.cc @@ -271,14 +271,10 @@ void LayoutEmbeddedContent::UpdateLayout() { ClearNeedsLayout(); } -void LayoutEmbeddedContent::Paint(const PaintInfo& paint_info) const { - EmbeddedContentPainter(*this).Paint(paint_info); -} - -void LayoutEmbeddedContent::PaintContents( +void LayoutEmbeddedContent::PaintReplaced( const PaintInfo& paint_info, const LayoutPoint& paint_offset) const { - EmbeddedContentPainter(*this).PaintContents(paint_info, paint_offset); + EmbeddedContentPainter(*this).PaintReplaced(paint_info, paint_offset); } CursorDirective LayoutEmbeddedContent::GetCursor(const LayoutPoint& point, diff --git a/third_party/blink/renderer/core/layout/layout_embedded_content.h b/third_party/blink/renderer/core/layout/layout_embedded_content.h index 03a429008ef891..dd85f9b148fc0d 100644 --- a/third_party/blink/renderer/core/layout/layout_embedded_content.h +++ b/third_party/blink/renderer/core/layout/layout_embedded_content.h @@ -63,8 +63,6 @@ class CORE_EXPORT LayoutEmbeddedContent : public LayoutReplaced { void UpdateGeometry(EmbeddedContentView&); bool IsLayoutEmbeddedContent() const final { return true; } - virtual void PaintContents(const PaintInfo&, - const LayoutPoint& paint_offset) const; bool IsThrottledFrameView() const; @@ -73,7 +71,8 @@ class CORE_EXPORT LayoutEmbeddedContent : public LayoutReplaced { void StyleDidChange(StyleDifference, const ComputedStyle* old_style) final; void UpdateLayout() override; - void Paint(const PaintInfo&) const override; + void PaintReplaced(const PaintInfo&, + const LayoutPoint& paint_offset) const override; CursorDirective GetCursor(const LayoutPoint&, Cursor&) const final; bool CanBeSelectionLeafInternal() const final { return true; } diff --git a/third_party/blink/renderer/core/layout/layout_embedded_object.cc b/third_party/blink/renderer/core/layout/layout_embedded_object.cc index 696c65e019fb8c..7baf19bcf23b7a 100644 --- a/third_party/blink/renderer/core/layout/layout_embedded_object.cc +++ b/third_party/blink/renderer/core/layout/layout_embedded_object.cc @@ -83,25 +83,6 @@ bool LayoutEmbeddedObject::ShowsUnavailablePluginIndicator() const { return plugin_availability_ != kPluginAvailable; } -void LayoutEmbeddedObject::PaintContents( - const PaintInfo& paint_info, - const LayoutPoint& paint_offset) const { - Element* element = ToElement(GetNode()); - if (!IsHTMLPlugInElement(element)) - return; - - LayoutEmbeddedContent::PaintContents(paint_info, paint_offset); -} - -void LayoutEmbeddedObject::Paint(const PaintInfo& paint_info) const { - if (ShowsUnavailablePluginIndicator()) { - LayoutReplaced::Paint(paint_info); - return; - } - - LayoutEmbeddedContent::Paint(paint_info); -} - void LayoutEmbeddedObject::PaintReplaced( const PaintInfo& paint_info, const LayoutPoint& paint_offset) const { diff --git a/third_party/blink/renderer/core/layout/layout_embedded_object.h b/third_party/blink/renderer/core/layout/layout_embedded_object.h index 88d4ea15a1aabe..8ee32cd7923cc8 100644 --- a/third_party/blink/renderer/core/layout/layout_embedded_object.h +++ b/third_party/blink/renderer/core/layout/layout_embedded_object.h @@ -50,11 +50,8 @@ class LayoutEmbeddedObject final : public LayoutEmbeddedContent { } private: - void PaintContents(const PaintInfo&, - const LayoutPoint& paint_offset) const final; void PaintReplaced(const PaintInfo&, const LayoutPoint& paint_offset) const final; - void Paint(const PaintInfo&) const final; PaintInvalidationReason InvalidatePaint( const PaintInvalidatorContext&) const final; diff --git a/third_party/blink/renderer/core/paint/embedded_content_painter.cc b/third_party/blink/renderer/core/paint/embedded_content_painter.cc index ca814c2d8f4f51..e75323dcb9e8de 100644 --- a/third_party/blink/renderer/core/paint/embedded_content_painter.cc +++ b/third_party/blink/renderer/core/paint/embedded_content_painter.cc @@ -20,104 +20,12 @@ namespace blink { -bool EmbeddedContentPainter::IsSelected() const { - SelectionState s = layout_embedded_content_.GetSelectionState(); - if (s == SelectionState::kNone) - return false; - - return true; -} - -void EmbeddedContentPainter::Paint(const PaintInfo& paint_info) { - // TODO(crbug.com/797779): For now embedded contents don't know whether - // they are painted in a fragmented context and may do something bad in a - // fragmented context, e.g. creating subsequences. Skip cache to avoid that. - // This will be unnecessary when the contents are fragment aware. - base::Optional cache_skipper; - DCHECK(layout_embedded_content_.HasLayer()); - if (layout_embedded_content_.Layer()->EnclosingPaginationLayer()) - cache_skipper.emplace(paint_info.context); - - AdjustPaintOffsetScope adjustment(layout_embedded_content_, paint_info); - const auto& local_paint_info = adjustment.GetPaintInfo(); - auto paint_offset = adjustment.PaintOffset(); - if (!ReplacedPainter(layout_embedded_content_) - .ShouldPaint(local_paint_info, paint_offset)) - return; - - if (layout_embedded_content_.HasBoxDecorationBackground() && - (local_paint_info.phase == PaintPhase::kForeground || - local_paint_info.phase == PaintPhase::kSelection)) { - BoxPainter(layout_embedded_content_) - .PaintBoxDecorationBackground(local_paint_info, paint_offset); - } - - if (local_paint_info.phase == PaintPhase::kMask) { - BoxPainter(layout_embedded_content_) - .PaintMask(local_paint_info, paint_offset); - return; - } - - if (ShouldPaintSelfOutline(local_paint_info.phase)) { - ObjectPainter(layout_embedded_content_) - .PaintOutline(local_paint_info, paint_offset); - } - - if (local_paint_info.phase != PaintPhase::kForeground) - return; - - if (layout_embedded_content_.GetEmbeddedContentView()) { - LayoutRect border_rect(paint_offset, layout_embedded_content_.Size()); - if (border_rect.IsEmpty()) - return; - - base::Optional scoped_paint_chunk_properties; - const auto* fragment = - local_paint_info.FragmentToPaint(layout_embedded_content_); - if (!fragment) - return; - const auto* properties = fragment->PaintProperties(); - - if (properties && properties->OverflowClip()) { - scoped_paint_chunk_properties.emplace( - local_paint_info.context.GetPaintController(), - properties->OverflowClip(), layout_embedded_content_, - DisplayItem::PaintPhaseToDrawingType(local_paint_info.phase)); - } - - layout_embedded_content_.PaintContents(local_paint_info, paint_offset); - } - - // Paint a partially transparent wash over selected EmbeddedContentViews. - if (IsSelected() && !local_paint_info.IsPrinting() && - !DrawingRecorder::UseCachedDrawingIfPossible(local_paint_info.context, - layout_embedded_content_, - local_paint_info.phase)) { - LayoutRect rect = layout_embedded_content_.LocalSelectionRect(); - rect.MoveBy(paint_offset); - IntRect selection_rect = PixelSnappedIntRect(rect); - DrawingRecorder recorder(local_paint_info.context, layout_embedded_content_, - local_paint_info.phase); - Color selection_bg = SelectionPaintingUtils::SelectionBackgroundColor( - layout_embedded_content_.GetDocument(), - layout_embedded_content_.StyleRef(), - layout_embedded_content_.GetNode()); - local_paint_info.context.FillRect(selection_rect, selection_bg); - } - - if (layout_embedded_content_.CanResize()) { - ScrollableAreaPainter( - *layout_embedded_content_.Layer()->GetScrollableArea()) - .PaintResizer(local_paint_info.context, RoundedIntPoint(paint_offset), - local_paint_info.GetCullRect()); - } -} - -void EmbeddedContentPainter::PaintContents(const PaintInfo& paint_info, +void EmbeddedContentPainter::PaintReplaced(const PaintInfo& paint_info, const LayoutPoint& paint_offset) { EmbeddedContentView* embedded_content_view = layout_embedded_content_.GetEmbeddedContentView(); - CHECK(embedded_content_view); + if (!embedded_content_view) + return; IntPoint paint_location(RoundedIntPoint( paint_offset + diff --git a/third_party/blink/renderer/core/paint/embedded_content_painter.h b/third_party/blink/renderer/core/paint/embedded_content_painter.h index ea101cd1d3e8b0..b72a09dc1f5cc2 100644 --- a/third_party/blink/renderer/core/paint/embedded_content_painter.h +++ b/third_party/blink/renderer/core/paint/embedded_content_painter.h @@ -20,12 +20,9 @@ class EmbeddedContentPainter { EmbeddedContentPainter(const LayoutEmbeddedContent& layout_embedded_content) : layout_embedded_content_(layout_embedded_content) {} - void Paint(const PaintInfo&); - void PaintContents(const PaintInfo&, const LayoutPoint& paint_offset); + void PaintReplaced(const PaintInfo&, const LayoutPoint& paint_offset); private: - bool IsSelected() const; - const LayoutEmbeddedContent& layout_embedded_content_; }; diff --git a/third_party/blink/renderer/core/paint/embedded_object_painter.cc b/third_party/blink/renderer/core/paint/embedded_object_painter.cc index 2b2790e7d06c10..99c1b77a7f65d8 100644 --- a/third_party/blink/renderer/core/paint/embedded_object_painter.cc +++ b/third_party/blink/renderer/core/paint/embedded_object_painter.cc @@ -7,6 +7,7 @@ #include "third_party/blink/renderer/core/frame/settings.h" #include "third_party/blink/renderer/core/layout/layout_embedded_object.h" #include "third_party/blink/renderer/core/layout/layout_theme.h" +#include "third_party/blink/renderer/core/paint/embedded_content_painter.h" #include "third_party/blink/renderer/core/paint/paint_info.h" #include "third_party/blink/renderer/platform/fonts/font.h" #include "third_party/blink/renderer/platform/fonts/font_selector.h" @@ -37,8 +38,11 @@ static Font ReplacementTextFont() { void EmbeddedObjectPainter::PaintReplaced(const PaintInfo& paint_info, const LayoutPoint& paint_offset) { - if (!layout_embedded_object_.ShowsUnavailablePluginIndicator()) + if (!layout_embedded_object_.ShowsUnavailablePluginIndicator()) { + EmbeddedContentPainter(layout_embedded_object_) + .PaintReplaced(paint_info, paint_offset); return; + } if (paint_info.phase == PaintPhase::kSelection) return; diff --git a/third_party/blink/renderer/core/paint/html_canvas_painter.cc b/third_party/blink/renderer/core/paint/html_canvas_painter.cc index be38ebb0e883d3..a5692927314b46 100644 --- a/third_party/blink/renderer/core/paint/html_canvas_painter.cc +++ b/third_party/blink/renderer/core/paint/html_canvas_painter.cc @@ -33,8 +33,6 @@ void HTMLCanvasPainter::PaintReplaced(const PaintInfo& paint_info, const LayoutPoint& paint_offset) { GraphicsContext& context = paint_info.context; - LayoutRect content_rect = layout_html_canvas_.ContentBoxRect(); - content_rect.MoveBy(paint_offset); LayoutRect paint_rect = layout_html_canvas_.ReplacedContentRect(); paint_rect.MoveBy(paint_offset); @@ -45,7 +43,7 @@ void HTMLCanvasPainter::PaintReplaced(const PaintInfo& paint_info, canvas->RenderingContext() && canvas->RenderingContext()->IsComposited()) { if (cc::Layer* layer = canvas->RenderingContext()->CcLayer()) { - IntRect pixel_snapped_rect = PixelSnappedIntRect(content_rect); + IntRect pixel_snapped_rect = PixelSnappedIntRect(paint_rect); layer->SetBounds(static_cast(pixel_snapped_rect.Size())); layer->SetIsDrawable(true); RecordForeignLayer( @@ -60,22 +58,9 @@ void HTMLCanvasPainter::PaintReplaced(const PaintInfo& paint_info, return; DrawingRecorder recorder(context, layout_html_canvas_, paint_info.phase); - - bool clip = !content_rect.Contains(paint_rect); - if (clip) { - context.Save(); - // TODO(chrishtr): this should be pixel-snapped. - context.Clip(FloatRect(content_rect)); - } - - { - ScopedInterpolationQuality interpolation_quality_scope( - context, InterpolationQualityForCanvas(layout_html_canvas_.StyleRef())); - canvas->Paint(context, paint_rect); - } - - if (clip) - context.Restore(); + ScopedInterpolationQuality interpolation_quality_scope( + context, InterpolationQualityForCanvas(layout_html_canvas_.StyleRef())); + canvas->Paint(context, paint_rect); } } // namespace blink diff --git a/third_party/blink/renderer/core/paint/object_paint_invalidator_test.cc b/third_party/blink/renderer/core/paint/object_paint_invalidator_test.cc index 30701f663e6e61..7b7a39ede81ee7 100644 --- a/third_party/blink/renderer/core/paint/object_paint_invalidator_test.cc +++ b/third_party/blink/renderer/core/paint/object_paint_invalidator_test.cc @@ -337,9 +337,11 @@ TEST_F(ObjectPaintInvalidatorTest, Selection) { const auto* graphics_layer = GetLayoutView().Layer()->GraphicsLayerBacking(); const auto* invalidations = &graphics_layer->GetRasterInvalidationTracking()->Invalidations(); - ASSERT_EQ(1u, invalidations->size()); + ASSERT_EQ(2u, invalidations->size()); EXPECT_EQ(IntRect(8, 8, 100, 100), (*invalidations)[0].rect); EXPECT_EQ(PaintInvalidationReason::kSelection, (*invalidations)[0].reason); + EXPECT_EQ(IntRect(8, 8, 100, 100), (*invalidations)[1].rect); + EXPECT_EQ(PaintInvalidationReason::kChunkAppeared, (*invalidations)[1].reason); EXPECT_EQ(LayoutRect(8, 8, 100, 100), target->SelectionVisualRect()); GetDocument().View()->SetTracksPaintInvalidations(false); @@ -359,9 +361,11 @@ TEST_F(ObjectPaintInvalidatorTest, Selection) { GetDocument().View()->UpdateAllLifecyclePhases(); invalidations = &graphics_layer->GetRasterInvalidationTracking()->Invalidations(); - ASSERT_EQ(1u, invalidations->size()); + ASSERT_EQ(2u, invalidations->size()); EXPECT_EQ(IntRect(8, 8, 100, 100), (*invalidations)[0].rect); EXPECT_EQ(PaintInvalidationReason::kSelection, (*invalidations)[0].reason); + EXPECT_EQ(IntRect(8, 8, 100, 100), (*invalidations)[1].rect); + EXPECT_EQ(PaintInvalidationReason::kChunkDisappeared, (*invalidations)[1].reason); EXPECT_EQ(LayoutRect(), target->SelectionVisualRect()); GetDocument().View()->SetTracksPaintInvalidations(false); } diff --git a/third_party/blink/renderer/core/paint/replaced_painter.cc b/third_party/blink/renderer/core/paint/replaced_painter.cc index 820d3cedc69387..923bb72c01ca51 100644 --- a/third_party/blink/renderer/core/paint/replaced_painter.cc +++ b/third_party/blink/renderer/core/paint/replaced_painter.cc @@ -15,13 +15,26 @@ #include "third_party/blink/renderer/core/paint/paint_info.h" #include "third_party/blink/renderer/core/paint/paint_layer.h" #include "third_party/blink/renderer/core/paint/rounded_inner_rect_clipper.h" +#include "third_party/blink/renderer/core/paint/scrollable_area_painter.h" #include "third_party/blink/renderer/core/paint/selection_painting_utils.h" +#include "third_party/blink/renderer/platform/graphics/paint/display_item_cache_skipper.h" #include "third_party/blink/renderer/platform/graphics/paint/drawing_recorder.h" #include "third_party/blink/renderer/platform/graphics/paint/scoped_paint_chunk_properties.h" namespace blink { void ReplacedPainter::Paint(const PaintInfo& paint_info) { + // TODO(crbug.com/797779): For now embedded contents don't know whether + // they are painted in a fragmented context and may do something bad in a + // fragmented context, e.g. creating subsequences. Skip cache to avoid that. + // This will be unnecessary when the contents are fragment aware. + base::Optional cache_skipper; + if (layout_replaced_.IsLayoutEmbeddedContent()) { + DCHECK(layout_replaced_.HasLayer()); + if (layout_replaced_.Layer()->EnclosingPaginationLayer()) + cache_skipper.emplace(paint_info.context); + } + AdjustPaintOffsetScope adjustment(layout_replaced_, paint_info); const auto& local_paint_info = adjustment.GetPaintInfo(); auto paint_offset = adjustment.PaintOffset(); @@ -32,7 +45,7 @@ void ReplacedPainter::Paint(const PaintInfo& paint_info) { LayoutRect border_rect(paint_offset, layout_replaced_.Size()); if (ShouldPaintSelfBlockBackground(local_paint_info.phase)) { - if (layout_replaced_.Style()->Visibility() == EVisibility::kVisible && + if (layout_replaced_.StyleRef().Visibility() == EVisibility::kVisible && layout_replaced_.HasBoxDecorationBackground()) { if (layout_replaced_.HasLayer() && layout_replaced_.Layer()->GetCompositingState() == @@ -42,8 +55,8 @@ void ReplacedPainter::Paint(const PaintInfo& paint_info) { ->DrawsBackgroundOntoContentLayer()) return; - layout_replaced_.PaintBoxDecorationBackground(local_paint_info, - paint_offset); + BoxPainter(layout_replaced_) + .PaintBoxDecorationBackground(local_paint_info, paint_offset); } // We're done. We don't bother painting any children. if (local_paint_info.phase == PaintPhase::kSelfBlockBackgroundOnly) @@ -51,7 +64,7 @@ void ReplacedPainter::Paint(const PaintInfo& paint_info) { } if (local_paint_info.phase == PaintPhase::kMask) { - layout_replaced_.PaintMask(local_paint_info, paint_offset); + BoxPainter(layout_replaced_).PaintMask(local_paint_info, paint_offset); return; } @@ -70,38 +83,37 @@ void ReplacedPainter::Paint(const PaintInfo& paint_info) { layout_replaced_.GetSelectionState() == SelectionState::kNone) return; - { + bool skip_clip = layout_replaced_.IsSVGRoot() && + !ToLayoutSVGRoot(layout_replaced_).ShouldApplyViewportClip(); + if (skip_clip || !layout_replaced_.ContentBoxRect().IsEmpty()) { base::Optional chunk_properties; - bool completely_clipped_out = false; - - if (layout_replaced_.Style()->HasBorderRadius() && border_rect.IsEmpty()) - completely_clipped_out = true; - - if (!layout_replaced_.IsSVGRoot()) { - if (const auto* fragment = paint_info.FragmentToPaint(layout_replaced_)) { - if (const auto* paint_properties = fragment->PaintProperties()) { - // Check filter for optimized image policy violation highlights, which - // may be applied locally. - if (paint_properties->Filter() && - (!layout_replaced_.HasLayer() || - !layout_replaced_.Layer()->IsSelfPaintingLayer())) { - chunk_properties.emplace( - local_paint_info.context.GetPaintController(), - fragment->ContentsProperties(), layout_replaced_, - DisplayItem::PaintPhaseToDrawingType(local_paint_info.phase)); - } else if (layout_replaced_.Style()->HasBorderRadius()) { - DCHECK(paint_properties->OverflowClip()); - chunk_properties.emplace( - local_paint_info.context.GetPaintController(), - paint_properties->OverflowClip(), layout_replaced_, - DisplayItem::PaintPhaseToDrawingType(local_paint_info.phase)); - } + if (const auto* fragment = paint_info.FragmentToPaint(layout_replaced_)) { + if (const auto* paint_properties = fragment->PaintProperties()) { + // Check filter for optimized image policy violation highlights, which + // may be applied locally. + if (paint_properties->Filter() && + (!layout_replaced_.HasLayer() || + !layout_replaced_.Layer()->IsSelfPaintingLayer())) { + chunk_properties.emplace( + local_paint_info.context.GetPaintController(), + fragment->ContentsProperties(), layout_replaced_, + paint_info.DisplayItemTypeForClipping()); + } else if (paint_properties->OverflowClip()) { + chunk_properties.emplace( + local_paint_info.context.GetPaintController(), + paint_properties->OverflowClip(), layout_replaced_, + paint_info.DisplayItemTypeForClipping()); } } } - if (!completely_clipped_out) - layout_replaced_.PaintReplaced(local_paint_info, paint_offset); + layout_replaced_.PaintReplaced(local_paint_info, paint_offset); + } + + if (layout_replaced_.CanResize()) { + ScrollableAreaPainter(*layout_replaced_.Layer()->GetScrollableArea()) + .PaintResizer(local_paint_info.context, RoundedIntPoint(paint_offset), + local_paint_info.GetCullRect()); } // The selection tint never gets clipped by border-radius rounding, since we diff --git a/third_party/blink/renderer/core/paint/svg_root_painter.cc b/third_party/blink/renderer/core/paint/svg_root_painter.cc index 448e42aed97de2..a4976a0a95e444 100644 --- a/third_party/blink/renderer/core/paint/svg_root_painter.cc +++ b/third_party/blink/renderer/core/paint/svg_root_painter.cc @@ -7,7 +7,6 @@ #include "base/optional.h" #include "third_party/blink/renderer/core/layout/svg/layout_svg_root.h" #include "third_party/blink/renderer/core/layout/svg/svg_layout_support.h" -#include "third_party/blink/renderer/core/paint/box_clipper.h" #include "third_party/blink/renderer/core/paint/box_painter.h" #include "third_party/blink/renderer/core/paint/object_paint_properties.h" #include "third_party/blink/renderer/core/paint/paint_info.h" @@ -51,13 +50,6 @@ void SVGRootPainter::PaintReplaced(const PaintInfo& paint_info, if (svg->HasEmptyViewBox()) return; - // Apply initial viewport clip. - base::Optional box_clipper; - if (layout_svg_root_.ShouldApplyViewportClip()) { - // TODO(pdr): Clip the paint info cull rect here. - box_clipper.emplace(layout_svg_root_, paint_info); - } - PaintInfo paint_info_before_filtering(paint_info); AffineTransform transform_to_border_box = TransformToPixelSnappedBorderBox(paint_offset);