From ba8f35a9a808048694721b87ce37ffe3c4794710 Mon Sep 17 00:00:00 2001 From: kkapsner Date: Sun, 3 Dec 2017 23:58:54 +0100 Subject: [PATCH] Hide lists --- options/settingsDisplay.js | 52 +++++++++++++++++++------------------- pageAction/pageAction.js | 7 +++-- releaseNotes.txt | 2 +- 3 files changed, 30 insertions(+), 31 deletions(-) diff --git a/options/settingsDisplay.js b/options/settingsDisplay.js index 033f85b..efd96e4 100644 --- a/options/settingsDisplay.js +++ b/options/settingsDisplay.js @@ -13,18 +13,18 @@ { "name": "blockMode" }, - { - "name": "whiteList", - "displayDependencies": { - "blockMode": ["blockReadout", "fakeReadout", "fakeInput", "askReadout", "block", "ask"] - } - }, - { - "name": "blackList", - "displayDependencies": { - "blockMode": ["blockReadout", "fakeReadout", "fakeInput", "askReadout", "ask", "allow"] - } - }, + // { + // "name": "whiteList", + // "displayDependencies": { + // "blockMode": ["blockReadout", "fakeReadout", "fakeInput", "askReadout", "block", "ask"] + // } + // }, + // { + // "name": "blackList", + // "displayDependencies": { + // "blockMode": ["blockReadout", "fakeReadout", "fakeInput", "askReadout", "ask", "allow"] + // } + // }, { "name": "askOnlyOnce", "displayDependencies": { @@ -199,20 +199,20 @@ } ] }, - { - "name": "ignoreList", - "displayDependencies": [ - { - "blockMode": ["fakeReadout", "fakeInput"], - "showNotifications": [true] - }, - { - "blockMode": ["askReadout", "ask"], - "askDenyMode": ["fake"], - "showNotifications": [true] - } - ] - }, + // { + // "name": "ignoreList", + // "displayDependencies": [ + // { + // "blockMode": ["fakeReadout", "fakeInput"], + // "showNotifications": [true] + // }, + // { + // "blockMode": ["askReadout", "ask"], + // "askDenyMode": ["fake"], + // "showNotifications": [true] + // } + // ] + // }, { "name": "showCallingFile", "displayDependencies": { diff --git a/pageAction/pageAction.js b/pageAction/pageAction.js index fc784b1..93f9cd5 100644 --- a/pageAction/pageAction.js +++ b/pageAction/pageAction.js @@ -5,7 +5,6 @@ "use strict"; const settings = require("./settings"); - const lists = require("./lists"); const {parseErrorStack} = require("./callingStack"); const {error, warning, message, notice, verbose, setPrefix: setLogPrefix} = require("./logging"); setLogPrefix("page action script"); @@ -55,7 +54,7 @@ domain ).then(function(domain){ if (domain){ - lists.appendTo("ignore", domain); + settings.set("showNotifications", false, domain); } window.close(); }); @@ -70,7 +69,7 @@ domain ).then(function(domain){ if (domain){ - lists.appendTo("white", domain); + settings.set("blockMode", "allow", domain); } window.close(); }); @@ -105,7 +104,7 @@ "^" + url.href.replace(/([\\+*?[^\]$(){}=!|.])/g, "\\$1") + "$" ).then(function(url){ if (url){ - lists.appendTo("white", url); + settings.set("blockMode", "allow", url); } window.close(); }); diff --git a/releaseNotes.txt b/releaseNotes.txt index 170faa3..d604e6b 100644 --- a/releaseNotes.txt +++ b/releaseNotes.txt @@ -3,7 +3,7 @@ Version 0.4.3: - changes: - - + - hide white, black and ignore list as they can be done with the url specific settings. They are still present and working in the background. new features: - reset settings