mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-04 19:55:19 +00:00
Don't log game controller buttons in the keyboard handler on Android
This commit is contained in:
parent
9aae258aeb
commit
ae25abeb0d
1 changed files with 5 additions and 1 deletions
|
|
@ -361,7 +361,11 @@ static SDL_Scancode TranslateKeycode(int keycode)
|
|||
scancode = Android_Keycodes[keycode];
|
||||
}
|
||||
if (scancode == SDL_SCANCODE_UNKNOWN) {
|
||||
__android_log_print(ANDROID_LOG_INFO, "SDL", "Unknown keycode %d", keycode);
|
||||
if (keycode >= 96 /* AKEYCODE_BUTTON_A */ && keycode < 111 /* AKEYCODE_ESCAPE */) {
|
||||
// Ignore game controller buttons
|
||||
} else {
|
||||
__android_log_print(ANDROID_LOG_INFO, "SDL", "Unknown keycode %d", keycode);
|
||||
}
|
||||
}
|
||||
return scancode;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue