| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2005, 2008 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005, 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 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 13 * Library General Public License for more details. | 13 * Library General Public License for more details. |
| 14 * | 14 * |
| 15 * You should have received a copy of the GNU Library General Public License | 15 * You should have received a copy of the GNU Library General Public License |
| 16 * along with this library; see the file COPYING.LIB. If not, write to | 16 * along with this library; see the file COPYING.LIB. If not, write to |
| 17 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 17 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 18 * Boston, MA 02110-1301, USA. | 18 * Boston, MA 02110-1301, USA. |
| 19 */ | 19 */ |
| 20 | 20 |
| 21 #ifndef SVGComponentTransferFunctionElement_h | 21 #ifndef SVGComponentTransferFunctionElement_h |
| 22 #define SVGComponentTransferFunctionElement_h | 22 #define SVGComponentTransferFunctionElement_h |
| 23 | 23 |
| 24 #include "core/svg/SVGAnimatedEnumeration.h" | 24 #include "core/svg/SVGAnimatedEnumeration.h" |
| 25 #include "core/svg/SVGAnimatedNumber.h" | 25 #include "core/svg/SVGAnimatedNumber.h" |
| 26 #include "core/svg/SVGAnimatedNumberList.h" | 26 #include "core/svg/SVGAnimatedNumberList.h" |
| 27 #include "core/svg/SVGElement.h" | 27 #include "core/svg/SVGElement.h" |
| 28 #include "platform/graphics/filters/FEComponentTransfer.h" | 28 #include "platform/graphics/filters/FEComponentTransfer.h" |
| 29 #include "platform/heap/Handle.h" |
| 29 | 30 |
| 30 namespace blink { | 31 namespace blink { |
| 31 | 32 |
| 32 template<> const SVGEnumerationStringEntries& getStaticStringEntries<ComponentTr
ansferType>(); | 33 template<> const SVGEnumerationStringEntries& getStaticStringEntries<ComponentTr
ansferType>(); |
| 33 | 34 |
| 34 class SVGComponentTransferFunctionElement : public SVGElement { | 35 class SVGComponentTransferFunctionElement : public SVGElement { |
| 35 DEFINE_WRAPPERTYPEINFO(); | 36 DEFINE_WRAPPERTYPEINFO(); |
| 36 public: | 37 public: |
| 37 ComponentTransferFunction transferFunction() const; | 38 ComponentTransferFunction transferFunction() const; |
| 38 | 39 |
| 39 SVGAnimatedNumberList* tableValues() { return m_tableValues.get(); } | 40 SVGAnimatedNumberList* tableValues() { return m_tableValues.get(); } |
| 40 SVGAnimatedNumber* slope() { return m_slope.get(); } | 41 SVGAnimatedNumber* slope() { return m_slope.get(); } |
| 41 SVGAnimatedNumber* intercept() { return m_intercept.get(); } | 42 SVGAnimatedNumber* intercept() { return m_intercept.get(); } |
| 42 SVGAnimatedNumber* amplitude() { return m_amplitude.get(); } | 43 SVGAnimatedNumber* amplitude() { return m_amplitude.get(); } |
| 43 SVGAnimatedNumber* exponent() { return m_exponent.get(); } | 44 SVGAnimatedNumber* exponent() { return m_exponent.get(); } |
| 44 SVGAnimatedNumber* offset() { return m_offset.get(); } | 45 SVGAnimatedNumber* offset() { return m_offset.get(); } |
| 45 SVGAnimatedEnumeration<ComponentTransferType>* type() { return m_type.get();
} | 46 SVGAnimatedEnumeration<ComponentTransferType>* type() { return m_type.get();
} |
| 46 | 47 |
| 48 virtual void trace(Visitor*) override; |
| 49 |
| 47 protected: | 50 protected: |
| 48 SVGComponentTransferFunctionElement(const QualifiedName&, Document&); | 51 SVGComponentTransferFunctionElement(const QualifiedName&, Document&); |
| 49 | 52 |
| 50 bool isSupportedAttribute(const QualifiedName&); | 53 bool isSupportedAttribute(const QualifiedName&); |
| 51 virtual void parseAttribute(const QualifiedName&, const AtomicString&) overr
ide final; | 54 virtual void parseAttribute(const QualifiedName&, const AtomicString&) overr
ide final; |
| 52 virtual void svgAttributeChanged(const QualifiedName&) override final; | 55 virtual void svgAttributeChanged(const QualifiedName&) override final; |
| 53 | 56 |
| 54 virtual bool rendererIsNeeded(const RenderStyle&) override final { return fa
lse; } | 57 virtual bool rendererIsNeeded(const RenderStyle&) override final { return fa
lse; } |
| 55 | 58 |
| 56 private: | 59 private: |
| 57 RefPtr<SVGAnimatedNumberList> m_tableValues; | 60 RefPtrWillBeMember<SVGAnimatedNumberList> m_tableValues; |
| 58 RefPtr<SVGAnimatedNumber> m_slope; | 61 RefPtrWillBeMember<SVGAnimatedNumber> m_slope; |
| 59 RefPtr<SVGAnimatedNumber> m_intercept; | 62 RefPtrWillBeMember<SVGAnimatedNumber> m_intercept; |
| 60 RefPtr<SVGAnimatedNumber> m_amplitude; | 63 RefPtrWillBeMember<SVGAnimatedNumber> m_amplitude; |
| 61 RefPtr<SVGAnimatedNumber> m_exponent; | 64 RefPtrWillBeMember<SVGAnimatedNumber> m_exponent; |
| 62 RefPtr<SVGAnimatedNumber> m_offset; | 65 RefPtrWillBeMember<SVGAnimatedNumber> m_offset; |
| 63 RefPtr<SVGAnimatedEnumeration<ComponentTransferType> > m_type; | 66 RefPtrWillBeMember<SVGAnimatedEnumeration<ComponentTransferType> > m_type; |
| 64 }; | 67 }; |
| 65 | 68 |
| 66 } // namespace blink | 69 } // namespace blink |
| 67 | 70 |
| 68 #endif // SVGComponentTransferFunctionElement_h | 71 #endif // SVGComponentTransferFunctionElement_h |
| OLD | NEW |