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

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

Issue 2760793002: Use v8::Context::NewRemoteContext in RemoteWindowProxy. (Closed)
Patch Set: Clean up association logic Created 3 years, 9 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/WindowProxy.cpp
diff --git a/third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp b/third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp
index a92a918d47f38f63458460101620263297259097..761b4a5c50260087de64d90bd90070998e813310 100644
--- a/third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp
+++ b/third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp
@@ -147,4 +147,18 @@ void WindowProxy::initializeIfNeeded() {
}
}
+v8::Local<v8::Object> WindowProxy::associateWithWrapper(
+ DOMWindow* window,
+ const WrapperTypeInfo* wrapperTypeInfo,
+ v8::Local<v8::Object> wrapper) {
+ if (m_world->domDataStore().set(m_isolate, window, wrapperTypeInfo,
+ wrapper)) {
+ wrapperTypeInfo->wrapperCreated();
+ V8DOMWrapper::setNativeInfo(m_isolate, wrapper, wrapperTypeInfo, window);
+ DCHECK(V8DOMWrapper::hasInternalFieldsSet(wrapper));
+ }
+ SECURITY_CHECK(toScriptWrappable(wrapper) == window);
+ return wrapper;
+}
+
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698