Index: third_party/WebKit/Source/core/paint/InlineFlowBoxPainter.cpp |
diff --git a/third_party/WebKit/Source/core/paint/InlineFlowBoxPainter.cpp b/third_party/WebKit/Source/core/paint/InlineFlowBoxPainter.cpp |
index 00edfb18a7d4be6292ea6eb12d8907b067a4b5e3..89093b2ff0dab50909aad0a8ebd1ce8242a717f1 100644 |
--- a/third_party/WebKit/Source/core/paint/InlineFlowBoxPainter.cpp |
+++ b/third_party/WebKit/Source/core/paint/InlineFlowBoxPainter.cpp |
@@ -7,11 +7,11 @@ |
#include "core/layout/LayoutBlock.h" |
#include "core/layout/LayoutInline.h" |
#include "core/layout/LayoutView.h" |
+#include "core/layout/api/LineLayoutAPIShim.h" |
#include "core/layout/api/LineLayoutBoxModel.h" |
#include "core/layout/api/SelectionState.h" |
#include "core/layout/line/InlineFlowBox.h" |
#include "core/paint/BoxPainter.h" |
-#include "core/paint/LineLayoutPaintShim.h" |
#include "core/paint/PaintInfo.h" |
#include "core/paint/PaintLayer.h" |
#include "platform/graphics/GraphicsContextStateSaver.h" |
@@ -62,7 +62,7 @@ void InlineFlowBoxPainter::paintFillLayers(const PaintInfo& paintInfo, const Col |
void InlineFlowBoxPainter::paintFillLayer(const PaintInfo& paintInfo, const Color& c, const FillLayer& fillLayer, const LayoutRect& rect, SkXfermode::Mode op) |
{ |
- LayoutBoxModelObject* boxModel = toLayoutBoxModelObject(LineLayoutPaintShim::layoutObjectFrom(m_inlineFlowBox.boxModelObject())); |
+ LayoutBoxModelObject* boxModel = toLayoutBoxModelObject(LineLayoutAPIShim::layoutObjectFrom(m_inlineFlowBox.boxModelObject())); |
StyleImage* img = fillLayer.image(); |
bool hasFillImage = img && img->canRender(); |
if ((!hasFillImage && !m_inlineFlowBox.lineLayoutItem().style()->hasBorderRadius()) || (!m_inlineFlowBox.prevLineBox() && !m_inlineFlowBox.nextLineBox()) || !m_inlineFlowBox.parent()) { |
@@ -182,7 +182,7 @@ void InlineFlowBoxPainter::paintBoxDecorationBackground(const PaintInfo& paintIn |
// You can use p::first-line to specify a background. If so, the root line boxes for |
// a line may actually have to paint a background. |
- LayoutObject* inlineFlowBoxLayoutObject = LineLayoutPaintShim::layoutObjectFrom(m_inlineFlowBox.lineLayoutItem()); |
+ LayoutObject* inlineFlowBoxLayoutObject = LineLayoutAPIShim::layoutObjectFrom(m_inlineFlowBox.lineLayoutItem()); |
const ComputedStyle* styleToUse = m_inlineFlowBox.lineLayoutItem().style(m_inlineFlowBox.isFirstLineStyle()); |
bool shouldPaintBoxDecorationBackground; |
if (m_inlineFlowBox.parent()) |
@@ -222,7 +222,7 @@ void InlineFlowBoxPainter::paintBoxDecorationBackground(const PaintInfo& paintIn |
case DontPaintBorders: |
break; |
case PaintBordersWithoutClip: |
- BoxPainter::paintBorder(*toLayoutBoxModelObject(LineLayoutPaintShim::layoutObjectFrom(m_inlineFlowBox.boxModelObject())), paintInfo, adjustedFrameRect, m_inlineFlowBox.lineLayoutItem().styleRef(m_inlineFlowBox.isFirstLineStyle()), BackgroundBleedNone, m_inlineFlowBox.includeLogicalLeftEdge(), m_inlineFlowBox.includeLogicalRightEdge()); |
+ BoxPainter::paintBorder(*toLayoutBoxModelObject(LineLayoutAPIShim::layoutObjectFrom(m_inlineFlowBox.boxModelObject())), paintInfo, adjustedFrameRect, m_inlineFlowBox.lineLayoutItem().styleRef(m_inlineFlowBox.isFirstLineStyle()), BackgroundBleedNone, m_inlineFlowBox.includeLogicalLeftEdge(), m_inlineFlowBox.includeLogicalRightEdge()); |
break; |
case PaintBordersWithClip: |
// FIXME: What the heck do we do with RTL here? The math we're using is obviously not right, |
@@ -230,7 +230,7 @@ void InlineFlowBoxPainter::paintBoxDecorationBackground(const PaintInfo& paintIn |
LayoutRect imageStripPaintRect = paintRectForImageStrip(adjustedPaintOffset, frameRect.size(), LTR); |
GraphicsContextStateSaver stateSaver(paintInfo.context); |
paintInfo.context.clip(adjustedClipRect); |
- BoxPainter::paintBorder(*toLayoutBoxModelObject(LineLayoutPaintShim::layoutObjectFrom(m_inlineFlowBox.boxModelObject())), paintInfo, imageStripPaintRect, m_inlineFlowBox.lineLayoutItem().styleRef(m_inlineFlowBox.isFirstLineStyle())); |
+ BoxPainter::paintBorder(*toLayoutBoxModelObject(LineLayoutAPIShim::layoutObjectFrom(m_inlineFlowBox.boxModelObject())), paintInfo, imageStripPaintRect, m_inlineFlowBox.lineLayoutItem().styleRef(m_inlineFlowBox.isFirstLineStyle())); |
break; |
} |
} |
@@ -279,7 +279,7 @@ void InlineFlowBoxPainter::paintMask(const PaintInfo& paintInfo, const LayoutPoi |
return; // Don't paint anything while we wait for the image to load. |
} |
- LayoutBoxModelObject* boxModel = toLayoutBoxModelObject(LineLayoutPaintShim::layoutObjectFrom(m_inlineFlowBox.boxModelObject())); |
+ LayoutBoxModelObject* boxModel = toLayoutBoxModelObject(LineLayoutAPIShim::layoutObjectFrom(m_inlineFlowBox.boxModelObject())); |
// The simple case is where we are the only box for this object. In those |
// cases only a single call to draw is required. |
if (!m_inlineFlowBox.prevLineBox() && !m_inlineFlowBox.nextLineBox()) { |