| 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 259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 270 AtomicString id(targetReferenceFromResource(element)); | 270 AtomicString id(targetReferenceFromResource(element)); |
| 271 if (setLinkedResource(getRenderSVGResourceContainerById(document, id))) | 271 if (setLinkedResource(getRenderSVGResourceContainerById(document, id))) |
| 272 foundResources = true; | 272 foundResources = true; |
| 273 else | 273 else |
| 274 registerPendingResource(extensions, id, element); | 274 registerPendingResource(extensions, id, element); |
| 275 } | 275 } |
| 276 | 276 |
| 277 return foundResources; | 277 return foundResources; |
| 278 } | 278 } |
| 279 | 279 |
| 280 void SVGResources::layoutIfNeeded() |
| 281 { |
| 282 if (m_clipperFilterMaskerData) { |
| 283 if (RenderSVGResourceClipper* clipper = m_clipperFilterMaskerData->clipp
er) |
| 284 clipper->layoutIfNeeded(); |
| 285 if (RenderSVGResourceMasker* masker = m_clipperFilterMaskerData->masker) |
| 286 masker->layoutIfNeeded(); |
| 287 if (RenderSVGResourceFilter* filter = m_clipperFilterMaskerData->filter) |
| 288 filter->layoutIfNeeded(); |
| 289 } |
| 290 |
| 291 if (m_markerData) { |
| 292 if (RenderSVGResourceMarker* marker = m_markerData->markerStart) |
| 293 marker->layoutIfNeeded(); |
| 294 if (RenderSVGResourceMarker* marker = m_markerData->markerMid) |
| 295 marker->layoutIfNeeded(); |
| 296 if (RenderSVGResourceMarker* marker = m_markerData->markerEnd) |
| 297 marker->layoutIfNeeded(); |
| 298 } |
| 299 } |
| 300 |
| 280 void SVGResources::removeClientFromCache(RenderObject* object, bool markForInval
idation) const | 301 void SVGResources::removeClientFromCache(RenderObject* object, bool markForInval
idation) const |
| 281 { | 302 { |
| 282 if (!m_clipperFilterMaskerData && !m_markerData && !m_fillStrokeData && !m_l
inkedResource) | 303 if (!m_clipperFilterMaskerData && !m_markerData && !m_fillStrokeData && !m_l
inkedResource) |
| 283 return; | 304 return; |
| 284 | 305 |
| 285 if (m_linkedResource) { | 306 if (m_linkedResource) { |
| 286 ASSERT(!m_clipperFilterMaskerData); | 307 ASSERT(!m_clipperFilterMaskerData); |
| 287 ASSERT(!m_markerData); | 308 ASSERT(!m_markerData); |
| 288 ASSERT(!m_fillStrokeData); | 309 ASSERT(!m_fillStrokeData); |
| 289 m_linkedResource->removeClientFromCache(object, markForInvalidation); | 310 m_linkedResource->removeClientFromCache(object, markForInvalidation); |
| (...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 652 if (RenderSVGResourceContainer* stroke = m_fillStrokeData->stroke) | 673 if (RenderSVGResourceContainer* stroke = m_fillStrokeData->stroke) |
| 653 fprintf(stderr, " |-> Stroke : %p (node=%p)\n", stroke, stroke->
element()); | 674 fprintf(stderr, " |-> Stroke : %p (node=%p)\n", stroke, stroke->
element()); |
| 654 } | 675 } |
| 655 | 676 |
| 656 if (m_linkedResource) | 677 if (m_linkedResource) |
| 657 fprintf(stderr, " |-> xlink:href : %p (node=%p)\n", m_linkedResource, m_
linkedResource->element()); | 678 fprintf(stderr, " |-> xlink:href : %p (node=%p)\n", m_linkedResource, m_
linkedResource->element()); |
| 658 } | 679 } |
| 659 #endif | 680 #endif |
| 660 | 681 |
| 661 } | 682 } |
| OLD | NEW |