OLD | NEW |
1 /* | 1 /* |
2 * This file is part of Adblock Plus <http://adblockplus.org/>, | 2 * This file is part of Adblock Plus <http://adblockplus.org/>, |
3 * Copyright (C) 2006-2014 Eyeo GmbH | 3 * Copyright (C) 2006-2014 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 29 matching lines...) Expand all Loading... |
40 }; | 40 }; |
41 | 41 |
42 this.browserAction = new BrowserAction(this); | 42 this.browserAction = new BrowserAction(this); |
43 this.contextMenus = new ContextMenus(this); | 43 this.contextMenus = new ContextMenus(this); |
44 }; | 44 }; |
45 Page.prototype = { | 45 Page.prototype = { |
46 get url() | 46 get url() |
47 { | 47 { |
48 return this._frames[0].url; | 48 return this._frames[0].url; |
49 }, | 49 }, |
| 50 equals: function(page) |
| 51 { |
| 52 return this._id == page._id; |
| 53 }, |
50 activate: function() | 54 activate: function() |
51 { | 55 { |
52 this._tab.activate(); | 56 this._tab.activate(); |
53 }, | 57 }, |
54 sendMessage: function(message, responseCallback) | 58 sendMessage: function(message, responseCallback) |
55 { | 59 { |
56 this._messageProxy.sendMessage(message, responseCallback, {pageId: this._i
d}); | 60 this._messageProxy.sendMessage(message, responseCallback, {pageId: this._i
d}); |
57 } | 61 } |
58 }; | 62 }; |
59 | 63 |
(...skipping 611 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
671 page.activate(); | 675 page.activate(); |
672 if (callback) | 676 if (callback) |
673 callback(page); | 677 callback(page); |
674 return; | 678 return; |
675 } | 679 } |
676 } | 680 } |
677 | 681 |
678 ext.pages.open(optionsUrl, callback); | 682 ext.pages.open(optionsUrl, callback); |
679 }; | 683 }; |
680 })(); | 684 })(); |
OLD | NEW |