aboutsummaryrefslogtreecommitdiff
path: root/src/volume-control.vala
diff options
context:
space:
mode:
Diffstat (limited to 'src/volume-control.vala')
-rw-r--r--src/volume-control.vala7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/volume-control.vala b/src/volume-control.vala
index 20450ca..5a8bbe2 100644
--- a/src/volume-control.vala
+++ b/src/volume-control.vala
@@ -175,9 +175,9 @@ public class VolumeControl : Object
}
if (_pulse_use_stream_restore == false &&
- _volume != volume_to_double (i.volume.values[0]))
+ _volume != volume_to_double (i.volume.max ()))
{
- _volume = volume_to_double (i.volume.values[0]);
+ _volume = volume_to_double (i.volume.max ());
volume_changed (_volume);
}
}
@@ -512,7 +512,8 @@ public class VolumeControl : Object
if (i == null)
return;
- unowned CVolume cvol = vol_set (i.volume, 1, double_to_volume (_volume));
+ unowned CVolume cvol = i.volume;
+ cvol.scale (double_to_volume (_volume));
c.set_sink_volume_by_index (i.index, cvol, set_volume_success_cb);
}