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-2016 Eyeo GmbH | 3 * Copyright (C) 2006-2016 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 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
213 BrowserAction.prototype = { | 213 BrowserAction.prototype = { |
214 _applyChanges: function() | 214 _applyChanges: function() |
215 { | 215 { |
216 if ("iconPath" in this._changes) | 216 if ("iconPath" in this._changes) |
217 { | 217 { |
218 chrome.browserAction.setIcon( | 218 chrome.browserAction.setIcon( |
219 { | 219 { |
220 tabId: this._tabId, | 220 tabId: this._tabId, |
221 path: { | 221 path: { |
222 19: this._changes.iconPath.replace("$size", "19"), | 222 19: this._changes.iconPath.replace("$size", "19"), |
223 38: this._changes.iconPath.replace("$size", "38") | 223 20: this._changes.iconPath.replace("$size", "20"), |
| 224 38: this._changes.iconPath.replace("$size", "38"), |
| 225 40: this._changes.iconPath.replace("$size", "40") |
224 } | 226 } |
225 }); | 227 }); |
226 } | 228 } |
227 if ("badgeText" in this._changes) | 229 if ("badgeText" in this._changes) |
228 { | 230 { |
229 chrome.browserAction.setBadgeText( | 231 chrome.browserAction.setBadgeText( |
230 { | 232 { |
231 tabId: this._tabId, | 233 tabId: this._tabId, |
232 text: this._changes.badgeText | 234 text: this._changes.badgeText |
233 }); | 235 }); |
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
618 ext.windows = { | 620 ext.windows = { |
619 create: function(createData, callback) | 621 create: function(createData, callback) |
620 { | 622 { |
621 chrome.windows.create(createData, function(createdWindow) | 623 chrome.windows.create(createData, function(createdWindow) |
622 { | 624 { |
623 afterTabLoaded(callback)(createdWindow.tabs[0]); | 625 afterTabLoaded(callback)(createdWindow.tabs[0]); |
624 }); | 626 }); |
625 } | 627 } |
626 }; | 628 }; |
627 })(); | 629 })(); |
OLD | NEW |