From 74968f0ec1cf6eed36aae711a56dd46172955194 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Fri, 27 Dec 2019 11:40:29 +0100 Subject: [PATCH] WindowServer: Don't send paint events to occluded windows We wouldn't be able to see what they paint anyway, and nobody should be using paint events to drive program logic. --- Servers/WindowServer/WSClientConnection.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Servers/WindowServer/WSClientConnection.cpp b/Servers/WindowServer/WSClientConnection.cpp index d91186513e..30f0b68711 100644 --- a/Servers/WindowServer/WSClientConnection.cpp +++ b/Servers/WindowServer/WSClientConnection.cpp @@ -436,7 +436,7 @@ OwnPtr WSClientConnection::handle(const Win void WSClientConnection::post_paint_message(WSWindow& window) { auto rect_set = window.take_pending_paint_rects(); - if (window.is_minimized()) + if (window.is_minimized() || window.is_occluded()) return; Vector rects;