From 7ec03b8946e4a28e2fc18ce413d012310f9d7532 Mon Sep 17 00:00:00 2001 From: Beau Hastings Date: Thu, 6 May 2021 08:47:55 +0800 Subject: [PATCH] omit progress bar hint when drawing own progress bar (-p) see #31 Signed-off-by: Beau Hastings --- volume | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/volume b/volume index c3543e2..4593733 100755 --- a/volume +++ b/volume @@ -149,13 +149,17 @@ define_notify() { -t "$EXPIRES" ) local -a hints=( - int:value:"$vol" # Replaces previous notification in some notification servers string:synchronous:volume # Replaces previous notification in NotifyOSD string:x-canonical-private-synchronous:volume ) + # If we're not drawing our own progress bar, allow the notification daemon to draw its own (if supported) + if ! $SHOW_VOLUME_PROGRESS; then + hints+=(int:value:"$vol") + fi + (( ${#NOTIFY_CAPS[@]} < 1 )) && load_notify_server_caps if has_capability icon-static; then