Commit 6cbaaa1a authored by Nicolas Fella's avatar Nicolas Fella
Browse files

[app/mpris] Use property binding

parent cefe6eec
Pipeline #27456 passed with stage
in 5 minutes and 30 seconds
......@@ -56,7 +56,6 @@ Kirigami.Page
{
muted = !muted
root.pluginInterface.volume = muted ? 0 : volumeUnmuted
muteButton.icon.name = muted ? "audio-volume-muted" : soundState(root.pluginInterface.volume)
}
function msToTime(currentTime, totalTime)
......@@ -163,7 +162,7 @@ Kirigami.Page
Layout.fillWidth: true
Button {
id: muteButton
icon.name: soundState(root.pluginInterface.volume)
icon.name: muted ? "audio-volume-muted" : soundState(root.pluginInterface.volume)
onClicked: toggleMute()
}
Slider {
......@@ -175,7 +174,6 @@ Kirigami.Page
onValueChanged: {
volumeUnmuted = value
root.pluginInterface.volume = value
muteButton.icon.name = soundState(root.pluginInterface.volume)
}
}
}
......
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