| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 bool isImmutable() const { return isAnimVal(); } | 55 bool isImmutable() const { return isAnimVal(); } |
| 56 | 56 |
| 57 virtual void commitChange(); | 57 virtual void commitChange(); |
| 58 | 58 |
| 59 SVGElement* contextElement() const { return m_contextElement; } | 59 SVGElement* contextElement() const { return m_contextElement; } |
| 60 | 60 |
| 61 const QualifiedName& attributeName() { return m_attributeName; } | 61 const QualifiedName& attributeName() { return m_attributeName; } |
| 62 | 62 |
| 63 void attachToSVGElementAttribute(SVGElement* contextElement, | 63 void attachToSVGElementAttribute(SVGElement* contextElement, |
| 64 const QualifiedName& attributeName) { | 64 const QualifiedName& attributeName) { |
| 65 ASSERT(!isImmutable()); | 65 DCHECK(!isImmutable()); |
| 66 ASSERT(contextElement); | 66 DCHECK(contextElement); |
| 67 ASSERT(attributeName != QualifiedName::null()); | 67 DCHECK(attributeName != QualifiedName::null()); |
| 68 m_contextElement = contextElement; | 68 m_contextElement = contextElement; |
| 69 m_attributeName = attributeName; | 69 m_attributeName = attributeName; |
| 70 } | 70 } |
| 71 | 71 |
| 72 virtual AnimatedPropertyType type() const = 0; | 72 virtual AnimatedPropertyType type() const = 0; |
| 73 | 73 |
| 74 DEFINE_INLINE_VIRTUAL_TRACE() {} | 74 DEFINE_INLINE_VIRTUAL_TRACE() {} |
| 75 | 75 |
| 76 static void throwReadOnly(ExceptionState&); | 76 static void throwReadOnly(ExceptionState&); |
| 77 | 77 |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 115 | 115 |
| 116 protected: | 116 protected: |
| 117 SVGPropertyTearOff(Property* target, | 117 SVGPropertyTearOff(Property* target, |
| 118 SVGElement* contextElement, | 118 SVGElement* contextElement, |
| 119 PropertyIsAnimValType propertyIsAnimVal, | 119 PropertyIsAnimValType propertyIsAnimVal, |
| 120 const QualifiedName& attributeName = QualifiedName::null()) | 120 const QualifiedName& attributeName = QualifiedName::null()) |
| 121 : SVGPropertyTearOffBase(contextElement, | 121 : SVGPropertyTearOffBase(contextElement, |
| 122 propertyIsAnimVal, | 122 propertyIsAnimVal, |
| 123 attributeName), | 123 attributeName), |
| 124 m_target(target) { | 124 m_target(target) { |
| 125 ASSERT(m_target); | 125 DCHECK(m_target); |
| 126 } | 126 } |
| 127 | 127 |
| 128 private: | 128 private: |
| 129 Member<Property> m_target; | 129 Member<Property> m_target; |
| 130 }; | 130 }; |
| 131 | 131 |
| 132 } // namespace blink | 132 } // namespace blink |
| 133 | 133 |
| 134 #endif // SVGPropertyTearOff_h | 134 #endif // SVGPropertyTearOff_h |
| OLD | NEW |