summaryrefslogtreecommitdiffstats
path: root/src/platformsupport/input/xkbcommon/qxkbcommon.cpp
diff options
context:
space:
mode:
authorTarja Sundqvist <tarja.sundqvist@qt.io>2022-11-11 09:29:17 +0200
committerTarja Sundqvist <tarja.sundqvist@qt.io>2022-11-11 09:29:17 +0200
commit4ee4fc18b4067b90efa46ca9baba74f53b54d9ec (patch)
treecc68622c9b85992d99a8373ab55471ee821a4ebf /src/platformsupport/input/xkbcommon/qxkbcommon.cpp
parentab28ff2207e8f33754c79793089dbf943d67736d (diff)
parentebb49c66aaf22ed55d62ff7bc3690fce00b7d8ba (diff)
Merge remote-tracking branch 'origin/tqtc/lts-5.15.8' into tqtc/lts-5.15-opensourcev5.15.8-lts-lgpl
Diffstat (limited to 'src/platformsupport/input/xkbcommon/qxkbcommon.cpp')
-rw-r--r--src/platformsupport/input/xkbcommon/qxkbcommon.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/platformsupport/input/xkbcommon/qxkbcommon.cpp b/src/platformsupport/input/xkbcommon/qxkbcommon.cpp
index 877c5d848f..b713c19447 100644
--- a/src/platformsupport/input/xkbcommon/qxkbcommon.cpp
+++ b/src/platformsupport/input/xkbcommon/qxkbcommon.cpp
@@ -41,7 +41,9 @@
#include <private/qmakearray_p.h>
+#include <QtCore/private/qstringiterator_p.h>
#include <QtCore/QMetaMethod>
+
#include <QtGui/QKeyEvent>
#include <QtGui/private/qguiapplication_p.h>
@@ -574,7 +576,9 @@ static int keysymToQtKey_internal(xkb_keysym_t keysym, Qt::KeyboardModifiers mod
// e.g CTRL + ۲ (arabic two), is mapped to CTRL + Qt::Key_2.
qtKey = Qt::Key_0 + text.unicode()->digitValue();
} else {
- qtKey = text.unicode()->toUpper().unicode();
+ text = text.toUpper();
+ QStringIterator i(text);
+ qtKey = i.next(0);
}
}