Chromium Code Reviews| Index: Source/core/paint/BlockPainter.cpp |
| diff --git a/Source/core/paint/BlockPainter.cpp b/Source/core/paint/BlockPainter.cpp |
| index b92e7b3e5549a8e0a76197024be600725dcff16c..1e599981110b9cbbe25a0b57a19458a7ceeb04b9 100644 |
| --- a/Source/core/paint/BlockPainter.cpp |
| +++ b/Source/core/paint/BlockPainter.cpp |
| @@ -109,8 +109,11 @@ void BlockPainter::paintInlineBox(InlineBox& inlineBox, PaintInfo& paintInfo, co |
| return; |
| LayoutPoint childPoint = paintOffset; |
| - if (inlineBox.parent()->renderer().style()->isFlippedBlocksWritingMode()) // Faster than calling containingBlock(). |
| + const RenderObject& renderer = inlineBox.parent()->renderer(); |
| + if (!UNLIKELY(renderer.document().containsAnyVerticalWritingModes()) |
| + && renderer.style()->slowIsFlippedBlocksWritingMode()) { // Faster than calling containingBlock(). |
|
pdr.
2014/10/21 23:35:34
I think this comment belongs with the parent() cal
|
| childPoint = inlineBox.renderer().containingBlock()->flipForWritingModeForChild(&toRenderBox(inlineBox.renderer()), childPoint); |
| + } |
| paintAsInlineBlock(&inlineBox.renderer(), paintInfo, childPoint); |
| } |
| @@ -331,7 +334,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 +421,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; |