mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-15 14:18:37 +00:00
GRIM: Improve GrimEngine::clearEventQueue() handling
This commit is contained in:
parent
25f31a4989
commit
5e723aa971
@ -1619,9 +1619,8 @@ void GrimEngine::setMode(EngineMode mode) {
|
||||
}
|
||||
|
||||
void GrimEngine::clearEventQueue() {
|
||||
Common::Event event;
|
||||
while (g_system->getEventManager()->pollEvent(event)) {
|
||||
}
|
||||
g_system->getEventManager()->purgeKeyboardEvents();
|
||||
g_system->getEventManager()->purgeMouseEvents();
|
||||
|
||||
for (int i = 0; i < KEYCODE_EXTRA_LAST; ++i) {
|
||||
_controlsState[i] = false;
|
||||
|
@ -711,8 +711,7 @@ void Lua_V1::EnableDebugKeys() {
|
||||
}
|
||||
|
||||
void Lua_V1::FlushControls() {
|
||||
g_system->getEventManager()->purgeKeyboardEvents();
|
||||
g_system->getEventManager()->purgeMouseEvents();
|
||||
g_grim->clearEventQueue();
|
||||
}
|
||||
|
||||
void Lua_V1::LightMgrSetChange() {
|
||||
|
Loading…
Reference in New Issue
Block a user