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 386 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
397 collections.allLangs.removeItem(subscription); | 397 collections.allLangs.removeItem(subscription); |
398 collections.langs.addItems(subscription); | 398 collections.langs.addItems(subscription); |
399 } | 399 } |
400 else | 400 else |
401 { | 401 { |
402 collections.allLangs.addItems(subscription); | 402 collections.allLangs.addItems(subscription); |
403 collections.langs.removeItem(subscription); | 403 collections.langs.removeItem(subscription); |
404 } | 404 } |
405 } | 405 } |
406 } | 406 } |
407 for (var i in collections) | |
408 collections[i].updateItem(subscription); | |
409 } | 407 } |
| 408 |
| 409 for (var name in collections) |
| 410 collections[name].updateItem(subscription); |
410 } | 411 } |
411 | 412 |
412 if (!Object.observe) | 413 if (!Object.observe) |
413 { | 414 { |
414 Object.keys(subscription).forEach(function(property) | 415 Object.keys(subscription).forEach(function(property) |
415 { | 416 { |
416 var value = subscription[property]; | 417 var value = subscription[property]; |
417 Object.defineProperty(subscription, property, | 418 Object.defineProperty(subscription, property, |
418 { | 419 { |
419 get: function() | 420 get: function() |
(...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1163 }); | 1164 }); |
1164 ext.backgroundPage.sendMessage( | 1165 ext.backgroundPage.sendMessage( |
1165 { | 1166 { |
1166 type: "subscriptions.listen", | 1167 type: "subscriptions.listen", |
1167 filter: ["added", "disabled", "homepage", "lastDownload", "removed", | 1168 filter: ["added", "disabled", "homepage", "lastDownload", "removed", |
1168 "title", "downloadStatus", "downloading"] | 1169 "title", "downloadStatus", "downloading"] |
1169 }); | 1170 }); |
1170 | 1171 |
1171 window.addEventListener("DOMContentLoaded", onDOMLoaded, false); | 1172 window.addEventListener("DOMContentLoaded", onDOMLoaded, false); |
1172 })(); | 1173 })(); |
OLD | NEW |