From 4d7592bf5f9c52ecfc6a33ba80dfd01937e8a1c4 Mon Sep 17 00:00:00 2001 From: vaxerski <43317083+vaxerski@users.noreply.github.com> Date: Wed, 19 Jan 2022 19:49:53 +0100 Subject: [PATCH] fix that for laggy pcs --- src/windowManager.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/windowManager.cpp b/src/windowManager.cpp index a0b9590..3af1d10 100644 --- a/src/windowManager.cpp +++ b/src/windowManager.cpp @@ -374,16 +374,13 @@ void CWindowManager::refreshDirtyWindows() { const auto PWORKSPACE = getWorkspaceByID(window.getWorkspaceID()); - if (!PWORKSPACE) - continue; - // Fullscreen flag - bool bHasFullscreenWindow = PWORKSPACE->getHasFullscreenWindow(); + bool bHasFullscreenWindow = PWORKSPACE ? PWORKSPACE->getHasFullscreenWindow() : false; // first and foremost, let's check if the window isn't on a hidden workspace // or an animated workspace - if (!isWorkspaceVisible(window.getWorkspaceID()) - || PWORKSPACE->getAnimationInProgress()) { + if (PWORKSPACE && (!isWorkspaceVisible(window.getWorkspaceID()) + || PWORKSPACE->getAnimationInProgress())) { const auto MONITOR = getMonitorFromWindow(&window);