mirror of
https://thingvellir.net/git/overte
synced 2025-03-27 23:52:03 +01:00
Merge pull request #11575 from ElderOrb/QTBUG-49297
workaround for https://bugreports.qt.io/browse/QTBUG-49297
This commit is contained in:
commit
1227168939
1 changed files with 14 additions and 0 deletions
|
@ -39,6 +39,20 @@ TextField {
|
|||
|
||||
y: textFieldLabel.visible ? textFieldLabel.height + textFieldLabel.anchors.bottomMargin : 0
|
||||
|
||||
// workaround for https://bugreports.qt.io/browse/QTBUG-49297
|
||||
Keys.onPressed: {
|
||||
switch (event.key) {
|
||||
case Qt.Key_Return:
|
||||
case Qt.Key_Enter:
|
||||
event.accepted = true;
|
||||
|
||||
// emit accepted signal manually
|
||||
if (acceptableInput) {
|
||||
accepted();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
style: TextFieldStyle {
|
||||
textColor: {
|
||||
if (isLightColorScheme) {
|
||||
|
|
Loading…
Reference in a new issue