summaryrefslogtreecommitdiffstats
path: root/src/client/qwaylandwindow_p.h
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2017-09-20 11:38:52 +0200
committerLiang Qi <liang.qi@qt.io>2017-09-20 11:38:52 +0200
commit20ebb685e0fef048e56ed19403575634ce4b3435 (patch)
tree6ad6fedfbe4d361e40a0307f1f0cdc39044b53b6 /src/client/qwaylandwindow_p.h
parente1f89e15cf00420bd77ac16a867a1cadc9b942fc (diff)
parent3cb09edd71745edda4bbe8de3a6d7ad8e4ea5f58 (diff)
Merge remote-tracking branch 'origin/5.9' into 5.10
Diffstat (limited to 'src/client/qwaylandwindow_p.h')
-rw-r--r--src/client/qwaylandwindow_p.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/client/qwaylandwindow_p.h b/src/client/qwaylandwindow_p.h
index 9f6ff5b4e..961b7881d 100644
--- a/src/client/qwaylandwindow_p.h
+++ b/src/client/qwaylandwindow_p.h
@@ -53,7 +53,6 @@
#include <QtCore/QWaitCondition>
#include <QtCore/QMutex>
-#include <QtCore/QAtomicPointer>
#include <QtGui/QIcon>
#include <QtCore/QVariant>
@@ -143,7 +142,7 @@ public:
QWaylandDisplay *display() const { return mDisplay; }
QWaylandShellSurface *shellSurface() const;
QWaylandSubSurface *subSurfaceWindow() const;
- QWaylandScreen *screen() const { return mScreen; }
+ QWaylandScreen *screen() const;
void handleContentOrientationChange(Qt::ScreenOrientation orientation) override;
void setOrientationMask(Qt::ScreenOrientations mask);
@@ -210,7 +209,10 @@ public slots:
void requestResize();
protected:
- QWaylandScreen *mScreen;
+ void surface_enter(struct ::wl_output *output) override;
+ void surface_leave(struct ::wl_output *output) override;
+
+ QVector<QWaylandScreen *> mScreens; //As seen by wl_surface.enter/leave events. Chronological order.
QWaylandDisplay *mDisplay;
QWaylandShellSurface *mShellSurface;
QWaylandSubSurface *mSubSurfaceWindow;
@@ -222,7 +224,7 @@ protected:
WId mWindowId;
bool mWaitingForFrameSync;
- QAtomicPointer<struct wl_callback> mFrameCallback;
+ struct ::wl_callback *mFrameCallback = nullptr;
QWaitCondition mFrameSyncWait;
QMutex mResizeLock;
@@ -245,6 +247,9 @@ protected:
QWaylandShmBackingStore *mBackingStore;
+private slots:
+ void handleScreenRemoved(QScreen *qScreen);
+
private:
bool setWindowStateInternal(Qt::WindowStates flags);
void setGeometry_helper(const QRect &rect);
@@ -254,6 +259,8 @@ private:
bool shouldCreateSubSurface() const;
void reset(bool sendDestroyEvent = true);
void sendExposeEvent(const QRect &rect);
+ static void closePopups(QWaylandWindow *parent);
+ QWaylandScreen *calculateScreenFromSurfaceEvents() const;
void handleMouseEventWithDecoration(QWaylandInputDevice *inputDevice, const QWaylandPointerEvent &e);