| Index: Source/core/svg/SVGElement.cpp
|
| diff --git a/Source/core/svg/SVGElement.cpp b/Source/core/svg/SVGElement.cpp
|
| index f5b0584cc27b2ae6b5291cd41248eb87738c1f21..c3e1e220fba2765be4ffafe1048dde5d442b76da 100644
|
| --- a/Source/core/svg/SVGElement.cpp
|
| +++ b/Source/core/svg/SVGElement.cpp
|
| @@ -418,12 +418,12 @@ void SVGElement::invalidateRelativeLengthClients(SubtreeLayoutScope* layoutScope
|
| TemporaryChange<bool> inRelativeLengthClientsInvalidationChange(m_inRelativeLengthClientsInvalidation, true);
|
| #endif
|
|
|
| - LayoutObject* renderer = this->layoutObject();
|
| - if (renderer && selfHasRelativeLengths()) {
|
| - if (renderer->isSVGResourceContainer())
|
| - toLayoutSVGResourceContainer(renderer)->invalidateCacheAndMarkForLayout(layoutScope);
|
| + LayoutObject* layoutObject = this->layoutObject();
|
| + if (layoutObject && selfHasRelativeLengths()) {
|
| + if (layoutObject->isSVGResourceContainer())
|
| + toLayoutSVGResourceContainer(layoutObject)->invalidateCacheAndMarkForLayout(layoutScope);
|
| else
|
| - renderer->setNeedsLayoutAndFullPaintInvalidation(LayoutInvalidationReason::Unknown, MarkContainerChain, layoutScope);
|
| + layoutObject->setNeedsLayoutAndFullPaintInvalidation(LayoutInvalidationReason::Unknown, MarkContainerChain, layoutScope);
|
| }
|
|
|
| for (SVGElement* element : m_elementsWithRelativeLengths) {
|
| @@ -913,8 +913,8 @@ PassRefPtr<ComputedStyle> SVGElement::customStyleForLayoutObject()
|
|
|
| const ComputedStyle* style = nullptr;
|
| if (Element* parent = parentOrShadowHostElement()) {
|
| - if (LayoutObject* renderer = parent->layoutObject())
|
| - style = renderer->style();
|
| + if (LayoutObject* layoutObject = parent->layoutObject())
|
| + style = layoutObject->style();
|
| }
|
|
|
| return document().ensureStyleResolver().styleForElement(correspondingElement(), style, DisallowStyleSharing);
|
| @@ -945,8 +945,8 @@ const ComputedStyle* SVGElement::ensureComputedStyle(PseudoId pseudoElementSpeci
|
|
|
| const ComputedStyle* parentStyle = nullptr;
|
| if (Element* parent = parentOrShadowHostElement()) {
|
| - if (LayoutObject* renderer = parent->layoutObject())
|
| - parentStyle = renderer->style();
|
| + if (LayoutObject* layoutObject = parent->layoutObject())
|
| + parentStyle = layoutObject->style();
|
| }
|
|
|
| return svgRareData()->overrideComputedStyle(this, parentStyle);
|
| @@ -958,10 +958,10 @@ bool SVGElement::hasFocusEventListeners() const
|
| || hasEventListeners(EventTypeNames::focus) || hasEventListeners(EventTypeNames::blur);
|
| }
|
|
|
| -void SVGElement::markForLayoutAndParentResourceInvalidation(LayoutObject* renderer)
|
| +void SVGElement::markForLayoutAndParentResourceInvalidation(LayoutObject* layoutObject)
|
| {
|
| - ASSERT(renderer);
|
| - LayoutSVGResourceContainer::markForLayoutAndParentResourceInvalidation(renderer, true);
|
| + ASSERT(layoutObject);
|
| + LayoutSVGResourceContainer::markForLayoutAndParentResourceInvalidation(layoutObject, true);
|
| }
|
|
|
| void SVGElement::invalidateInstances()
|
|
|