fix(queue): preserve metadata and polish extended view

cx
This commit is contained in:
vicrodh committed 2026-08-22 20:58:46 -06:00
1 parent c7038a6858
commit 5e4d7ca033
20 files changed
+280 -14

No files matched your search

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#4285f4" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect width="18" height="18" x="3" y="3" rx="2" />
<path d="M15 3v18" />
<path d="m10 15-3-3 3-3" />
</svg>

After

Width:  |  Height:  |  Size: 291 B

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#000000" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect width="18" height="18" x="3" y="3" rx="2" />
<path d="M15 3v18" />
<path d="m10 15-3-3 3-3" />
</svg>

After

Width:  |  Height:  |  Size: 291 B

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#ef4444" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect width="18" height="18" x="3" y="3" rx="2" />
<path d="M15 3v18" />
<path d="m10 15-3-3 3-3" />
</svg>

After

Width:  |  Height:  |  Size: 291 B

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#888888" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect width="18" height="18" x="3" y="3" rx="2" />
<path d="M15 3v18" />
<path d="m10 15-3-3 3-3" />
</svg>

After

Width:  |  Height:  |  Size: 291 B

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#ffffff" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect width="18" height="18" x="3" y="3" rx="2" />
<path d="M15 3v18" />
<path d="m10 15-3-3 3-3" />
</svg>

After

Width:  |  Height:  |  Size: 291 B

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#cccccc" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect width="18" height="18" x="3" y="3" rx="2" />
<path d="M15 3v18" />
<path d="m10 15-3-3 3-3" />
</svg>

After

Width:  |  Height:  |  Size: 291 B

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#fbbf24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect width="18" height="18" x="3" y="3" rx="2" />
<path d="M15 3v18" />
<path d="m10 15-3-3 3-3" />
</svg>

After

Width:  |  Height:  |  Size: 291 B

+19 -1
View File
@@ -32,6 +32,13 @@ Rectangle {
property bool active: false
property bool activeBackground: false
property bool btnEnabled: true
/// Optional host for the shared QbzTooltip mechanism. Kept opt-in so the
/// many icon-only call sites that intentionally have no bubble stay inert.
property var tooltip: null
property string tooltipKey: ""
property string tooltipText: ""
readonly property string resolvedTooltipKey: tooltipKey !== ""
? tooltipKey : "icon-" + name
signal clicked()
QbzTheme { id: theme }
@@ -62,6 +69,17 @@ Rectangle {
enabled: parent.btnEnabled
hoverEnabled: true
cursorShape: parent.btnEnabled ? Qt.PointingHandCursor : Qt.ArrowCursor
onClicked: if (parent.btnEnabled) parent.clicked()
onContainsMouseChanged: {
if (btn.tooltip && btn.tooltipText !== "")
btn.tooltip.hover(containsMouse, btn, btn.resolvedTooltipKey,
btn.tooltipText)
}
onClicked: {
if (!parent.btnEnabled)
return
if (btn.tooltip)
btn.tooltip.hide(btn.resolvedTooltipKey)
parent.clicked()
}
}
}
+10 -1
View File
@@ -772,7 +772,10 @@ Rectangle {
QbzIconButton {
btnSize: 28
iconSize: 15
name: "maximize-2"
name: "panel-right-open"
tooltip: tips
tooltipKey: "queue-view-open"
tooltipText: QbzSession.tr("Queue View", QbzSession.trRev)
onClicked: QbzShell.navigateTo("queue-view")
}
QueueTab {
@@ -1528,4 +1531,10 @@ Rectangle {
}
}
}
QbzTooltip {
id: tips
anchors.fill: parent
z: 4000
}
}
+38 -8
View File
@@ -273,6 +273,8 @@ Rectangle {
Rectangle {
width: parent.width
height: 54
topLeftRadius: theme.radiusMd
topRightRadius: theme.radiusMd
color: theme.ambientOn ? theme.surfaceMainA30 : theme.surfaceMain
Row {
@@ -283,7 +285,10 @@ Rectangle {
QbzIconButton {
btnSize: 32
name: "chevron-left"
name: "panel-right-close"
tooltip: tips
tooltipKey: "queue-view-close"
tooltipText: QbzSession.tr("Back", QbzSession.trRev)
onClicked: QbzShell.navigateBack()
}
Text {
@@ -310,8 +315,8 @@ Rectangle {
spacing: theme.spacingXs
QbzLineEdit {
width: Math.max(130, Math.min(240, root.width
- (root.width >= 720 ? 330 : 210)))
width: Math.max(110, Math.min(220, root.width
- (root.width >= 720 ? 490 : 390)))
searchMode: true
text: root.doc.searchQuery || ""
placeholder: QbzSession.tr("Search queue", QbzSession.trRev)
@@ -321,6 +326,9 @@ Rectangle {
btnSize: 32
name: "trash-list"
btnEnabled: root.rows.length > 0
tooltip: tips
tooltipKey: "queue-view-clear"
tooltipText: QbzSession.tr("Clear", QbzSession.trRev)
onClicked: QbzQueue.queueClear()
}
QbzIconButton {
@@ -328,19 +336,35 @@ Rectangle {
name: "add-to-list"
btnEnabled: root.rows.length > 0
&& !(root.currentRow && root.currentRow.isEphemeral === true)
tooltip: tips
tooltipKey: "queue-view-save"
tooltipText: QbzSession.tr("Add to Playlist", QbzSession.trRev)
onClicked: QbzQueue.queueSaveAsPlaylist()
}
QbzIconButton {
btnSize: 32
name: "infinity"
active: root.doc.infinitePlay === true
onClicked: QbzQueue.queueToggleInfinitePlay()
Row {
anchors.verticalCenter: parent.verticalCenter
spacing: 6
Text {
anchors.verticalCenter: parent.verticalCenter
text: QbzSession.tr("Continuous playback", QbzSession.trRev)
color: theme.textSecondary
font.pixelSize: 11
}
QbzToggle {
anchors.verticalCenter: parent.verticalCenter
checked: root.doc.infinitePlay === true
onToggled: QbzQueue.queueToggleInfinitePlay()
}
}
QbzIconButton {
id: sleepButton
btnSize: 32
name: "clock"
active: QbzQueue.sleepActive
tooltip: tips
tooltipKey: "queue-view-sleep"
tooltipText: QbzSession.tr("Set Timer", QbzSession.trRev)
onClicked: sleepMenu.openAtCursor(sleepButton, 0, sleepButton.height)
CardMenu {
@@ -564,4 +588,10 @@ Rectangle {
}
}
}
QbzTooltip {
id: tips
anchors.fill: parent
z: 4000
}
}