From e6255beec9114afd1fad9e7d62ebec433a627d54 Mon Sep 17 00:00:00 2001 From: Giulio Camuffo Date: Thu, 29 Jan 2015 14:35:44 +0200 Subject: Namespace the platform plugins MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There currently is a QWaylandInputDevice class both in the wayland QPA plugin and in the QtCompositor API. This causes the qwindow-compositor example to crash when running nested in a wayland session due to a mismatch between the two classes. By namespacing all the plugin code we make sure that name clashes will not happen anymore. Change-Id: I17497cff697599200bea68bf01dfde474526390f Reviewed-by: Jørgen Lind --- src/plugins/hardwareintegration/client/brcm-egl/main.cpp | 4 ++++ src/plugins/hardwareintegration/client/drm-egl-server/main.cpp | 4 ++++ src/plugins/hardwareintegration/client/libhybris-egl-server/main.cpp | 4 ++++ src/plugins/hardwareintegration/client/wayland-egl/main.cpp | 4 ++++ src/plugins/hardwareintegration/client/xcomposite-egl/main.cpp | 4 ++++ src/plugins/hardwareintegration/client/xcomposite-glx/main.cpp | 4 ++++ 6 files changed, 24 insertions(+) (limited to 'src/plugins/hardwareintegration/client') diff --git a/src/plugins/hardwareintegration/client/brcm-egl/main.cpp b/src/plugins/hardwareintegration/client/brcm-egl/main.cpp index c023332eb..eb0d99c4c 100644 --- a/src/plugins/hardwareintegration/client/brcm-egl/main.cpp +++ b/src/plugins/hardwareintegration/client/brcm-egl/main.cpp @@ -44,6 +44,8 @@ QT_BEGIN_NAMESPACE +namespace QtWaylandClient { + class QWaylandBrcmEglClientBufferPlugin : public QWaylandClientBufferIntegrationPlugin { Q_OBJECT @@ -59,6 +61,8 @@ QWaylandClientBufferIntegration *QWaylandBrcmEglClientBufferPlugin::create(const return new QWaylandBrcmEglIntegration(); } +} + QT_END_NAMESPACE #include "main.moc" diff --git a/src/plugins/hardwareintegration/client/drm-egl-server/main.cpp b/src/plugins/hardwareintegration/client/drm-egl-server/main.cpp index 6a3df4431..3a74a8f8e 100644 --- a/src/plugins/hardwareintegration/client/drm-egl-server/main.cpp +++ b/src/plugins/hardwareintegration/client/drm-egl-server/main.cpp @@ -44,6 +44,8 @@ QT_BEGIN_NAMESPACE +namespace QtWaylandClient { + class DrmEglServerBufferPlugin : public QWaylandServerBufferIntegrationPlugin { Q_OBJECT @@ -59,6 +61,8 @@ QWaylandServerBufferIntegration *DrmEglServerBufferPlugin::create(const QString& return new DrmEglServerBufferIntegration(); } +} + QT_END_NAMESPACE #include "main.moc" diff --git a/src/plugins/hardwareintegration/client/libhybris-egl-server/main.cpp b/src/plugins/hardwareintegration/client/libhybris-egl-server/main.cpp index 9aee15790..18d002e2c 100644 --- a/src/plugins/hardwareintegration/client/libhybris-egl-server/main.cpp +++ b/src/plugins/hardwareintegration/client/libhybris-egl-server/main.cpp @@ -44,6 +44,8 @@ QT_BEGIN_NAMESPACE +namespace QtWaylandClient { + class LibHybrisEglServerBufferPlugin : public QWaylandServerBufferIntegrationPlugin { Q_OBJECT @@ -59,6 +61,8 @@ QWaylandServerBufferIntegration *LibHybrisEglServerBufferPlugin::create(const QS return new LibHybrisEglServerBufferIntegration(); } +} + QT_END_NAMESPACE #include "main.moc" diff --git a/src/plugins/hardwareintegration/client/wayland-egl/main.cpp b/src/plugins/hardwareintegration/client/wayland-egl/main.cpp index e4cd8c1f0..020a41e02 100644 --- a/src/plugins/hardwareintegration/client/wayland-egl/main.cpp +++ b/src/plugins/hardwareintegration/client/wayland-egl/main.cpp @@ -44,6 +44,8 @@ QT_BEGIN_NAMESPACE +namespace QtWaylandClient { + class QWaylandEglClientBufferPlugin : public QWaylandClientBufferIntegrationPlugin { Q_OBJECT @@ -59,6 +61,8 @@ QWaylandClientBufferIntegration *QWaylandEglClientBufferPlugin::create(const QSt return new QWaylandEglClientBufferIntegration(); } +} + QT_END_NAMESPACE #include "main.moc" diff --git a/src/plugins/hardwareintegration/client/xcomposite-egl/main.cpp b/src/plugins/hardwareintegration/client/xcomposite-egl/main.cpp index 4b9835f1d..eddb5cbdc 100644 --- a/src/plugins/hardwareintegration/client/xcomposite-egl/main.cpp +++ b/src/plugins/hardwareintegration/client/xcomposite-egl/main.cpp @@ -44,6 +44,8 @@ QT_BEGIN_NAMESPACE +namespace QtWaylandClient { + class QWaylandXCompositeEglClientBufferIntegrationPlugin : public QWaylandClientBufferIntegrationPlugin { Q_OBJECT @@ -59,6 +61,8 @@ QWaylandClientBufferIntegration *QWaylandXCompositeEglClientBufferIntegrationPlu return new QWaylandXCompositeEGLClientBufferIntegration(); } +} + QT_END_NAMESPACE #include "main.moc" diff --git a/src/plugins/hardwareintegration/client/xcomposite-glx/main.cpp b/src/plugins/hardwareintegration/client/xcomposite-glx/main.cpp index 2c6f0fde8..0b3c31334 100644 --- a/src/plugins/hardwareintegration/client/xcomposite-glx/main.cpp +++ b/src/plugins/hardwareintegration/client/xcomposite-glx/main.cpp @@ -44,6 +44,8 @@ QT_BEGIN_NAMESPACE +namespace QtWaylandClient { + class QWaylandXCompositeGlxClientBufferIntegrationPlugin : public QWaylandClientBufferIntegrationPlugin { Q_OBJECT @@ -59,6 +61,8 @@ QWaylandClientBufferIntegration *QWaylandXCompositeGlxClientBufferIntegrationPlu return new QWaylandXCompositeGLXIntegration(); } +} + QT_END_NAMESPACE #include "main.moc" -- cgit v1.2.3