From: Toni Wilen Date: Wed, 11 Jul 2018 17:43:37 +0000 (+0300) Subject: RP update. X-Git-Tag: 4010~13 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=91f6f5576f8512c751903eaac3c9822f32d55101;p=francis%2Fwinuae.git RP update. --- diff --git a/od-win32/dinput.cpp b/od-win32/dinput.cpp index 1bf93abe..1260ae5c 100644 --- a/od-win32/dinput.cpp +++ b/od-win32/dinput.cpp @@ -2155,7 +2155,7 @@ static void handle_rawinput_2 (RAWINPUT *raw, LPARAM lParam) USHORT usButtonFlags = rm->usButtonFlags; #ifdef RETROPLATFORM - if (usButtonFlags) { + if (usButtonFlags && isfocus() != 0) { usButtonFlags = rp_rawbuttons(lParam, usButtonFlags); } #endif diff --git a/od-win32/rp.cpp b/od-win32/rp.cpp index fe8b6b33..ca432599 100644 --- a/od-win32/rp.cpp +++ b/od-win32/rp.cpp @@ -522,6 +522,8 @@ static int port_insert (int inputmap_port, int devicetype, DWORD flags, const TC if (devicetype == RP_INPUTDEVICE_JOYSTICK || devicetype == RP_INPUTDEVICE_GAMEPAD || devicetype == RP_INPUTDEVICE_JOYPAD) { if (inputmap_port >= 0 && inputmap_port < 4) { dacttype[inputmap_port] = devicetype; + inputdevice_compa_clear(&changed_prefs, inputmap_port); + inputdevice_joyport_config(&changed_prefs, _T("none"), NULL, inputmap_port, 0, 0, true); return 1; } return 0;