Looking at the qml file (qml/Components/VolumeControl.qml), it seems Qt is now assuming -1 is double by default, which is what is probably causing the issue.
A simple patch to force the value to be an integer fixes the volume up/down when using hw keys, but there are still some other issues with the volume indicator.
Once you manually select a volume value by touching the indicator, the hw key behavor changes (it sends the same dbus message, but the value doesn't move correctly anymore at the volume bar). If you also play a bit with the volume indicator (e.g. changing volume when using the camera app), it can easily get to a point where unity8 stops sending the dbus messages, breaking the indicator.
I noticed that the var type used by dbus changed since we moved to qt5.2 (int->double), which broke volume down:
Before: canonical. indicator. sound serial=178 path=/com/ canonical/ indicator/ sound; interface= org.gtk. Actions; member=Activate
method call sender=:1.20 -> dest=com.
string "volume"
array [
variant int32 -1
]
array [
]
After: canonical. indicator. sound serial=176 path=/com/ canonical/ indicator/ sound; interface= org.gtk. Actions; member=Activate
method call sender=:1.51 -> dest=com.
string "volume"
array [
variant double -1
]
array [
]
Looking at the qml file (qml/Components /VolumeControl. qml), it seems Qt is now assuming -1 is double by default, which is what is probably causing the issue.
A simple patch to force the value to be an integer fixes the volume up/down when using hw keys, but there are still some other issues with the volume indicator.
Once you manually select a volume value by touching the indicator, the hw key behavor changes (it sends the same dbus message, but the value doesn't move correctly anymore at the volume bar). If you also play a bit with the volume indicator (e.g. changing volume when using the camera app), it can easily get to a point where unity8 stops sending the dbus messages, breaking the indicator.
$ bzr diff /VolumeControl. qml' VolumeControl. qml 2013-10-10 03:39:40 +0000 VolumeControl. qml 2014-03-18 20:41:22 +0000
=== modified file 'qml/Components
--- qml/Components/
+++ qml/Components/
@@ -22,6 +22,9 @@
objectName: "volumeControl"
visible: false
+ property int stepUp: 1 nGroup {
+ property int stepDown: -1
+
QDBusActio
id: actionGroup
busType: 1
@@ -32,11 +35,11 @@
}
function volumeUp() { actionObject. activate( 1); actionObject. activate( stepUp) ;
- actionGroup.
+ actionGroup.
}
function volumeDown() { actionObject. activate( -1); actionObject. activate( stepDown) ;
- actionGroup.
+ actionGroup.
}
Component. onCompleted: actionGroup.start()