wayland: fix Qt 6.7 compatibility

This commit is contained in:
outfoxxed 2024-04-12 01:21:26 -07:00
parent 98318c4dcb
commit fd5b73adbb
Signed by: outfoxxed
GPG key ID: 4C88A185FB89301E
2 changed files with 10 additions and 0 deletions

View file

@ -7,6 +7,7 @@
#include <private/qwaylandwindow_p.h>
#include <qlogging.h>
#include <qobject.h>
#include <qtversionchecks.h>
#include <qtypes.h>
#include "lock.hpp"
@ -88,7 +89,11 @@ void QSWaylandSessionLockSurface::ext_session_lock_surface_v1_configure(
this->configured = true;
this->window()->resizeFromApplyConfigure(this->size);
#if QT_VERSION < QT_VERSION_CHECK(6, 7, 0)
this->window()->handleExpose(QRect(QPoint(), this->size));
#else
this->window()->sendRecursiveExposeEvent();
#endif
if (this->visible) this->initVisible();
} else {
// applyConfigureWhenPossible runs too late and causes a protocol error on reconfigure.

View file

@ -10,6 +10,7 @@
#include <qpoint.h>
#include <qrect.h>
#include <qsize.h>
#include <qtversionchecks.h>
#include <qtypes.h>
#include <qwayland-wlr-layer-shell-unstable-v1.h>
@ -86,7 +87,11 @@ void QSWaylandLayerSurface::zwlr_layer_surface_v1_configure(
if (!this->configured) {
this->configured = true;
this->window()->resizeFromApplyConfigure(this->size);
#if QT_VERSION < QT_VERSION_CHECK(6, 7, 0)
this->window()->handleExpose(QRect(QPoint(), this->size));
#else
this->window()->sendRecursiveExposeEvent();
#endif
} else {
this->window()->applyConfigureWhenPossible();
}