summaryrefslogtreecommitdiff
path: root/src/Compositor.cpp
diff options
context:
space:
mode:
authorVaxry <vaxry@vaxry.net>2024-03-14 18:25:28 +0000
committerVaxry <vaxry@vaxry.net>2024-03-14 18:25:28 +0000
commit164e92f8e376536fff89dac41cde654293e64522 (patch)
tree2441ec753b92a6fd6f7d22aa341a307ed19dba76 /src/Compositor.cpp
parent3e67ee0f5f66c74c0a0bd4f797361fd100c2e2d2 (diff)
internal: minor fixups for fading out xwayland windows
fixes #4935
Diffstat (limited to 'src/Compositor.cpp')
-rw-r--r--src/Compositor.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp
index 4d3fd65b..eda5b5ed 100644
--- a/src/Compositor.cpp
+++ b/src/Compositor.cpp
@@ -1433,11 +1433,15 @@ void CCompositor::cleanupFadingOut(const int& monid) {
bool valid = windowExists(w);
if (!valid || !w->m_bFadingOut || w->m_fAlpha.value() == 0.f) {
- if (valid && !w->m_bReadyToDelete)
- continue;
+ if (valid) {
+ w->m_bFadingOut = false;
+
+ if (!w->m_bReadyToDelete)
+ continue;
+
+ removeWindowFromVectorSafe(w);
+ }
- w->m_bFadingOut = false;
- removeWindowFromVectorSafe(w);
std::erase(m_vWindowsFadingOut, w);
Debug::log(LOG, "Cleanup: destroyed a window");