OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2005 Alexander Kellett <lypanov@kde.org> | 2 * Copyright (C) 2005 Alexander Kellett <lypanov@kde.org> |
3 * | 3 * |
4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
8 * | 8 * |
9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 19 matching lines...) Expand all Loading... |
30 #include "core/svg/SVGUnitTypes.h" | 30 #include "core/svg/SVGUnitTypes.h" |
31 | 31 |
32 namespace WebCore { | 32 namespace WebCore { |
33 | 33 |
34 class SVGMaskElement FINAL : public SVGElement, | 34 class SVGMaskElement FINAL : public SVGElement, |
35 public SVGTests, | 35 public SVGTests, |
36 public SVGExternalResourcesRequired { | 36 public SVGExternalResourcesRequired { |
37 public: | 37 public: |
38 static PassRefPtr<SVGMaskElement> create(Document&); | 38 static PassRefPtr<SVGMaskElement> create(Document&); |
39 | 39 |
| 40 SVGAnimatedLength* x() const { return m_x.get(); } |
| 41 SVGAnimatedLength* y() const { return m_y.get(); } |
| 42 SVGAnimatedLength* width() const { return m_width.get(); } |
| 43 SVGAnimatedLength* height() const { return m_height.get(); } |
| 44 |
40 private: | 45 private: |
41 explicit SVGMaskElement(Document&); | 46 explicit SVGMaskElement(Document&); |
42 | 47 |
43 virtual bool isValid() const { return SVGTests::isValid(); } | 48 virtual bool isValid() const { return SVGTests::isValid(); } |
44 virtual bool needsPendingResourceHandling() const { return false; } | 49 virtual bool needsPendingResourceHandling() const { return false; } |
45 | 50 |
46 bool isSupportedAttribute(const QualifiedName&); | 51 bool isSupportedAttribute(const QualifiedName&); |
47 virtual void parseAttribute(const QualifiedName&, const AtomicString&) OVERR
IDE; | 52 virtual void parseAttribute(const QualifiedName&, const AtomicString&) OVERR
IDE; |
48 virtual void svgAttributeChanged(const QualifiedName&); | 53 virtual void svgAttributeChanged(const QualifiedName&); |
49 virtual void childrenChanged(bool changedByParser = false, Node* beforeChang
e = 0, Node* afterChange = 0, int childCountDelta = 0); | 54 virtual void childrenChanged(bool changedByParser = false, Node* beforeChang
e = 0, Node* afterChange = 0, int childCountDelta = 0); |
50 | 55 |
51 virtual RenderObject* createRenderer(RenderStyle*); | 56 virtual RenderObject* createRenderer(RenderStyle*); |
52 | 57 |
53 virtual bool selfHasRelativeLengths() const; | 58 virtual bool selfHasRelativeLengths() const; |
54 | 59 |
| 60 RefPtr<SVGAnimatedLength> m_x; |
| 61 RefPtr<SVGAnimatedLength> m_y; |
| 62 RefPtr<SVGAnimatedLength> m_width; |
| 63 RefPtr<SVGAnimatedLength> m_height; |
55 BEGIN_DECLARE_ANIMATED_PROPERTIES(SVGMaskElement) | 64 BEGIN_DECLARE_ANIMATED_PROPERTIES(SVGMaskElement) |
56 DECLARE_ANIMATED_ENUMERATION(MaskUnits, maskUnits, SVGUnitTypes::SVGUnit
Type) | 65 DECLARE_ANIMATED_ENUMERATION(MaskUnits, maskUnits, SVGUnitTypes::SVGUnit
Type) |
57 DECLARE_ANIMATED_ENUMERATION(MaskContentUnits, maskContentUnits, SVGUnit
Types::SVGUnitType) | 66 DECLARE_ANIMATED_ENUMERATION(MaskContentUnits, maskContentUnits, SVGUnit
Types::SVGUnitType) |
58 DECLARE_ANIMATED_LENGTH(X, x) | |
59 DECLARE_ANIMATED_LENGTH(Y, y) | |
60 DECLARE_ANIMATED_LENGTH(Width, width) | |
61 DECLARE_ANIMATED_LENGTH(Height, height) | |
62 DECLARE_ANIMATED_BOOLEAN(ExternalResourcesRequired, externalResourcesReq
uired) | 67 DECLARE_ANIMATED_BOOLEAN(ExternalResourcesRequired, externalResourcesReq
uired) |
63 END_DECLARE_ANIMATED_PROPERTIES | 68 END_DECLARE_ANIMATED_PROPERTIES |
64 | 69 |
65 // SVGTests | 70 // SVGTests |
66 virtual void synchronizeRequiredFeatures() { SVGTests::synchronizeRequiredFe
atures(this); } | 71 virtual void synchronizeRequiredFeatures() { SVGTests::synchronizeRequiredFe
atures(this); } |
67 virtual void synchronizeRequiredExtensions() { SVGTests::synchronizeRequired
Extensions(this); } | 72 virtual void synchronizeRequiredExtensions() { SVGTests::synchronizeRequired
Extensions(this); } |
68 virtual void synchronizeSystemLanguage() { SVGTests::synchronizeSystemLangua
ge(this); } | 73 virtual void synchronizeSystemLanguage() { SVGTests::synchronizeSystemLangua
ge(this); } |
69 }; | 74 }; |
70 | 75 |
71 DEFINE_NODE_TYPE_CASTS(SVGMaskElement, hasTagName(SVGNames::maskTag)); | 76 DEFINE_NODE_TYPE_CASTS(SVGMaskElement, hasTagName(SVGNames::maskTag)); |
72 | 77 |
73 } | 78 } |
74 | 79 |
75 #endif | 80 #endif |
OLD | NEW |