OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005, 2007 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, |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 return entries; | 88 return entries; |
89 } | 89 } |
90 | 90 |
91 template <> | 91 template <> |
92 unsigned short getMaxExposedEnumValue<SVGFEBlendElement::Mode>() { | 92 unsigned short getMaxExposedEnumValue<SVGFEBlendElement::Mode>() { |
93 return SVGFEBlendElement::ModeLighten; | 93 return SVGFEBlendElement::ModeLighten; |
94 } | 94 } |
95 | 95 |
96 inline SVGFEBlendElement::SVGFEBlendElement(Document& document) | 96 inline SVGFEBlendElement::SVGFEBlendElement(Document& document) |
97 : SVGFilterPrimitiveStandardAttributes(SVGNames::feBlendTag, document), | 97 : SVGFilterPrimitiveStandardAttributes(SVGNames::feBlendTag, document), |
98 m_in1(SVGAnimatedString::create(this, | 98 m_in1(SVGAnimatedString::create(this, SVGNames::inAttr)), |
99 SVGNames::inAttr, | 99 m_in2(SVGAnimatedString::create(this, SVGNames::in2Attr)), |
100 SVGString::create())), | |
101 m_in2(SVGAnimatedString::create(this, | |
102 SVGNames::in2Attr, | |
103 SVGString::create())), | |
104 m_mode( | 100 m_mode( |
105 SVGAnimatedEnumeration<Mode>::create(this, | 101 SVGAnimatedEnumeration<Mode>::create(this, |
106 SVGNames::modeAttr, | 102 SVGNames::modeAttr, |
107 SVGFEBlendElement::ModeNormal)) { | 103 SVGFEBlendElement::ModeNormal)) { |
108 addToPropertyMap(m_in1); | 104 addToPropertyMap(m_in1); |
109 addToPropertyMap(m_in2); | 105 addToPropertyMap(m_in2); |
110 addToPropertyMap(m_mode); | 106 addToPropertyMap(m_mode); |
111 } | 107 } |
112 | 108 |
113 DEFINE_TRACE(SVGFEBlendElement) { | 109 DEFINE_TRACE(SVGFEBlendElement) { |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 FilterEffect* effect = FEBlend::create( | 154 FilterEffect* effect = FEBlend::create( |
159 filter, toWebBlendMode(m_mode->currentValue()->enumValue())); | 155 filter, toWebBlendMode(m_mode->currentValue()->enumValue())); |
160 FilterEffectVector& inputEffects = effect->inputEffects(); | 156 FilterEffectVector& inputEffects = effect->inputEffects(); |
161 inputEffects.reserveCapacity(2); | 157 inputEffects.reserveCapacity(2); |
162 inputEffects.append(input1); | 158 inputEffects.append(input1); |
163 inputEffects.append(input2); | 159 inputEffects.append(input2); |
164 return effect; | 160 return effect; |
165 } | 161 } |
166 | 162 |
167 } // namespace blink | 163 } // namespace blink |
OLD | NEW |