From 7cc2c0acefdc0759a83d4e1f0173b29f3928e2ba Mon Sep 17 00:00:00 2001 From: Jon Rogers <67245+devnullvoid@users.noreply.github.com> Date: Sat, 30 Aug 2025 14:15:31 -0400 Subject: [PATCH] TopBar VPN: fix centered icon by anchoring DankIcon center; remove inner wrapper --- Modules/TopBar/Vpn.qml | 26 +++++++++++--------------- 1 file changed, 11 insertions(+), 15 deletions(-) diff --git a/Modules/TopBar/Vpn.qml b/Modules/TopBar/Vpn.qml index c96f6c04..392be87f 100644 --- a/Modules/TopBar/Vpn.qml +++ b/Modules/TopBar/Vpn.qml @@ -27,23 +27,19 @@ Rectangle { return Qt.rgba(base.r, base.g, base.b, base.a * Theme.widgetTransparency) } - Item { + DankIcon { + id: icon + name: VpnService.isBusy ? "sync" : (VpnService.connected ? "vpn_lock" : "vpn_key_off") + size: Theme.iconSize - 6 + color: VpnService.connected ? Theme.primary : Theme.surfaceText anchors.centerIn: parent - DankIcon { - id: icon - name: VpnService.isBusy ? "sync" : (VpnService.connected ? "vpn_lock" : "vpn_key_off") - size: Theme.iconSize - 6 - color: VpnService.connected ? Theme.primary : Theme.surfaceText - anchors.verticalCenter: parent.verticalCenter - - RotationAnimation on rotation { - running: VpnService.isBusy - loops: Animation.Infinite - from: 0 - to: 360 - duration: 900 - } + RotationAnimation on rotation { + running: VpnService.isBusy + loops: Animation.Infinite + from: 0 + to: 360 + duration: 900 } }