Blame SOURCES/0022-Wayland-client-use-wl_keyboard-to-determine-active-s.patch

165ad0
From 64e133f830ce48b6732397325b768ed9193c2cb4 Mon Sep 17 00:00:00 2001
f8c1a9
From: =?UTF-8?q?M=C3=A9ven=20Car?= <meven.car@enioka.com>
f8c1a9
Date: Wed, 18 Aug 2021 18:28:20 +0200
165ad0
Subject: [PATCH 22/40] Wayland client: use wl_keyboard to determine active
f8c1a9
 state
f8c1a9
f8c1a9
Commit f497a5bb87270174b8e0106b7eca1992d44ff15d made QWaylandDisplay
f8c1a9
use the xdgshell's active state for QWindow::isActive(), instead of
f8c1a9
using wl_keyboard activate/deactivate events.
f8c1a9
f8c1a9
That seems to have been a misunderstanding, since xdgshell activation
f8c1a9
is only supposed to be used to determine visual appearance, and there
f8c1a9
is an explicit warning not to assume it means focus.
f8c1a9
f8c1a9
This commit reverts this logic back to listening to wl_keyboard.
f8c1a9
It adds a fallback when there is no wl_keyboard available to handle
f8c1a9
activated/deactivated events through xdg-shell, in order to fix
f8c1a9
QTBUG-53702.
f8c1a9
f8c1a9
windowStates is handled so that we're not using the Xdg hint for
f8c1a9
anything with QWindowSystemInterface::handleWindowStateChanged or
f8c1a9
anything where we need to track only having one active.
f8c1a9
f8c1a9
We are still exposing it for decorations, which is the only reason to
f8c1a9
use the Xdghint over keyboard focus - so you can keep the toplevel
f8c1a9
active whilst you show a popup.
f8c1a9
f8c1a9
cherry-pick 40036a1b80e5234e6db7d5cbeff122aa7ee13e20
f8c1a9
f8c1a9
Change-Id: I4343d2ed9fb5b066cde95628ed0b4ccc84a424db
f8c1a9
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
f8c1a9
---
f8c1a9
 src/client/qwaylanddisplay.cpp                | 19 +++++++++++--------
f8c1a9
 src/client/qwaylanddisplay_p.h                |  1 +
f8c1a9
 src/client/qwaylandwindow.cpp                 | 13 +++++++++++--
f8c1a9
 src/client/qwaylandwindow_p.h                 |  1 +
f8c1a9
 .../qwaylandshellintegration_p.h              |  7 +++----
f8c1a9
 .../qwaylandxdgshellv5integration.cpp         |  7 -------
f8c1a9
 .../qwaylandxdgshellv5integration_p.h         |  1 -
f8c1a9
 .../qwaylandxdgshellv6integration.cpp         | 14 --------------
f8c1a9
 .../qwaylandxdgshellv6integration_p.h         |  1 -
f8c1a9
 .../xdg-shell/qwaylandxdgshell.cpp            | 16 +++++-----------
f8c1a9
 .../xdg-shell/qwaylandxdgshellintegration.cpp | 14 --------------
f8c1a9
 .../xdg-shell/qwaylandxdgshellintegration_p.h |  1 -
f8c1a9
 tests/auto/client/xdgshell/tst_xdgshell.cpp   | 10 +++++++---
f8c1a9
 13 files changed, 39 insertions(+), 66 deletions(-)
f8c1a9
f8c1a9
diff --git a/src/client/qwaylanddisplay.cpp b/src/client/qwaylanddisplay.cpp
f8c1a9
index e0dfe8b2..27303110 100644
f8c1a9
--- a/src/client/qwaylanddisplay.cpp
f8c1a9
+++ b/src/client/qwaylanddisplay.cpp
f8c1a9
@@ -575,14 +575,10 @@ void QWaylandDisplay::handleKeyboardFocusChanged(QWaylandInputDevice *inputDevic
f8c1a9
     if (mLastKeyboardFocus == keyboardFocus)
f8c1a9
         return;
f8c1a9
 
f8c1a9
-    if (mWaylandIntegration->mShellIntegration) {
f8c1a9
-        mWaylandIntegration->mShellIntegration->handleKeyboardFocusChanged(keyboardFocus, mLastKeyboardFocus);
f8c1a9
-    } else {
f8c1a9
-        if (keyboardFocus)
f8c1a9
-            handleWindowActivated(keyboardFocus);
f8c1a9
-        if (mLastKeyboardFocus)
f8c1a9
-            handleWindowDeactivated(mLastKeyboardFocus);
f8c1a9
-    }
f8c1a9
+    if (keyboardFocus)
f8c1a9
+        handleWindowActivated(keyboardFocus);
f8c1a9
+    if (mLastKeyboardFocus)
f8c1a9
+        handleWindowDeactivated(mLastKeyboardFocus);
f8c1a9
 
f8c1a9
     mLastKeyboardFocus = keyboardFocus;
f8c1a9
 }
f8c1a9
@@ -627,6 +623,13 @@ QWaylandInputDevice *QWaylandDisplay::defaultInputDevice() const
f8c1a9
     return mInputDevices.isEmpty() ? 0 : mInputDevices.first();
f8c1a9
 }
f8c1a9
 
f8c1a9
+bool QWaylandDisplay::isKeyboardAvailable() const
f8c1a9
+{
f8c1a9
+    return std::any_of(
f8c1a9
+            mInputDevices.constBegin(), mInputDevices.constEnd(),
f8c1a9
+            [this](const QWaylandInputDevice *device) { return device->keyboard() != nullptr; });
f8c1a9
+}
f8c1a9
+
f8c1a9
 #if QT_CONFIG(cursor)
f8c1a9
 
f8c1a9
 QWaylandCursor *QWaylandDisplay::waylandCursor()
f8c1a9
diff --git a/src/client/qwaylanddisplay_p.h b/src/client/qwaylanddisplay_p.h
f8c1a9
index 3b092bc8..09a1736a 100644
f8c1a9
--- a/src/client/qwaylanddisplay_p.h
f8c1a9
+++ b/src/client/qwaylanddisplay_p.h
f8c1a9
@@ -215,6 +215,7 @@ public:
f8c1a9
     void destroyFrameQueue(const FrameQueue &q);
f8c1a9
     void dispatchQueueWhile(wl_event_queue *queue, std::function<bool()> condition, int timeout = -1);
f8c1a9
 
f8c1a9
+    bool isKeyboardAvailable() const;
f8c1a9
 public slots:
f8c1a9
     void blockingReadEvents();
f8c1a9
     void flushRequests();
f8c1a9
diff --git a/src/client/qwaylandwindow.cpp b/src/client/qwaylandwindow.cpp
f8c1a9
index c020a58f..ba881cb3 100644
f8c1a9
--- a/src/client/qwaylandwindow.cpp
f8c1a9
+++ b/src/client/qwaylandwindow.cpp
f8c1a9
@@ -96,7 +96,6 @@ QWaylandWindow::QWaylandWindow(QWindow *window, QWaylandDisplay *display)
f8c1a9
 QWaylandWindow::~QWaylandWindow()
f8c1a9
 {
f8c1a9
     mDisplay->destroyFrameQueue(mFrameQueue);
f8c1a9
-    mDisplay->handleWindowDestroyed(this);
f8c1a9
 
f8c1a9
     delete mWindowDecoration;
f8c1a9
 
f8c1a9
@@ -266,6 +265,8 @@ void QWaylandWindow::reset()
f8c1a9
 
f8c1a9
     mMask = QRegion();
f8c1a9
     mQueuedBuffer = nullptr;
f8c1a9
+
f8c1a9
+    mDisplay->handleWindowDestroyed(this);
f8c1a9
 }
f8c1a9
 
f8c1a9
 QWaylandWindow *QWaylandWindow::fromWlSurface(::wl_surface *surface)
f8c1a9
@@ -1083,10 +1084,18 @@ bool QWaylandWindow::setMouseGrabEnabled(bool grab)
f8c1a9
     return true;
f8c1a9
 }
f8c1a9
 
f8c1a9
+Qt::WindowStates QWaylandWindow::windowStates() const
f8c1a9
+{
f8c1a9
+    return mLastReportedWindowStates;
f8c1a9
+}
f8c1a9
+
f8c1a9
 void QWaylandWindow::handleWindowStatesChanged(Qt::WindowStates states)
f8c1a9
 {
f8c1a9
     createDecoration();
f8c1a9
-    QWindowSystemInterface::handleWindowStateChanged(window(), states, mLastReportedWindowStates);
f8c1a9
+    Qt::WindowStates statesWithoutActive = states & ~Qt::WindowActive;
f8c1a9
+    Qt::WindowStates lastStatesWithoutActive = mLastReportedWindowStates & ~Qt::WindowActive;
f8c1a9
+    QWindowSystemInterface::handleWindowStateChanged(window(), statesWithoutActive,
f8c1a9
+                                                     lastStatesWithoutActive);
f8c1a9
     mLastReportedWindowStates = states;
f8c1a9
 }
f8c1a9
 
f8c1a9
diff --git a/src/client/qwaylandwindow_p.h b/src/client/qwaylandwindow_p.h
f8c1a9
index 6cc1664b..e0687962 100644
f8c1a9
--- a/src/client/qwaylandwindow_p.h
f8c1a9
+++ b/src/client/qwaylandwindow_p.h
f8c1a9
@@ -148,6 +148,7 @@ public:
f8c1a9
     void setWindowState(Qt::WindowStates states) override;
f8c1a9
     void setWindowFlags(Qt::WindowFlags flags) override;
f8c1a9
     void handleWindowStatesChanged(Qt::WindowStates states);
f8c1a9
+    Qt::WindowStates windowStates() const;
f8c1a9
 
f8c1a9
     void raise() override;
f8c1a9
     void lower() override;
f8c1a9
diff --git a/src/client/shellintegration/qwaylandshellintegration_p.h b/src/client/shellintegration/qwaylandshellintegration_p.h
f8c1a9
index ccad0048..4cc9b3b8 100644
f8c1a9
--- a/src/client/shellintegration/qwaylandshellintegration_p.h
f8c1a9
+++ b/src/client/shellintegration/qwaylandshellintegration_p.h
f8c1a9
@@ -73,11 +73,10 @@ public:
f8c1a9
         return true;
f8c1a9
     }
f8c1a9
     virtual QWaylandShellSurface *createShellSurface(QWaylandWindow *window) = 0;
f8c1a9
+    // kept for binary compat with layer-shell-qt
f8c1a9
     virtual void handleKeyboardFocusChanged(QWaylandWindow *newFocus, QWaylandWindow *oldFocus) {
f8c1a9
-        if (newFocus)
f8c1a9
-            m_display->handleWindowActivated(newFocus);
f8c1a9
-        if (oldFocus)
f8c1a9
-            m_display->handleWindowDeactivated(oldFocus);
f8c1a9
+        Q_UNUSED(newFocus);
f8c1a9
+        Q_UNUSED(oldFocus);
f8c1a9
     }
f8c1a9
     virtual void *nativeResourceForWindow(const QByteArray &resource, QWindow *window) {
f8c1a9
         Q_UNUSED(resource);
f8c1a9
diff --git a/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5integration.cpp b/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5integration.cpp
f8c1a9
index 4e25949f..cfc60939 100644
f8c1a9
--- a/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5integration.cpp
f8c1a9
+++ b/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5integration.cpp
f8c1a9
@@ -85,13 +85,6 @@ QWaylandShellSurface *QWaylandXdgShellV5Integration::createShellSurface(QWayland
f8c1a9
     return m_xdgShell->createXdgSurface(window);
f8c1a9
 }
f8c1a9
 
f8c1a9
-void QWaylandXdgShellV5Integration::handleKeyboardFocusChanged(QWaylandWindow *newFocus, QWaylandWindow *oldFocus) {
f8c1a9
-    if (newFocus && qobject_cast<QWaylandXdgPopupV5 *>(newFocus->shellSurface()))
f8c1a9
-        m_display->handleWindowActivated(newFocus);
f8c1a9
-    if (oldFocus && qobject_cast<QWaylandXdgPopupV5 *>(oldFocus->shellSurface()))
f8c1a9
-        m_display->handleWindowDeactivated(oldFocus);
f8c1a9
-}
f8c1a9
-
f8c1a9
 }
f8c1a9
 
f8c1a9
 QT_END_NAMESPACE
f8c1a9
diff --git a/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5integration_p.h b/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5integration_p.h
f8c1a9
index ce6bdb9e..aed88670 100644
f8c1a9
--- a/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5integration_p.h
f8c1a9
+++ b/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5integration_p.h
f8c1a9
@@ -67,7 +67,6 @@ public:
f8c1a9
     QWaylandXdgShellV5Integration() {}
f8c1a9
     bool initialize(QWaylandDisplay *display) override;
f8c1a9
     QWaylandShellSurface *createShellSurface(QWaylandWindow *window) override;
f8c1a9
-    void handleKeyboardFocusChanged(QWaylandWindow *newFocus, QWaylandWindow *oldFocus) override;
f8c1a9
 
f8c1a9
 private:
f8c1a9
     QScopedPointer<QWaylandXdgShellV5> m_xdgShell;
f8c1a9
diff --git a/src/plugins/shellintegration/xdg-shell-v6/qwaylandxdgshellv6integration.cpp b/src/plugins/shellintegration/xdg-shell-v6/qwaylandxdgshellv6integration.cpp
f8c1a9
index 03164316..e8da8ba1 100644
f8c1a9
--- a/src/plugins/shellintegration/xdg-shell-v6/qwaylandxdgshellv6integration.cpp
f8c1a9
+++ b/src/plugins/shellintegration/xdg-shell-v6/qwaylandxdgshellv6integration.cpp
f8c1a9
@@ -68,20 +68,6 @@ QWaylandShellSurface *QWaylandXdgShellV6Integration::createShellSurface(QWayland
f8c1a9
     return m_xdgShell->getXdgSurface(window);
f8c1a9
 }
f8c1a9
 
f8c1a9
-void QWaylandXdgShellV6Integration::handleKeyboardFocusChanged(QWaylandWindow *newFocus, QWaylandWindow *oldFocus)
f8c1a9
-{
f8c1a9
-    if (newFocus) {
f8c1a9
-        auto *xdgSurface = qobject_cast<QWaylandXdgSurfaceV6 *>(newFocus->shellSurface());
f8c1a9
-        if (xdgSurface && !xdgSurface->handlesActiveState())
f8c1a9
-            m_display->handleWindowActivated(newFocus);
f8c1a9
-    }
f8c1a9
-    if (oldFocus && qobject_cast<QWaylandXdgSurfaceV6 *>(oldFocus->shellSurface())) {
f8c1a9
-        auto *xdgSurface = qobject_cast<QWaylandXdgSurfaceV6 *>(oldFocus->shellSurface());
f8c1a9
-        if (xdgSurface && !xdgSurface->handlesActiveState())
f8c1a9
-            m_display->handleWindowDeactivated(oldFocus);
f8c1a9
-    }
f8c1a9
-}
f8c1a9
-
f8c1a9
 }
f8c1a9
 
f8c1a9
 QT_END_NAMESPACE
f8c1a9
diff --git a/src/plugins/shellintegration/xdg-shell-v6/qwaylandxdgshellv6integration_p.h b/src/plugins/shellintegration/xdg-shell-v6/qwaylandxdgshellv6integration_p.h
f8c1a9
index 261f8cbb..c1bcd5c6 100644
f8c1a9
--- a/src/plugins/shellintegration/xdg-shell-v6/qwaylandxdgshellv6integration_p.h
f8c1a9
+++ b/src/plugins/shellintegration/xdg-shell-v6/qwaylandxdgshellv6integration_p.h
f8c1a9
@@ -65,7 +65,6 @@ public:
f8c1a9
     QWaylandXdgShellV6Integration() {}
f8c1a9
     bool initialize(QWaylandDisplay *display) override;
f8c1a9
     QWaylandShellSurface *createShellSurface(QWaylandWindow *window) override;
f8c1a9
-    void handleKeyboardFocusChanged(QWaylandWindow *newFocus, QWaylandWindow *oldFocus) override;
f8c1a9
 
f8c1a9
 private:
f8c1a9
     QScopedPointer<QWaylandXdgShellV6> m_xdgShell;
f8c1a9
diff --git a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell.cpp b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell.cpp
f8c1a9
index 7d33dabd..d7d0ddf7 100644
f8c1a9
--- a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell.cpp
f8c1a9
+++ b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell.cpp
f8c1a9
@@ -67,11 +67,6 @@ QWaylandXdgSurface::Toplevel::Toplevel(QWaylandXdgSurface *xdgSurface)
f8c1a9
 
f8c1a9
 QWaylandXdgSurface::Toplevel::~Toplevel()
f8c1a9
 {
f8c1a9
-    if (m_applied.states & Qt::WindowActive) {
f8c1a9
-        QWaylandWindow *window = m_xdgSurface->window();
f8c1a9
-        window->display()->handleWindowDeactivated(window);
f8c1a9
-    }
f8c1a9
-
f8c1a9
     // The protocol spec requires that the decoration object is deleted before xdg_toplevel.
f8c1a9
     delete m_decoration;
f8c1a9
     m_decoration = nullptr;
f8c1a9
@@ -85,16 +80,15 @@ void QWaylandXdgSurface::Toplevel::applyConfigure()
f8c1a9
     if (!(m_applied.states & (Qt::WindowMaximized|Qt::WindowFullScreen)))
f8c1a9
         m_normalSize = m_xdgSurface->m_window->windowFrameGeometry().size();
f8c1a9
 
f8c1a9
-    if ((m_pending.states & Qt::WindowActive) && !(m_applied.states & Qt::WindowActive))
f8c1a9
+    if ((m_pending.states & Qt::WindowActive) && !(m_applied.states & Qt::WindowActive)
f8c1a9
+        && !m_xdgSurface->m_window->display()->isKeyboardAvailable())
f8c1a9
         m_xdgSurface->m_window->display()->handleWindowActivated(m_xdgSurface->m_window);
f8c1a9
 
f8c1a9
-    if (!(m_pending.states & Qt::WindowActive) && (m_applied.states & Qt::WindowActive))
f8c1a9
+    if (!(m_pending.states & Qt::WindowActive) && (m_applied.states & Qt::WindowActive)
f8c1a9
+        && !m_xdgSurface->m_window->display()->isKeyboardAvailable())
f8c1a9
         m_xdgSurface->m_window->display()->handleWindowDeactivated(m_xdgSurface->m_window);
f8c1a9
 
f8c1a9
-    // TODO: none of the other plugins send WindowActive either, but is it on purpose?
f8c1a9
-    Qt::WindowStates statesWithoutActive = m_pending.states & ~Qt::WindowActive;
f8c1a9
-
f8c1a9
-    m_xdgSurface->m_window->handleWindowStatesChanged(statesWithoutActive);
f8c1a9
+    m_xdgSurface->m_window->handleWindowStatesChanged(m_pending.states);
f8c1a9
 
f8c1a9
     if (m_pending.size.isEmpty()) {
f8c1a9
         // An empty size in the configure means it's up to the client to choose the size
f8c1a9
diff --git a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshellintegration.cpp b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshellintegration.cpp
f8c1a9
index 8769d971..da0dd6a7 100644
f8c1a9
--- a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshellintegration.cpp
f8c1a9
+++ b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshellintegration.cpp
f8c1a9
@@ -69,20 +69,6 @@ QWaylandShellSurface *QWaylandXdgShellIntegration::createShellSurface(QWaylandWi
f8c1a9
     return m_xdgShell->getXdgSurface(window);
f8c1a9
 }
f8c1a9
 
f8c1a9
-void QWaylandXdgShellIntegration::handleKeyboardFocusChanged(QWaylandWindow *newFocus, QWaylandWindow *oldFocus)
f8c1a9
-{
f8c1a9
-    if (newFocus) {
f8c1a9
-        auto *xdgSurface = qobject_cast<QWaylandXdgSurface *>(newFocus->shellSurface());
f8c1a9
-        if (xdgSurface && !xdgSurface->handlesActiveState())
f8c1a9
-            m_display->handleWindowActivated(newFocus);
f8c1a9
-    }
f8c1a9
-    if (oldFocus && qobject_cast<QWaylandXdgSurface *>(oldFocus->shellSurface())) {
f8c1a9
-        auto *xdgSurface = qobject_cast<QWaylandXdgSurface *>(oldFocus->shellSurface());
f8c1a9
-        if (xdgSurface && !xdgSurface->handlesActiveState())
f8c1a9
-            m_display->handleWindowDeactivated(oldFocus);
f8c1a9
-    }
f8c1a9
-}
f8c1a9
-
f8c1a9
 }
f8c1a9
 
f8c1a9
 QT_END_NAMESPACE
f8c1a9
diff --git a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshellintegration_p.h b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshellintegration_p.h
f8c1a9
index b6caa6c9..2f929f98 100644
f8c1a9
--- a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshellintegration_p.h
f8c1a9
+++ b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshellintegration_p.h
f8c1a9
@@ -65,7 +65,6 @@ public:
f8c1a9
     QWaylandXdgShellIntegration() {}
f8c1a9
     bool initialize(QWaylandDisplay *display) override;
f8c1a9
     QWaylandShellSurface *createShellSurface(QWaylandWindow *window) override;
f8c1a9
-    void handleKeyboardFocusChanged(QWaylandWindow *newFocus, QWaylandWindow *oldFocus) override;
f8c1a9
 
f8c1a9
 private:
f8c1a9
     QScopedPointer<QWaylandXdgShell> m_xdgShell;
f8c1a9
diff --git a/tests/auto/client/xdgshell/tst_xdgshell.cpp b/tests/auto/client/xdgshell/tst_xdgshell.cpp
f8c1a9
index e2593314..73d1eb9c 100644
f8c1a9
--- a/tests/auto/client/xdgshell/tst_xdgshell.cpp
f8c1a9
+++ b/tests/auto/client/xdgshell/tst_xdgshell.cpp
f8c1a9
@@ -31,6 +31,7 @@
f8c1a9
 #include <QtGui/QOpenGLWindow>
f8c1a9
 #include <QtGui/qpa/qplatformnativeinterface.h>
f8c1a9
 #include <QtWaylandClient/private/wayland-wayland-client-protocol.h>
f8c1a9
+#include <QtWaylandClient/private/qwaylandwindow_p.h>
f8c1a9
 
f8c1a9
 using namespace MockCompositor;
f8c1a9
 
f8c1a9
@@ -155,9 +156,12 @@ void tst_xdgshell::configureStates()
f8c1a9
     // Toplevel windows don't know their position on xdg-shell
f8c1a9
 //    QCOMPARE(window.frameGeometry().topLeft(), QPoint()); // TODO: this doesn't currently work when window decorations are enabled
f8c1a9
 
f8c1a9
-//    QEXPECT_FAIL("", "configure has already been acked, we shouldn't have to wait for isActive", Continue);
f8c1a9
-//    QVERIFY(window.isActive());
f8c1a9
-    QTRY_VERIFY(window.isActive()); // Just make sure it eventually get's set correctly
f8c1a9
+    // window.windowstate() is driven by keyboard focus, however for decorations we want to follow
f8c1a9
+    // XDGShell this is internal to QtWayland so it is queried directly
f8c1a9
+    auto waylandWindow = static_cast<QtWaylandClient::QWaylandWindow *>(window.handle());
f8c1a9
+    Q_ASSERT(waylandWindow);
f8c1a9
+    QTRY_VERIFY(waylandWindow->windowStates().testFlag(
f8c1a9
+            Qt::WindowActive)); // Just make sure it eventually get's set correctly
f8c1a9
 
f8c1a9
     const QSize screenSize(640, 480);
f8c1a9
     const uint maximizedSerial = exec([=] {
f8c1a9
-- 
165ad0
2.35.1
f8c1a9