From 9126b04b10bdd33a1c61ad068161f6f97c7707d3 Mon Sep 17 00:00:00 2001 From: zach Date: Thu, 2 Jul 2026 18:50:14 +0200 Subject: [PATCH] fix: close tray menus when hovering bar + showOnHover enabled --- Modules/Bar/Bar.qml | 5 +---- Modules/Launcher/Wrapper.qml | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/Modules/Bar/Bar.qml b/Modules/Bar/Bar.qml index 18bfc1f..ae4374e 100644 --- a/Modules/Bar/Bar.qml +++ b/Modules/Bar/Bar.qml @@ -3,12 +3,9 @@ pragma ComponentBehavior: Bound import Quickshell import QtQuick import QtQuick.Layouts -import qs.Components import qs.Modules import qs.Config -import qs.Helpers import qs.Modules.SysTray -import qs.Modules.SysTray.Widgets import qs.Modules.Network import qs.Modules.Updates @@ -26,7 +23,7 @@ RowLayout { const ch = childAt(x, height / 2) as WrappedLoader; if (!ch || ch?.id === "spacer") { - if (!popouts.currentName.startsWith("traymenu")) + if (!popouts.currentName.startsWith("traymenu") || Config.bar.tray.showOnHover) popouts.hasCurrent = false; return; } diff --git a/Modules/Launcher/Wrapper.qml b/Modules/Launcher/Wrapper.qml index 84d18ab..1df7f68 100644 --- a/Modules/Launcher/Wrapper.qml +++ b/Modules/Launcher/Wrapper.qml @@ -15,7 +15,7 @@ Item { if (visibilities.resources && panels.resourcesWrapper.x + panels.resourcesWrapper.width > root.x) max -= panels.resources.nonAnimHeight; if (panels.popouts.hasCurrent) - if (panels.popouts.current.x + panels.popouts.current.width > root.x && panels.popouts.current.x < root.x + root.width) + if (panels.popouts.current?.x + panels.popouts.current?.width > root.x && panels.popouts.current?.x < root.x + root.width) max -= panels.popouts.nonAnimHeight; return max; }