Skip to content

Commit

Permalink
compositor: fix ghost fadingOut windows remaining after cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
vaxerski committed Apr 6, 2024
1 parent 6e4c15e commit 80f8524
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions src/Compositor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1459,19 +1459,14 @@ void CCompositor::cleanupFadingOut(const int& monid) {
if (w->m_iMonitorID != (long unsigned int)monid)
continue;

bool valid = windowExists(w);
if (!w->m_bFadingOut || w->m_fAlpha.value() == 0.f) {

if (!valid || !w->m_bFadingOut || w->m_fAlpha.value() == 0.f) {
if (valid) {
w->m_bFadingOut = false;
w->m_bFadingOut = false;

if (!w->m_bReadyToDelete)
continue;

removeWindowFromVectorSafe(w);
}
if (!w->m_bReadyToDelete)
continue;

std::erase(m_vWindowsFadingOut, w);
removeWindowFromVectorSafe(w);

Debug::log(LOG, "Cleanup: destroyed a window");
return;
Expand Down

0 comments on commit 80f8524

Please sign in to comment.