vexpress: Add support for the -bios flag to provide firmware
[qemu/kevin.git] / ui / sdl2-keymap.h
blob5a12f4543ada7342904d89fca6126cd245dbd8df
2 /* map SDL2 scancodes to QKeyCode */
4 static const int sdl2_scancode_to_qcode[SDL_NUM_SCANCODES] = {
5 [SDL_SCANCODE_A] = Q_KEY_CODE_A,
6 [SDL_SCANCODE_B] = Q_KEY_CODE_B,
7 [SDL_SCANCODE_C] = Q_KEY_CODE_C,
8 [SDL_SCANCODE_D] = Q_KEY_CODE_D,
9 [SDL_SCANCODE_E] = Q_KEY_CODE_E,
10 [SDL_SCANCODE_F] = Q_KEY_CODE_F,
11 [SDL_SCANCODE_G] = Q_KEY_CODE_G,
12 [SDL_SCANCODE_H] = Q_KEY_CODE_H,
13 [SDL_SCANCODE_I] = Q_KEY_CODE_I,
14 [SDL_SCANCODE_J] = Q_KEY_CODE_J,
15 [SDL_SCANCODE_K] = Q_KEY_CODE_K,
16 [SDL_SCANCODE_L] = Q_KEY_CODE_L,
17 [SDL_SCANCODE_M] = Q_KEY_CODE_M,
18 [SDL_SCANCODE_N] = Q_KEY_CODE_N,
19 [SDL_SCANCODE_O] = Q_KEY_CODE_O,
20 [SDL_SCANCODE_P] = Q_KEY_CODE_P,
21 [SDL_SCANCODE_Q] = Q_KEY_CODE_Q,
22 [SDL_SCANCODE_R] = Q_KEY_CODE_R,
23 [SDL_SCANCODE_S] = Q_KEY_CODE_S,
24 [SDL_SCANCODE_T] = Q_KEY_CODE_T,
25 [SDL_SCANCODE_U] = Q_KEY_CODE_U,
26 [SDL_SCANCODE_V] = Q_KEY_CODE_V,
27 [SDL_SCANCODE_W] = Q_KEY_CODE_W,
28 [SDL_SCANCODE_X] = Q_KEY_CODE_X,
29 [SDL_SCANCODE_Y] = Q_KEY_CODE_Y,
30 [SDL_SCANCODE_Z] = Q_KEY_CODE_Z,
32 [SDL_SCANCODE_1] = Q_KEY_CODE_1,
33 [SDL_SCANCODE_2] = Q_KEY_CODE_2,
34 [SDL_SCANCODE_3] = Q_KEY_CODE_3,
35 [SDL_SCANCODE_4] = Q_KEY_CODE_4,
36 [SDL_SCANCODE_5] = Q_KEY_CODE_5,
37 [SDL_SCANCODE_6] = Q_KEY_CODE_6,
38 [SDL_SCANCODE_7] = Q_KEY_CODE_7,
39 [SDL_SCANCODE_8] = Q_KEY_CODE_8,
40 [SDL_SCANCODE_9] = Q_KEY_CODE_9,
41 [SDL_SCANCODE_0] = Q_KEY_CODE_0,
43 [SDL_SCANCODE_RETURN] = Q_KEY_CODE_RET,
44 [SDL_SCANCODE_ESCAPE] = Q_KEY_CODE_ESC,
45 [SDL_SCANCODE_BACKSPACE] = Q_KEY_CODE_BACKSPACE,
46 [SDL_SCANCODE_TAB] = Q_KEY_CODE_TAB,
47 [SDL_SCANCODE_SPACE] = Q_KEY_CODE_SPC,
48 [SDL_SCANCODE_MINUS] = Q_KEY_CODE_MINUS,
49 [SDL_SCANCODE_EQUALS] = Q_KEY_CODE_EQUAL,
50 [SDL_SCANCODE_LEFTBRACKET] = Q_KEY_CODE_BRACKET_LEFT,
51 [SDL_SCANCODE_RIGHTBRACKET] = Q_KEY_CODE_BRACKET_RIGHT,
52 [SDL_SCANCODE_BACKSLASH] = Q_KEY_CODE_BACKSLASH,
53 #if 0
54 [SDL_SCANCODE_NONUSHASH] = Q_KEY_CODE_NONUSHASH,
55 #endif
56 [SDL_SCANCODE_SEMICOLON] = Q_KEY_CODE_SEMICOLON,
57 [SDL_SCANCODE_APOSTROPHE] = Q_KEY_CODE_APOSTROPHE,
58 [SDL_SCANCODE_GRAVE] = Q_KEY_CODE_GRAVE_ACCENT,
59 [SDL_SCANCODE_COMMA] = Q_KEY_CODE_COMMA,
60 [SDL_SCANCODE_PERIOD] = Q_KEY_CODE_DOT,
61 [SDL_SCANCODE_SLASH] = Q_KEY_CODE_SLASH,
62 [SDL_SCANCODE_CAPSLOCK] = Q_KEY_CODE_CAPS_LOCK,
64 [SDL_SCANCODE_F1] = Q_KEY_CODE_F1,
65 [SDL_SCANCODE_F2] = Q_KEY_CODE_F2,
66 [SDL_SCANCODE_F3] = Q_KEY_CODE_F3,
67 [SDL_SCANCODE_F4] = Q_KEY_CODE_F4,
68 [SDL_SCANCODE_F5] = Q_KEY_CODE_F5,
69 [SDL_SCANCODE_F6] = Q_KEY_CODE_F6,
70 [SDL_SCANCODE_F7] = Q_KEY_CODE_F7,
71 [SDL_SCANCODE_F8] = Q_KEY_CODE_F8,
72 [SDL_SCANCODE_F9] = Q_KEY_CODE_F9,
73 [SDL_SCANCODE_F10] = Q_KEY_CODE_F10,
74 [SDL_SCANCODE_F11] = Q_KEY_CODE_F11,
75 [SDL_SCANCODE_F12] = Q_KEY_CODE_F12,
77 [SDL_SCANCODE_PRINTSCREEN] = Q_KEY_CODE_PRINT,
78 [SDL_SCANCODE_SCROLLLOCK] = Q_KEY_CODE_SCROLL_LOCK,
79 [SDL_SCANCODE_PAUSE] = Q_KEY_CODE_PAUSE,
80 [SDL_SCANCODE_INSERT] = Q_KEY_CODE_INSERT,
81 [SDL_SCANCODE_HOME] = Q_KEY_CODE_HOME,
82 [SDL_SCANCODE_PAGEUP] = Q_KEY_CODE_PGUP,
83 [SDL_SCANCODE_DELETE] = Q_KEY_CODE_DELETE,
84 [SDL_SCANCODE_END] = Q_KEY_CODE_END,
85 [SDL_SCANCODE_PAGEDOWN] = Q_KEY_CODE_PGDN,
86 [SDL_SCANCODE_RIGHT] = Q_KEY_CODE_RIGHT,
87 [SDL_SCANCODE_LEFT] = Q_KEY_CODE_LEFT,
88 [SDL_SCANCODE_DOWN] = Q_KEY_CODE_DOWN,
89 [SDL_SCANCODE_UP] = Q_KEY_CODE_UP,
90 [SDL_SCANCODE_NUMLOCKCLEAR] = Q_KEY_CODE_NUM_LOCK,
92 [SDL_SCANCODE_KP_DIVIDE] = Q_KEY_CODE_KP_DIVIDE,
93 [SDL_SCANCODE_KP_MULTIPLY] = Q_KEY_CODE_KP_MULTIPLY,
94 [SDL_SCANCODE_KP_MINUS] = Q_KEY_CODE_KP_SUBTRACT,
95 [SDL_SCANCODE_KP_PLUS] = Q_KEY_CODE_KP_ADD,
96 [SDL_SCANCODE_KP_ENTER] = Q_KEY_CODE_KP_ENTER,
97 [SDL_SCANCODE_KP_1] = Q_KEY_CODE_KP_1,
98 [SDL_SCANCODE_KP_2] = Q_KEY_CODE_KP_2,
99 [SDL_SCANCODE_KP_3] = Q_KEY_CODE_KP_3,
100 [SDL_SCANCODE_KP_4] = Q_KEY_CODE_KP_4,
101 [SDL_SCANCODE_KP_5] = Q_KEY_CODE_KP_5,
102 [SDL_SCANCODE_KP_6] = Q_KEY_CODE_KP_6,
103 [SDL_SCANCODE_KP_7] = Q_KEY_CODE_KP_7,
104 [SDL_SCANCODE_KP_8] = Q_KEY_CODE_KP_8,
105 [SDL_SCANCODE_KP_9] = Q_KEY_CODE_KP_9,
106 [SDL_SCANCODE_KP_0] = Q_KEY_CODE_KP_0,
107 [SDL_SCANCODE_KP_PERIOD] = Q_KEY_CODE_KP_DECIMAL,
108 #if 0
109 [SDL_SCANCODE_NONUSBACKSLASH] = Q_KEY_CODE_NONUSBACKSLASH,
110 [SDL_SCANCODE_APPLICATION] = Q_KEY_CODE_APPLICATION,
111 [SDL_SCANCODE_POWER] = Q_KEY_CODE_POWER,
112 [SDL_SCANCODE_KP_EQUALS] = Q_KEY_CODE_KP_EQUALS,
114 [SDL_SCANCODE_F13] = Q_KEY_CODE_F13,
115 [SDL_SCANCODE_F14] = Q_KEY_CODE_F14,
116 [SDL_SCANCODE_F15] = Q_KEY_CODE_F15,
117 [SDL_SCANCODE_F16] = Q_KEY_CODE_F16,
118 [SDL_SCANCODE_F17] = Q_KEY_CODE_F17,
119 [SDL_SCANCODE_F18] = Q_KEY_CODE_F18,
120 [SDL_SCANCODE_F19] = Q_KEY_CODE_F19,
121 [SDL_SCANCODE_F20] = Q_KEY_CODE_F20,
122 [SDL_SCANCODE_F21] = Q_KEY_CODE_F21,
123 [SDL_SCANCODE_F22] = Q_KEY_CODE_F22,
124 [SDL_SCANCODE_F23] = Q_KEY_CODE_F23,
125 [SDL_SCANCODE_F24] = Q_KEY_CODE_F24,
127 [SDL_SCANCODE_EXECUTE] = Q_KEY_CODE_EXECUTE,
128 #endif
129 [SDL_SCANCODE_HELP] = Q_KEY_CODE_HELP,
130 [SDL_SCANCODE_MENU] = Q_KEY_CODE_MENU,
131 #if 0
132 [SDL_SCANCODE_SELECT] = Q_KEY_CODE_SELECT,
133 #endif
134 [SDL_SCANCODE_STOP] = Q_KEY_CODE_STOP,
135 [SDL_SCANCODE_AGAIN] = Q_KEY_CODE_AGAIN,
136 [SDL_SCANCODE_UNDO] = Q_KEY_CODE_UNDO,
137 [SDL_SCANCODE_CUT] = Q_KEY_CODE_CUT,
138 [SDL_SCANCODE_COPY] = Q_KEY_CODE_COPY,
139 [SDL_SCANCODE_PASTE] = Q_KEY_CODE_PASTE,
140 [SDL_SCANCODE_FIND] = Q_KEY_CODE_FIND,
141 #if 0
142 [SDL_SCANCODE_MUTE] = Q_KEY_CODE_MUTE,
143 [SDL_SCANCODE_VOLUMEUP] = Q_KEY_CODE_VOLUMEUP,
144 [SDL_SCANCODE_VOLUMEDOWN] = Q_KEY_CODE_VOLUMEDOWN,
146 [SDL_SCANCODE_KP_COMMA] = Q_KEY_CODE_KP_COMMA,
147 [SDL_SCANCODE_KP_EQUALSAS400] = Q_KEY_CODE_KP_EQUALSAS400,
149 [SDL_SCANCODE_INTERNATIONAL1] = Q_KEY_CODE_INTERNATIONAL1,
150 [SDL_SCANCODE_INTERNATIONAL2] = Q_KEY_CODE_INTERNATIONAL2,
151 [SDL_SCANCODE_INTERNATIONAL3] = Q_KEY_CODE_INTERNATIONAL3,
152 [SDL_SCANCODE_INTERNATIONAL4] = Q_KEY_CODE_INTERNATIONAL4,
153 [SDL_SCANCODE_INTERNATIONAL5] = Q_KEY_CODE_INTERNATIONAL5,
154 [SDL_SCANCODE_INTERNATIONAL6] = Q_KEY_CODE_INTERNATIONAL6,
155 [SDL_SCANCODE_INTERNATIONAL7] = Q_KEY_CODE_INTERNATIONAL7,
156 [SDL_SCANCODE_INTERNATIONAL8] = Q_KEY_CODE_INTERNATIONAL8,
157 [SDL_SCANCODE_INTERNATIONAL9] = Q_KEY_CODE_INTERNATIONAL9,
158 [SDL_SCANCODE_LANG1] = Q_KEY_CODE_LANG1,
159 [SDL_SCANCODE_LANG2] = Q_KEY_CODE_LANG2,
160 [SDL_SCANCODE_LANG3] = Q_KEY_CODE_LANG3,
161 [SDL_SCANCODE_LANG4] = Q_KEY_CODE_LANG4,
162 [SDL_SCANCODE_LANG5] = Q_KEY_CODE_LANG5,
163 [SDL_SCANCODE_LANG6] = Q_KEY_CODE_LANG6,
164 [SDL_SCANCODE_LANG7] = Q_KEY_CODE_LANG7,
165 [SDL_SCANCODE_LANG8] = Q_KEY_CODE_LANG8,
166 [SDL_SCANCODE_LANG9] = Q_KEY_CODE_LANG9,
167 [SDL_SCANCODE_ALTERASE] = Q_KEY_CODE_ALTERASE,
168 #endif
169 [SDL_SCANCODE_SYSREQ] = Q_KEY_CODE_SYSRQ,
170 #if 0
171 [SDL_SCANCODE_CANCEL] = Q_KEY_CODE_CANCEL,
172 [SDL_SCANCODE_CLEAR] = Q_KEY_CODE_CLEAR,
173 [SDL_SCANCODE_PRIOR] = Q_KEY_CODE_PRIOR,
174 [SDL_SCANCODE_RETURN2] = Q_KEY_CODE_RETURN2,
175 [SDL_SCANCODE_SEPARATOR] = Q_KEY_CODE_SEPARATOR,
176 [SDL_SCANCODE_OUT] = Q_KEY_CODE_OUT,
177 [SDL_SCANCODE_OPER] = Q_KEY_CODE_OPER,
178 [SDL_SCANCODE_CLEARAGAIN] = Q_KEY_CODE_CLEARAGAIN,
179 [SDL_SCANCODE_CRSEL] = Q_KEY_CODE_CRSEL,
180 [SDL_SCANCODE_EXSEL] = Q_KEY_CODE_EXSEL,
181 [SDL_SCANCODE_KP_00] = Q_KEY_CODE_KP_00,
182 [SDL_SCANCODE_KP_000] = Q_KEY_CODE_KP_000,
183 [SDL_SCANCODE_THOUSANDSSEPARATOR] = Q_KEY_CODE_THOUSANDSSEPARATOR,
184 [SDL_SCANCODE_DECIMALSEPARATOR] = Q_KEY_CODE_DECIMALSEPARATOR,
185 [SDL_SCANCODE_CURRENCYUNIT] = Q_KEY_CODE_CURRENCYUNIT,
186 [SDL_SCANCODE_CURRENCYSUBUNIT] = Q_KEY_CODE_CURRENCYSUBUNIT,
187 [SDL_SCANCODE_KP_LEFTPAREN] = Q_KEY_CODE_KP_LEFTPAREN,
188 [SDL_SCANCODE_KP_RIGHTPAREN] = Q_KEY_CODE_KP_RIGHTPAREN,
189 [SDL_SCANCODE_KP_LEFTBRACE] = Q_KEY_CODE_KP_LEFTBRACE,
190 [SDL_SCANCODE_KP_RIGHTBRACE] = Q_KEY_CODE_KP_RIGHTBRACE,
191 [SDL_SCANCODE_KP_TAB] = Q_KEY_CODE_KP_TAB,
192 [SDL_SCANCODE_KP_BACKSPACE] = Q_KEY_CODE_KP_BACKSPACE,
193 [SDL_SCANCODE_KP_A] = Q_KEY_CODE_KP_A,
194 [SDL_SCANCODE_KP_B] = Q_KEY_CODE_KP_B,
195 [SDL_SCANCODE_KP_C] = Q_KEY_CODE_KP_C,
196 [SDL_SCANCODE_KP_D] = Q_KEY_CODE_KP_D,
197 [SDL_SCANCODE_KP_E] = Q_KEY_CODE_KP_E,
198 [SDL_SCANCODE_KP_F] = Q_KEY_CODE_KP_F,
199 [SDL_SCANCODE_KP_XOR] = Q_KEY_CODE_KP_XOR,
200 [SDL_SCANCODE_KP_POWER] = Q_KEY_CODE_KP_POWER,
201 [SDL_SCANCODE_KP_PERCENT] = Q_KEY_CODE_KP_PERCENT,
202 [SDL_SCANCODE_KP_LESS] = Q_KEY_CODE_KP_LESS,
203 [SDL_SCANCODE_KP_GREATER] = Q_KEY_CODE_KP_GREATER,
204 [SDL_SCANCODE_KP_AMPERSAND] = Q_KEY_CODE_KP_AMPERSAND,
205 [SDL_SCANCODE_KP_DBLAMPERSAND] = Q_KEY_CODE_KP_DBLAMPERSAND,
206 [SDL_SCANCODE_KP_VERTICALBAR] = Q_KEY_CODE_KP_VERTICALBAR,
207 [SDL_SCANCODE_KP_DBLVERTICALBAR] = Q_KEY_CODE_KP_DBLVERTICALBAR,
208 [SDL_SCANCODE_KP_COLON] = Q_KEY_CODE_KP_COLON,
209 [SDL_SCANCODE_KP_HASH] = Q_KEY_CODE_KP_HASH,
210 [SDL_SCANCODE_KP_SPACE] = Q_KEY_CODE_KP_SPACE,
211 [SDL_SCANCODE_KP_AT] = Q_KEY_CODE_KP_AT,
212 [SDL_SCANCODE_KP_EXCLAM] = Q_KEY_CODE_KP_EXCLAM,
213 [SDL_SCANCODE_KP_MEMSTORE] = Q_KEY_CODE_KP_MEMSTORE,
214 [SDL_SCANCODE_KP_MEMRECALL] = Q_KEY_CODE_KP_MEMRECALL,
215 [SDL_SCANCODE_KP_MEMCLEAR] = Q_KEY_CODE_KP_MEMCLEAR,
216 [SDL_SCANCODE_KP_MEMADD] = Q_KEY_CODE_KP_MEMADD,
217 [SDL_SCANCODE_KP_MEMSUBTRACT] = Q_KEY_CODE_KP_MEMSUBTRACT,
218 [SDL_SCANCODE_KP_MEMMULTIPLY] = Q_KEY_CODE_KP_MEMMULTIPLY,
219 [SDL_SCANCODE_KP_MEMDIVIDE] = Q_KEY_CODE_KP_MEMDIVIDE,
220 [SDL_SCANCODE_KP_PLUSMINUS] = Q_KEY_CODE_KP_PLUSMINUS,
221 [SDL_SCANCODE_KP_CLEAR] = Q_KEY_CODE_KP_CLEAR,
222 [SDL_SCANCODE_KP_CLEARENTRY] = Q_KEY_CODE_KP_CLEARENTRY,
223 [SDL_SCANCODE_KP_BINARY] = Q_KEY_CODE_KP_BINARY,
224 [SDL_SCANCODE_KP_OCTAL] = Q_KEY_CODE_KP_OCTAL,
225 [SDL_SCANCODE_KP_DECIMAL] = Q_KEY_CODE_KP_DECIMAL,
226 [SDL_SCANCODE_KP_HEXADECIMAL] = Q_KEY_CODE_KP_HEXADECIMAL,
227 #endif
228 [SDL_SCANCODE_LCTRL] = Q_KEY_CODE_CTRL,
229 [SDL_SCANCODE_LSHIFT] = Q_KEY_CODE_SHIFT,
230 [SDL_SCANCODE_LALT] = Q_KEY_CODE_ALT,
231 [SDL_SCANCODE_LGUI] = Q_KEY_CODE_META_L,
232 [SDL_SCANCODE_RCTRL] = Q_KEY_CODE_CTRL_R,
233 [SDL_SCANCODE_RSHIFT] = Q_KEY_CODE_SHIFT_R,
234 [SDL_SCANCODE_RALT] = Q_KEY_CODE_ALTGR,
235 [SDL_SCANCODE_RGUI] = Q_KEY_CODE_META_R,
236 #if 0
237 [SDL_SCANCODE_MODE] = Q_KEY_CODE_MODE,
238 [SDL_SCANCODE_AUDIONEXT] = Q_KEY_CODE_AUDIONEXT,
239 [SDL_SCANCODE_AUDIOPREV] = Q_KEY_CODE_AUDIOPREV,
240 [SDL_SCANCODE_AUDIOSTOP] = Q_KEY_CODE_AUDIOSTOP,
241 [SDL_SCANCODE_AUDIOPLAY] = Q_KEY_CODE_AUDIOPLAY,
242 [SDL_SCANCODE_AUDIOMUTE] = Q_KEY_CODE_AUDIOMUTE,
243 [SDL_SCANCODE_MEDIASELECT] = Q_KEY_CODE_MEDIASELECT,
244 [SDL_SCANCODE_WWW] = Q_KEY_CODE_WWW,
245 [SDL_SCANCODE_MAIL] = Q_KEY_CODE_MAIL,
246 [SDL_SCANCODE_CALCULATOR] = Q_KEY_CODE_CALCULATOR,
247 [SDL_SCANCODE_COMPUTER] = Q_KEY_CODE_COMPUTER,
248 [SDL_SCANCODE_AC_SEARCH] = Q_KEY_CODE_AC_SEARCH,
249 [SDL_SCANCODE_AC_HOME] = Q_KEY_CODE_AC_HOME,
250 [SDL_SCANCODE_AC_BACK] = Q_KEY_CODE_AC_BACK,
251 [SDL_SCANCODE_AC_FORWARD] = Q_KEY_CODE_AC_FORWARD,
252 [SDL_SCANCODE_AC_STOP] = Q_KEY_CODE_AC_STOP,
253 [SDL_SCANCODE_AC_REFRESH] = Q_KEY_CODE_AC_REFRESH,
254 [SDL_SCANCODE_AC_BOOKMARKS] = Q_KEY_CODE_AC_BOOKMARKS,
255 [SDL_SCANCODE_BRIGHTNESSDOWN] = Q_KEY_CODE_BRIGHTNESSDOWN,
256 [SDL_SCANCODE_BRIGHTNESSUP] = Q_KEY_CODE_BRIGHTNESSUP,
257 [SDL_SCANCODE_DISPLAYSWITCH] = Q_KEY_CODE_DISPLAYSWITCH,
258 [SDL_SCANCODE_KBDILLUMTOGGLE] = Q_KEY_CODE_KBDILLUMTOGGLE,
259 [SDL_SCANCODE_KBDILLUMDOWN] = Q_KEY_CODE_KBDILLUMDOWN,
260 [SDL_SCANCODE_KBDILLUMUP] = Q_KEY_CODE_KBDILLUMUP,
261 [SDL_SCANCODE_EJECT] = Q_KEY_CODE_EJECT,
262 [SDL_SCANCODE_SLEEP] = Q_KEY_CODE_SLEEP,
263 [SDL_SCANCODE_APP1] = Q_KEY_CODE_APP1,
264 [SDL_SCANCODE_APP2] = Q_KEY_CODE_APP2,
265 #endif