| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008 Nikolas Zimmermann <zimmermann@kde.org> | 3 * Copyright (C) 2008 Nikolas Zimmermann <zimmermann@kde.org> |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 | 110 |
| 111 SVGElement::InvalidationGuard invalidationGuard(this); | 111 SVGElement::InvalidationGuard invalidationGuard(this); |
| 112 | 112 |
| 113 bool isLengthAttribute = attrName == SVGNames::xAttr | 113 bool isLengthAttribute = attrName == SVGNames::xAttr |
| 114 || attrName == SVGNames::yAttr | 114 || attrName == SVGNames::yAttr |
| 115 || attrName == SVGNames::widthAttr | 115 || attrName == SVGNames::widthAttr |
| 116 || attrName == SVGNames::heightAttr; | 116 || attrName == SVGNames::heightAttr; |
| 117 | 117 |
| 118 if (isLengthAttribute) { | 118 if (isLengthAttribute) { |
| 119 updateRelativeLengthsInformation(); | 119 updateRelativeLengthsInformation(); |
| 120 if (RenderObject* renderer = this->renderer()) | 120 if (LayoutObject* renderer = this->renderer()) |
| 121 markForLayoutAndParentResourceInvalidation(renderer); | 121 markForLayoutAndParentResourceInvalidation(renderer); |
| 122 } | 122 } |
| 123 } | 123 } |
| 124 | 124 |
| 125 RenderObject* SVGForeignObjectElement::createRenderer(const RenderStyle&) | 125 LayoutObject* SVGForeignObjectElement::createRenderer(const RenderStyle&) |
| 126 { | 126 { |
| 127 return new RenderSVGForeignObject(this); | 127 return new RenderSVGForeignObject(this); |
| 128 } | 128 } |
| 129 | 129 |
| 130 bool SVGForeignObjectElement::rendererIsNeeded(const RenderStyle& style) | 130 bool SVGForeignObjectElement::rendererIsNeeded(const RenderStyle& style) |
| 131 { | 131 { |
| 132 // Suppress foreignObject renderers in SVG hidden containers. | 132 // Suppress foreignObject renderers in SVG hidden containers. |
| 133 // (https://bugs.webkit.org/show_bug.cgi?id=87297) | 133 // (https://bugs.webkit.org/show_bug.cgi?id=87297) |
| 134 // Note that we currently do not support foreignObject instantiation via <us
e>, hence it is safe | 134 // Note that we currently do not support foreignObject instantiation via <us
e>, hence it is safe |
| 135 // to use parentElement() here. If that changes, this method should be updat
ed to use | 135 // to use parentElement() here. If that changes, this method should be updat
ed to use |
| (...skipping 11 matching lines...) Expand all Loading... |
| 147 | 147 |
| 148 bool SVGForeignObjectElement::selfHasRelativeLengths() const | 148 bool SVGForeignObjectElement::selfHasRelativeLengths() const |
| 149 { | 149 { |
| 150 return m_x->currentValue()->isRelative() | 150 return m_x->currentValue()->isRelative() |
| 151 || m_y->currentValue()->isRelative() | 151 || m_y->currentValue()->isRelative() |
| 152 || m_width->currentValue()->isRelative() | 152 || m_width->currentValue()->isRelative() |
| 153 || m_height->currentValue()->isRelative(); | 153 || m_height->currentValue()->isRelative(); |
| 154 } | 154 } |
| 155 | 155 |
| 156 } // namespace blink | 156 } // namespace blink |
| OLD | NEW |