focus to first window on not found in refocus

This commit is contained in:
vaxerski 2022-07-31 17:07:39 +02:00
parent e95aa8ef26
commit dba4596c7e
1 changed files with 3 additions and 0 deletions

View File

@ -183,6 +183,9 @@ void CInputManager::mouseMoveUnified(uint32_t time, bool refocus) {
} else
pFoundWindow = g_pCompositor->vectorToWindowIdeal(mouseCoords);
if (!pFoundWindow && refocus)
pFoundWindow = g_pCompositor->getFirstWindowOnWorkspace(PWORKSPACE->m_iID);
if (pFoundWindow) {
if (!pFoundWindow->m_bIsX11) {
foundSurface = g_pCompositor->vectorWindowToSurface(mouseCoords, pFoundWindow, surfaceCoords);