fix: draw the inner radio indicator border

... as designed/intended in Figma

plus fix a TODO, use HoverHandler instead of a MouseArea to chaneg the
mouse cursor shape
This commit is contained in:
Lukáš Tinkl 2023-04-03 19:56:34 +02:00 committed by Lukáš Tinkl
parent 47c8747473
commit 7523b1a62b
2 changed files with 10 additions and 15 deletions

View File

@ -1,5 +1,5 @@
import QtQuick 2.13
import QtQuick.Controls 2.14
import QtQuick 2.15
import QtQuick.Controls 2.15
import StatusQ.Core.Theme 0.1
@ -30,15 +30,13 @@ RadioButton {
radius: width/2
color: selectionColor
border.color: StatusColors.colors['grey3']
border.width: 1
}
}
MouseArea {
id: mouseArea
anchors.fill: parent
hoverEnabled: true
HoverHandler {
enabled: control.enabled
cursorShape: Qt.PointingHandCursor
onPressed: mouse.accepted = false
}
}

View File

@ -1,6 +1,6 @@
import QtQuick 2.14
import QtQuick.Controls 2.12
import QtQuick.Layouts 1.14
import QtQuick 2.15
import QtQuick.Controls 2.15
import QtQuick.Layouts 1.15
import StatusQ.Core 0.1
import StatusQ.Core.Theme 0.1
@ -76,11 +76,8 @@ Button {
}
}
// TODO: To remove when switch to Qt 5.15
MouseArea {
anchors.fill: parent
hoverEnabled: true
HoverHandler {
enabled: root.enabled
cursorShape: Qt.PointingHandCursor
onClicked: { root.clicked() }
}
}