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, |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 // number 0. If the index is equal to 0, then the new item is inserted at the | 56 // number 0. If the index is equal to 0, then the new item is inserted at the |
57 // front of the list. | 57 // front of the list. |
58 m_values.insert(index, newItem); | 58 m_values.insert(index, newItem); |
59 } | 59 } |
60 | 60 |
61 String SVGStringList::removeItem(size_t index, ExceptionState& exceptionState) { | 61 String SVGStringList::removeItem(size_t index, ExceptionState& exceptionState) { |
62 if (!checkIndexBound(index, exceptionState)) | 62 if (!checkIndexBound(index, exceptionState)) |
63 return String(); | 63 return String(); |
64 | 64 |
65 String oldItem = m_values.at(index); | 65 String oldItem = m_values.at(index); |
66 m_values.remove(index); | 66 m_values.erase(index); |
67 return oldItem; | 67 return oldItem; |
68 } | 68 } |
69 | 69 |
70 void SVGStringList::appendItem(const String& newItem) { | 70 void SVGStringList::appendItem(const String& newItem) { |
71 m_values.push_back(newItem); | 71 m_values.push_back(newItem); |
72 } | 72 } |
73 | 73 |
74 void SVGStringList::replaceItem(const String& newItem, | 74 void SVGStringList::replaceItem(const String& newItem, |
75 size_t index, | 75 size_t index, |
76 ExceptionState& exceptionState) { | 76 ExceptionState& exceptionState) { |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 } | 162 } |
163 | 163 |
164 float SVGStringList::calculateDistance(SVGPropertyBase*, SVGElement*) { | 164 float SVGStringList::calculateDistance(SVGPropertyBase*, SVGElement*) { |
165 // SVGStringList is never animated. | 165 // SVGStringList is never animated. |
166 NOTREACHED(); | 166 NOTREACHED(); |
167 | 167 |
168 return -1.0f; | 168 return -1.0f; |
169 } | 169 } |
170 | 170 |
171 } // namespace blink | 171 } // namespace blink |
OLD | NEW |