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

Delta Between Two Patch Sets: new-options.js

Issue 29558637: Issue 5806 - Acceptable ads being added to the UI on load (Closed)
Left Patch Set: Created Sept. 28, 2017, 5:03 p.m.
Right Patch Set: Created Sept. 28, 2017, 5:20 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « no previous file | no next file » | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
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-present eyeo GmbH 3 * Copyright (C) 2006-present 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 864 matching lines...) Expand 10 before | Expand all | Expand 10 after
875 E("whitelisting-textbox").setAttribute("placeholder", exampleValue); 875 E("whitelisting-textbox").setAttribute("placeholder", exampleValue);
876 E("whitelisting-textbox").addEventListener("keyup", (e) => 876 E("whitelisting-textbox").addEventListener("keyup", (e) =>
877 { 877 {
878 E("whitelisting-add-button").disabled = !e.target.value; 878 E("whitelisting-add-button").disabled = !e.target.value;
879 }, false); 879 }, false);
880 880
881 getDocLink("contribute", (link) => 881 getDocLink("contribute", (link) =>
882 { 882 {
883 E("contribute").href = link; 883 E("contribute").href = link;
884 }); 884 });
885
886 // General tab
887 setAcceptableAds();
888 getDocLink("acceptable_ads_criteria", (link) => 885 getDocLink("acceptable_ads_criteria", (link) =>
889 { 886 {
890 setLinks("enable-aa-description", link); 887 setLinks("enable-aa-description", link);
891 }); 888 });
892 getDocLink("adblock_plus_{browser}_dnt", url => 889 getDocLink("adblock_plus_{browser}_dnt", url =>
893 { 890 {
894 setLinks("dnt", url); 891 setLinks("dnt", url);
895 }); 892 });
896 893
897 // Advanced tab 894 // Advanced tab
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
1118 1115
1119 // Load user subscriptions 1116 // Load user subscriptions
1120 ext.backgroundPage.sendMessage({ 1117 ext.backgroundPage.sendMessage({
1121 type: "subscriptions.get", 1118 type: "subscriptions.get",
1122 downloadable: true 1119 downloadable: true
1123 }, 1120 },
1124 (subscriptions) => 1121 (subscriptions) =>
1125 { 1122 {
1126 for (let subscription of subscriptions) 1123 for (let subscription of subscriptions)
1127 onSubscriptionMessage("added", subscription); 1124 onSubscriptionMessage("added", subscription);
1125
1126 setAcceptableAds();
1128 }); 1127 });
1129 }); 1128 });
1130 }); 1129 });
1131 } 1130 }
1132 1131
1133 function addWhitelistedDomain() 1132 function addWhitelistedDomain()
1134 { 1133 {
1135 let domain = E("whitelisting-textbox"); 1134 let domain = E("whitelisting-textbox");
1136 for (let whitelistItem of collections.whitelist.items) 1135 for (let whitelistItem of collections.whitelist.items)
1137 { 1136 {
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
1404 }); 1403 });
1405 ext.backgroundPage.sendMessage({ 1404 ext.backgroundPage.sendMessage({
1406 type: "subscriptions.listen", 1405 type: "subscriptions.listen",
1407 filter: ["added", "disabled", "homepage", "lastDownload", "removed", 1406 filter: ["added", "disabled", "homepage", "lastDownload", "removed",
1408 "title", "downloadStatus", "downloading"] 1407 "title", "downloadStatus", "downloading"]
1409 }); 1408 });
1410 1409
1411 window.addEventListener("DOMContentLoaded", onDOMLoaded, false); 1410 window.addEventListener("DOMContentLoaded", onDOMLoaded, false);
1412 window.addEventListener("hashchange", onHashChange, false); 1411 window.addEventListener("hashchange", onHashChange, false);
1413 } 1412 }
LEFTRIGHT
« no previous file | no next file » | Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Toggle Comments ('s')

Powered by Google App Engine
This is Rietveld