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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp

Issue 1966743004: Move tracking of ActiveScriptWrappables to V8PerIsolateData. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: lazy creation of map Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp
diff --git a/third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp b/third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp
index 39e86ef0fc4215c6d09df3b76e6ea7201c9bfefe..d8b07299c39035eedcf7f8ee5f87fc51ea33a437 100644
--- a/third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp
+++ b/third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp
@@ -190,6 +190,8 @@ void V8PerIsolateData::willBeDestroyed(v8::Isolate* isolate)
// Clear any data that may have handles into the heap,
// prior to calling ThreadState::detach().
data->clearEndOfScopeTasks();
+
+ data->m_activeScriptWrappables.clear();
}
// destroy() clear things that should be cleared after ThreadState::detach()
@@ -341,4 +343,12 @@ ThreadDebugger* V8PerIsolateData::threadDebugger()
return m_threadDebugger.get();
}
+void V8PerIsolateData::addActiveScriptWrappable(ActiveScriptWrappable* wrappable)
+{
+ if (!m_activeScriptWrappables)
+ m_activeScriptWrappables = new ActiveScriptWrappableSet();
+
+ m_activeScriptWrappables->add(wrappable);
+}
+
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.h ('k') | third_party/WebKit/Source/platform/heap/ThreadState.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698