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

Unified Diff: third_party/WebKit/Source/bindings/scripts/v8_attributes.py

Issue 2449103002: binding: Makes event listener attributes use the relevant realm. (Closed)
Patch Set: Created 4 years, 2 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/scripts/v8_attributes.py
diff --git a/third_party/WebKit/Source/bindings/scripts/v8_attributes.py b/third_party/WebKit/Source/bindings/scripts/v8_attributes.py
index 2f0f27665031708fd2a7c25ff3a05e9fc7bd0a57..d28bb73b68382f9b7faf5127494a391d5881177a 100644
--- a/third_party/WebKit/Source/bindings/scripts/v8_attributes.py
+++ b/third_party/WebKit/Source/bindings/scripts/v8_attributes.py
@@ -458,9 +458,14 @@ def setter_expression(interface, attribute, context):
if (interface.name in ['Window', 'WorkerGlobalScope'] and
attribute.name == 'onerror'):
includes.add('bindings/core/v8/V8ErrorHandler.h')
- arguments.append('V8EventListenerHelper::ensureEventListener<V8ErrorHandler>(v8Value, true, ScriptState::current(info.GetIsolate()))')
+ arguments.append(
+ 'V8EventListenerHelper::ensureEventListener<V8ErrorHandler>(' +
+ 'v8Value, true, ScriptState::forReceiverObject(info))')
else:
- arguments.append('V8EventListenerHelper::getEventListener(ScriptState::current(info.GetIsolate()), v8Value, true, ListenerFindOrCreate)')
+ arguments.append(
+ 'V8EventListenerHelper::getEventListener(' +
+ 'ScriptState::forReceiverObject(info), v8Value, true, ' +
+ 'ListenerFindOrCreate)')
else:
arguments.append('cppValue')
if context['is_setter_raises_exception']:

Powered by Google App Engine
This is Rietveld 408576698