summaryrefslogtreecommitdiffstats
path: root/ui
diff options
context:
space:
mode:
authorAkihiko Odaki2021-02-12 01:04:04 +0100
committerGerd Hoffmann2021-02-19 15:00:12 +0100
commit708b72557ff510493ab3653c7a1ebfe983009469 (patch)
tree87cdee76d64dec9a8ab32ae7f8692b35bf4cb0a2 /ui
parentspice: flush drawing before notifying client (diff)
downloadqemu-708b72557ff510493ab3653c7a1ebfe983009469.tar.gz
qemu-708b72557ff510493ab3653c7a1ebfe983009469.tar.xz
qemu-708b72557ff510493ab3653c7a1ebfe983009469.zip
ui/cocoa: Support unique keys of JIS keyboards
Signed-off-by: Akihiko Odaki <akihiko.odaki@gmail.com> Message-Id: <20210212000404.28413-1-akihiko.odaki@gmail.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'ui')
-rw-r--r--ui/cocoa.m7
1 files changed, 7 insertions, 0 deletions
diff --git a/ui/cocoa.m b/ui/cocoa.m
index 13fba8103e..78fcfeaf04 100644
--- a/ui/cocoa.m
+++ b/ui/cocoa.m
@@ -240,6 +240,13 @@ const int mac_to_qkeycode_map[] = {
[kVK_F14] = Q_KEY_CODE_SCROLL_LOCK,
[kVK_F15] = Q_KEY_CODE_PAUSE,
+ // JIS keyboards only
+ [kVK_JIS_Yen] = Q_KEY_CODE_YEN,
+ [kVK_JIS_Underscore] = Q_KEY_CODE_RO,
+ [kVK_JIS_KeypadComma] = Q_KEY_CODE_KP_COMMA,
+ [kVK_JIS_Eisu] = Q_KEY_CODE_MUHENKAN,
+ [kVK_JIS_Kana] = Q_KEY_CODE_HENKAN,
+
/*
* The eject and volume keys can't be used here because they are handled at
* a lower level than what an Application can see.