The keycode in key events is affected by modifiers by default.

This behavior can be customized with SDL_HINT_KEYCODE_OPTIONS.
This commit is contained in:
Sam Lantinga
2024-06-22 00:04:33 -07:00
parent 1e81424b3d
commit 90034b16dc
6 changed files with 149 additions and 29 deletions
+2
View File
@@ -362,6 +362,8 @@ now looks like this:
SDL_Keymod mod = event.key.mod;
```
The keycode in key events is affected by modifiers by default. e.g. pressing the A key would generate the keycode `SDLK_a`, or 'a', and pressing it while holding the shift key would generate the keycode `SDLK_A`, or 'A'. This behavior can be customized with `SDL_HINT_KEYCODE_OPTIONS`.
The gamepad event structures caxis, cbutton, cdevice, ctouchpad, and csensor have been renamed gaxis, gbutton, gdevice, gtouchpad, and gsensor.
The mouseX and mouseY fields of SDL_MouseWheelEvent have been renamed mouse_x and mouse_y.