1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-01-24 21:42:51 -05:00

top bar improvements

This commit is contained in:
bbedward
2025-09-02 15:58:34 -04:00
parent 544a17b0db
commit 809274a294
3 changed files with 1058 additions and 1008 deletions

View File

@@ -80,43 +80,18 @@ DankPopout {
property alias bluetoothCodecSelector: bluetoothCodecSelector
Rectangle {
id: controlContent
id: controlContent
anchors.fill: parent
implicitHeight: mainColumn.implicitHeight + Theme.spacingM
anchors.fill: parent
implicitHeight: mainColumn.implicitHeight + Theme.spacingM
color: Theme.popupBackground()
radius: Theme.cornerRadius
border.color: Qt.rgba(Theme.outline.r, Theme.outline.g,
Theme.outline.b, 0.08)
border.width: 1
antialiasing: true
smooth: true
focus: true
Component.onCompleted: {
if (root.shouldBeVisible)
forceActiveFocus()
}
Keys.onPressed: function (event) {
if (event.key === Qt.Key_Escape) {
root.close()
event.accepted = true
} else {
event.accepted = false
}
}
Connections {
function onShouldBeVisibleChanged() {
if (root.shouldBeVisible)
Qt.callLater(function () {
controlContent.forceActiveFocus()
})
}
target: root
}
color: Theme.popupBackground()
radius: Theme.cornerRadius
border.color: Qt.rgba(Theme.outline.r, Theme.outline.g,
Theme.outline.b, 0.08)
border.width: 1
antialiasing: true
smooth: true
Column {
id: mainColumn