summaryrefslogtreecommitdiffstats
path: root/src/gui/platform
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@qt.io>2022-04-08 17:26:20 +0200
committerTor Arne Vestbø <tor.arne.vestbo@qt.io>2022-04-29 18:03:37 +0200
commitce12b4bd3a824f043fbcb5827381340104b92bf6 (patch)
tree719446276774a9593930840227c19dcb3630f1d9 /src/gui/platform
parent786121bf731f1a0ef4f08e5d9c80637c38b4ca6a (diff)
QAppleKeyMapper: Print key via QKeySequence instead of as QChar
The keys map beyond the Unicode range, so we can't print them as QChar. Luckily QKeySequence takes care of all of this for us in QKeySequencePrivate::keyName() via QKeySequence::encodeString(). Pick-to: 6.2 6.3 Change-Id: I822c4f925854e22af5a3b4a7028cb0ed18fb67b2 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Diffstat (limited to 'src/gui/platform')
-rw-r--r--src/gui/platform/darwin/qapplekeymapper.mm2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/platform/darwin/qapplekeymapper.mm b/src/gui/platform/darwin/qapplekeymapper.mm
index 98c7378e1f..c7994f46f0 100644
--- a/src/gui/platform/darwin/qapplekeymapper.mm
+++ b/src/gui/platform/darwin/qapplekeymapper.mm
@@ -551,7 +551,7 @@ const QAppleKeyMapper::KeyMap &QAppleKeyMapper::keyMapForKey(VirtualKeyCode virt
qCDebug(lcQpaKeyMapper).verbosity(0) << "\t" << qtModifiers
<< "+" << qUtf8Printable(QString::asprintf("0x%02x", virtualKey))
<< "=" << qUtf8Printable(QString::asprintf("%d / 0x%02x /", qtKey, qtKey))
- << QString(QChar(qtKey));
+ << QKeySequence(qtKey).toString();
}
return keyMap;