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

Unified Diff: Source/bindings/core/v8/custom/V8InjectedScriptManager.cpp

Issue 307943002: Oilpan: Prepare moving InspectorController and InspectorAgents to oilpan. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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: Source/bindings/core/v8/custom/V8InjectedScriptManager.cpp
diff --git a/Source/bindings/core/v8/custom/V8InjectedScriptManager.cpp b/Source/bindings/core/v8/custom/V8InjectedScriptManager.cpp
index d38626e2f8fd73d36d311476e2318e39767f3a6e..108d55d929158814f901849dbe299ef2ed657544 100644
--- a/Source/bindings/core/v8/custom/V8InjectedScriptManager.cpp
+++ b/Source/bindings/core/v8/custom/V8InjectedScriptManager.cpp
@@ -48,7 +48,7 @@ namespace WebCore {
struct InjectedScriptManager::CallbackData {
ScopedPersistent<v8::Object> handle;
- RefPtr<InjectedScriptHost> host;
+ RefPtrWillBePersistent<InjectedScriptHost> host;
};
static v8::Local<v8::Object> createInjectedScriptHostV8Wrapper(InjectedScriptHost* host, v8::Isolate* isolate)
@@ -63,7 +63,11 @@ static v8::Local<v8::Object> createInjectedScriptHostV8Wrapper(InjectedScriptHos
// Avoid setting the wrapper if allocation failed.
return v8::Local<v8::Object>();
}
+#if ENABLE(OILPAN)
+ V8DOMWrapper::setNativeInfoWithPersistentHandle(instanceTemplate, &V8InjectedScriptHost::wrapperTypeInfo, host, new Persistent<InjectedScriptHost>(host));
+#else
V8DOMWrapper::setNativeInfo(instanceTemplate, &V8InjectedScriptHost::wrapperTypeInfo, host);
+#endif
// Create a weak reference to the v8 wrapper of InspectorBackend to deref
// InspectorBackend when the wrapper is garbage collected.
InjectedScriptManager::CallbackData* data = new InjectedScriptManager::CallbackData;
« no previous file with comments | « no previous file | Source/core/inspector/CodeGeneratorInstrumentation.py » ('j') | Source/core/inspector/InspectorTimelineAgent.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698