| OLD | NEW |
| 1 /* | 1 /* |
| 2 * This file is part of Adblock Plus <https://adblockplus.org/>, | 2 * This file is part of Adblock Plus <https://adblockplus.org/>, |
| 3 * Copyright (C) 2006-2015 Eyeo GmbH | 3 * Copyright (C) 2006-2015 Eyeo GmbH |
| 4 * | 4 * |
| 5 * Adblock Plus is free software: you can redistribute it and/or modify | 5 * Adblock Plus is free software: you can redistribute it and/or modify |
| 6 * it under the terms of the GNU General Public License version 3 as | 6 * it under the terms of the GNU General Public License version 3 as |
| 7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
| 8 * | 8 * |
| 9 * Adblock Plus is distributed in the hope that it will be useful, | 9 * Adblock Plus is distributed in the hope that it will be useful, |
| 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| (...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 292 | 292 |
| 293 | 293 |
| 294 /* Web requests */ | 294 /* Web requests */ |
| 295 | 295 |
| 296 ext.webRequest = { | 296 ext.webRequest = { |
| 297 onBeforeRequest: new ext._EventTarget(), | 297 onBeforeRequest: new ext._EventTarget(), |
| 298 handlerBehaviorChanged: function() {} | 298 handlerBehaviorChanged: function() {} |
| 299 }; | 299 }; |
| 300 | 300 |
| 301 | 301 |
| 302 /* Background page */ | |
| 303 | |
| 304 ext.backgroundPage = { | |
| 305 getWindow: function() | |
| 306 { | |
| 307 return window; | |
| 308 } | |
| 309 }; | |
| 310 | |
| 311 | |
| 312 /* Background page proxy (for access from content scripts) */ | 302 /* Background page proxy (for access from content scripts) */ |
| 313 | 303 |
| 314 var backgroundPageProxy = { | 304 var backgroundPageProxy = { |
| 315 cache: new ext.PageMap(), | 305 cache: new ext.PageMap(), |
| 316 | 306 |
| 317 registerObject: function(obj, objects) | 307 registerObject: function(obj, objects) |
| 318 { | 308 { |
| 319 var objectId = objects.indexOf(obj); | 309 var objectId = objects.indexOf(obj); |
| 320 | 310 |
| 321 if (objectId == -1) | 311 if (objectId == -1) |
| (...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 675 tab.activate(); | 665 tab.activate(); |
| 676 if (callback) | 666 if (callback) |
| 677 callback(page); | 667 callback(page); |
| 678 return; | 668 return; |
| 679 } | 669 } |
| 680 } | 670 } |
| 681 | 671 |
| 682 ext.pages.open(optionsUrl, callback); | 672 ext.pages.open(optionsUrl, callback); |
| 683 }; | 673 }; |
| 684 })(); | 674 })(); |
| OLD | NEW |