From 5aaa5590c71e5fe666563f22f8ed7f2d9fea1687 Mon Sep 17 00:00:00 2001 From: Pascal Precht Date: Tue, 6 Jul 2021 11:22:41 +0200 Subject: [PATCH] fix(StatusChatInfoButton): disable hover effects when sensor is disabled Closes #231 --- ui/StatusQ/src/StatusQ/Controls/StatusChatInfoButton.qml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ui/StatusQ/src/StatusQ/Controls/StatusChatInfoButton.qml b/ui/StatusQ/src/StatusQ/Controls/StatusChatInfoButton.qml index fbb37eb904..2bd4b296f8 100644 --- a/ui/StatusQ/src/StatusQ/Controls/StatusChatInfoButton.qml +++ b/ui/StatusQ/src/StatusQ/Controls/StatusChatInfoButton.qml @@ -22,6 +22,7 @@ Rectangle { property StatusIconSettings icon: StatusIconSettings {} property int type: StatusChatInfoButton.Type.PublicChat property alias tooltip: statusToolTip + property alias sensor: sensor signal clicked(var mouse) signal pinnedMessagesCountClicked(var mouse) @@ -38,13 +39,13 @@ Rectangle { } radius: 8 - color: sensor.containsMouse ? Theme.palette.baseColor2 : "transparent" + color: sensor.enabled && sensor.containsMouse ? Theme.palette.baseColor2 : "transparent" MouseArea { id: sensor anchors.fill: parent hoverEnabled: true - cursorShape: Qt.PointingHandCursor + cursorShape: enabled ? Qt.PointingHandCursor : Qt.ArrowCursor onClicked: statusChatInfoButton.clicked(mouse)