Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(613)

Unified Diff: third_party/WebKit/Source/core/paint/PaintInvalidator.cpp

Issue 2745793004: Remove PaintInvalidatorContext::newVisualRect (Closed)
Patch Set: - Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/paint/PaintInvalidator.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintInvalidator.cpp b/third_party/WebKit/Source/core/paint/PaintInvalidator.cpp
index bd696e9e2cf7adc6eaecee1baca706052a8678c3..7b9decab4cb72ddd6de796c6cfe3425279919573 100644
--- a/third_party/WebKit/Source/core/paint/PaintInvalidator.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintInvalidator.cpp
@@ -367,13 +367,13 @@ void PaintInvalidator::updateVisualRect(const LayoutObject& object,
IntSize adjustment = object.scrollAdjustmentForPaintInvalidation(
*context.paintInvalidationContainer);
- context.newVisualRect = computeVisualRectInBacking(object, context);
- context.newVisualRect.move(adjustment);
+ LayoutRect newVisualRect = computeVisualRectInBacking(object, context);
+ newVisualRect.move(adjustment);
if (object.isText()) {
// Use visual rect location for LayoutTexts because it suffices to check
// whether a visual rect changes for layout caused invalidation.
- context.newLocation = context.newVisualRect.location();
+ context.newLocation = newVisualRect.location();
} else {
context.newLocation = computeLocationInBacking(object, context);
context.newLocation.move(adjustment);
@@ -381,11 +381,11 @@ void PaintInvalidator::updateVisualRect(const LayoutObject& object,
// Location of empty visual rect doesn't affect paint invalidation. Set it
// to newLocation to avoid saving the previous location separately in
// ObjectPaintInvalidator.
- if (context.newVisualRect.isEmpty())
- context.newVisualRect.setLocation(context.newLocation);
+ if (newVisualRect.isEmpty())
+ newVisualRect.setLocation(context.newLocation);
}
- object.getMutableForPainting().setVisualRect(context.newVisualRect);
+ object.getMutableForPainting().setVisualRect(newVisualRect);
objectPaintInvalidator.setLocationInBacking(context.newLocation);
}

Powered by Google App Engine
This is Rietveld 408576698