From 1aa0e5567d2185f57fccd936b13d1bf3cea30a34 Mon Sep 17 00:00:00 2001
From: varjolintu
Date: Wed, 7 Mar 2018 07:04:26 +0200
Subject: [PATCH] Add a new option showLoginNotifications
---
keepassxc-browser/background/browserAction.js | 2 +-
keepassxc-browser/background/page.js | 6 +++++-
keepassxc-browser/options/options.html | 7 ++++++-
3 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/keepassxc-browser/background/browserAction.js b/keepassxc-browser/background/browserAction.js
index 7b72292..d2fdb7d 100755
--- a/keepassxc-browser/background/browserAction.js
+++ b/keepassxc-browser/background/browserAction.js
@@ -239,7 +239,7 @@ browserAction.setRememberPopup = function(tabId, username, password, url, userna
browserAction.show(null, {'id': id});
- if (page.settings.showNotifications) {
+ if (page.settings.showLoginNotifications) {
showNotification('Create or modify the credentials by clicking on the extension icon.');
}
});
diff --git a/keepassxc-browser/background/page.js b/keepassxc-browser/background/page.js
index f82b2ea..ab7bd27 100755
--- a/keepassxc-browser/background/page.js
+++ b/keepassxc-browser/background/page.js
@@ -5,7 +5,8 @@ const defaultSettings = {
usePasswordGenerator: true,
autoFillSingleEntry: false,
autoRetrieveCredentials: true,
- showNotifications: true
+ showNotifications: true,
+ showLoginNotifications: true
};
var page = {};
@@ -38,6 +39,9 @@ page.initSettings = function() {
if (!('showNotifications' in page.settings)) {
page.settings.showNotifications = defaultSettings.showNotifications;
}
+ if (!('showLoginNotifications' in page.settings)) {
+ page.settings.showLoginNotifications = defaultSettings.showLoginNotifications;
+ }
browser.storage.local.set({'settings': page.settings});
resolve(page.settings);
});
diff --git a/keepassxc-browser/options/options.html b/keepassxc-browser/options/options.html
index 4184bee..55e060f 100644
--- a/keepassxc-browser/options/options.html
+++ b/keepassxc-browser/options/options.html
@@ -130,7 +130,12 @@
- Allow KeePassXC-Browser to show notifications when user interaction is needed from the extension icon.
+ Show notifications for errors and when user interaction is required.
+
+
+