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 778 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
789 { | 789 { |
790 let wnd = Services.wm.getMostRecentWindow("abp:sendReport"); | 790 let wnd = Services.wm.getMostRecentWindow("abp:sendReport"); |
791 if (wnd) | 791 if (wnd) |
792 wnd.focus(); | 792 wnd.focus(); |
793 else | 793 else |
794 { | 794 { |
795 let uri = this.getCurrentLocation(window); | 795 let uri = this.getCurrentLocation(window); |
796 if (uri) | 796 if (uri) |
797 { | 797 { |
798 let {getBrowser} = require("appSupport"); | 798 let {getBrowser} = require("appSupport"); |
799 window.openDialog("chrome://adblockplus/content/ui/sendReport.xul", "_bl
ank", "chrome,centerscreen,resizable=no", getBrowser(window).contentWindow, uri)
; | 799 let browser = getBrowser(window); |
| 800 if ("selectedBrowser" in browser) |
| 801 browser = browser.selectedBrowser; |
| 802 window.openDialog("chrome://adblockplus/content/ui/sendReport.xul", "_bl
ank", "chrome,centerscreen,resizable=no", browser.contentWindow, uri, browser); |
800 } | 803 } |
801 } | 804 } |
802 }, | 805 }, |
803 | 806 |
804 /** | 807 /** |
805 * Opens our contribution page. | 808 * Opens our contribution page. |
806 */ | 809 */ |
807 openContributePage: function(/**Window*/ window) | 810 openContributePage: function(/**Window*/ window) |
808 { | 811 { |
809 this.loadDocLink("contribute", window); | 812 this.loadDocLink("contribute", window); |
(...skipping 1091 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1901 ["abp-command-contribute-hide", "command", UI.hideContributeButton.bind(UI)], | 1904 ["abp-command-contribute-hide", "command", UI.hideContributeButton.bind(UI)], |
1902 ["abp-command-toggleshownotifications", "command", Notification.toggleIgnoreCa
tegory.bind(Notification, "*", null)] | 1905 ["abp-command-toggleshownotifications", "command", Notification.toggleIgnoreCa
tegory.bind(Notification, "*", null)] |
1903 ]; | 1906 ]; |
1904 | 1907 |
1905 onShutdown.add(function() | 1908 onShutdown.add(function() |
1906 { | 1909 { |
1907 for (let window of UI.applicationWindows) | 1910 for (let window of UI.applicationWindows) |
1908 if (UI.isBottombarOpen(window)) | 1911 if (UI.isBottombarOpen(window)) |
1909 UI.toggleBottombar(window); | 1912 UI.toggleBottombar(window); |
1910 }); | 1913 }); |
OLD | NEW |