heugh jazz

This commit is contained in:
Dark Steveneq
2025-10-19 02:58:12 +02:00
parent 5c9b0ec49a
commit 902693bd40
9 changed files with 358 additions and 55 deletions

View File

@@ -6,18 +6,41 @@ import QtQuick.Layouts 6.8
import QYRComponents 1.0
Rectangle {
visible: Player.hasVideo
visible: Player.active
color: Colors.surface1
radius: 10
property bool unrolled: true
// width: childrenRect.width
height: 64
height: unrolled ? 560 : 96
MouseArea {
anchors.fill: parent
height: 20
hoverEnabled: true
propagateComposedEvents: true
onClicked: unrolled = true;
onContainsMouseChanged: function() {
if (!containsMouse) {
unrolled = false;
}
}
}
ColumnLayout {
anchors.fill: parent
Item {
visible: unrolled
Layout.fillHeight: true
}
RowLayout {
Button {
text: Player.playing ? "Pause" : "Play"
text: Player.loading ? "Loading" : (Player.playing ? "Pause" : "Play")
enabled: !Player.loading
onClicked: function() {
if (Player.playing) {
Player.pause()
@@ -32,10 +55,28 @@ Rectangle {
onClicked: Player.stop()
}
Label {
heading: "h4"
text: new Date(Player.position).toISOString().slice(14, 19)
}
Slider {
Layout.fillWidth: true
from: 0
to: 106
to: Player.duration
value: Player.position
buffered: Player.buffered
onMoved: Player.position = value
}
Label {
heading: "h4"
text: new Date(Player.duration).toISOString().slice(14, 19)
}
Label {
text: Player.buffered
}
Slider {
@@ -45,5 +86,24 @@ Rectangle {
onMoved: Player.volume = value
}
}
Label {
Layout.fillWidth: true
wrapMode: Text.WordWrap
clip: true
text: Player.title
heading: "h2"
font.bold: true
}
Label {
visible: unrolled
Layout.fillWidth: true
wrapMode: Text.WordWrap
clip: true
text: Player.description
heading: "h4"
font.bold: true
}
}
}