OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006 Apple Inc. All rights reserved. |
3 * Copyright (C) 2006 Nikolas Zimmermann <zimmermann@kde.org> | 3 * Copyright (C) 2006 Nikolas Zimmermann <zimmermann@kde.org> |
4 * Copyright (C) 2007 Rob Buis <buis@kde.org> | 4 * Copyright (C) 2007 Rob Buis <buis@kde.org> |
5 * | 5 * |
6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
10 * | 10 * |
(...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
343 HashSet<SVGElement*>* referencingElements = it->value.get(); | 343 HashSet<SVGElement*>* referencingElements = it->value.get(); |
344 HashSet<SVGElement*>::iterator setIt = referencingElements->find(referen
cingElement); | 344 HashSet<SVGElement*>::iterator setIt = referencingElements->find(referen
cingElement); |
345 if (setIt == referencingElements->end()) | 345 if (setIt == referencingElements->end()) |
346 continue; | 346 continue; |
347 | 347 |
348 referencingElements->remove(setIt); | 348 referencingElements->remove(setIt); |
349 if (referencingElements->isEmpty()) | 349 if (referencingElements->isEmpty()) |
350 toBeRemoved.append(referencedElement); | 350 toBeRemoved.append(referencedElement); |
351 } | 351 } |
352 | 352 |
353 Vector<SVGElement*>::iterator vectorEnd = toBeRemoved.end(); | 353 m_elementDependencies.removeAll(toBeRemoved); |
354 for (Vector<SVGElement*>::iterator it = toBeRemoved.begin(); it != vectorEnd
; ++it) | |
355 m_elementDependencies.remove(*it); | |
356 } | 354 } |
357 | 355 |
358 void SVGDocumentExtensions::rebuildAllElementReferencesForTarget(SVGElement* ref
erencedElement) | 356 void SVGDocumentExtensions::rebuildAllElementReferencesForTarget(SVGElement* ref
erencedElement) |
359 { | 357 { |
360 ASSERT(referencedElement); | 358 ASSERT(referencedElement); |
361 HashMap<SVGElement*, OwnPtr<HashSet<SVGElement*> > >::iterator it = m_elemen
tDependencies.find(referencedElement); | 359 HashMap<SVGElement*, OwnPtr<HashSet<SVGElement*> > >::iterator it = m_elemen
tDependencies.find(referencedElement); |
362 if (it == m_elementDependencies.end()) | 360 if (it == m_elementDependencies.end()) |
363 return; | 361 return; |
364 ASSERT(it->key == referencedElement); | 362 ASSERT(it->key == referencedElement); |
365 Vector<SVGElement*> toBeNotified; | 363 Vector<SVGElement*> toBeNotified; |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
438 } | 436 } |
439 | 437 |
440 void SVGDocumentExtensions::removePendingSVGFontFaceElementsForRemoval() | 438 void SVGDocumentExtensions::removePendingSVGFontFaceElementsForRemoval() |
441 { | 439 { |
442 m_pendingSVGFontFaceElementsForRemoval.clear(); | 440 m_pendingSVGFontFaceElementsForRemoval.clear(); |
443 } | 441 } |
444 | 442 |
445 #endif | 443 #endif |
446 | 444 |
447 } | 445 } |
OLD | NEW |