Schedule workspace repaint when window leaves current desktop

When a window leaves the current virtual desktop, we need to schedule a
workspace repaint so the compositor repaints the old region of the
window on the current desktop.

In hindsight, the scene graph must schedule a repaint, but it's not
doable with the current effects api, it will be changed with future
refactoring changes.

BUG: 444172
This commit is contained in:
Vlad Zahorodnii 2022-02-12 13:18:39 +02:00
parent d7ee3f1221
commit a4bb3896bf

View file

@ -496,8 +496,10 @@ void AbstractClient::setDesktops(QVector<VirtualDesktop*> desktops)
updateWindowRules(Rules::Desktops);
Q_EMIT desktopChanged();
if (wasOnCurrentDesktop != isOnCurrentDesktop())
if (wasOnCurrentDesktop != isOnCurrentDesktop()) {
addWorkspaceRepaint(visibleGeometry());
Q_EMIT desktopPresenceChanged(this, was_desk);
}
Q_EMIT x11DesktopIdsChanged();
}