mate-desktop / mate-notification-daemon

Daemon to display passive pop-up notifications
https://mate-desktop.org
GNU General Public License v2.0
30 stars 26 forks source link

Add a menu item to toggle "do-not-disturb" #166

Closed kbsali closed 3 years ago

kbsali commented 4 years ago

Feature request : add a menu item to toggle "do-not-disturb" instead of having to do this through the settings window.

Expected behaviour

Very often when I'm at work I want to easily & quickly toggle the "do-not-disturb" feature.

Actual behaviour

To do so today, I have to click on the "Settings..." item of the applet to open up the "Indicator Notificatino Settings" windows and then check the "Enable do not disturb" checkbox.

Steps to reproduce the behaviour

MATE general version

1.22

Package version

1.22.1-0ubuntu1

Linux Distribution

Ubuntu-Mate 19.10

Link to downstream report of your Distribution

raveit65 commented 4 years ago

Yeah, a little applet would be nice which would toogle the state For the moment you can add 2 user-defined panel launcher from add-to-panel-menu One with this command gsettings set org.mate.NotificationDaemon do-not-disturb true And another with gsettings set org.mate.NotificationDaemon do-not-disturb false Works fine here.

kbsali commented 4 years ago

thanks for the tips, I did not have the full command in mind yet! :) I have added those 2 launchers, but the bell icon indicator won't update (when enabling "do not disturb" from the settings window, the icon show a "Z"). Is that normal? Any work around ? thanks for you help!

trism commented 4 years ago

indicator-notifications uses a different settings key for do-not-disturb: gsettings set net.launchpad.indicator.notifications do-not-disturb true (which is the app showing the bell icon in ubuntu mate)

kbsali commented 4 years ago

thanks @trism. So executing this in a terminal works as expected gsettings set org.mate.NotificationDaemon do-not-disturb false && gsettings set net.launchpad.indicator.notifications do-not-disturb false gsettings set org.mate.NotificationDaemon do-not-disturb true && gsettings set net.launchpad.indicator.notifications do-not-disturb true

But when pasting those commands in custom launchers it won't do anything (see screenshot)...

2020-02-27_18-57

What am I doing wrong?

raveit65 commented 4 years ago

I am using type application and not application in terminal with the single command gsettings set org.mate.NotificationDaemon do-not-disturb true

trism commented 4 years ago

Settings the net.launchpad.indicator.notifications do-not-disturb key will set the org.mate.NotificationDaemon do-not-disturb key when indicator-notifications is running, so you don't need both. There is a separate key because indicator-notifications doesn't only run on mate.

kbsali commented 4 years ago

perfect, switched to Application and net.launchpad.indicator.notifications do-not-disturb only, it fixes the issue.

The toggle menu item would still make it even easier! :)

thanks guys! :+1: