From 9fb0ee620c1f87394b4aca5290f4958420add700 Mon Sep 17 00:00:00 2001 From: David Capello Date: Tue, 18 Jun 2024 15:24:12 -0300 Subject: [PATCH] [x11] Don't use ui::move_region() to move windows on X11 It's quite slow, it's faster just to repaint the background. --- src/ui/window.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/ui/window.cpp b/src/ui/window.cpp index 70bf2c616..b063fe9bc 100644 --- a/src/ui/window.cpp +++ b/src/ui/window.cpp @@ -848,7 +848,12 @@ void Window::moveWindow(const gfx::Rect& rect, bool use_blit) // If the GPU acceleration is enabled on this window we avoid // copying regions of pixels as it's super slow to read GPU // surfaces. - if (display()->nativeWindow()->gpuAcceleration()) { + if (display()->nativeWindow()->gpuAcceleration() +#if LAF_LINUX + // On X11 it's better to avoid copying screen areas + || true +#endif + ) { use_blit = false; }