Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(674)

Side by Side Diff: third_party/WebKit/Source/core/svg/SVGCursorElement.cpp

Issue 1488603002: Use LocalStyleChange for element cursor changes in SVG. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed URI paths Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/svg/css/cursor-change-href-expected.txt ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005, 2006, 2008 Nikolas Zimmermann <zimmermann@kde.org> 2 * Copyright (C) 2004, 2005, 2006, 2008 Nikolas Zimmermann <zimmermann@kde.org>
3 * Copyright (C) 2004, 2005, 2006, 2007 Rob Buis <buis@kde.org> 3 * Copyright (C) 2004, 2005, 2006, 2007 Rob Buis <buis@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 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 73
74 void SVGCursorElement::svgAttributeChanged(const QualifiedName& attrName) 74 void SVGCursorElement::svgAttributeChanged(const QualifiedName& attrName)
75 { 75 {
76 if (attrName == SVGNames::xAttr || attrName == SVGNames::yAttr 76 if (attrName == SVGNames::xAttr || attrName == SVGNames::yAttr
77 || SVGTests::isKnownAttribute(attrName) 77 || SVGTests::isKnownAttribute(attrName)
78 || SVGURIReference::isKnownAttribute(attrName)) { 78 || SVGURIReference::isKnownAttribute(attrName)) {
79 SVGElement::InvalidationGuard invalidationGuard(this); 79 SVGElement::InvalidationGuard invalidationGuard(this);
80 80
81 // Any change of a cursor specific attribute triggers this recalc. 81 // Any change of a cursor specific attribute triggers this recalc.
82 for (const auto& client : m_clients) 82 for (const auto& client : m_clients)
83 client->setNeedsStyleRecalc(SubtreeStyleChange, StyleChangeReasonFor Tracing::create(StyleChangeReason::SVGCursor)); 83 client->setNeedsStyleRecalc(LocalStyleChange, StyleChangeReasonForTr acing::create(StyleChangeReason::SVGCursor));
84 84
85 return; 85 return;
86 } 86 }
87 87
88 SVGElement::svgAttributeChanged(attrName); 88 SVGElement::svgAttributeChanged(attrName);
89 } 89 }
90 90
91 DEFINE_TRACE(SVGCursorElement) 91 DEFINE_TRACE(SVGCursorElement)
92 { 92 {
93 #if ENABLE(OILPAN) 93 #if ENABLE(OILPAN)
94 visitor->trace(m_x); 94 visitor->trace(m_x);
95 visitor->trace(m_y); 95 visitor->trace(m_y);
96 visitor->trace(m_clients); 96 visitor->trace(m_clients);
97 #endif 97 #endif
98 SVGElement::trace(visitor); 98 SVGElement::trace(visitor);
99 SVGTests::trace(visitor); 99 SVGTests::trace(visitor);
100 SVGURIReference::trace(visitor); 100 SVGURIReference::trace(visitor);
101 } 101 }
102 102
103 } // namespace blink 103 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/svg/css/cursor-change-href-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698