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

Side by Side Diff: third_party/WebKit/Source/core/dom/IntersectionObserver.cpp

Issue 1884083002: Revert of Rename Heap to ThreadHeap (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/dom/IntersectionObserver.h" 5 #include "core/dom/IntersectionObserver.h"
6 6
7 #include "bindings/core/v8/ExceptionState.h" 7 #include "bindings/core/v8/ExceptionState.h"
8 #include "core/css/parser/CSSParserTokenRange.h" 8 #include "core/css/parser/CSSParserTokenRange.h"
9 #include "core/css/parser/CSSTokenizer.h" 9 #include "core/css/parser/CSSTokenizer.h"
10 #include "core/dom/Element.h" 10 #include "core/dom/Element.h"
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 default: 147 default:
148 ASSERT_NOT_REACHED(); 148 ASSERT_NOT_REACHED();
149 break; 149 break;
150 } 150 }
151 root.document().ensureIntersectionObserverController().addTrackedObserver(*t his); 151 root.document().ensureIntersectionObserverController().addTrackedObserver(*t his);
152 } 152 }
153 153
154 #if ENABLE(OILPAN) 154 #if ENABLE(OILPAN)
155 void IntersectionObserver::clearWeakMembers(Visitor* visitor) 155 void IntersectionObserver::clearWeakMembers(Visitor* visitor)
156 { 156 {
157 if (ThreadHeap::isHeapObjectAlive(m_root)) 157 if (Heap::isHeapObjectAlive(m_root))
158 return; 158 return;
159 disconnect(); 159 disconnect();
160 m_root = nullptr; 160 m_root = nullptr;
161 } 161 }
162 #endif 162 #endif
163 163
164 LayoutObject* IntersectionObserver::rootLayoutObject() const 164 LayoutObject* IntersectionObserver::rootLayoutObject() const
165 { 165 {
166 Node* node = rootNode(); 166 Node* node = rootNode();
167 if (node->isDocumentNode()) 167 if (node->isDocumentNode())
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 306
307 DEFINE_TRACE(IntersectionObserver) 307 DEFINE_TRACE(IntersectionObserver)
308 { 308 {
309 visitor->template registerWeakMembers<IntersectionObserver, &IntersectionObs erver::clearWeakMembers>(this); 309 visitor->template registerWeakMembers<IntersectionObserver, &IntersectionObs erver::clearWeakMembers>(this);
310 visitor->trace(m_callback); 310 visitor->trace(m_callback);
311 visitor->trace(m_observations); 311 visitor->trace(m_observations);
312 visitor->trace(m_entries); 312 visitor->trace(m_entries);
313 } 313 }
314 314
315 } // namespace blink 315 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/ElementData.cpp ('k') | third_party/WebKit/Source/core/dom/Node.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698