window: don't focus on activate if window isn't mapped yet

ref #7089
This commit is contained in:
Vaxry 2024-08-28 20:33:29 +02:00
parent 98e99cd03d
commit 9642311ac2
1 changed files with 5 additions and 0 deletions

View File

@ -1307,6 +1307,11 @@ void CWindow::activate(bool force) {
if (!force && (!m_sWindowData.focusOnActivate.valueOr(*PFOCUSONACTIVATE) || (m_eSuppressedEvents & SUPPRESS_ACTIVATE_FOCUSONLY) || (m_eSuppressedEvents & SUPPRESS_ACTIVATE)))
return;
if (!m_bIsMapped) {
Debug::log(LOG, "Ignoring CWindow::activate focus/warp, window is not mapped yet.");
return;
}
if (m_bIsFloating)
g_pCompositor->changeWindowZOrder(m_pSelf.lock(), true);