summaryrefslogtreecommitdiffstats
path: root/src/client/qwaylanddisplay.cpp
diff options
context:
space:
mode:
authorJohan Klokkhammer Helsing <johan.helsing@qt.io>2018-11-01 13:48:52 +0100
committerJohan Helsing <johan.helsing@qt.io>2019-04-08 07:51:16 +0000
commit5405de120bba480f780e37e90fbd7c2ff1308b01 (patch)
tree5c62a9475fefd392785583a4a08c15397c73ce1a /src/client/qwaylanddisplay.cpp
parentd65783c9e1f40e176943b8706bf6bbed8320bcc8 (diff)
Client: Don't be exposed if we want to create a sub or shell surface
Because some shells don't allow attaching buffers before configure, we need to not be exposed until we know that we don't want a shell surface. Change-Id: Ida7101a99f953d02cf6401e4ea8d28cfabd6e102 Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com> Reviewed-by: David Edmundson <davidedmundson@kde.org>
Diffstat (limited to 'src/client/qwaylanddisplay.cpp')
-rw-r--r--src/client/qwaylanddisplay.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/client/qwaylanddisplay.cpp b/src/client/qwaylanddisplay.cpp
index a2957e0dd..f2bd3160a 100644
--- a/src/client/qwaylanddisplay.cpp
+++ b/src/client/qwaylanddisplay.cpp
@@ -88,13 +88,6 @@ struct wl_surface *QWaylandDisplay::createSurface(void *handle)
return surface;
}
-QWaylandShellSurface *QWaylandDisplay::createShellSurface(QWaylandWindow *window)
-{
- if (!mWaylandIntegration->shellIntegration())
- return nullptr;
- return mWaylandIntegration->shellIntegration()->createShellSurface(window);
-}
-
struct ::wl_region *QWaylandDisplay::createRegion(const QRegion &qregion)
{
struct ::wl_region *region = mCompositor.create_region();
@@ -108,12 +101,18 @@ struct ::wl_region *QWaylandDisplay::createRegion(const QRegion &qregion)
::wl_subsurface *QWaylandDisplay::createSubSurface(QWaylandWindow *window, QWaylandWindow *parent)
{
if (!mSubCompositor) {
+ qCWarning(lcQpaWayland) << "Can't create subsurface, not supported by the compositor.";
return nullptr;
}
return mSubCompositor->get_subsurface(window->object(), parent->object());
}
+QWaylandShellIntegration *QWaylandDisplay::shellIntegration() const
+{
+ return mWaylandIntegration->shellIntegration();
+}
+
QWaylandClientBufferIntegration * QWaylandDisplay::clientBufferIntegration() const
{
return mWaylandIntegration->clientBufferIntegration();