Index: background.js |
=================================================================== |
--- a/background.js |
+++ b/background.js |
@@ -146,13 +146,33 @@ |
{ |
this.text = text; |
this.disabled = false; |
- } |
+ }, |
+ WhitelistFilter: function() {} |
}; |
modules.filterClasses.Filter.fromText = function(text) |
{ |
return new modules.filterClasses.Filter(text); |
}; |
+ modules.filterValidation = |
+ { |
+ parseFilter: function(text) |
+ { |
+ return {filter: modules.filterClasses.Filter.fromText(text)}; |
+ }, |
+ parseFilters: function(text) |
+ { |
+ var lines = text.split("\n"); |
+ var filters = []; |
+ var errors = []; |
+ |
+ for (var i = 0; i < lines.length; i++) |
+ filters.push(modules.filterValidation.parseFilter(lines[i]).filter); |
+ |
+ return {filters: filters, errors: errors}; |
+ } |
+ }; |
+ |
modules.synchronizer = { |
Synchronizer: {} |
}; |
@@ -221,9 +241,26 @@ |
"@@||alternate.de^$document", |
"@@||der.postillion.com^$document", |
"@@||taz.de^$document", |
- "@@||amazon.de^$document" |
+ "@@||amazon.de^$document", |
+ "||biglemon.am/bg_poster/banner.jpg", |
+ "winfuture.de###header_logo_link", |
+ "###WerbungObenRechts10_GesamtDIV", |
+ "###WerbungObenRechts8_GesamtDIV", |
+ "###WerbungObenRechts9_GesamtDIV", |
+ "###WerbungUntenLinks4_GesamtDIV", |
+ "###WerbungUntenLinks7_GesamtDIV", |
+ "###WerbungUntenLinks8_GesamtDIV", |
+ "###WerbungUntenLinks9_GesamtDIV", |
+ "###Werbung_Sky", |
+ "###Werbung_Wide", |
+ "###__ligatus_placeholder__", |
+ "###ad-bereich1-08", |
+ "###ad-bereich1-superbanner", |
+ "###ad-bereich2-08", |
+ "###ad-bereich2-skyscrapper" |
]; |
var knownFilters = filters.map(modules.filterClasses.Filter.fromText); |
+ global.WhitelistFilter = modules.filterClasses.WhitelistFilter; |
Thomas Greiner
2015/06/30 09:23:26
This does not need to be in the global namespace.
saroyanm
2015/07/08 18:25:38
Done.
|
var subscriptions = [ |
"https://easylist-downloads.adblockplus.org/easylistgermany+easylist.txt", |