From e3ad78e84f3ca56da12360756c736a5b69bacf42 Mon Sep 17 00:00:00 2001 From: ZackWeinstein <32457340+ZackWeinstein@users.noreply.github.com> Date: Fri, 25 Feb 2022 09:58:31 -0500 Subject: [PATCH] Allowing Swap screens hotkey to swap between displaying only top screen and only bottom screen. (#1283) --- src/frontend/qt_sdl/main.cpp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/frontend/qt_sdl/main.cpp b/src/frontend/qt_sdl/main.cpp index 4d30dc80..c31e78ae 100644 --- a/src/frontend/qt_sdl/main.cpp +++ b/src/frontend/qt_sdl/main.cpp @@ -2777,6 +2777,22 @@ void MainWindow::onChangeScreenSwap(bool checked) { Config::ScreenSwap = checked?1:0; + // Swap between top and bottom screen when displaying one screen. + if (Config::ScreenSizing == 4) + { + // Bottom Screen. + Config::ScreenSizing = 5; + actScreenSizing[4]->setChecked(false); + actScreenSizing[Config::ScreenSizing]->setChecked(true); + } + else if (Config::ScreenSizing == 5) + { + // Top Screen. + Config::ScreenSizing = 4; + actScreenSizing[5]->setChecked(false); + actScreenSizing[Config::ScreenSizing]->setChecked(true); + } + emit screenLayoutChange(); }