| 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 12 matching lines...) Expand all Loading... |
| 23 #include "core/SVGNames.h" | 23 #include "core/SVGNames.h" |
| 24 #include "core/svg/graphics/filters/SVGFilterBuilder.h" | 24 #include "core/svg/graphics/filters/SVGFilterBuilder.h" |
| 25 | 25 |
| 26 namespace blink { | 26 namespace blink { |
| 27 | 27 |
| 28 template <> | 28 template <> |
| 29 const SVGEnumerationStringEntries& | 29 const SVGEnumerationStringEntries& |
| 30 getStaticStringEntries<CompositeOperationType>() { | 30 getStaticStringEntries<CompositeOperationType>() { |
| 31 DEFINE_STATIC_LOCAL(SVGEnumerationStringEntries, entries, ()); | 31 DEFINE_STATIC_LOCAL(SVGEnumerationStringEntries, entries, ()); |
| 32 if (entries.isEmpty()) { | 32 if (entries.isEmpty()) { |
| 33 entries.append(std::make_pair(FECOMPOSITE_OPERATOR_OVER, "over")); | 33 entries.push_back(std::make_pair(FECOMPOSITE_OPERATOR_OVER, "over")); |
| 34 entries.append(std::make_pair(FECOMPOSITE_OPERATOR_IN, "in")); | 34 entries.push_back(std::make_pair(FECOMPOSITE_OPERATOR_IN, "in")); |
| 35 entries.append(std::make_pair(FECOMPOSITE_OPERATOR_OUT, "out")); | 35 entries.push_back(std::make_pair(FECOMPOSITE_OPERATOR_OUT, "out")); |
| 36 entries.append(std::make_pair(FECOMPOSITE_OPERATOR_ATOP, "atop")); | 36 entries.push_back(std::make_pair(FECOMPOSITE_OPERATOR_ATOP, "atop")); |
| 37 entries.append(std::make_pair(FECOMPOSITE_OPERATOR_XOR, "xor")); | 37 entries.push_back(std::make_pair(FECOMPOSITE_OPERATOR_XOR, "xor")); |
| 38 entries.append( | 38 entries.push_back( |
| 39 std::make_pair(FECOMPOSITE_OPERATOR_ARITHMETIC, "arithmetic")); | 39 std::make_pair(FECOMPOSITE_OPERATOR_ARITHMETIC, "arithmetic")); |
| 40 entries.append(std::make_pair(FECOMPOSITE_OPERATOR_LIGHTER, "lighter")); | 40 entries.push_back(std::make_pair(FECOMPOSITE_OPERATOR_LIGHTER, "lighter")); |
| 41 } | 41 } |
| 42 return entries; | 42 return entries; |
| 43 } | 43 } |
| 44 | 44 |
| 45 template <> | 45 template <> |
| 46 unsigned short getMaxExposedEnumValue<CompositeOperationType>() { | 46 unsigned short getMaxExposedEnumValue<CompositeOperationType>() { |
| 47 return FECOMPOSITE_OPERATOR_ARITHMETIC; | 47 return FECOMPOSITE_OPERATOR_ARITHMETIC; |
| 48 } | 48 } |
| 49 | 49 |
| 50 inline SVGFECompositeElement::SVGFECompositeElement(Document& document) | 50 inline SVGFECompositeElement::SVGFECompositeElement(Document& document) |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 133 FilterEffect* input2 = filterBuilder->getEffectById( | 133 FilterEffect* input2 = filterBuilder->getEffectById( |
| 134 AtomicString(m_in2->currentValue()->value())); | 134 AtomicString(m_in2->currentValue()->value())); |
| 135 ASSERT(input1 && input2); | 135 ASSERT(input1 && input2); |
| 136 | 136 |
| 137 FilterEffect* effect = FEComposite::create( | 137 FilterEffect* effect = FEComposite::create( |
| 138 filter, m_svgOperator->currentValue()->enumValue(), | 138 filter, m_svgOperator->currentValue()->enumValue(), |
| 139 m_k1->currentValue()->value(), m_k2->currentValue()->value(), | 139 m_k1->currentValue()->value(), m_k2->currentValue()->value(), |
| 140 m_k3->currentValue()->value(), m_k4->currentValue()->value()); | 140 m_k3->currentValue()->value(), m_k4->currentValue()->value()); |
| 141 FilterEffectVector& inputEffects = effect->inputEffects(); | 141 FilterEffectVector& inputEffects = effect->inputEffects(); |
| 142 inputEffects.reserveCapacity(2); | 142 inputEffects.reserveCapacity(2); |
| 143 inputEffects.append(input1); | 143 inputEffects.push_back(input1); |
| 144 inputEffects.append(input2); | 144 inputEffects.push_back(input2); |
| 145 return effect; | 145 return effect; |
| 146 } | 146 } |
| 147 | 147 |
| 148 } // namespace blink | 148 } // namespace blink |
| OLD | NEW |