| 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 424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 435 | 435 |
| 436 void SVGResources::buildSetOfResources( | 436 void SVGResources::buildSetOfResources( |
| 437 HashSet<LayoutSVGResourceContainer*>& set) { | 437 HashSet<LayoutSVGResourceContainer*>& set) { |
| 438 if (!hasResourceData()) | 438 if (!hasResourceData()) |
| 439 return; | 439 return; |
| 440 | 440 |
| 441 if (m_linkedResource) { | 441 if (m_linkedResource) { |
| 442 ASSERT(!m_clipperFilterMaskerData); | 442 ASSERT(!m_clipperFilterMaskerData); |
| 443 ASSERT(!m_markerData); | 443 ASSERT(!m_markerData); |
| 444 ASSERT(!m_fillStrokeData); | 444 ASSERT(!m_fillStrokeData); |
| 445 set.add(m_linkedResource); | 445 set.insert(m_linkedResource); |
| 446 return; | 446 return; |
| 447 } | 447 } |
| 448 | 448 |
| 449 if (m_clipperFilterMaskerData) { | 449 if (m_clipperFilterMaskerData) { |
| 450 if (m_clipperFilterMaskerData->clipper) | 450 if (m_clipperFilterMaskerData->clipper) |
| 451 set.add(m_clipperFilterMaskerData->clipper); | 451 set.insert(m_clipperFilterMaskerData->clipper); |
| 452 if (m_clipperFilterMaskerData->filter) | 452 if (m_clipperFilterMaskerData->filter) |
| 453 set.add(m_clipperFilterMaskerData->filter); | 453 set.insert(m_clipperFilterMaskerData->filter); |
| 454 if (m_clipperFilterMaskerData->masker) | 454 if (m_clipperFilterMaskerData->masker) |
| 455 set.add(m_clipperFilterMaskerData->masker); | 455 set.insert(m_clipperFilterMaskerData->masker); |
| 456 } | 456 } |
| 457 | 457 |
| 458 if (m_markerData) { | 458 if (m_markerData) { |
| 459 if (m_markerData->markerStart) | 459 if (m_markerData->markerStart) |
| 460 set.add(m_markerData->markerStart); | 460 set.insert(m_markerData->markerStart); |
| 461 if (m_markerData->markerMid) | 461 if (m_markerData->markerMid) |
| 462 set.add(m_markerData->markerMid); | 462 set.insert(m_markerData->markerMid); |
| 463 if (m_markerData->markerEnd) | 463 if (m_markerData->markerEnd) |
| 464 set.add(m_markerData->markerEnd); | 464 set.insert(m_markerData->markerEnd); |
| 465 } | 465 } |
| 466 | 466 |
| 467 if (m_fillStrokeData) { | 467 if (m_fillStrokeData) { |
| 468 if (m_fillStrokeData->fill) | 468 if (m_fillStrokeData->fill) |
| 469 set.add(m_fillStrokeData->fill); | 469 set.insert(m_fillStrokeData->fill); |
| 470 if (m_fillStrokeData->stroke) | 470 if (m_fillStrokeData->stroke) |
| 471 set.add(m_fillStrokeData->stroke); | 471 set.insert(m_fillStrokeData->stroke); |
| 472 } | 472 } |
| 473 } | 473 } |
| 474 | 474 |
| 475 bool SVGResources::setClipper(LayoutSVGResourceClipper* clipper) { | 475 bool SVGResources::setClipper(LayoutSVGResourceClipper* clipper) { |
| 476 if (!clipper) | 476 if (!clipper) |
| 477 return false; | 477 return false; |
| 478 | 478 |
| 479 ASSERT(clipper->resourceType() == ClipperResourceType); | 479 ASSERT(clipper->resourceType() == ClipperResourceType); |
| 480 | 480 |
| 481 if (!m_clipperFilterMaskerData) | 481 if (!m_clipperFilterMaskerData) |
| (...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 678 stroke->element()); | 678 stroke->element()); |
| 679 } | 679 } |
| 680 | 680 |
| 681 if (m_linkedResource) | 681 if (m_linkedResource) |
| 682 fprintf(stderr, " |-> xlink:href : %p (node=%p)\n", m_linkedResource, | 682 fprintf(stderr, " |-> xlink:href : %p (node=%p)\n", m_linkedResource, |
| 683 m_linkedResource->element()); | 683 m_linkedResource->element()); |
| 684 } | 684 } |
| 685 #endif | 685 #endif |
| 686 | 686 |
| 687 } // namespace blink | 687 } // namespace blink |
| OLD | NEW |