From 629a5f7eea3b17f56606d3b588a5fd96ded99fef Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Fri, 4 Oct 2019 16:24:06 +1000 Subject: [PATCH] dinput: Dont allow Fixed actions to be changed. --- dlls/dinput/config.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dlls/dinput/config.c b/dlls/dinput/config.c index cd2c4b921e7..bfb535c9b2a 100644 --- a/dlls/dinput/config.c +++ b/dlls/dinput/config.c @@ -91,6 +91,7 @@ static BOOL CALLBACK collect_devices(LPCDIDEVICEINSTANCEW lpddi, IDirectInputDev for (j = 0; j < user_af->dwNumActions; j++) { user_af->rgoAction[j].dwSemantic = data->original_lpdiaf->rgoAction[j].dwSemantic; + user_af->rgoAction[j].dwFlags = data->original_lpdiaf->rgoAction[j].dwFlags; user_af->rgoAction[j].u.lptszActionName = data->original_lpdiaf->rgoAction[j].u.lptszActionName; } IDirectInputDevice8_BuildActionMap(lpdid, user_af, data->usernames[i], 0); @@ -334,6 +335,8 @@ static void assign_action(HWND dialog) if (old_action == action) return; if (obj < 0) return; + if (lpdiaf->rgoAction[old_action].dwFlags & DIA_APPFIXED) return; + type = device->ddo[obj].dwType; /* Clear old action */ -- 2.23.0