Keyboard layout independent shortcuts
This commit is contained in:
parent
994c62b64a
commit
c3b7234315
|
@ -106,7 +106,7 @@ static const char *get_key_name(const SDL_Event *e, char *buf) {
|
||||||
!(e->key.keysym.mod & KMOD_NUM)) {
|
!(e->key.keysym.mod & KMOD_NUM)) {
|
||||||
return numpad[scancode - SDL_SCANCODE_KP_1];
|
return numpad[scancode - SDL_SCANCODE_KP_1];
|
||||||
} else {
|
} else {
|
||||||
strcpy(buf, SDL_GetKeyName(e->key.keysym.sym));
|
strcpy(buf, SDL_GetScancodeName(e->key.keysym.scancode));
|
||||||
str_tolower(buf);
|
str_tolower(buf);
|
||||||
return buf;
|
return buf;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue