From 13f91a67fc1ea717b0604f674f0cd30768062a0d Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Thu, 21 May 2026 09:56:15 -0700 Subject: [PATCH] Fixed Ipega controllers being ignored in keyboard mode (thanks @AntTheAlchemist!) --- src/joystick/SDL_gamepad.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/joystick/SDL_gamepad.c b/src/joystick/SDL_gamepad.c index 6dab310b80..5d65991646 100644 --- a/src/joystick/SDL_gamepad.c +++ b/src/joystick/SDL_gamepad.c @@ -206,7 +206,7 @@ static const struct SDL_GamepadBlacklistWords SDL_gamepad_blacklist_words[] = { {"Synaptics ", GAMEPAD_BLACKLIST_ANYWHERE}, // "Synaptics TM2768-001", "SynPS/2 Synaptics TouchPad" {"Trackpad", GAMEPAD_BLACKLIST_ANYWHERE}, {"Clickpad", GAMEPAD_BLACKLIST_ANYWHERE}, - // "PG-90215 Keyboard", "Usb Keyboard Usb Keyboard Consumer Control", "Framework Laptop 16 Keyboard Module - ISO System Control" + // "Usb Keyboard Usb Keyboard Consumer Control", "Framework Laptop 16 Keyboard Module - ISO System Control" {" Keyboard", GAMEPAD_BLACKLIST_ANYWHERE}, {" Laptop ", GAMEPAD_BLACKLIST_ANYWHERE}, // "Framework Laptop 16 Numpad Module System Control" {"Mouse ", GAMEPAD_BLACKLIST_BEGIN}, // "Mouse passthrough" @@ -3281,6 +3281,10 @@ bool SDL_ShouldIgnoreGamepad(Uint16 vendor_id, Uint16 product_id, Uint16 version case GAMEPAD_BLACKLIST_ANYWHERE: if (SDL_strstr(name, blacklist_word->str) != NULL) { + if (SDL_startswith(name, "PG-") { + // Ipega gamepads have modes with keyboard keys in addition to gamepad controls + break; + } return true; } break;