| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2005, 2006, 2007 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005, 2006, 2007 Nikolas Zimmermann <zimmermann@kde.org> |
| 3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> |
| 4 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> | 4 * Copyright (C) 2009 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 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 void SVGFilterPrimitiveStandardAttributes::childrenChanged(const ChildrenChange&
change) | 85 void SVGFilterPrimitiveStandardAttributes::childrenChanged(const ChildrenChange&
change) |
| 86 { | 86 { |
| 87 SVGElement::childrenChanged(change); | 87 SVGElement::childrenChanged(change); |
| 88 | 88 |
| 89 if (!change.byParser) | 89 if (!change.byParser) |
| 90 invalidate(); | 90 invalidate(); |
| 91 } | 91 } |
| 92 | 92 |
| 93 void SVGFilterPrimitiveStandardAttributes::setStandardAttributes(FilterEffect* f
ilterEffect) const | 93 void SVGFilterPrimitiveStandardAttributes::setStandardAttributes(FilterEffect* f
ilterEffect) const |
| 94 { | 94 { |
| 95 ASSERT(filterEffect); | 95 DCHECK(filterEffect); |
| 96 if (!filterEffect) | |
| 97 return; | |
| 98 | 96 |
| 99 if (hasAttribute(SVGNames::xAttr)) | 97 if (x()->isSpecified()) |
| 100 filterEffect->setHasX(true); | 98 filterEffect->setHasX(true); |
| 101 if (hasAttribute(SVGNames::yAttr)) | 99 if (y()->isSpecified()) |
| 102 filterEffect->setHasY(true); | 100 filterEffect->setHasY(true); |
| 103 if (hasAttribute(SVGNames::widthAttr)) | 101 if (width()->isSpecified()) |
| 104 filterEffect->setHasWidth(true); | 102 filterEffect->setHasWidth(true); |
| 105 if (hasAttribute(SVGNames::heightAttr)) | 103 if (height()->isSpecified()) |
| 106 filterEffect->setHasHeight(true); | 104 filterEffect->setHasHeight(true); |
| 107 } | 105 } |
| 108 | 106 |
| 109 LayoutObject* SVGFilterPrimitiveStandardAttributes::createLayoutObject(const Com
putedStyle&) | 107 LayoutObject* SVGFilterPrimitiveStandardAttributes::createLayoutObject(const Com
putedStyle&) |
| 110 { | 108 { |
| 111 return new LayoutSVGResourceFilterPrimitive(this); | 109 return new LayoutSVGResourceFilterPrimitive(this); |
| 112 } | 110 } |
| 113 | 111 |
| 114 bool SVGFilterPrimitiveStandardAttributes::layoutObjectIsNeeded(const ComputedSt
yle& style) | 112 bool SVGFilterPrimitiveStandardAttributes::layoutObjectIsNeeded(const ComputedSt
yle& style) |
| 115 { | 113 { |
| (...skipping 26 matching lines...) Expand all Loading... |
| 142 return; | 140 return; |
| 143 | 141 |
| 144 LayoutObject* layoutObject = parent->layoutObject(); | 142 LayoutObject* layoutObject = parent->layoutObject(); |
| 145 if (!layoutObject || !layoutObject->isSVGResourceFilterPrimitive()) | 143 if (!layoutObject || !layoutObject->isSVGResourceFilterPrimitive()) |
| 146 return; | 144 return; |
| 147 | 145 |
| 148 LayoutSVGResourceContainer::markForLayoutAndParentResourceInvalidation(layou
tObject, false); | 146 LayoutSVGResourceContainer::markForLayoutAndParentResourceInvalidation(layou
tObject, false); |
| 149 } | 147 } |
| 150 | 148 |
| 151 } // namespace blink | 149 } // namespace blink |
| OLD | NEW |