summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Ghinet <samuel.ghinet@qt.io>2022-03-22 13:00:20 +0200
committerSamuel Ghinet <samuel.ghinet@qt.io>2022-03-22 12:06:12 +0000
commit9c5f390aa8dae73a6bcaa26d0d9dd205ed6db9a5 (patch)
tree6d6961d79504a0a113e9e18ae733213c588dd4aa
parent22c67db406ec02d42e34dc182741ad473ba714fb (diff)
downloadqt-creator-9c5f390aa8dae73a6bcaa26d0d9dd205ed6db9a5.tar.gz
Qds Project Wizard fix: cannot select style
This bug was caused by QDS-5741: Use hover states for interactive items Task-number: QDS-6470 Change-Id: Ice12374257645e39a6c488c30ab584636ba52e9a Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
-rw-r--r--share/qtcreator/qmldesigner/newprojectdialog/imports/NewProjectDialog/Styles.qml11
1 files changed, 3 insertions, 8 deletions
diff --git a/share/qtcreator/qmldesigner/newprojectdialog/imports/NewProjectDialog/Styles.qml b/share/qtcreator/qmldesigner/newprojectdialog/imports/NewProjectDialog/Styles.qml
index 2f8da50c6c..5e1a25cb9d 100644
--- a/share/qtcreator/qmldesigner/newprojectdialog/imports/NewProjectDialog/Styles.qml
+++ b/share/qtcreator/qmldesigner/newprojectdialog/imports/NewProjectDialog/Styles.qml
@@ -140,6 +140,7 @@ Item {
id: delegateId
width: stylesList.width
height: DialogValues.styleListItemHeight
+ hoverEnabled: true
onClicked: stylesList.currentIndex = index
@@ -161,13 +162,13 @@ Item {
height: DialogValues.styleImageHeight
+ 2 * DialogValues.styleImageBorderWidth
- border.color: itemRectMouseArea.containsMouse
+ border.color: delegateId.hovered
? DialogValues.textColor
: (index === stylesList.currentIndex
? DialogValues.textColorInteraction
: "transparent")
- border.width: index === stylesList.currentIndex || itemRectMouseArea.containsMouse
+ border.width: index === stylesList.currentIndex || delegateId.hovered
? DialogValues.styleImageBorderWidth
: 0
@@ -182,12 +183,6 @@ Item {
asynchronous: false
source: "image://newprojectdialog_library/" + BackendApi.styleModel.iconId(model.index)
}
-
- MouseArea {
- id: itemRectMouseArea
- anchors.fill: parent
- hoverEnabled: true
- }
} // Rectangle
Text {