From fd183914c819dc6c56abe3634b2dbe6604d01e38 Mon Sep 17 00:00:00 2001 From: Fen <48841404+infinifen@users.noreply.github.com> Date: Wed, 1 May 2024 23:10:01 +0200 Subject: [PATCH] Fix 2d27e8e: Update numpad keycodes for SDL2, making it usable (#12596) * Fix 2d27e8e: Update numpad keycodes for SDL2, making it usable * Cleanup: List sdl2 numpad mappings individually (cherry picked from commit 2559bdfa6f65e6a44bb1f4fd72ab9c5eb42b09c6) --- src/video/sdl2_v.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/video/sdl2_v.cpp b/src/video/sdl2_v.cpp index 0b74850a86..1edfc45ec6 100644 --- a/src/video/sdl2_v.cpp +++ b/src/video/sdl2_v.cpp @@ -560,7 +560,16 @@ static const SDLVkMapping _vk_mapping[] = { AM_UP(SDLK_F1, SDLK_F12, WKC_F1, WKC_F12), /* Numeric part. */ - AM(SDLK_KP_0, SDLK_KP_9, '0', '9'), + AS(SDLK_KP_1, '1'), + AS(SDLK_KP_2, '2'), + AS(SDLK_KP_3, '3'), + AS(SDLK_KP_4, '4'), + AS(SDLK_KP_5, '5'), + AS(SDLK_KP_6, '6'), + AS(SDLK_KP_7, '7'), + AS(SDLK_KP_8, '8'), + AS(SDLK_KP_9, '9'), + AS(SDLK_KP_0, '0'), AS(SDLK_KP_DIVIDE, WKC_NUM_DIV), AS(SDLK_KP_MULTIPLY, WKC_NUM_MUL), AS(SDLK_KP_MINUS, WKC_NUM_MINUS),