aboutsummaryrefslogtreecommitdiff
path: root/ui
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <f4bug@amsat.org>2022-02-15 16:21:14 +0100
committerPhilippe Mathieu-Daudé <f4bug@amsat.org>2022-03-15 13:36:33 +0100
commit9459262dc4218110f4d3c5dce0b4fe43e1faffdb (patch)
treefe8ab0219edc217861649babcebcd3d58eda2a97 /ui
parent4cb37d1192e112159e3f8cb13de98a09fef502fa (diff)
ui/cocoa: Constify qkeycode translation arrays
Reported-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Akihiko Odaki <akihiko.odaki@gmail.com> Tested-by: Akihiko Odaki <akihiko.odaki@gmail.com> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Diffstat (limited to 'ui')
-rw-r--r--ui/cocoa.m4
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/cocoa.m b/ui/cocoa.m
index c88149852b..a66ba3d7b6 100644
--- a/ui/cocoa.m
+++ b/ui/cocoa.m
@@ -671,7 +671,7 @@ QemuCocoaView *cocoaView;
/* translates Macintosh keycodes to QEMU's keysym */
- int without_control_translation[] = {
+ static const int without_control_translation[] = {
[0 ... 0xff] = 0, // invalid key
[kVK_UpArrow] = QEMU_KEY_UP,
@@ -686,7 +686,7 @@ QemuCocoaView *cocoaView;
[kVK_Delete] = QEMU_KEY_BACKSPACE,
};
- int with_control_translation[] = {
+ static const int with_control_translation[] = {
[0 ... 0xff] = 0, // invalid key
[kVK_UpArrow] = QEMU_KEY_CTRL_UP,