fix: handle window change directions in fullscreen (#2728)

This commit is contained in:
István Donkó 2023-07-18 12:12:50 +02:00 committed by GitHub
parent d2eb4fee76
commit 5c8a20be77
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1013,8 +1013,11 @@ void CKeybindManager::moveFocusTo(std::string args) {
}
};
const auto PWINDOWTOCHANGETO = PLASTWINDOW->m_bIsFullscreen ? g_pCompositor->getNextWindowOnWorkspace(PLASTWINDOW, arg == 'u' || arg == 't' || arg == 'r') :
g_pCompositor->getWindowInDirection(PLASTWINDOW, arg);
const auto PWINDOWTOCHANGETO = PLASTWINDOW->m_bIsFullscreen
? (arg == 'd' || arg == 'b' || arg == 'r'
? g_pCompositor->getNextWindowOnWorkspace(PLASTWINDOW, true)
: g_pCompositor->getPrevWindowOnWorkspace(PLASTWINDOW, true))
: g_pCompositor->getWindowInDirection(PLASTWINDOW, arg);
// Found window in direction, switch to it
if (PWINDOWTOCHANGETO) {