Fix bar icon positioning in horizontal mode

This commit is contained in:
David Heinemeier Hansson
2026-05-20 14:56:42 +02:00
parent fab0d69e87
commit 20ff942481
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -68,7 +68,7 @@ BarWidget {
readonly property string reportHumidity: current ? (current.humidity + "%") : ""
visible: label !== ""
implicitWidth: button.implicitWidth + Style.spacing.controlGap
implicitWidth: bar && bar.vertical ? button.implicitWidth : button.implicitWidth + Style.spacing.controlGap
implicitHeight: button.implicitHeight
function setting(name, fallback) {
@@ -281,8 +281,8 @@ BarWidget {
WidgetButton {
id: button
anchors.left: parent.left
anchors.verticalCenter: parent.verticalCenter
x: bar && bar.vertical ? Math.round((parent.width - width) / 2) : 0
width: implicitWidth
height: implicitHeight
bar: root.bar