Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: lib/appSupport.js

Issue 6286955629248512: disable acceptable ads from first run page (Closed)
Patch Set: state declaration in runasync function Created May 3, 2014, 7:58 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 898 matching lines...) Expand 10 before | Expand all | Expand 10 after
909 menuItem = window.NativeWindow.menu.add(actionText, iconUrl, toggleWhiteli st.bind(null, window)); 909 menuItem = window.NativeWindow.menu.add(actionText, iconUrl, toggleWhiteli st.bind(null, window));
910 }; 910 };
911 911
912 UI.openSubscriptionDialog = function(window, url, title, mainURL, mainTitle) 912 UI.openSubscriptionDialog = function(window, url, title, mainURL, mainTitle)
913 { 913 {
914 let dialogTitle = this.overlay.attributes.subscriptionDialogTitle; 914 let dialogTitle = this.overlay.attributes.subscriptionDialogTitle;
915 let dialogMessage = this.overlay.attributes.subscriptionDialogMessage.repl ace(/\?1\?/, title).replace(/\?2\?/, url); 915 let dialogMessage = this.overlay.attributes.subscriptionDialogMessage.repl ace(/\?1\?/, title).replace(/\?2\?/, url);
916 if (Utils.confirm(window, dialogMessage, dialogTitle)) 916 if (Utils.confirm(window, dialogMessage, dialogTitle))
917 this.setSubscription(url, title); 917 this.setSubscription(url, title);
918 }; 918 };
919
920 UI.openFiltersDialog = function()
921 {
922 let window = UI.currentWindow;
923 if (!window)
924 return
925
926 let browser = exports.addTab(window, "about:addons").browser;
927 browser.addEventListener("load", function openAddonPrefs(event)
928 {
929 browser.removeEventListener("load", openAddonPrefs, true);
930 Utils.runAsync(function()
931 {
932 let event = new Event("Event");
933 event.initEvent("popstate", true, false);
934 event.state = {id: require("info").addonID};
935 browser._contentWindow.dispatchEvent(event);
936 });
937 }, true);
938 };
919 939
920 break; 940 break;
921 } 941 }
922 } 942 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld