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

Unified Diff: Source/core/dom/VisitedLinkState.cpp

Issue 65303008: Have ElementTraversal::firstWithin() take a reference (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 7 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/dom/TreeScope.cpp ('k') | Source/core/dom/shadow/ElementShadow.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/VisitedLinkState.cpp
diff --git a/Source/core/dom/VisitedLinkState.cpp b/Source/core/dom/VisitedLinkState.cpp
index e49512a85b112893d995f9b879729394d651c8d6..f715a3dfeb9f7d2f1b9ae98d22a22a0118d6167f 100644
--- a/Source/core/dom/VisitedLinkState.cpp
+++ b/Source/core/dom/VisitedLinkState.cpp
@@ -63,7 +63,7 @@ void VisitedLinkState::invalidateStyleForAllLinks()
{
if (m_linksCheckedForVisitedState.isEmpty())
return;
- for (Element* element = ElementTraversal::firstWithin(&m_document); element; element = ElementTraversal::next(*element)) {
+ for (Element* element = ElementTraversal::firstWithin(m_document); element; element = ElementTraversal::next(*element)) {
if (element->isLink())
element->setNeedsStyleRecalc();
}
@@ -73,7 +73,7 @@ void VisitedLinkState::invalidateStyleForLink(LinkHash linkHash)
{
if (!m_linksCheckedForVisitedState.contains(linkHash))
return;
- for (Element* element = ElementTraversal::firstWithin(&m_document); element; element = ElementTraversal::next(*element)) {
+ for (Element* element = ElementTraversal::firstWithin(m_document); element; element = ElementTraversal::next(*element)) {
if (element->isLink() && linkHashForElement(*element) == linkHash)
element->setNeedsStyleRecalc();
}
« no previous file with comments | « Source/core/dom/TreeScope.cpp ('k') | Source/core/dom/shadow/ElementShadow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698