OLD | NEW |
1 /* | 1 /* |
2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) | 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) |
3 * Copyright (C) 2004, 2006, 2007, 2012 Apple Inc. All rights reserved. | 3 * Copyright (C) 2004, 2006, 2007, 2012 Apple Inc. All rights reserved. |
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 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
289 } | 289 } |
290 | 290 |
291 bool StyleSheetContents::wrapperDeleteRule(unsigned index) { | 291 bool StyleSheetContents::wrapperDeleteRule(unsigned index) { |
292 ASSERT(m_isMutable); | 292 ASSERT(m_isMutable); |
293 SECURITY_DCHECK(index < ruleCount()); | 293 SECURITY_DCHECK(index < ruleCount()); |
294 | 294 |
295 if (index < m_importRules.size()) { | 295 if (index < m_importRules.size()) { |
296 m_importRules[index]->clearParentStyleSheet(); | 296 m_importRules[index]->clearParentStyleSheet(); |
297 if (m_importRules[index]->isFontFaceRule()) | 297 if (m_importRules[index]->isFontFaceRule()) |
298 notifyRemoveFontFaceRule(toStyleRuleFontFace(m_importRules[index].get())); | 298 notifyRemoveFontFaceRule(toStyleRuleFontFace(m_importRules[index].get())); |
299 m_importRules.remove(index); | 299 m_importRules.erase(index); |
300 return true; | 300 return true; |
301 } | 301 } |
302 index -= m_importRules.size(); | 302 index -= m_importRules.size(); |
303 | 303 |
304 if (index < m_namespaceRules.size()) { | 304 if (index < m_namespaceRules.size()) { |
305 if (!m_childRules.isEmpty()) | 305 if (!m_childRules.isEmpty()) |
306 return false; | 306 return false; |
307 m_namespaceRules.remove(index); | 307 m_namespaceRules.erase(index); |
308 return true; | 308 return true; |
309 } | 309 } |
310 index -= m_namespaceRules.size(); | 310 index -= m_namespaceRules.size(); |
311 | 311 |
312 if (m_childRules[index]->isFontFaceRule()) | 312 if (m_childRules[index]->isFontFaceRule()) |
313 notifyRemoveFontFaceRule(toStyleRuleFontFace(m_childRules[index].get())); | 313 notifyRemoveFontFaceRule(toStyleRuleFontFace(m_childRules[index].get())); |
314 m_childRules.remove(index); | 314 m_childRules.erase(index); |
315 return true; | 315 return true; |
316 } | 316 } |
317 | 317 |
318 void StyleSheetContents::parserAddNamespace(const AtomicString& prefix, | 318 void StyleSheetContents::parserAddNamespace(const AtomicString& prefix, |
319 const AtomicString& uri) { | 319 const AtomicString& uri) { |
320 ASSERT(!uri.isNull()); | 320 ASSERT(!uri.isNull()); |
321 if (prefix.isNull()) { | 321 if (prefix.isNull()) { |
322 m_defaultNamespace = uri; | 322 m_defaultNamespace = uri; |
323 return; | 323 return; |
324 } | 324 } |
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
703 visitor->trace(m_namespaceRules); | 703 visitor->trace(m_namespaceRules); |
704 visitor->trace(m_childRules); | 704 visitor->trace(m_childRules); |
705 visitor->trace(m_loadingClients); | 705 visitor->trace(m_loadingClients); |
706 visitor->trace(m_completedClients); | 706 visitor->trace(m_completedClients); |
707 visitor->trace(m_ruleSet); | 707 visitor->trace(m_ruleSet); |
708 visitor->trace(m_referencedFromResource); | 708 visitor->trace(m_referencedFromResource); |
709 visitor->trace(m_parserContext); | 709 visitor->trace(m_parserContext); |
710 } | 710 } |
711 | 711 |
712 } // namespace blink | 712 } // namespace blink |
OLD | NEW |