From 52828901efedb146cb572573b2381e73d2ada4d9 Mon Sep 17 00:00:00 2001 From: Stenzek Date: Sat, 27 Oct 2018 20:06:35 +1000 Subject: Core: Switch controller interface to render widget on booting Previously, the Qt frontend would initialize the controller interface on starting, resulting in the cursor position being relative to the main window, instead of the render window. --- Source/Core/DolphinQt/MainWindow.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'Source/Core/DolphinQt/MainWindow.cpp') diff --git a/Source/Core/DolphinQt/MainWindow.cpp b/Source/Core/DolphinQt/MainWindow.cpp index f02542da95..e2b9e15791 100644 --- a/Source/Core/DolphinQt/MainWindow.cpp +++ b/Source/Core/DolphinQt/MainWindow.cpp @@ -940,6 +940,11 @@ void MainWindow::HideRenderWidget(bool reinit) if (m_render_widget->isFullScreen()) SetFullScreenResolution(focus); }); + + // The controller interface will still be registered to the old render widget, if the core + // has booted. Therefore, we should re-bind it to the main window for now. When the core + // is next started, it will be swapped back to the new render widget. + g_controller_interface.ChangeWindow(GetWindowSystemInfo(windowHandle()).render_surface); } } -- cgit v1.2.3