From 6e4c15e70ab79cde40c025dd4345cb0700adb4b3 Mon Sep 17 00:00:00 2001 From: Vaxry Date: Sat, 6 Apr 2024 14:51:35 +0100 Subject: [PATCH] compositor: remove windows from fadingOut properly --- src/Compositor.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Compositor.cpp b/src/Compositor.cpp index 3ac9a73f..92c967f0 100644 --- a/src/Compositor.cpp +++ b/src/Compositor.cpp @@ -692,10 +692,10 @@ CMonitor* CCompositor::getMonitorFromVector(const Vector2D& point) { } void CCompositor::removeWindowFromVectorSafe(CWindow* pWindow) { - if (windowExists(pWindow) && !pWindow->m_bFadingOut) + if (windowExists(pWindow) && !pWindow->m_bFadingOut) { std::erase_if(m_vWindows, [&](std::unique_ptr& el) { return el.get() == pWindow; }); - - std::erase_if(m_vWindowsFadingOut, [&](CWindow* el) { return el == pWindow; }); + std::erase_if(m_vWindowsFadingOut, [&](CWindow* el) { return el == pWindow; }); + } } bool CCompositor::windowExists(CWindow* pWindow) {