| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> |
| 3 * Copyright (C) 2004, 2005 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005 Rob Buis <buis@kde.org> |
| 4 * Copyright (C) 2010 Dirk Schulze <krit@webkit.org> | 4 * Copyright (C) 2010 Dirk Schulze <krit@webkit.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 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 Element* target = SVGURIReference::targetElementFromIRIString( | 92 Element* target = SVGURIReference::targetElementFromIRIString( |
| 93 hrefString(), treeScope(), &id); | 93 hrefString(), treeScope(), &id); |
| 94 if (!target) { | 94 if (!target) { |
| 95 if (id.isEmpty()) { | 95 if (id.isEmpty()) { |
| 96 fetchImageResource(); | 96 fetchImageResource(); |
| 97 } else { | 97 } else { |
| 98 document().accessSVGExtensions().addPendingResource(id, this); | 98 document().accessSVGExtensions().addPendingResource(id, this); |
| 99 ASSERT(hasPendingResources()); | 99 ASSERT(hasPendingResources()); |
| 100 } | 100 } |
| 101 } else if (target->isSVGElement()) { | 101 } else if (target->isSVGElement()) { |
| 102 // Register us with the target in the dependencies map. Any change of hrefEl
ement | 102 // Register us with the target in the dependencies map. Any change of |
| 103 // that leads to relayout/repainting now informs us, so we can react to it. | 103 // hrefElement that leads to relayout/repainting now informs us, so we can |
| 104 // react to it. |
| 104 addReferenceTo(toSVGElement(target)); | 105 addReferenceTo(toSVGElement(target)); |
| 105 } | 106 } |
| 106 | 107 |
| 107 invalidate(); | 108 invalidate(); |
| 108 } | 109 } |
| 109 | 110 |
| 110 void SVGFEImageElement::svgAttributeChanged(const QualifiedName& attrName) { | 111 void SVGFEImageElement::svgAttributeChanged(const QualifiedName& attrName) { |
| 111 if (attrName == SVGNames::preserveAspectRatioAttr) { | 112 if (attrName == SVGNames::preserveAspectRatioAttr) { |
| 112 SVGElement::InvalidationGuard invalidationGuard(this); | 113 SVGElement::InvalidationGuard invalidationGuard(this); |
| 113 invalidate(); | 114 invalidate(); |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 m_cachedImage->errorOccurred() ? nullptr : m_cachedImage->getImage(); | 156 m_cachedImage->errorOccurred() ? nullptr : m_cachedImage->getImage(); |
| 156 return FEImage::createWithImage(filter, image, | 157 return FEImage::createWithImage(filter, image, |
| 157 m_preserveAspectRatio->currentValue()); | 158 m_preserveAspectRatio->currentValue()); |
| 158 } | 159 } |
| 159 | 160 |
| 160 return FEImage::createWithIRIReference(filter, treeScope(), hrefString(), | 161 return FEImage::createWithIRIReference(filter, treeScope(), hrefString(), |
| 161 m_preserveAspectRatio->currentValue()); | 162 m_preserveAspectRatio->currentValue()); |
| 162 } | 163 } |
| 163 | 164 |
| 164 } // namespace blink | 165 } // namespace blink |
| OLD | NEW |