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 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 inline SVGFECompositeElement::SVGFECompositeElement(Document& document) | 45 inline SVGFECompositeElement::SVGFECompositeElement(Document& document) |
46 : SVGFilterPrimitiveStandardAttributes(SVGNames::feCompositeTag, document) | 46 : SVGFilterPrimitiveStandardAttributes(SVGNames::feCompositeTag, document) |
47 , m_k1(SVGAnimatedNumber::create(this, SVGNames::k1Attr, SVGNumber::create()
)) | 47 , m_k1(SVGAnimatedNumber::create(this, SVGNames::k1Attr, SVGNumber::create()
)) |
48 , m_k2(SVGAnimatedNumber::create(this, SVGNames::k2Attr, SVGNumber::create()
)) | 48 , m_k2(SVGAnimatedNumber::create(this, SVGNames::k2Attr, SVGNumber::create()
)) |
49 , m_k3(SVGAnimatedNumber::create(this, SVGNames::k3Attr, SVGNumber::create()
)) | 49 , m_k3(SVGAnimatedNumber::create(this, SVGNames::k3Attr, SVGNumber::create()
)) |
50 , m_k4(SVGAnimatedNumber::create(this, SVGNames::k4Attr, SVGNumber::create()
)) | 50 , m_k4(SVGAnimatedNumber::create(this, SVGNames::k4Attr, SVGNumber::create()
)) |
51 , m_in1(SVGAnimatedString::create(this, SVGNames::inAttr, SVGString::create(
))) | 51 , m_in1(SVGAnimatedString::create(this, SVGNames::inAttr, SVGString::create(
))) |
52 , m_in2(SVGAnimatedString::create(this, SVGNames::in2Attr, SVGString::create
())) | 52 , m_in2(SVGAnimatedString::create(this, SVGNames::in2Attr, SVGString::create
())) |
53 , m_svgOperator(SVGAnimatedEnumeration<CompositeOperationType>::create(this,
SVGNames::operatorAttr, FECOMPOSITE_OPERATOR_OVER)) | 53 , m_svgOperator(SVGAnimatedEnumeration<CompositeOperationType>::create(this,
SVGNames::operatorAttr, FECOMPOSITE_OPERATOR_OVER)) |
54 { | 54 { |
55 ScriptWrappable::init(this); | |
56 | |
57 addToPropertyMap(m_k1); | 55 addToPropertyMap(m_k1); |
58 addToPropertyMap(m_k2); | 56 addToPropertyMap(m_k2); |
59 addToPropertyMap(m_k3); | 57 addToPropertyMap(m_k3); |
60 addToPropertyMap(m_k4); | 58 addToPropertyMap(m_k4); |
61 addToPropertyMap(m_in1); | 59 addToPropertyMap(m_in1); |
62 addToPropertyMap(m_in2); | 60 addToPropertyMap(m_in2); |
63 addToPropertyMap(m_svgOperator); | 61 addToPropertyMap(m_svgOperator); |
64 } | 62 } |
65 | 63 |
66 DEFINE_NODE_FACTORY(SVGFECompositeElement) | 64 DEFINE_NODE_FACTORY(SVGFECompositeElement) |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 return nullptr; | 161 return nullptr; |
164 | 162 |
165 RefPtr<FilterEffect> effect = FEComposite::create(filter, m_svgOperator->cur
rentValue()->enumValue(), m_k1->currentValue()->value(), m_k2->currentValue()->v
alue(), m_k3->currentValue()->value(), m_k4->currentValue()->value()); | 163 RefPtr<FilterEffect> effect = FEComposite::create(filter, m_svgOperator->cur
rentValue()->enumValue(), m_k1->currentValue()->value(), m_k2->currentValue()->v
alue(), m_k3->currentValue()->value(), m_k4->currentValue()->value()); |
166 FilterEffectVector& inputEffects = effect->inputEffects(); | 164 FilterEffectVector& inputEffects = effect->inputEffects(); |
167 inputEffects.reserveCapacity(2); | 165 inputEffects.reserveCapacity(2); |
168 inputEffects.append(input1); | 166 inputEffects.append(input1); |
169 inputEffects.append(input2); | 167 inputEffects.append(input2); |
170 return effect.release(); | 168 return effect.release(); |
171 } | 169 } |
172 | 170 |
173 } | 171 } // namespace blink |
OLD | NEW |