| Index: chrome/renderer/resources/extensions/web_request_custom_bindings.js
|
| diff --git a/chrome/renderer/resources/extensions/web_request_custom_bindings.js b/chrome/renderer/resources/extensions/web_request_custom_bindings.js
|
| index 8699cbff664b6b488355836f0831625a713b01a1..caaaf20b957123252b360ecfd11edb9804648c42 100644
|
| --- a/chrome/renderer/resources/extensions/web_request_custom_bindings.js
|
| +++ b/chrome/renderer/resources/extensions/web_request_custom_bindings.js
|
| @@ -22,13 +22,15 @@ var validate = require('schemaUtils').validate;
|
| // callback, {urls: 'http://*.google.com/*'});
|
| // ^ callback will only be called for onBeforeRequests matching the filter.
|
| function WebRequestEvent(eventName, opt_argSchemas, opt_extraArgSchemas,
|
| - opt_eventOptions) {
|
| + opt_eventOptions, opt_processId, opt_routeId) {
|
| if (typeof eventName != 'string')
|
| throw new Error('chrome.WebRequestEvent requires an event name.');
|
|
|
| this.eventName_ = eventName;
|
| this.argSchemas_ = opt_argSchemas;
|
| this.extraArgSchemas_ = opt_extraArgSchemas;
|
| + this.processId_ = opt_processId ? opt_processId : -1;
|
| + this.routeId_ = opt_routeId ? opt_routeId : -1;
|
| this.subEvents_ = [];
|
| this.eventOptions_ = chromeHidden.parseEventOptions(opt_eventOptions);
|
| if (this.eventOptions_.supportsRules) {
|
| @@ -64,7 +66,8 @@ WebRequestEvent.prototype.addListener =
|
| // subEvent listener.
|
| validate(Array.prototype.slice.call(arguments, 1), this.extraArgSchemas_);
|
| chromeHidden.internalAPIs.webRequestInternal.addEventListener(
|
| - cb, opt_filter, opt_extraInfo, this.eventName_, subEventName);
|
| + cb, opt_filter, opt_extraInfo, this.eventName_, subEventName,
|
| + this.processId_, this.routeId_);
|
|
|
| var subEvent = new chrome.Event(subEventName, this.argSchemas_);
|
| var subEventCallback = cb;
|
| @@ -157,3 +160,5 @@ chromeHidden.registerCustomHook('webRequest', function(api) {
|
| {forIOThread: true});
|
| });
|
| });
|
| +
|
| +exports.webRequestEvent = WebRequestEvent;
|
|
|