mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 12:17:45 +02:00
move key logic from onClicked to onReleased
This commit is contained in:
parent
928e3d2ef7
commit
c46531296f
1 changed files with 8 additions and 12 deletions
|
@ -45,18 +45,6 @@ Item {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onClicked: {
|
|
||||||
mouse.accepted = true;
|
|
||||||
Tablet.playSound(TabletEnums.ButtonClick);
|
|
||||||
|
|
||||||
webEntity.synthesizeKeyPress(glyph);
|
|
||||||
webEntity.synthesizeKeyPress(glyph, mirrorText);
|
|
||||||
|
|
||||||
if (toggle) {
|
|
||||||
toggled = !toggled;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
onDoubleClicked: {
|
onDoubleClicked: {
|
||||||
mouse.accepted = true;
|
mouse.accepted = true;
|
||||||
}
|
}
|
||||||
|
@ -94,6 +82,14 @@ Item {
|
||||||
|
|
||||||
onReleased: {
|
onReleased: {
|
||||||
if (containsMouse) {
|
if (containsMouse) {
|
||||||
|
Tablet.playSound(TabletEnums.ButtonClick);
|
||||||
|
|
||||||
|
webEntity.synthesizeKeyPress(glyph);
|
||||||
|
webEntity.synthesizeKeyPress(glyph, mirrorText);
|
||||||
|
|
||||||
|
if (toggle) {
|
||||||
|
toggled = !toggled;
|
||||||
|
}
|
||||||
keyItem.state = "mouseOver";
|
keyItem.state = "mouseOver";
|
||||||
} else {
|
} else {
|
||||||
if (toggled) {
|
if (toggled) {
|
||||||
|
|
Loading…
Reference in a new issue