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

Delta Between Two Patch Sets: devtools-panel.js

Issue 29716584: Issue 6451 - Generate $csp exception filters properly (Closed)
Left Patch Set: Created March 7, 2018, 2:14 p.m.
Right Patch Set: Lowercase the $csp option Created March 7, 2018, 3:10 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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 if (request.type == "POPUP") 44 if (request.type == "POPUP")
45 { 45 {
46 options.push("popup"); 46 options.push("popup");
47 47
48 if (request.url == "about:blank") 48 if (request.url == "about:blank")
49 domainSpecific = true; 49 domainSpecific = true;
50 } 50 }
51 51
52 if (request.type == "CSP") 52 if (request.type == "CSP")
53 options.push("CSP"); 53 options.push("csp");
Thomas Greiner 2018/03/07 14:34:44 Detail: I know that filter options are case insens
kzar 2018/03/07 15:11:40 Done.
54 54
55 if (domainSpecific) 55 if (domainSpecific)
56 options.push("domain=" + request.docDomain); 56 options.push("domain=" + request.docDomain);
57 57
58 if (options.length > 0) 58 if (options.length > 0)
59 filter += "$" + options.join(","); 59 filter += "$" + options.join(",");
60 60
61 return filter; 61 return filter;
62 } 62 }
63 63
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 break; 258 break;
259 } 259 }
260 }); 260 });
261 261
262 // Since Chrome 54 the themeName is accessible, for earlier versions we must 262 // Since Chrome 54 the themeName is accessible, for earlier versions we must
263 // assume the default theme is being used. 263 // assume the default theme is being used.
264 // https://bugs.chromium.org/p/chromium/issues/detail?id=608869 264 // https://bugs.chromium.org/p/chromium/issues/detail?id=608869
265 let theme = browser.devtools.panels.themeName || "default"; 265 let theme = browser.devtools.panels.themeName || "default";
266 document.body.classList.add(theme); 266 document.body.classList.add(theme);
267 }, false); 267 }, false);
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