1
0
Fork 0
mirror of https://github.com/HenkKalkwater/harbour-sailfin.git synced 2025-09-05 18:22:46 +00:00

Move playback logic to C++ side

This commit is contained in:
Chris Josten 2021-02-14 00:21:49 +01:00
parent 5ddd5e8e2e
commit a244c27b1a
8 changed files with 147 additions and 84 deletions

View file

@ -26,7 +26,7 @@ Column {
property real playProgress: 0.0
property bool favourited: false
property alias imageBlurhash: playImage.blurhash
signal playPressed(bool startFromBeginning)
signal playPressed(bool resume)
spacing: Theme.paddingLarge
BackgroundItem {
@ -57,7 +57,7 @@ Column {
color: Theme.highlightColor
width: parent.width * playProgress
}
onClicked: playPressed(false)
onClicked: playPressed(true)
}
Row {
anchors {
@ -71,7 +71,7 @@ Column {
id: playFromBeginning
icon.source: "image://theme/icon-m-backup"
visible: playProgress > 0
onClicked: playPressed(true)
onClicked: playPressed(false)
}
IconButton {
id: favouriteButton