From d354480840cb9db5dc58737bce7b3957e7280c59 Mon Sep 17 00:00:00 2001 From: miruka Date: Fri, 6 Dec 2019 08:20:30 -0400 Subject: [PATCH] Work around Qt hover bug for tooltips --- src/qml/Base/HToolTip.qml | 4 ++-- src/qml/Window.qml | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/qml/Base/HToolTip.qml b/src/qml/Base/HToolTip.qml index 7507a4f5..76736eda 100644 --- a/src/qml/Base/HToolTip.qml +++ b/src/qml/Base/HToolTip.qml @@ -11,9 +11,9 @@ ToolTip { property alias label: label property alias backgroundColor: background.color - readonly property bool hideNow: visible && ! window.hovered + readonly property bool hideNow: ! window.hovered - onHideNowChanged: if (hideNow) toolTip.hide() + onHideNowChanged: if (visible && hideNow) toolTip.hide() background: Rectangle { diff --git a/src/qml/Window.qml b/src/qml/Window.qml index 2a44b791..22be16cc 100644 --- a/src/qml/Window.qml +++ b/src/qml/Window.qml @@ -13,6 +13,8 @@ ApplicationWindow { color: "transparent" + // FIXME: Qt 5.13.1 bug, this randomly stops updating after the cursor + // leaves the window until it's clicked again. readonly property alias hovered: windowHover.hovered readonly property bool hidden: @@ -21,7 +23,7 @@ ApplicationWindow { window.visibility == window.Minimized || window.visibility == window.Hidden - // Note: For JS object variables, the corresponding method to notify + // NOTE: For JS object variables, the corresponding method to notify // key/value changes must be called manually, e.g. settingsChanged(). property var modelSources: ({}) property var sidePaneModelSource: []