mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 05:17:02 +02:00
allow control spinbox with mouse wheel
This commit is contained in:
parent
826d853edf
commit
9bf3759e8d
1 changed files with 10 additions and 22 deletions
|
@ -154,26 +154,14 @@ SpinBox {
|
||||||
visible: spinBox.labelInside != ""
|
visible: spinBox.labelInside != ""
|
||||||
}
|
}
|
||||||
|
|
||||||
// MouseArea {
|
MouseArea {
|
||||||
// anchors.fill: parent
|
anchors.fill: parent
|
||||||
// propagateComposedEvents: true
|
acceptedButtons: Qt.NoButton
|
||||||
// onWheel: {
|
onWheel: {
|
||||||
// if(spinBox.activeFocus)
|
if (wheel.angleDelta.y > 0)
|
||||||
// wheel.accepted = false
|
value += stepSize
|
||||||
// else
|
else
|
||||||
// wheel.accepted = true
|
value -= stepSize
|
||||||
// }
|
}
|
||||||
// onPressed: {
|
}
|
||||||
// mouse.accepted = false
|
|
||||||
// }
|
|
||||||
// onReleased: {
|
|
||||||
// mouse.accepted = false
|
|
||||||
// }
|
|
||||||
// onClicked: {
|
|
||||||
// mouse.accepted = false
|
|
||||||
// }
|
|
||||||
// onDoubleClicked: {
|
|
||||||
// mouse.accepted = false
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue