From 00ff3526be3255b0a942828119761fe0e70c02b5 Mon Sep 17 00:00:00 2001 From: Lars Uebernickel Date: Tue, 18 Mar 2014 09:51:40 +0100 Subject: Scale volume in notifications when allow-amplified-volume is set --- src/service.vala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/service.vala') diff --git a/src/service.vala b/src/service.vala index 970867f..4c4f6e6 100644 --- a/src/service.vala +++ b/src/service.vala @@ -141,7 +141,7 @@ public class IndicatorSound.Service: Object { icon = "notification-audio-volume-high"; this.notification.update ("indicator-sound", "", icon); - this.notification.set_hint_int32 ("value", ((int32) (100 * v)).clamp (-1, 101)); + this.notification.set_hint_int32 ("value", ((int32) (100 * v / this.max_volume)).clamp (-1, 101)); try { this.notification.show (); } -- cgit v1.2.3