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

Side by Side Diff: extensions/renderer/resources/guest_view/guest_view_events.js

Issue 2912883004: [Extensions Bindings] Don't allow `event` module with native bindings (Closed)
Patch Set: lazyboy's Created 3 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Event management for GuestViewContainers. 5 // Event management for GuestViewContainers.
6 6
7 var EventBindings = require('event_bindings');
8 var GuestViewInternalNatives = requireNative('guest_view_internal'); 7 var GuestViewInternalNatives = requireNative('guest_view_internal');
9 var MessagingNatives = requireNative('messaging_natives'); 8 var MessagingNatives = requireNative('messaging_natives');
10 9
11 var EventBindings; 10 var EventBindings;
12 var CreateEvent = function(name) { 11 var CreateEvent = function(name) {
13 if (bindingUtil) { 12 if (bindingUtil) {
14 return bindingUtil.createCustomEvent(name, null, 13 return bindingUtil.createCustomEvent(name, null,
15 true /* supportsFilters */); 14 true /* supportsFilters */);
16 } 15 }
17 var eventOpts = {supportsListeners: true, supportsFilters: true}; 16 var eventOpts = {supportsListeners: true, supportsFilters: true};
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 return $Function.apply(func, view.events, $Array.slice(arguments)); 182 return $Function.apply(func, view.events, $Array.slice(arguments));
184 }; 183 };
185 }; 184 };
186 185
187 // Implemented by the derived event manager, if one exists. 186 // Implemented by the derived event manager, if one exists.
188 GuestViewEvents.prototype.getEvents = function() { return {}; }; 187 GuestViewEvents.prototype.getEvents = function() { return {}; };
189 188
190 // Exports. 189 // Exports.
191 exports.$set('GuestViewEvents', GuestViewEvents); 190 exports.$set('GuestViewEvents', GuestViewEvents);
192 exports.$set('CreateEvent', CreateEvent); 191 exports.$set('CreateEvent', CreateEvent);
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698