|
|
[Reland] Invalidate whitespace text on text color changes
This patch updates the optimization added in [1] to invalidate
whitespace text on color changes because whitespace text can have
decorations such as underlines which still need to repaint.
The big idea of the optimization in [1] is to not unnecessarily repaint
expensive items such as images that are in an <a> element. On hover, <a>
will change color and underline styles which should not affect images.
This patch adds a test to prove this optimization still works and
prevents it from breaking in the future.
This patch contains a fix for a performance regression[2] where text
nodes without text (i.e., !firstTextBox) would be invalidated. This is
tested by fast/repaint/inline-outline-repaint-2.html but was incorrectly
thought to be a benign change in the original patch. Additional comments
have been added both about the optimization and about the tricky
empty-text case. Additionally, hasTextBoxes has been introduced to make
this area cleaner.
[1] https://src.chromium.org/viewvc/blink?view=rev&revision=152046
[2] https://src.chromium.org/viewvc/blink?view=rev&revision=202374
TBR=chrishtr
BUG= 529944
Committed: https://crrev.com/72f85dacbbef4c117efdb8e353036873d167b989
Cr-Commit-Position: refs/heads/master@{#350412}
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+104 lines, -15 lines) |
Patch |
 |
A |
third_party/WebKit/LayoutTests/paint/invalidation/non-text-link-invalidation-optimization.html
|
View
|
|
1 chunk |
+28 lines, -0 lines |
0 comments
|
Download
|
 |
A + |
third_party/WebKit/LayoutTests/paint/invalidation/non-text-link-invalidation-optimization-expected.txt
|
View
|
|
0 chunks |
+-1 lines, --1 lines |
0 comments
|
Download
|
 |
A |
third_party/WebKit/LayoutTests/paint/invalidation/text-decoration-invalidation.html
|
View
|
|
1 chunk |
+36 lines, -0 lines |
0 comments
|
Download
|
 |
A |
third_party/WebKit/LayoutTests/paint/invalidation/text-decoration-invalidation-expected.html
|
View
|
|
1 chunk |
+19 lines, -0 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/dom/ContainerNode.cpp
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/editing/VisibleUnits.cpp
|
View
|
|
2 chunks |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/editing/iterators/SimplifiedBackwardsTextIterator.cpp
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutObject.cpp
|
View
|
|
1 chunk |
+5 lines, -2 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutText.h
|
View
|
|
1 chunk |
+3 lines, -0 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutTreeAsText.cpp
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGInlineText.cpp
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/style/ComputedStyle.cpp
|
View
|
|
2 chunks |
+3 lines, -3 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/style/StyleDifference.h
|
View
|
|
2 chunks |
+4 lines, -4 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
Total messages: 17 (7 generated)
|