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

Unified Diff: Source/bindings/v8/custom/V8MessageEventCustom.cpp

Issue 109473008: Remove custom signatures from V8 bindings (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years 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
« no previous file with comments | « Source/bindings/v8/V8Binding.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/v8/custom/V8MessageEventCustom.cpp
diff --git a/Source/bindings/v8/custom/V8MessageEventCustom.cpp b/Source/bindings/v8/custom/V8MessageEventCustom.cpp
index 9060e643728f40367c20cf7436610219e4f14d20..9db80ecc88ff8a7f9fe108617fa6cd47c26d83ec 100644
--- a/Source/bindings/v8/custom/V8MessageEventCustom.cpp
+++ b/Source/bindings/v8/custom/V8MessageEventCustom.cpp
@@ -106,16 +106,8 @@ void V8MessageEvent::initMessageEventMethodCustom(const v8::FunctionCallbackInfo
v8::Handle<v8::Value> dataArg = info[3];
V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, originArg, info[4]);
V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, lastEventIdArg, info[5]);
-
- DOMWindow* sourceArg = 0;
- if (info[6]->IsObject()) {
- v8::Handle<v8::Object> wrapper = v8::Handle<v8::Object>::Cast(info[6]);
- v8::Handle<v8::Object> window = wrapper->FindInstanceInPrototypeChain(V8Window::domTemplate(info.GetIsolate(), worldTypeInMainThread(info.GetIsolate())));
- if (!window.IsEmpty())
- sourceArg = V8Window::toNative(window);
- }
+ DOMWindow* sourceArg = toNativeDOMWindow(info[6], info.GetIsolate());
OwnPtr<MessagePortArray> portArray;
-
const int portArrayIndex = 7;
if (!isUndefinedOrNull(info[portArrayIndex])) {
portArray = adoptPtr(new MessagePortArray);
« no previous file with comments | « Source/bindings/v8/V8Binding.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698