diff --git a/mako/config b/mako/config index 2587d6d..9be34d8 100644 --- a/mako/config +++ b/mako/config @@ -6,3 +6,10 @@ default-timeout=4000 [mode=do-not-disturb] invisible=1 + +# The volume OSD must survive both gamemode effects: DND (which gamemode-session +# turns on) would hide it, and niri draws fullscreen windows above the top layer. +# Listed after [mode=do-not-disturb] so it wins over invisible=1. +[app-name=volume-osd] +invisible=0 +layer=overlay diff --git a/scripts/volume.sh b/scripts/volume.sh index 8e4d9c7..12e26c4 100755 --- a/scripts/volume.sh +++ b/scripts/volume.sh @@ -8,13 +8,15 @@ case "${1:-}" in esac if [ "$(pamixer --get-mute)" = "true" ]; then - notify-send -h string:x-canonical-private-synchronous:volume \ + notify-send -a volume-osd \ + -h string:x-canonical-private-synchronous:volume \ -h int:value:0 \ -t 1500 \ "Muted" else LEVEL=$(pamixer --get-volume) - notify-send -h string:x-canonical-private-synchronous:volume \ + notify-send -a volume-osd \ + -h string:x-canonical-private-synchronous:volume \ -h int:value:"$LEVEL" \ -t 1500 \ "Volume: ${LEVEL}%"