From 1dcd40a5e99ef08f4ebbb7b7d6c66138cff659ac Mon Sep 17 00:00:00 2001 From: Jeffrey Pfau Date: Mon, 6 Apr 2015 22:02:06 -0700 Subject: [PATCH] Qt: Fix window not regaining focus after exiting savestate window --- CHANGES | 1 + src/platform/qt/Window.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index e24bdfe59..b04e773bf 100644 --- a/CHANGES +++ b/CHANGES @@ -7,6 +7,7 @@ Bugfixes: - GBA Audio: FIFOs should not poll DMAs that are not scheduled for audio - Qt: Fix "QOpenGLContext::swapBuffers() called with non-exposed window" warning - GBA Memory: Ensure changing the timing of a DMA reschedules it + - Qt: Fix window not regaining focus after exiting savestate window 0.2.0: (2015-04-03) Features: diff --git a/src/platform/qt/Window.cpp b/src/platform/qt/Window.cpp index c280757ea..b48732e31 100644 --- a/src/platform/qt/Window.cpp +++ b/src/platform/qt/Window.cpp @@ -541,7 +541,7 @@ void Window::openStateWindow(LoadSave ls) { connect(m_stateWindow, &LoadSaveState::closed, [this]() { m_screenWidget->layout()->removeWidget(m_stateWindow); m_stateWindow = nullptr; - setFocus(); + QMetaObject::invokeMethod(this, "setFocus", Qt::QueuedConnection); }); if (!wasPaused) { m_controller->setPaused(true);