From 020daad85f070ea766f2077e757f2c73e6a5e0be Mon Sep 17 00:00:00 2001 From: Rafael Kitover Date: Wed, 2 Sep 2020 00:50:45 +0000 Subject: [PATCH] Fix joy accels when emulation is paused. Start the joystick polling timer on pause and stop it on resume, so that accelerators bound to joystick events are still processed. Followup on def5d3e4. Signed-off-by: Rafael Kitover --- src/wx/panel.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/wx/panel.cpp b/src/wx/panel.cpp index 033de105..8d263ba4 100644 --- a/src/wx/panel.cpp +++ b/src/wx/panel.cpp @@ -969,6 +969,8 @@ void GameArea::Pause() if (loaded != IMAGE_UNKNOWN) soundPause(); + + wxGetApp().frame->StartJoyPollTimer(); } void GameArea::Resume() @@ -982,6 +984,8 @@ void GameArea::Resume() if (loaded != IMAGE_UNKNOWN) soundResume(); + wxGetApp().frame->StopJoyPollTimer(); + SetFocus(); }