From 748004d81e096d919221d9496aed2c04f67780af Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Mon, 6 Sep 2021 20:52:14 +0300 Subject: [PATCH] x11: Avoid discarding the window pixmap for no reason If the buffer size changes after creating or destroying the decoration, the surface item will discard the pixmap. If the buffer size remains the same, we can continue using old pixmap. --- src/x11client.cpp | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/x11client.cpp b/src/x11client.cpp index 456b83fcfe..2df6f2eb09 100644 --- a/src/x11client.cpp +++ b/src/x11client.cpp @@ -1150,9 +1150,6 @@ void X11Client::createDecoration(const QRect& oldgeom) resize(adjustedSize()); updateDecorationInputShape(); maybeCreateX11DecorationRenderer(); - if (Compositor::compositing()) { - discardWindowPixmap(); - } Q_EMIT geometryShapeChanged(this, oldgeom); } @@ -1165,8 +1162,6 @@ void X11Client::destroyDecoration() maybeDestroyX11DecorationRenderer(); resize(adjustedSize()); move(grav); - if (Compositor::compositing()) - discardWindowPixmap(); if (!isZombie()) { Q_EMIT geometryShapeChanged(this, oldgeom); }