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

Unified Diff: third_party/WebKit/Source/core/dom/IntersectionObserverController.cpp

Issue 2553343004: IntersectionObserver: use nullptr for implicit root. (Closed)
Patch Set: rebase Created 4 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/dom/IntersectionObserverController.cpp
diff --git a/third_party/WebKit/Source/core/dom/IntersectionObserverController.cpp b/third_party/WebKit/Source/core/dom/IntersectionObserverController.cpp
index d0888bc33b42b649732eea215d9a7386cf034955..b7550390b78fb00a758f10e1cbd841007c2c6b02 100644
--- a/third_party/WebKit/Source/core/dom/IntersectionObserverController.cpp
+++ b/third_party/WebKit/Source/core/dom/IntersectionObserverController.cpp
@@ -5,6 +5,7 @@
#include "core/dom/IntersectionObserverController.h"
#include "core/dom/Document.h"
+#include "core/dom/Element.h"
#include "core/dom/TaskRunnerHelper.h"
#include "platform/tracing/TraceEvent.h"
@@ -86,7 +87,7 @@ void IntersectionObserverController::removeTrackedObserversForRoot(
const Node& root) {
HeapVector<Member<IntersectionObserver>> toRemove;
for (auto& observer : m_trackedIntersectionObservers) {
- if (observer->rootNode() == &root)
+ if (observer->root() == &root)
toRemove.append(observer);
}
m_trackedIntersectionObservers.removeAll(toRemove);

Powered by Google App Engine
This is Rietveld 408576698