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-2017 eyeo GmbH | 3 * Copyright (C) 2006-2017 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 640 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
651 if (frame) | 651 if (frame) |
652 return frame.parent || null; | 652 return frame.parent || null; |
653 | 653 |
654 return frames.get(0) || null; | 654 return frames.get(0) || null; |
655 } | 655 } |
656 }; | 656 }; |
657 } | 657 } |
658 | 658 |
659 return ext.onMessage._dispatch( | 659 return ext.onMessage._dispatch( |
660 message, sender, sendResponse | 660 message, sender, sendResponse |
661 ).indexOf(true) != -1; | 661 ).includes(true); |
662 }); | 662 }); |
663 | 663 |
664 | 664 |
665 /* Storage */ | 665 /* Storage */ |
666 | 666 |
667 ext.storage = { | 667 ext.storage = { |
668 get(keys, callback) | 668 get(keys, callback) |
669 { | 669 { |
670 chrome.storage.local.get(keys, callback); | 670 chrome.storage.local.get(keys, callback); |
671 }, | 671 }, |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
758 ext.windows = { | 758 ext.windows = { |
759 create(createData, callback) | 759 create(createData, callback) |
760 { | 760 { |
761 chrome.windows.create(createData, createdWindow => | 761 chrome.windows.create(createData, createdWindow => |
762 { | 762 { |
763 afterTabLoaded(callback)(createdWindow.tabs[0]); | 763 afterTabLoaded(callback)(createdWindow.tabs[0]); |
764 }); | 764 }); |
765 } | 765 } |
766 }; | 766 }; |
767 }()); | 767 }()); |
OLD | NEW |