Index: Source/core/svg/SVGPathBuilder.cpp |
diff --git a/Source/core/svg/SVGPathBuilder.cpp b/Source/core/svg/SVGPathBuilder.cpp |
index f75bf5145e8cb201f251ac8980b4f2d58b294092..962cd989a33c6a5a37efb96bf0e23e975c01f832 100644 |
--- a/Source/core/svg/SVGPathBuilder.cpp |
+++ b/Source/core/svg/SVGPathBuilder.cpp |
@@ -28,43 +28,34 @@ |
namespace blink { |
-SVGPathBuilder::SVGPathBuilder() |
- : m_path(0) |
-{ |
-} |
- |
void SVGPathBuilder::moveTo(const FloatPoint& targetPoint, bool closed, PathCoordinateMode mode) |
{ |
- ASSERT(m_path); |
m_current = mode == AbsoluteCoordinates ? targetPoint : m_current + targetPoint; |
- if (closed && !m_path->isEmpty()) |
- m_path->closeSubpath(); |
- m_path->moveTo(m_current); |
+ if (closed && !m_path.isEmpty()) |
+ m_path.closeSubpath(); |
+ m_path.moveTo(m_current); |
} |
void SVGPathBuilder::lineTo(const FloatPoint& targetPoint, PathCoordinateMode mode) |
{ |
- ASSERT(m_path); |
m_current = mode == AbsoluteCoordinates ? targetPoint : m_current + targetPoint; |
- m_path->addLineTo(m_current); |
+ m_path.addLineTo(m_current); |
} |
void SVGPathBuilder::curveToCubic(const FloatPoint& point1, const FloatPoint& point2, const FloatPoint& targetPoint, PathCoordinateMode mode) |
{ |
- ASSERT(m_path); |
if (mode == RelativeCoordinates) { |
- m_path->addBezierCurveTo(m_current + point1, m_current + point2, m_current + targetPoint); |
+ m_path.addBezierCurveTo(m_current + point1, m_current + point2, m_current + targetPoint); |
m_current += targetPoint; |
} else { |
m_current = targetPoint; |
- m_path->addBezierCurveTo(point1, point2, m_current); |
+ m_path.addBezierCurveTo(point1, point2, m_current); |
} |
} |
void SVGPathBuilder::closePath() |
{ |
- ASSERT(m_path); |
- m_path->closeSubpath(); |
+ m_path.closeSubpath(); |
} |
} |