| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2005, 2006, 2008 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005, 2006, 2008 Nikolas Zimmermann <zimmermann@kde.org> |
| 3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> |
| 4 * Copyright (C) 2009, 2014 Apple Inc. All rights reserved. | 4 * Copyright (C) 2009, 2014 Apple Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 virtual short tabIndex() const override; | 59 virtual short tabIndex() const override; |
| 60 virtual bool supportsFocus() const override { return false; } | 60 virtual bool supportsFocus() const override { return false; } |
| 61 | 61 |
| 62 bool isOutermostSVGSVGElement() const; | 62 bool isOutermostSVGSVGElement() const; |
| 63 | 63 |
| 64 bool hasTagName(const SVGQualifiedName& name) const { return hasLocalName(na
me.localName()); } | 64 bool hasTagName(const SVGQualifiedName& name) const { return hasLocalName(na
me.localName()); } |
| 65 | 65 |
| 66 virtual String title() const override; | 66 virtual String title() const override; |
| 67 bool hasRelativeLengths() const { return !m_elementsWithRelativeLengths.isEm
pty(); } | 67 bool hasRelativeLengths() const { return !m_elementsWithRelativeLengths.isEm
pty(); } |
| 68 static bool isAnimatableCSSProperty(const QualifiedName&); | 68 static bool isAnimatableCSSProperty(const QualifiedName&); |
| 69 |
| 69 enum CTMScope { | 70 enum CTMScope { |
| 70 NearestViewportScope, // Used by SVGGraphicsElement::getCTM() | 71 NearestViewportScope, // Used by SVGGraphicsElement::getCTM() |
| 71 ScreenScope, // Used by SVGGraphicsElement::getScreenCTM() | 72 ScreenScope, // Used by SVGGraphicsElement::getScreenCTM() |
| 72 AncestorScope // Used by SVGSVGElement::get{Enclosure|Intersection}List(
) | 73 AncestorScope // Used by SVGSVGElement::get{Enclosure|Intersection}List(
) |
| 73 }; | 74 }; |
| 74 virtual AffineTransform localCoordinateSpaceTransform(CTMScope) const; | 75 virtual AffineTransform localCoordinateSpaceTransform(CTMScope) const; |
| 75 virtual bool needsPendingResourceHandling() const { return true; } | 76 virtual bool needsPendingResourceHandling() const { return true; } |
| 76 | 77 |
| 77 bool instanceUpdatesBlocked() const; | 78 bool instanceUpdatesBlocked() const; |
| 78 void setInstanceUpdatesBlocked(bool); | 79 void setInstanceUpdatesBlocked(bool); |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 181 private: | 182 private: |
| 182 RawPtrWillBeMember<SVGElement> m_targetElement; | 183 RawPtrWillBeMember<SVGElement> m_targetElement; |
| 183 }; | 184 }; |
| 184 | 185 |
| 185 void invalidateInstances(); | 186 void invalidateInstances(); |
| 186 | 187 |
| 187 virtual void trace(Visitor*) override; | 188 virtual void trace(Visitor*) override; |
| 188 | 189 |
| 189 static const AtomicString& eventParameterName(); | 190 static const AtomicString& eventParameterName(); |
| 190 | 191 |
| 192 virtual bool isPresentationAttribute(const QualifiedName&) const override; |
| 193 |
| 191 protected: | 194 protected: |
| 192 SVGElement(const QualifiedName&, Document&, ConstructionType = CreateSVGElem
ent); | 195 SVGElement(const QualifiedName&, Document&, ConstructionType = CreateSVGElem
ent); |
| 193 | 196 |
| 194 virtual void parseAttribute(const QualifiedName&, const AtomicString&) overr
ide; | 197 virtual void parseAttribute(const QualifiedName&, const AtomicString&) overr
ide; |
| 195 | 198 |
| 196 // FIXME: |parseAttributeNew| is a new implementation of parseAttribute | 199 // FIXME: |parseAttributeNew| is a new implementation of parseAttribute |
| 197 // which maps attribute using |m_attributeToPropertyMap|. | 200 // which maps attribute using |m_attributeToPropertyMap|. |
| 198 // This is to replace |parseAttribute()| after all derived class switch to c
all this. | 201 // This is to replace |parseAttribute()| after all derived class switch to c
all this. |
| 199 void parseAttributeNew(const QualifiedName&, const AtomicString&); | 202 void parseAttributeNew(const QualifiedName&, const AtomicString&); |
| 200 | 203 |
| 201 virtual void attributeChanged(const QualifiedName&, const AtomicString&, Att
ributeModificationReason = ModifiedDirectly) override; | 204 virtual void attributeChanged(const QualifiedName&, const AtomicString&, Att
ributeModificationReason = ModifiedDirectly) override; |
| 202 | 205 |
| 203 virtual bool isPresentationAttribute(const QualifiedName&) const override; | |
| 204 virtual void collectStyleForPresentationAttribute(const QualifiedName&, cons
t AtomicString&, MutableStylePropertySet*) override; | 206 virtual void collectStyleForPresentationAttribute(const QualifiedName&, cons
t AtomicString&, MutableStylePropertySet*) override; |
| 205 | 207 |
| 206 virtual InsertionNotificationRequest insertedInto(ContainerNode*) override; | 208 virtual InsertionNotificationRequest insertedInto(ContainerNode*) override; |
| 207 virtual void removedFrom(ContainerNode*) override; | 209 virtual void removedFrom(ContainerNode*) override; |
| 208 virtual void childrenChanged(const ChildrenChange&) override; | 210 virtual void childrenChanged(const ChildrenChange&) override; |
| 209 | 211 |
| 210 static CSSPropertyID cssPropertyIdForSVGAttributeName(const QualifiedName&); | 212 static CSSPropertyID cssPropertyIdForSVGAttributeName(const QualifiedName&); |
| 211 void updateRelativeLengthsInformation() { updateRelativeLengthsInformation(s
elfHasRelativeLengths(), this); } | 213 void updateRelativeLengthsInformation() { updateRelativeLengthsInformation(s
elfHasRelativeLengths(), this); } |
| 212 void updateRelativeLengthsInformation(bool hasRelativeLengths, SVGElement*); | 214 void updateRelativeLengthsInformation(bool hasRelativeLengths, SVGElement*); |
| 213 static void markForLayoutAndParentResourceInvalidation(RenderObject*); | 215 static void markForLayoutAndParentResourceInvalidation(RenderObject*); |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 282 template<typename T> inline bool is##thisType(const PassRefPtrWillBeRawPtr<T
>& node) { return is##thisType(node.get()); } \ | 284 template<typename T> inline bool is##thisType(const PassRefPtrWillBeRawPtr<T
>& node) { return is##thisType(node.get()); } \ |
| 283 template<typename T> inline bool is##thisType(const RefPtrWillBeMember<T>& n
ode) { return is##thisType(node.get()); } \ | 285 template<typename T> inline bool is##thisType(const RefPtrWillBeMember<T>& n
ode) { return is##thisType(node.get()); } \ |
| 284 template <> inline bool isElementOfType<const thisType>(const SVGElement& el
ement) { return is##thisType(element); } \ | 286 template <> inline bool isElementOfType<const thisType>(const SVGElement& el
ement) { return is##thisType(element); } \ |
| 285 DEFINE_ELEMENT_TYPE_CASTS_WITH_FUNCTION(thisType) | 287 DEFINE_ELEMENT_TYPE_CASTS_WITH_FUNCTION(thisType) |
| 286 | 288 |
| 287 } // namespace blink | 289 } // namespace blink |
| 288 | 290 |
| 289 #include "core/SVGElementTypeHelpers.h" | 291 #include "core/SVGElementTypeHelpers.h" |
| 290 | 292 |
| 291 #endif // SVGElement_h | 293 #endif // SVGElement_h |
| OLD | NEW |