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

Unified Diff: Source/core/paint/BlockPainter.cpp

Issue 669803002: Optimize for horizontal writing mode (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: w compile fix Created 6 years, 2 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: Source/core/paint/BlockPainter.cpp
diff --git a/Source/core/paint/BlockPainter.cpp b/Source/core/paint/BlockPainter.cpp
index b92e7b3e5549a8e0a76197024be600725dcff16c..37d7621cc2ba2769af93ac3532def08777bfe07e 100644
--- a/Source/core/paint/BlockPainter.cpp
+++ b/Source/core/paint/BlockPainter.cpp
@@ -109,7 +109,7 @@ void BlockPainter::paintInlineBox(InlineBox& inlineBox, PaintInfo& paintInfo, co
return;
LayoutPoint childPoint = paintOffset;
- if (inlineBox.parent()->renderer().style()->isFlippedBlocksWritingMode()) // Faster than calling containingBlock().
+ if (inlineBox.parent()->renderer().style()->slowIsFlippedBlocksWritingMode()) // Faster than calling containingBlock().
childPoint = inlineBox.renderer().containingBlock()->flipForWritingModeForChild(&toRenderBox(inlineBox.renderer()), childPoint);
paintAsInlineBlock(&inlineBox.renderer(), paintInfo, childPoint);
@@ -331,7 +331,7 @@ void BlockPainter::paintColumnRules(PaintInfo& paintInfo, const LayoutPoint& pai
ruleLogicalLeft = currLogicalLeftOffset;
}
} else {
- bool topToBottom = !m_renderBlock.style()->isFlippedBlocksWritingMode();
+ bool topToBottom = !m_renderBlock.style()->slowIsFlippedBlocksWritingMode();
LayoutUnit ruleLeft = m_renderBlock.isHorizontalWritingMode()
? m_renderBlock.borderLeft() + m_renderBlock.paddingLeft()
: colGap / 2 - colGap - ruleThickness / 2 + m_renderBlock.borderBefore() + m_renderBlock.paddingBefore();
@@ -418,7 +418,7 @@ void BlockPainter::paintColumnContents(PaintInfo& paintInfo, const LayoutPoint&
}
LayoutUnit blockDelta = (m_renderBlock.isHorizontalWritingMode() ? colRect.height() : colRect.width());
- if (m_renderBlock.style()->isFlippedBlocksWritingMode())
+ if (m_renderBlock.style()->slowIsFlippedBlocksWritingMode())
currLogicalTopOffset += blockDelta;
else
currLogicalTopOffset -= blockDelta;

Powered by Google App Engine
This is Rietveld 408576698