summaryrefslogtreecommitdiff
path: root/Source/WebCore/svg/PatternAttributes.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/svg/PatternAttributes.h')
-rw-r--r--Source/WebCore/svg/PatternAttributes.h43
1 files changed, 19 insertions, 24 deletions
diff --git a/Source/WebCore/svg/PatternAttributes.h b/Source/WebCore/svg/PatternAttributes.h
index 3677b74fa..5bed0bef5 100644
--- a/Source/WebCore/svg/PatternAttributes.h
+++ b/Source/WebCore/svg/PatternAttributes.h
@@ -17,12 +17,10 @@
* Boston, MA 02110-1301, USA.
*/
-#ifndef PatternAttributes_h
-#define PatternAttributes_h
+#pragma once
-#if ENABLE(SVG)
-#include "SVGLength.h"
-#include "SVGPreserveAspectRatio.h"
+#include "SVGLengthValue.h"
+#include "SVGPreserveAspectRatioValue.h"
namespace WebCore {
@@ -38,7 +36,7 @@ struct PatternAttributes {
, m_preserveAspectRatio()
, m_patternUnits(SVGUnitTypes::SVG_UNIT_TYPE_OBJECTBOUNDINGBOX)
, m_patternContentUnits(SVGUnitTypes::SVG_UNIT_TYPE_USERSPACEONUSE)
- , m_patternContentElement(0)
+ , m_patternContentElement(nullptr)
, m_xSet(false)
, m_ySet(false)
, m_widthSet(false)
@@ -52,36 +50,36 @@ struct PatternAttributes {
{
}
- SVGLength x() const { return m_x; }
- SVGLength y() const { return m_y; }
- SVGLength width() const { return m_width; }
- SVGLength height() const { return m_height; }
+ SVGLengthValue x() const { return m_x; }
+ SVGLengthValue y() const { return m_y; }
+ SVGLengthValue width() const { return m_width; }
+ SVGLengthValue height() const { return m_height; }
FloatRect viewBox() const { return m_viewBox; }
- SVGPreserveAspectRatio preserveAspectRatio() const { return m_preserveAspectRatio; }
+ SVGPreserveAspectRatioValue preserveAspectRatio() const { return m_preserveAspectRatio; }
SVGUnitTypes::SVGUnitType patternUnits() const { return m_patternUnits; }
SVGUnitTypes::SVGUnitType patternContentUnits() const { return m_patternContentUnits; }
AffineTransform patternTransform() const { return m_patternTransform; }
const SVGPatternElement* patternContentElement() const { return m_patternContentElement; }
- void setX(const SVGLength& value)
+ void setX(SVGLengthValue value)
{
m_x = value;
m_xSet = true;
}
- void setY(const SVGLength& value)
+ void setY(SVGLengthValue value)
{
m_y = value;
m_ySet = true;
}
- void setWidth(const SVGLength& value)
+ void setWidth(SVGLengthValue value)
{
m_width = value;
m_widthSet = true;
}
- void setHeight(const SVGLength& value)
+ void setHeight(SVGLengthValue value)
{
m_height = value;
m_heightSet = true;
@@ -93,7 +91,7 @@ struct PatternAttributes {
m_viewBoxSet = true;
}
- void setPreserveAspectRatio(const SVGPreserveAspectRatio& value)
+ void setPreserveAspectRatio(SVGPreserveAspectRatioValue value)
{
m_preserveAspectRatio = value;
m_preserveAspectRatioSet = true;
@@ -136,12 +134,12 @@ struct PatternAttributes {
private:
// Properties
- SVGLength m_x;
- SVGLength m_y;
- SVGLength m_width;
- SVGLength m_height;
+ SVGLengthValue m_x;
+ SVGLengthValue m_y;
+ SVGLengthValue m_width;
+ SVGLengthValue m_height;
FloatRect m_viewBox;
- SVGPreserveAspectRatio m_preserveAspectRatio;
+ SVGPreserveAspectRatioValue m_preserveAspectRatio;
SVGUnitTypes::SVGUnitType m_patternUnits;
SVGUnitTypes::SVGUnitType m_patternContentUnits;
AffineTransform m_patternTransform;
@@ -161,6 +159,3 @@ private:
};
} // namespace WebCore
-
-#endif // ENABLE(SVG)
-#endif