mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-16 15:29:55 +00:00
Ignore repeated keystrokes, except for text input events
This commit is contained in:
parent
f1ff9b69b3
commit
6958940131
1 changed files with 4 additions and 2 deletions
6
extern/sdl4ogre/sdlinputwrapper.cpp
vendored
6
extern/sdl4ogre/sdlinputwrapper.cpp
vendored
|
@ -123,10 +123,12 @@ namespace SFO
|
|||
mMouseListener->mouseReleased(evt.button, evt.button.button);
|
||||
break;
|
||||
case SDL_KEYDOWN:
|
||||
_handleKeyPress(evt.key);
|
||||
if (!evt.key.repeat)
|
||||
_handleKeyPress(evt.key);
|
||||
break;
|
||||
case SDL_KEYUP:
|
||||
mKeyboardListener->keyReleased(evt.key);
|
||||
if (!evt.key.repeat)
|
||||
mKeyboardListener->keyReleased(evt.key);
|
||||
break;
|
||||
case SDL_WINDOWEVENT:
|
||||
handleWindowEvent(evt);
|
||||
|
|
Loading…
Reference in a new issue