OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Nikolas Zimmermann <zimmermann@kde
.org> | 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Nikolas Zimmermann <zimmermann@kde
.org> |
3 * Copyright (C) 2004, 2005, 2006, 2008 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005, 2006, 2008 Rob Buis <buis@kde.org> |
4 * Copyright (C) 2008 Apple Inc. All rights reserved. | 4 * Copyright (C) 2008 Apple Inc. All rights reserved. |
5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> | 5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> |
6 * Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au> | 6 * Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au> |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
411 void SVGElement::invalidateRelativeLengthClients(SubtreeLayoutScope* layoutScope
) | 411 void SVGElement::invalidateRelativeLengthClients(SubtreeLayoutScope* layoutScope
) |
412 { | 412 { |
413 if (!inDocument()) | 413 if (!inDocument()) |
414 return; | 414 return; |
415 | 415 |
416 ASSERT(!m_inRelativeLengthClientsInvalidation); | 416 ASSERT(!m_inRelativeLengthClientsInvalidation); |
417 #if ENABLE(ASSERT) | 417 #if ENABLE(ASSERT) |
418 TemporaryChange<bool> inRelativeLengthClientsInvalidationChange(m_inRelative
LengthClientsInvalidation, true); | 418 TemporaryChange<bool> inRelativeLengthClientsInvalidationChange(m_inRelative
LengthClientsInvalidation, true); |
419 #endif | 419 #endif |
420 | 420 |
421 LayoutObject* layoutObject = this->layoutObject(); | 421 if (LayoutObject* layoutObject = this->layoutObject()) { |
422 if (layoutObject && selfHasRelativeLengths()) { | 422 if (hasRelativeLengths() && layoutObject->isSVGResourceContainer()) |
423 if (layoutObject->isSVGResourceContainer()) | |
424 toLayoutSVGResourceContainer(layoutObject)->invalidateCacheAndMarkFo
rLayout(layoutScope); | 423 toLayoutSVGResourceContainer(layoutObject)->invalidateCacheAndMarkFo
rLayout(layoutScope); |
425 else | 424 else if (selfHasRelativeLengths()) |
426 layoutObject->setNeedsLayoutAndFullPaintInvalidation(LayoutInvalidat
ionReason::Unknown, MarkContainerChain, layoutScope); | 425 layoutObject->setNeedsLayoutAndFullPaintInvalidation(LayoutInvalidat
ionReason::Unknown, MarkContainerChain, layoutScope); |
427 } | 426 } |
428 | 427 |
429 for (SVGElement* element : m_elementsWithRelativeLengths) { | 428 for (SVGElement* element : m_elementsWithRelativeLengths) { |
430 if (element != this) | 429 if (element != this) |
431 element->invalidateRelativeLengthClients(layoutScope); | 430 element->invalidateRelativeLengthClients(layoutScope); |
432 } | 431 } |
433 } | 432 } |
434 | 433 |
435 SVGSVGElement* SVGElement::ownerSVGElement() const | 434 SVGSVGElement* SVGElement::ownerSVGElement() const |
(...skipping 748 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1184 Element::trace(visitor); | 1183 Element::trace(visitor); |
1185 } | 1184 } |
1186 | 1185 |
1187 const AtomicString& SVGElement::eventParameterName() | 1186 const AtomicString& SVGElement::eventParameterName() |
1188 { | 1187 { |
1189 DEFINE_STATIC_LOCAL(const AtomicString, evtString, ("evt", AtomicString::Con
structFromLiteral)); | 1188 DEFINE_STATIC_LOCAL(const AtomicString, evtString, ("evt", AtomicString::Con
structFromLiteral)); |
1190 return evtString; | 1189 return evtString; |
1191 } | 1190 } |
1192 | 1191 |
1193 } // namespace blink | 1192 } // namespace blink |
OLD | NEW |