window: Improve how we tell the window to do layer-shell

Instead of telling it in the construction after forcing the window
creation, install an event handler that sets it when we get the
PlatformSurface event.

It has the advantage that it will also trigger in subsequent platform
surface events (e.g. after hide and show).
This commit is contained in:
Aleix Pol
2025-09-09 00:43:58 +02:00
parent 2b8544f5a0
commit cb79d3f60a
3 changed files with 70 additions and 17 deletions

View File

@ -138,6 +138,8 @@ public:
static Window *qmlAttachedProperties(QObject *object);
bool eventFilter(QObject *watched, QEvent *event) override;
Q_SIGNALS:
void anchorsChanged();
void exclusionZoneChanged();