From cc3f8a6da23b68b7aec3c1245f5d67568d6a356f Mon Sep 17 00:00:00 2001 From: tncga Date: Tue, 25 Jun 2019 13:14:04 +0300 Subject: [PATCH] dont show notification when focused --- app/main/assets/js/preload.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/main/assets/js/preload.js b/app/main/assets/js/preload.js index 5cc0d50..e5778eb 100644 --- a/app/main/assets/js/preload.js +++ b/app/main/assets/js/preload.js @@ -66,7 +66,7 @@ global.Notification = function (title, options) { options }) - if (store.get("desktopNotifications")) { + if (store.get("desktopNotifications") && !electron.getCurrentWindow().isFocused()) { notifications.dequeue() const notification = new OldNotification(title, options)