Index: Source/core/rendering/shapes/ShapeInsideInfo.cpp |
diff --git a/Source/core/rendering/shapes/ShapeInsideInfo.cpp b/Source/core/rendering/shapes/ShapeInsideInfo.cpp |
index f912831f7f224878e5c5c969a600f00feed186cf..3da79e5c4df477d0fcde65160fb0adff04ac953d 100644 |
--- a/Source/core/rendering/shapes/ShapeInsideInfo.cpp |
+++ b/Source/core/rendering/shapes/ShapeInsideInfo.cpp |
@@ -41,9 +41,9 @@ LineSegmentRange::LineSegmentRange(const InlineIterator& start, const InlineIter |
{ |
} |
-bool ShapeInsideInfo::isEnabledFor(const RenderBlock* renderer) |
+bool ShapeInsideInfo::isEnabledFor(const RenderBlock& renderer) |
{ |
- ShapeValue* shapeValue = renderer->style()->resolvedShapeInside(); |
+ ShapeValue* shapeValue = renderer.style()->resolvedShapeInside(); |
if (!shapeValue) |
return false; |
@@ -51,7 +51,7 @@ bool ShapeInsideInfo::isEnabledFor(const RenderBlock* renderer) |
case ShapeValue::Shape: |
return shapeValue->shape() && shapeValue->shape()->type() != BasicShape::BasicShapeInsetRectangleType && shapeValue->shape()->type() != BasicShape::BasicShapeInsetType; |
case ShapeValue::Image: |
- return shapeValue->isImageValid() && checkShapeImageOrigin(renderer->document(), *(shapeValue->image()->cachedImage())); |
+ return shapeValue->isImageValid() && checkShapeImageOrigin(renderer.document(), *(shapeValue->image()->cachedImage())); |
case ShapeValue::Box: |
return true; |
case ShapeValue::Outside: |
@@ -87,12 +87,12 @@ bool ShapeInsideInfo::updateSegmentsForLine(LayoutUnit lineTop, LayoutUnit lineH |
bool ShapeInsideInfo::adjustLogicalLineTop(float minSegmentWidth) |
{ |
- const Shape* shape = computedShape(); |
- if (!shape || m_lineHeight <= 0 || logicalLineTop() > shapeLogicalBottom()) |
+ const Shape& shape = computedShape(); |
+ if (m_lineHeight <= 0 || logicalLineTop() > shapeLogicalBottom()) |
return false; |
LayoutUnit newLineTop; |
- if (shape->firstIncludedIntervalLogicalTop(m_referenceBoxLineTop, FloatSize(minSegmentWidth, m_lineHeight), newLineTop)) { |
+ if (shape.firstIncludedIntervalLogicalTop(m_referenceBoxLineTop, FloatSize(minSegmentWidth, m_lineHeight), newLineTop)) { |
if (newLineTop > m_referenceBoxLineTop) { |
m_referenceBoxLineTop = newLineTop; |
return true; |
@@ -104,16 +104,16 @@ bool ShapeInsideInfo::adjustLogicalLineTop(float minSegmentWidth) |
ShapeValue* ShapeInsideInfo::shapeValue() const |
{ |
- return m_renderer->style()->resolvedShapeInside(); |
+ return m_renderer.style()->resolvedShapeInside(); |
} |
LayoutUnit ShapeInsideInfo::computeFirstFitPositionForFloat(const FloatSize& floatSize) const |
{ |
- if (!computedShape() || !floatSize.width() || shapeLogicalBottom() < logicalLineTop()) |
+ if (!floatSize.width() || shapeLogicalBottom() < logicalLineTop()) |
return 0; |
LayoutUnit firstFitPosition = 0; |
- if (computedShape()->firstIncludedIntervalLogicalTop(m_referenceBoxLineTop, floatSize, firstFitPosition) && (m_referenceBoxLineTop <= firstFitPosition)) |
+ if (computedShape().firstIncludedIntervalLogicalTop(m_referenceBoxLineTop, floatSize, firstFitPosition) && (m_referenceBoxLineTop <= firstFitPosition)) |
return firstFitPosition; |
return 0; |