diff options
Diffstat (limited to 'src/plugins/shellintegration')
6 files changed, 18 insertions, 0 deletions
diff --git a/src/plugins/shellintegration/fullscreen-shell-v1/qwaylandfullscreenshellv1surface.h b/src/plugins/shellintegration/fullscreen-shell-v1/qwaylandfullscreenshellv1surface.h index 8affdfd6..0a82e5ee 100644 --- a/src/plugins/shellintegration/fullscreen-shell-v1/qwaylandfullscreenshellv1surface.h +++ b/src/plugins/shellintegration/fullscreen-shell-v1/qwaylandfullscreenshellv1surface.h @@ -18,6 +18,7 @@ class Q_WAYLANDCLIENT_EXPORT QWaylandFullScreenShellV1Surface : public QWaylandS { public: QWaylandFullScreenShellV1Surface(QtWayland::zwp_fullscreen_shell_v1 *shell, QWaylandWindow *window); + std::any surfaceRole() const override { return m_shell->object(); } private: QtWayland::zwp_fullscreen_shell_v1 *m_shell = nullptr; diff --git a/src/plugins/shellintegration/ivi-shell/qwaylandivisurface_p.h b/src/plugins/shellintegration/ivi-shell/qwaylandivisurface_p.h index 7e6811fd..853897cd 100644 --- a/src/plugins/shellintegration/ivi-shell/qwaylandivisurface_p.h +++ b/src/plugins/shellintegration/ivi-shell/qwaylandivisurface_p.h @@ -28,6 +28,8 @@ public: void applyConfigure() override; + std::any surfaceRole() const override { return ivi_surface::object(); }; + private: void createExtendedSurface(QWaylandWindow *window); void ivi_surface_configure(int32_t width, int32_t height) override; diff --git a/src/plugins/shellintegration/qt-shell/qwaylandqtsurface_p.h b/src/plugins/shellintegration/qt-shell/qwaylandqtsurface_p.h index 2f95dd71..53c37f79 100644 --- a/src/plugins/shellintegration/qt-shell/qwaylandqtsurface_p.h +++ b/src/plugins/shellintegration/qt-shell/qwaylandqtsurface_p.h @@ -42,6 +42,8 @@ public: void raise() override; void lower() override; + std::any surfaceRole() const override { return object(); }; + private: void resetConfiguration(); void sendSizeHints(); diff --git a/src/plugins/shellintegration/wl-shell/qwaylandwlshellsurface_p.h b/src/plugins/shellintegration/wl-shell/qwaylandwlshellsurface_p.h index d3996f43..24600302 100644 --- a/src/plugins/shellintegration/wl-shell/qwaylandwlshellsurface_p.h +++ b/src/plugins/shellintegration/wl-shell/qwaylandwlshellsurface_p.h @@ -57,6 +57,8 @@ public: void applyConfigure() override; bool wantsDecorations() const override; + std::any surfaceRole() const override { return object(); }; + protected: void requestWindowStates(Qt::WindowStates states) override; diff --git a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell.cpp b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell.cpp index 9bd5209f..c1462e07 100644 --- a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell.cpp +++ b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell.cpp @@ -417,6 +417,15 @@ void *QWaylandXdgSurface::nativeResource(const QByteArray &resource) return nullptr; } +std::any QWaylandXdgSurface::surfaceRole() const +{ + if (m_toplevel) + return m_toplevel->object(); + if (m_popup) + return m_popup->object(); + return {}; +} + void QWaylandXdgSurface::requestWindowStates(Qt::WindowStates states) { if (m_toplevel) diff --git a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell_p.h b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell_p.h index abfd0db3..58860269 100644 --- a/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell_p.h +++ b/src/plugins/shellintegration/xdg-shell/qwaylandxdgshell_p.h @@ -72,6 +72,8 @@ public: void *nativeResource(const QByteArray &resource); + std::any surfaceRole() const override; + protected: void requestWindowStates(Qt::WindowStates states) override; void xdg_surface_configure(uint32_t serial) override; |