OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 2 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
3 * | 3 * |
4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
8 * | 8 * |
9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 HashSet<RenderSVGResourceContainer*>::iterator end = resourceSet.end(); | 62 HashSet<RenderSVGResourceContainer*>::iterator end = resourceSet.end(); |
63 for (HashSet<RenderSVGResourceContainer*>::iterator it = resourceSet.beg
in(); it != end; ++it) { | 63 for (HashSet<RenderSVGResourceContainer*>::iterator it = resourceSet.beg
in(); it != end; ++it) { |
64 if (m_allResources.contains(*it)) | 64 if (m_allResources.contains(*it)) |
65 return true; | 65 return true; |
66 } | 66 } |
67 } | 67 } |
68 | 68 |
69 // Then operate on the child resources of the given renderer. | 69 // Then operate on the child resources of the given renderer. |
70 // <marker id="a"> <path marker-start="url(#b)"/> ... | 70 // <marker id="a"> <path marker-start="url(#b)"/> ... |
71 // <marker id="b"> <path marker-start="url(#a)"/> ... | 71 // <marker id="b"> <path marker-start="url(#a)"/> ... |
72 for (RenderObject* child = renderer->firstChild(); child; child = child->nex
tSibling()) { | 72 for (RenderObject* child = renderer->slowFirstChild(); child; child = child-
>nextSibling()) { |
73 SVGResources* childResources = SVGResourcesCache::cachedResourcesForRend
erObject(child); | 73 SVGResources* childResources = SVGResourcesCache::cachedResourcesForRend
erObject(child); |
74 if (!childResources) | 74 if (!childResources) |
75 continue; | 75 continue; |
76 | 76 |
77 // A child of the given 'resource' contains resources. | 77 // A child of the given 'resource' contains resources. |
78 HashSet<RenderSVGResourceContainer*> childSet; | 78 HashSet<RenderSVGResourceContainer*> childSet; |
79 childResources->buildSetOfResources(childSet); | 79 childResources->buildSetOfResources(childSet); |
80 | 80 |
81 // Walk all child resources and check wheter they reference any resource
contained in the resources set. | 81 // Walk all child resources and check wheter they reference any resource
contained in the resources set. |
82 HashSet<RenderSVGResourceContainer*>::iterator end = childSet.end(); | 82 HashSet<RenderSVGResourceContainer*>::iterator end = childSet.end(); |
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
199 ASSERT(resourceLeadingToCycle == m_resources->clipper()); | 199 ASSERT(resourceLeadingToCycle == m_resources->clipper()); |
200 m_resources->resetClipper(); | 200 m_resources->resetClipper(); |
201 break; | 201 break; |
202 case SolidColorResourceType: | 202 case SolidColorResourceType: |
203 ASSERT_NOT_REACHED(); | 203 ASSERT_NOT_REACHED(); |
204 break; | 204 break; |
205 } | 205 } |
206 } | 206 } |
207 | 207 |
208 } | 208 } |
OLD | NEW |