Commit 599bc36e authored by Sergey Chupligin's avatar Sergey Chupligin

[VolumeControl] fix volume control

parent e2776cf8
...@@ -57,7 +57,26 @@ ProgressBar { ...@@ -57,7 +57,26 @@ ProgressBar {
Connections { Connections {
target: volumeControl target: volumeControl
onVolumeChanged: { onVolumeKeyPressed: {
if(key == Qt.Key_VolumeUp)
{
//up volume
if(volumeControl.volume < maximumValue)
{
volumeControl.volume = volumeControl.volume+1
}
}
else
{
//down volume
if(volumeControl.volume > 0)
{
volumeControl.volume = volumeControl.volume-1
}
}
volumeControl.windowVisible = true
volumeSlider.value = volumeControl.volume volumeSlider.value = volumeControl.volume
if (volumeControl.windowVisible) { if (volumeControl.windowVisible) {
voltimer.restart() voltimer.restart()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment