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

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

Issue 2465983002: Rename "paint invalidation rect" etc. to "visual rect". (Closed)
Patch Set: - Created 4 years, 1 month 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/GridPainter.cpp
diff --git a/third_party/WebKit/Source/core/paint/GridPainter.cpp b/third_party/WebKit/Source/core/paint/GridPainter.cpp
index 066b901e33083de3ba4111804c5872735d21cdf7..ca4cf67545a66b3dd226577f08c446bb672e4845 100644
--- a/third_party/WebKit/Source/core/paint/GridPainter.cpp
+++ b/third_party/WebKit/Source/core/paint/GridPainter.cpp
@@ -48,9 +48,8 @@ void GridPainter::paintChildren(const PaintInfo& paintInfo,
const LayoutPoint& paintOffset) {
ASSERT(!m_layoutGrid.needsLayout());
- LayoutRect localPaintInvalidationRect =
- LayoutRect(paintInfo.cullRect().m_rect);
- localPaintInvalidationRect.moveBy(-paintOffset);
+ LayoutRect localVisualRect = LayoutRect(paintInfo.cullRect().m_rect);
+ localVisualRect.moveBy(-paintOffset);
Vector<LayoutUnit> columnPositions = m_layoutGrid.columnPositions();
if (!m_layoutGrid.styleRef().isLeftToRightDirection()) {
@@ -64,12 +63,10 @@ void GridPainter::paintChildren(const PaintInfo& paintInfo,
std::sort(columnPositions.begin(), columnPositions.end());
}
- GridSpan dirtiedColumns =
- dirtiedGridAreas(columnPositions, localPaintInvalidationRect.x(),
- localPaintInvalidationRect.maxX());
- GridSpan dirtiedRows = dirtiedGridAreas(m_layoutGrid.rowPositions(),
- localPaintInvalidationRect.y(),
- localPaintInvalidationRect.maxY());
+ GridSpan dirtiedColumns = dirtiedGridAreas(
+ columnPositions, localVisualRect.x(), localVisualRect.maxX());
+ GridSpan dirtiedRows = dirtiedGridAreas(
+ m_layoutGrid.rowPositions(), localVisualRect.y(), localVisualRect.maxY());
if (!m_layoutGrid.styleRef().isLeftToRightDirection()) {
// As we changed the order of tracks previously, we need to swap the dirtied
@@ -93,7 +90,7 @@ void GridPainter::paintChildren(const PaintInfo& paintInfo,
}
for (auto* item : m_layoutGrid.itemsOverflowingGridArea()) {
- if (item->frameRect().intersects(localPaintInvalidationRect))
+ if (item->frameRect().intersects(localVisualRect))
gridItemsToBePainted.append(
std::make_pair(item, m_layoutGrid.paintIndexForGridItem(item)));
}

Powered by Google App Engine
This is Rietveld 408576698