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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/DOMDataStore.h

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/DOMDataStore.h
diff --git a/third_party/WebKit/Source/bindings/core/v8/DOMDataStore.h b/third_party/WebKit/Source/bindings/core/v8/DOMDataStore.h
index 03d903065415b8d46156e68f9e01e0d5b8b46332..2af77e2c3981fdbf59a012d9ecf06d2f8851ea31 100644
--- a/third_party/WebKit/Source/bindings/core/v8/DOMDataStore.h
+++ b/third_party/WebKit/Source/bindings/core/v8/DOMDataStore.h
@@ -120,6 +120,17 @@ class DOMDataStore {
return m_wrapperMap->newLocal(isolate, object);
}
+ WARN_UNUSED_RESULT bool set(v8::Isolate* isolate,
+ ScriptWrappable* object,
+ const WrapperTypeInfo* wrapperTypeInfo,
+ v8::Local<v8::Object>& wrapper) {
+ DCHECK(object);
+ DCHECK(!wrapper.IsEmpty());
+ if (m_isMainWorld)
+ return object->setWrapper(isolate, wrapperTypeInfo, wrapper);
+ return m_wrapperMap->set(object, wrapperTypeInfo, wrapper);
+ }
+
void markWrapper(ScriptWrappable* scriptWrappable) {
m_wrapperMap->markWrapper(scriptWrappable);
}
@@ -138,17 +149,6 @@ class DOMDataStore {
}
private:
- WARN_UNUSED_RESULT bool set(v8::Isolate* isolate,
- ScriptWrappable* object,
- const WrapperTypeInfo* wrapperTypeInfo,
- v8::Local<v8::Object>& wrapper) {
- ASSERT(object);
- ASSERT(!wrapper.IsEmpty());
- if (m_isMainWorld)
- return object->setWrapper(isolate, wrapperTypeInfo, wrapper);
- return m_wrapperMap->set(object, wrapperTypeInfo, wrapper);
- }
-
// We can use a wrapper stored in a ScriptWrappable when we're in the main
// world. This method does the fast check if we're in the main world. If this
// method returns true, it is guaranteed that we're in the main world. On the

Powered by Google App Engine
This is Rietveld 408576698