-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Invalidate layer when its composited scrolling status changed
When a composited scrolling layer's object is set 'pointer-events:none', the layer will no longer use composited scrolling (though it is still composited). This is controlled by ComputedStyle::VisibleToHitTesting(). When this happens, no other conditions trigger invalidation of the layer. Now invalidate a layer when its composited scrolling status changed. [email protected] (cherry picked from commit 9ba2227) Bug: 758474 Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Change-Id: I3c01a543a5424d8c746e901047abc606874e0290 Reviewed-on: https://chromium-review.googlesource.com/717028 Reviewed-by: Philip Rogers <[email protected]> Commit-Queue: Xianzhu Wang <[email protected]> Cr-Original-Commit-Position: refs/heads/master@{#509172} Reviewed-on: https://chromium-review.googlesource.com/726379 Reviewed-by: Xianzhu Wang <[email protected]> Cr-Commit-Position: refs/branch-heads/3239@{#53} Cr-Branched-From: adb61db-refs/heads/master@{#508578}
- Loading branch information
1 parent
f9a91c4
commit 2dcf849
Showing
7 changed files
with
106 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
...outTests/paint/invalidation/compositing/pointer-events-composited-scrolling-expected.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<!DOCTYPE html> | ||
<div id="content" style="margin-top: 38px; width: 50px; height: 50px; background: blue"></div> |
67 changes: 67 additions & 0 deletions
67
...youtTests/paint/invalidation/compositing/pointer-events-composited-scrolling-expected.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
{ | ||
"layers": [ | ||
{ | ||
"name": "LayoutView #document", | ||
"bounds": [800, 600], | ||
"contentsOpaque": true, | ||
"backgroundColor": "#FFFFFF" | ||
}, | ||
{ | ||
"name": "LayoutBlockFlow DIV id='target'", | ||
"position": [8, 8], | ||
"bounds": [100, 100], | ||
"paintInvalidations": [ | ||
{ | ||
"object": "LayoutBlockFlow DIV id='target'", | ||
"rect": [0, 0, 100, 100], | ||
"reason": "full" | ||
}, | ||
{ | ||
"object": "LayoutBlockFlow DIV id='target'", | ||
"rect": [0, 0, 100, 100], | ||
"reason": "compositing update" | ||
}, | ||
{ | ||
"object": "LayoutBlockFlow DIV id='content'", | ||
"rect": [0, 30, 50, 50], | ||
"reason": "compositing update" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "Overflow Controls Host Layer", | ||
"position": [8, 8], | ||
"bounds": [100, 100], | ||
"drawsContent": false | ||
}, | ||
{ | ||
"name": "Horizontal Scrollbar Layer", | ||
"position": [8, 108], | ||
"bounds": [100, 0] | ||
}, | ||
{ | ||
"name": "Vertical Scrollbar Layer", | ||
"position": [108, 8], | ||
"bounds": [0, 100] | ||
} | ||
], | ||
"objectPaintInvalidations": [ | ||
{ | ||
"object": "LayoutBlockFlow DIV id='target'", | ||
"reason": "compositing update" | ||
}, | ||
{ | ||
"object": "LayoutBlockFlow DIV id='target'", | ||
"reason": "geometry" | ||
}, | ||
{ | ||
"object": "LayoutBlockFlow DIV id='target'", | ||
"reason": "geometry" | ||
}, | ||
{ | ||
"object": "LayoutBlockFlow DIV id='content'", | ||
"reason": "compositing update" | ||
} | ||
] | ||
} | ||
|
15 changes: 15 additions & 0 deletions
15
...ebKit/LayoutTests/paint/invalidation/compositing/pointer-events-composited-scrolling.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<!DOCTYPE html> | ||
<style>*::-webkit-scrollbar { display: none }</style> | ||
<div id="target" style="overflow: scroll; will-change: transform; width: 100px; height: 100px"> | ||
<div id="content" style="margin: 80px 0; width: 50px; height: 50px; background: blue"></div> | ||
</div> | ||
<script src="../resources/text-based-repaint.js"></script> | ||
<script> | ||
function repaintTest() { | ||
target.style.pointerEvents = 'none'; | ||
} | ||
onload = function() { | ||
target.scrollTop = 50; | ||
runRepaintAndPixelTest(); | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters