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

Unified Diff: background.js

Issue 29355222: Issue 4477 - Update adblockpluscore dependency (Closed)
Patch Set: Created Sept. 27, 2016, 3:25 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | dependencies » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: background.js
diff --git a/background.js b/background.js
index 3e2eb08be89145c56ce79fe3ad3d676b8a4655dd..cfc9536c00e1c2d3a57673cbaecff059253279fc 100644
--- a/background.js
+++ b/background.js
@@ -30,13 +30,18 @@ port.on("get-selectors", function(msg, sender)
if (!checkWhitelisted(sender.page, sender.frame,
RegExpFilter.typeMap.DOCUMENT |
RegExpFilter.typeMap.ELEMHIDE))
+ {
+ var specificOnly = checkWhitelisted(sender.page, sender.frame,
+ RegExpFilter.typeMap.GENERICHIDE);
selectors = ElemHide.getSelectorsForDomain(
extractHostFromFrame(sender.frame),
- checkWhitelisted(sender.page, sender.frame,
- RegExpFilter.typeMap.GENERICHIDE)
+ specificOnly ? ElemHide.SPECIFIC_ONLY : ElemHide.ALL_MATCHING
);
+ }
else
+ {
selectors = [];
+ }
return {selectors: selectors, trace: trace};
});
« no previous file with comments | « no previous file | dependencies » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld