| Index: Source/core/rendering/svg/RenderSVGShape.cpp
|
| diff --git a/Source/core/rendering/svg/RenderSVGShape.cpp b/Source/core/rendering/svg/RenderSVGShape.cpp
|
| index b91234f97685edfefe0b2f677162f855bf9f1216..63e60fc2066925c0a907de4ac2953aee1de9fc8d 100644
|
| --- a/Source/core/rendering/svg/RenderSVGShape.cpp
|
| +++ b/Source/core/rendering/svg/RenderSVGShape.cpp
|
| @@ -248,26 +248,6 @@ void RenderSVGShape::strokeShape(RenderStyle* style, GraphicsContext* context)
|
| }
|
| }
|
|
|
| -void RenderSVGShape::fillAndStrokeShape(GraphicsContext* context)
|
| -{
|
| - RenderStyle* style = this->style();
|
| -
|
| - fillShape(style, context);
|
| -
|
| - if (!style->svgStyle()->hasVisibleStroke())
|
| - return;
|
| -
|
| - GraphicsContextStateSaver stateSaver(*context, false);
|
| -
|
| - if (hasNonScalingStroke()) {
|
| - AffineTransform nonScalingTransform = nonScalingStrokeTransform();
|
| - if (!setupNonScalingStrokeContext(nonScalingTransform, stateSaver))
|
| - return;
|
| - }
|
| -
|
| - strokeShape(style, context);
|
| -}
|
| -
|
| void RenderSVGShape::paint(PaintInfo& paintInfo, const LayoutPoint&)
|
| {
|
| if (paintInfo.context->paintingDisabled() || style()->visibility() == HIDDEN || isEmpty())
|
| @@ -290,9 +270,34 @@ void RenderSVGShape::paint(PaintInfo& paintInfo, const LayoutPoint&)
|
| if (svgStyle->shapeRendering() == SR_CRISPEDGES)
|
| childPaintInfo.context->setShouldAntialias(false);
|
|
|
| - fillAndStrokeShape(childPaintInfo.context);
|
| - if (!m_markerPositions.isEmpty())
|
| - drawMarkers(childPaintInfo);
|
| + for (int i = 0; i < 3; i++) {
|
| + switch(svgStyle->paintOrder(i)) {
|
| + case PO_FILL:
|
| + fillShape(this->style(), childPaintInfo.context);
|
| + break;
|
| + case PO_STROKE:
|
| + if (svgStyle->hasVisibleStroke()) {
|
| + GraphicsContextStateSaver stateSaver(*childPaintInfo.context, false);
|
| + AffineTransform nonScalingTransform;
|
| +
|
| + if (hasNonScalingStroke()) {
|
| + AffineTransform nonScalingTransform = nonScalingStrokeTransform();
|
| + if (!setupNonScalingStrokeContext(nonScalingTransform, stateSaver))
|
| + return;
|
| + }
|
| +
|
| + strokeShape(this->style(), childPaintInfo.context);
|
| + }
|
| + break;
|
| + case PO_MARKERS:
|
| + if (!m_markerPositions.isEmpty())
|
| + drawMarkers(childPaintInfo);
|
| + break;
|
| + default:
|
| + ASSERT_NOT_REACHED();
|
| + break;
|
| + }
|
| + }
|
| }
|
| }
|
|
|
|
|