aboutsummaryrefslogtreecommitdiff
path: root/src/service.vala
diff options
context:
space:
mode:
Diffstat (limited to 'src/service.vala')
-rw-r--r--src/service.vala12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/service.vala b/src/service.vala
index 22cb1c6..c942fc7 100644
--- a/src/service.vala
+++ b/src/service.vala
@@ -285,16 +285,18 @@ public class IndicatorSound.Service: Object {
if (!support_sync_notification)
return;
- /* Suppress notifications of volume changes if it is because the
- output stream changed. */
+ /* Update our volume and output */
var oldoutput = this.last_output_notification;
this.last_output_notification = this.volume_control.stream;
- if (oldoutput != this.last_output_notification)
- return;
- /* Supress updates that don't change the value */
var oldvolume = this.last_volume_notification;
this.last_volume_notification = volume_control.volume;
+
+ /* Suppress notifications of volume changes if it is because the
+ output stream changed. */
+ if (oldoutput != this.last_output_notification)
+ return;
+ /* Supress updates that don't change the value */
if (oldvolume == this.last_volume_notification)
return;