2023-04-18 08:01:07 +00:00
|
|
|
From 9edd2a05c79a1c40867440826c830c76136152da Mon Sep 17 00:00:00 2001
|
2022-01-24 11:52:52 +00:00
|
|
|
From: David Edmundson <davidedmundson@kde.org>
|
|
|
|
Date: Sun, 14 Nov 2021 13:54:19 +0000
|
2023-04-18 08:01:07 +00:00
|
|
|
Subject: [PATCH 16/55] Client: Avoid processing of events when showing windows
|
2022-01-24 11:52:52 +00:00
|
|
|
|
|
|
|
The only time we want to dispatch events from the wayland socket is when
|
|
|
|
the application is waiting for external events. Doing so at any other
|
|
|
|
time will cause unpredictable behavior in client code.
|
|
|
|
|
|
|
|
This caused a crash downstream where we had outputs get altered whilst
|
|
|
|
itterating through outputs, which shouldn't happen.
|
|
|
|
|
|
|
|
There is no benefit to flushing here, it won't make anything appear
|
|
|
|
faster as we haven't attached the buffer yet.
|
|
|
|
|
|
|
|
Change-Id: Ie13eae4012dab96a93d8810f468d1343402b8c28
|
|
|
|
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|
|
|
Reviewed-by: Aleix Pol Gonzalez <aleixpol@kde.org>
|
|
|
|
(cherry picked from commit 46ed85a80b28d519cf5887bbdce55d1bf57886c3)
|
|
|
|
---
|
|
|
|
src/client/qwaylandwindow.cpp | 1 -
|
|
|
|
1 file changed, 1 deletion(-)
|
|
|
|
|
|
|
|
diff --git a/src/client/qwaylandwindow.cpp b/src/client/qwaylandwindow.cpp
|
2023-04-18 08:01:07 +00:00
|
|
|
index b363c352..b98435ed 100644
|
2022-01-24 11:52:52 +00:00
|
|
|
--- a/src/client/qwaylandwindow.cpp
|
|
|
|
+++ b/src/client/qwaylandwindow.cpp
|
2023-04-18 08:01:07 +00:00
|
|
|
@@ -437,7 +437,6 @@ void QWaylandWindow::setVisible(bool visible)
|
2022-01-24 11:52:52 +00:00
|
|
|
if (window()->type() == Qt::Popup || window()->type() == Qt::ToolTip)
|
|
|
|
activePopups << this;
|
|
|
|
initWindow();
|
|
|
|
- mDisplay->flushRequests();
|
|
|
|
|
|
|
|
setGeometry(windowGeometry());
|
|
|
|
// Don't flush the events here, or else the newly visible window may start drawing, but since
|
|
|
|
--
|
2023-04-18 08:01:07 +00:00
|
|
|
2.40.0
|
2022-01-24 11:52:52 +00:00
|
|
|
|