From e1d7a133334936be2ddd55754787dcdcf4a95515 Mon Sep 17 00:00:00 2001 From: vaxerski <43317083+vaxerski@users.noreply.github.com> Date: Wed, 7 Dec 2022 18:55:56 +0000 Subject: [PATCH] unset fullscreen in onWindowRemoved --- src/layout/IHyprLayout.cpp | 3 +++ src/managers/KeybindManager.cpp | 3 +-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/layout/IHyprLayout.cpp b/src/layout/IHyprLayout.cpp index d28ee2dc..8cd008a5 100644 --- a/src/layout/IHyprLayout.cpp +++ b/src/layout/IHyprLayout.cpp @@ -21,6 +21,9 @@ void IHyprLayout::onWindowCreated(CWindow* pWindow) { } void IHyprLayout::onWindowRemoved(CWindow* pWindow) { + if (pWindow->m_bIsFullscreen) + g_pCompositor->setWindowFullscreen(pWindow, false, FULLSCREEN_FULL); + if (pWindow->m_bIsFloating) { onWindowRemovedFloating(pWindow); } else { diff --git a/src/managers/KeybindManager.cpp b/src/managers/KeybindManager.cpp index 6433d47a..9176ffcd 100644 --- a/src/managers/KeybindManager.cpp +++ b/src/managers/KeybindManager.cpp @@ -930,9 +930,8 @@ void CKeybindManager::moveActiveToWorkspace(std::string args) { PWINDOW->m_vPosition = PWINDOW->m_vRealPosition.vec(); } - if (WASFULLSCREEN) { + if (WASFULLSCREEN) g_pCompositor->setWindowFullscreen(PWINDOW, true, OLDWORKSPACE->m_efFullscreenMode); - } if (!g_pCompositor->isWorkspaceSpecial(WORKSPACEID)) { g_pKeybindManager->changeworkspace(args);