|
Avoid paintInvalidationContainer parameter of invalidatePaintIfNeeded()
Change the original flow:
invalidateTreeIfNeeded(parentPaintInvalidationState)
{
newPaintInvalidationContainer = ...;
invalidatePaintIfNeeded(parentPaintInvalidationState, newPaintInvalidationContainer);
PaintInvalidationState childPaintInvalidationState(parentPaintInvalidationState);
invalidatePaintOfSubtreesIfNeeded(childPaintinvalidationState);
}
to:
invalidateTreeIfNeeded(parentPaintInvalidationState)
{
newPaintInvalidationState(parentPaintInvalidationState); // Which updates paintInvalidationContainer, but not geometry info for children.
invalidatePaintIfNeeded(newPaintInvalidationState);
newPaintInvalidationState.updatePaintOffsetAndClipForChildren();
invalidatePaintOfSubtreesIfNeeded(newPaintInvalidationState);
}
This is like how PaintPropertyTreeBuilderContexts are inherited and updated:
copy from parent first, then update in multiple steps. We may use the state
for different purposes after different steps.
The benefits are:
- Avoid additional paintInvalidationContainer in invalidatePaintIfNeeded()
by letting paintInvalidationState parameter contain the correct
paintInvalidationContainer for the current object;
- We move the logic to find the paintInvalidationContainer from LayoutObjects
into PaintInvalidationState which knows more information;
- This is a preparation for the next step works to avoid some
ForcedHorriblySlowRectMappings because we need to track correct
paintInvalidationContainer (for normal objects and stacked objects) in
PaintInvalidationState, instead of being passed in from
LayoutBoxModelObject::invalidateTreeIfNeeded();
BUG= 591199
Committed: https://crrev.com/468ca56ab508342df50c7ee16ac4f4e767a1614b
Cr-Commit-Position: refs/heads/master@{#381875}
Total comments: 2
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+239 lines, -174 lines) |
Patch |
 |
M |
third_party/WebKit/Source/core/frame/FrameView.cpp
|
View
|
1
2
3
4
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutBlock.h
|
View
|
1
2
3
4
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutBlock.cpp
|
View
|
|
2 chunks |
+2 lines, -5 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutBlockFlow.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutBlockFlowLine.cpp
|
View
|
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutBox.h
|
View
|
1
2
3
4
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutBox.cpp
|
View
|
1
2
3
4
5
|
2 chunks |
+4 lines, -4 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutBoxModelObject.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutBoxModelObject.cpp
|
View
|
1
2
3
4
|
2 chunks |
+12 lines, -13 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutEmbeddedObject.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutEmbeddedObject.cpp
|
View
|
|
1 chunk |
+2 lines, -4 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutHTMLCanvas.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutHTMLCanvas.cpp
|
View
|
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutMultiColumnSpannerPlaceholder.cpp
|
View
|
1
2
3
|
1 chunk |
+3 lines, -2 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutObject.h
|
View
|
1
2
3
4
|
3 chunks |
+4 lines, -4 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutObject.cpp
|
View
|
1
2
3
4
5
|
6 chunks |
+10 lines, -6 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutPart.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutPart.cpp
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutTable.h
|
View
|
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutTable.cpp
|
View
|
|
1 chunk |
+3 lines, -3 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutView.h
|
View
|
1
|
2 chunks |
+1 line, -27 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/LayoutView.cpp
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/PaintInvalidationState.h
|
View
|
1
2
3
4
5
|
4 chunks |
+53 lines, -7 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp
|
View
|
1
2
3
4
5
|
5 chunks |
+88 lines, -49 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGBlock.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGBlock.cpp
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGInline.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGInline.cpp
|
View
|
|
1 chunk |
+8 lines, -6 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGModelObject.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGModelObject.cpp
|
View
|
|
2 chunks |
+6 lines, -5 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGText.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/layout/svg/LayoutSVGText.cpp
|
View
|
1
|
1 chunk |
+9 lines, -7 lines |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/paint/PaintInvalidationCapableScrollableArea.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
third_party/WebKit/Source/core/paint/PaintInvalidationCapableScrollableArea.cpp
|
View
|
|
4 chunks |
+10 lines, -8 lines |
0 comments
|
Download
|
Total messages: 25 (15 generated)
|