From af1ee535788b4d64945ef578bde3764551297ab4 Mon Sep 17 00:00:00 2001 From: Jaime van Kessel Date: Fri, 23 Nov 2018 17:41:58 +0100 Subject: [PATCH] Fix the hover effect of action button CURA-5959 --- resources/qml/ActionButton.qml | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/resources/qml/ActionButton.qml b/resources/qml/ActionButton.qml index 8cd53b5d7e..6dd5839bb9 100644 --- a/resources/qml/ActionButton.qml +++ b/resources/qml/ActionButton.qml @@ -12,7 +12,6 @@ import UM 1.1 as UM Button { id: button - property alias cursorShape: mouseArea.cursorShape property alias iconSource: buttonIcon.source property alias textFont: buttonText.font property alias cornerRadius: backgroundRect.radius @@ -22,12 +21,14 @@ Button property color hoverColor: UM.Theme.getColor("primary_hover") property color disabledColor: color property color textColor: UM.Theme.getColor("button_text") - property color textHoverColor: UM.Theme.getColor("button_text_hover") + property color textHoverColor: textColor property color textDisabledColor: textColor property color outlineColor: color property color outlineHoverColor: hoverColor property color outlineDisabledColor: outlineColor + hoverEnabled: true + property alias shadowColor: shadow.color property alias shadowEnabled: shadow.visible @@ -95,13 +96,4 @@ Button delay: 500 visible: text != "" && button.hovered } - - MouseArea - { - id: mouseArea - anchors.fill: parent - // Ensure that the button will still accept the clicks on it's own. - onPressed: mouse.accepted = false - hoverEnabled: true - } }