From 595359afa5756f0871b19e7ffa7b2a462b75b05b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Thu, 22 Oct 2020 20:11:14 +0200 Subject: [PATCH] messageTray: Default to generic policy How and if notifications are shown is controlled by NotificationPolicy objects. But ever since 098bd45, only notification daemon sources or notifications associated with an app are hooked up to GSettings. The hardcoded default policy for built-in notifications (including those provided by extensions) arguably made sense back then, but now that the main setting has been rebranded as "Do Not Disturb" and is exposed prominently in the calendar drop-down, following GSettings is a better default. https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3291 Part-of: --- js/ui/messageTray.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js index 7aac503ec..546079f9b 100644 --- a/js/ui/messageTray.js +++ b/js/ui/messageTray.js @@ -134,6 +134,7 @@ var FocusGrabber = class FocusGrabber { // // A notification without a policy object will inherit the default one. var NotificationPolicy = GObject.registerClass({ + GTypeFlags: GObject.TypeFlags.ABSTRACT, Properties: { 'enable': GObject.ParamSpec.boolean( 'enable', 'enable', 'enable', GObject.ParamFlags.READABLE, true), @@ -718,7 +719,7 @@ var Source = GObject.registerClass({ } _createPolicy() { - return new NotificationPolicy(); + return new NotificationGenericPolicy(); } get narrowestPrivacyScope() {