mirror of
https://github.com/jmarshall23/CnC_Remastered_Collection.git
synced 2026-08-17 08:50:29 +02:00
Alt key now functions properly, fixed a-z and f1-f12 scancodes.
This commit is contained in:
@@ -754,7 +754,12 @@ void WWSDL_ProcessEvents(KeyNumType& key, int& flags) {
|
||||
}
|
||||
break;
|
||||
case SDL_KEYDOWN:
|
||||
Keyboard->Put_Element(event.key.keysym.sym);
|
||||
const Uint8* state = SDL_GetKeyboardState(NULL);
|
||||
|
||||
if(state[SDL_SCANCODE_RALT] || state[SDL_SCANCODE_LALT])
|
||||
Keyboard->Put_Element(event.key.keysym.sym | KN_ALT_BIT);
|
||||
else
|
||||
Keyboard->Put_Element(event.key.keysym.sym);
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user