From 2333c58fff009435503c3b7ef3d86569227056eb Mon Sep 17 00:00:00 2001 From: Lars Knoll Date: Tue, 15 Nov 2016 15:59:13 +0100 Subject: Use the feature system internally Get rid of almost all DEFINES += ... in the pro files, instead use the proper QT_CONFIG() macro to determine whether a feature is available. Change-Id: I867769be2085c6ba93b6815e223e2b89edcb245d Reviewed-by: Paul Olav Tvete --- src/client/client.pro | 12 +--- src/client/global/qwaylandclientextension.h | 2 +- .../qwaylandclientbufferintegration_p.h | 2 +- .../qwaylandclientbufferintegrationfactory_p.h | 2 +- .../qwaylandclientbufferintegrationplugin_p.h | 2 +- .../qwaylandhardwareintegration_p.h | 2 +- .../qwaylandserverbufferintegration_p.h | 2 +- .../qwaylandserverbufferintegrationfactory_p.h | 2 +- .../qwaylandserverbufferintegrationplugin_p.h | 2 +- .../qwaylandinputdeviceintegration_p.h | 2 +- .../qwaylandinputdeviceintegrationfactory_p.h | 2 +- .../qwaylandinputdeviceintegrationplugin_p.h | 2 +- src/client/qtwaylandclientglobal.h | 70 +++++++++++++++++++++ src/client/qtwaylandclientglobal_p.h | 59 ++++++++++++++++++ src/client/qwaylandabstractdecoration_p.h | 2 +- src/client/qwaylandbuffer_p.h | 2 +- src/client/qwaylandclientexport.h | 69 --------------------- src/client/qwaylandclipboard_p.h | 2 +- src/client/qwaylandcursor_p.h | 2 +- src/client/qwaylanddatadevicemanager_p.h | 2 +- src/client/qwaylanddataoffer_p.h | 2 +- src/client/qwaylanddatasource_p.h | 2 +- src/client/qwaylanddecorationfactory_p.h | 2 +- src/client/qwaylanddecorationplugin_p.h | 2 +- src/client/qwaylanddisplay_p.h | 2 +- src/client/qwaylanddnd_p.h | 2 +- src/client/qwaylandextendedsurface_p.h | 2 +- src/client/qwaylandinputdevice.cpp | 22 +++---- src/client/qwaylandinputdevice_p.h | 9 +-- src/client/qwaylandintegration_p.h | 3 +- src/client/qwaylandnativeinterface.cpp | 2 +- src/client/qwaylandnativeinterface_p.h | 2 +- src/client/qwaylandqtkey_p.h | 2 +- src/client/qwaylandscreen_p.h | 2 +- src/client/qwaylandshellsurface_p.h | 2 +- src/client/qwaylandshm_p.h | 2 +- src/client/qwaylandsubsurface_p.h | 2 +- src/client/qwaylandtouch_p.h | 2 +- src/client/qwaylandwindow_p.h | 2 +- src/client/qwaylandwindowmanagerintegration_p.h | 2 +- src/client/qwaylandwlshellsurface_p.h | 2 +- src/client/qwaylandxdgpopup_p.h | 2 +- src/client/qwaylandxdgshell_p.h | 2 +- src/client/qwaylandxdgsurface_p.h | 2 +- .../shellintegration/qwaylandshellintegration_p.h | 3 +- .../qwaylandshellintegrationfactory_p.h | 2 +- .../qwaylandshellintegrationplugin_p.h | 2 +- src/compositor/compositor.pro | 2 - .../compositor_api/qwaylandbufferref.cpp | 2 +- src/compositor/compositor_api/qwaylandbufferref.h | 7 ++- src/compositor/compositor_api/qwaylandclient.h | 2 +- .../compositor_api/qwaylandcompositor.cpp | 21 ++++--- src/compositor/compositor_api/qwaylandcompositor.h | 2 +- .../compositor_api/qwaylandcompositor_p.h | 8 +-- .../compositor_api/qwaylanddestroylistener.h | 2 +- src/compositor/compositor_api/qwaylanddrag.h | 2 +- .../compositor_api/qwaylandinputmethodcontrol_p.h | 2 +- src/compositor/compositor_api/qwaylandkeyboard.cpp | 17 ++--- src/compositor/compositor_api/qwaylandkeyboard_p.h | 10 +-- src/compositor/compositor_api/qwaylandkeymap.h | 2 +- src/compositor/compositor_api/qwaylandoutput_p.h | 2 +- src/compositor/compositor_api/qwaylandoutputmode.h | 2 +- src/compositor/compositor_api/qwaylandpointer_p.h | 2 +- src/compositor/compositor_api/qwaylandquickitem.h | 2 +- src/compositor/compositor_api/qwaylandresource.h | 2 +- src/compositor/compositor_api/qwaylandseat.h | 2 +- src/compositor/compositor_api/qwaylandseat_p.h | 6 +- src/compositor/compositor_api/qwaylandsurface.h | 2 +- src/compositor/compositor_api/qwaylandsurface_p.h | 2 +- .../compositor_api/qwaylandsurfacegrabber.h | 2 +- src/compositor/compositor_api/qwaylandtouch_p.h | 2 +- src/compositor/compositor_api/qwaylandview.h | 2 +- src/compositor/extensions/qwaylandwlshell_p.h | 2 +- src/compositor/global/global.pri | 2 +- src/compositor/global/qtwaylandcompositorglobal.h | 72 ++++++++++++++++++++++ .../global/qtwaylandcompositorglobal_p.h | 59 ++++++++++++++++++ .../global/qwaylandcompositorextension.h | 2 +- src/compositor/global/qwaylandexport.h | 56 ----------------- .../hardware_integration/hardware_integration.pri | 4 +- .../qwlclientbufferintegration_p.h | 2 +- .../qwlclientbufferintegrationfactory_p.h | 2 +- .../qwlclientbufferintegrationplugin_p.h | 2 +- .../qwlserverbufferintegration_p.h | 2 +- .../qwlserverbufferintegrationfactory_p.h | 2 +- .../qwlserverbufferintegrationplugin_p.h | 2 +- src/compositor/wayland_wrapper/qwlclientbuffer.cpp | 4 +- src/compositor/wayland_wrapper/qwlclientbuffer_p.h | 4 +- src/compositor/wayland_wrapper/qwlregion_p.h | 2 +- src/compositor/wayland_wrapper/wayland_wrapper.pri | 5 +- .../client/wayland-egl/wayland-egl.pri | 1 - .../compositor/brcm-egl/brcm-egl.pri | 2 - src/imports/compositor/qwaylandmousetracker_p.h | 2 +- .../compositor/qwaylandquickcompositorplugin.cpp | 2 +- .../shellintegration/ivi-shell/ivi-shell.pro | 5 +- src/shared/qwaylandxkb.cpp | 4 -- src/shared/qwaylandxkb_p.h | 4 -- sync.profile | 6 ++ tests/auto/compositor/compositor/compositor.pro | 5 +- 98 files changed, 398 insertions(+), 289 deletions(-) create mode 100644 src/client/qtwaylandclientglobal.h create mode 100644 src/client/qtwaylandclientglobal_p.h delete mode 100644 src/client/qwaylandclientexport.h create mode 100644 src/compositor/global/qtwaylandcompositorglobal.h create mode 100644 src/compositor/global/qtwaylandcompositorglobal_p.h delete mode 100644 src/compositor/global/qwaylandexport.h diff --git a/src/client/client.pro b/src/client/client.pro index 749e3b6a3..7482cfd6b 100644 --- a/src/client/client.pro +++ b/src/client/client.pro @@ -15,15 +15,8 @@ use_gold_linker: CONFIG += no_linker_version_script CONFIG -= precompile_header CONFIG += link_pkgconfig wayland-scanner -qtConfig(opengl) { - DEFINES += QT_WAYLAND_GL_SUPPORT -} - -qtConfig(xkbcommon-evdev) { +qtConfig(xkbcommon-evdev): \ QMAKE_USE_PRIVATE += xkbcommon_evdev -} else { - DEFINES += QT_NO_WAYLAND_XKB -} QMAKE_USE += wayland-client wayland-cursor @@ -108,7 +101,8 @@ HEADERS += qwaylandintegration_p.h \ qwaylandinputcontext_p.h \ qwaylanddatadevice_p.h \ qwaylandshm_p.h \ - qwaylandclientexport.h \ + qtwaylandclientglobal.h \ + qtwaylandclientglobal_p.h \ ../shared/qwaylandinputmethodeventbuilder_p.h \ ../shared/qwaylandmimehelper_p.h \ ../shared/qwaylandxkb_p.h \ diff --git a/src/client/global/qwaylandclientextension.h b/src/client/global/qwaylandclientextension.h index d1610c271..37345202c 100644 --- a/src/client/global/qwaylandclientextension.h +++ b/src/client/global/qwaylandclientextension.h @@ -38,7 +38,7 @@ #define QWAYLANDCLIENTEXTENSION_H #include -#include +#include struct wl_registry; diff --git a/src/client/hardwareintegration/qwaylandclientbufferintegration_p.h b/src/client/hardwareintegration/qwaylandclientbufferintegration_p.h index adaf2902a..f1f0cf932 100644 --- a/src/client/hardwareintegration/qwaylandclientbufferintegration_p.h +++ b/src/client/hardwareintegration/qwaylandclientbufferintegration_p.h @@ -52,7 +52,7 @@ // #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/client/hardwareintegration/qwaylandclientbufferintegrationfactory_p.h b/src/client/hardwareintegration/qwaylandclientbufferintegrationfactory_p.h index c70a2bd56..7eaeed16c 100644 --- a/src/client/hardwareintegration/qwaylandclientbufferintegrationfactory_p.h +++ b/src/client/hardwareintegration/qwaylandclientbufferintegrationfactory_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/hardwareintegration/qwaylandclientbufferintegrationplugin_p.h b/src/client/hardwareintegration/qwaylandclientbufferintegrationplugin_p.h index 2830f95fa..6496b33ed 100644 --- a/src/client/hardwareintegration/qwaylandclientbufferintegrationplugin_p.h +++ b/src/client/hardwareintegration/qwaylandclientbufferintegrationplugin_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/client/hardwareintegration/qwaylandhardwareintegration_p.h b/src/client/hardwareintegration/qwaylandhardwareintegration_p.h index db9e19ac9..8b4a71629 100644 --- a/src/client/hardwareintegration/qwaylandhardwareintegration_p.h +++ b/src/client/hardwareintegration/qwaylandhardwareintegration_p.h @@ -52,7 +52,7 @@ // #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/client/hardwareintegration/qwaylandserverbufferintegration_p.h b/src/client/hardwareintegration/qwaylandserverbufferintegration_p.h index e3943da80..67f857db8 100644 --- a/src/client/hardwareintegration/qwaylandserverbufferintegration_p.h +++ b/src/client/hardwareintegration/qwaylandserverbufferintegration_p.h @@ -55,7 +55,7 @@ #include #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/client/hardwareintegration/qwaylandserverbufferintegrationfactory_p.h b/src/client/hardwareintegration/qwaylandserverbufferintegrationfactory_p.h index f17856208..600c24c9b 100644 --- a/src/client/hardwareintegration/qwaylandserverbufferintegrationfactory_p.h +++ b/src/client/hardwareintegration/qwaylandserverbufferintegrationfactory_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/hardwareintegration/qwaylandserverbufferintegrationplugin_p.h b/src/client/hardwareintegration/qwaylandserverbufferintegrationplugin_p.h index 7eaaa1700..b3ed3ccc5 100644 --- a/src/client/hardwareintegration/qwaylandserverbufferintegrationplugin_p.h +++ b/src/client/hardwareintegration/qwaylandserverbufferintegrationplugin_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/client/inputdeviceintegration/qwaylandinputdeviceintegration_p.h b/src/client/inputdeviceintegration/qwaylandinputdeviceintegration_p.h index ada63b713..1fa0fd6de 100644 --- a/src/client/inputdeviceintegration/qwaylandinputdeviceintegration_p.h +++ b/src/client/inputdeviceintegration/qwaylandinputdeviceintegration_p.h @@ -52,7 +52,7 @@ // #include -#include +#include #include diff --git a/src/client/inputdeviceintegration/qwaylandinputdeviceintegrationfactory_p.h b/src/client/inputdeviceintegration/qwaylandinputdeviceintegrationfactory_p.h index d6d0e843c..80096e790 100644 --- a/src/client/inputdeviceintegration/qwaylandinputdeviceintegrationfactory_p.h +++ b/src/client/inputdeviceintegration/qwaylandinputdeviceintegrationfactory_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/inputdeviceintegration/qwaylandinputdeviceintegrationplugin_p.h b/src/client/inputdeviceintegration/qwaylandinputdeviceintegrationplugin_p.h index c4a578d2e..2d9961dba 100644 --- a/src/client/inputdeviceintegration/qwaylandinputdeviceintegrationplugin_p.h +++ b/src/client/inputdeviceintegration/qwaylandinputdeviceintegrationplugin_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/client/qtwaylandclientglobal.h b/src/client/qtwaylandclientglobal.h new file mode 100644 index 000000000..5f474f378 --- /dev/null +++ b/src/client/qtwaylandclientglobal.h @@ -0,0 +1,70 @@ +/**************************************************************************** +** +** Copyright (C) 2016 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of the plugins of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 3 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPL3 included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 3 requirements +** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 2.0 or (at your option) the GNU General +** Public license version 3 or any later version approved by the KDE Free +** Qt Foundation. The licenses are as published by the Free Software +** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-2.0.html and +** https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef QWAYLANDCLIENTGLOBAL_H +#define QWAYLANDCLIENTGLOBAL_H + +// +// W A R N I N G +// ------------- +// +// This file is not part of the Qt API. It exists purely as an +// implementation detail. This header file may change from version to +// version without notice, or even be removed. +// +// We mean it. +// + +#include +#include + +QT_BEGIN_NAMESPACE + +#if !defined(Q_WAYLAND_CLIENT_EXPORT) +# if defined(QT_SHARED) +# define Q_WAYLAND_CLIENT_EXPORT Q_DECL_EXPORT +# else +# define Q_WAYLAND_CLIENT_EXPORT +# endif +#endif + +QT_END_NAMESPACE + +#endif //QWAYLANDCLIENTGLOBAL_H + diff --git a/src/client/qtwaylandclientglobal_p.h b/src/client/qtwaylandclientglobal_p.h new file mode 100644 index 000000000..f2106d0b8 --- /dev/null +++ b/src/client/qtwaylandclientglobal_p.h @@ -0,0 +1,59 @@ +/**************************************************************************** +** +** Copyright (C) 2016 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of the plugins of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 3 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPL3 included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 3 requirements +** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 2.0 or (at your option) the GNU General +** Public license version 3 or any later version approved by the KDE Free +** Qt Foundation. The licenses are as published by the Free Software +** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-2.0.html and +** https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef QWAYLANDCLIENTGLOBAL_P_H +#define QWAYLANDCLIENTGLOBAL_P_H + +// +// W A R N I N G +// ------------- +// +// This file is not part of the Qt API. It exists purely as an +// implementation detail. This header file may change from version to +// version without notice, or even be removed. +// +// We mean it. +// + +#include +#include +#include + +#endif //QWAYLANDCLIENTGLOBAL_P_H + diff --git a/src/client/qwaylandabstractdecoration_p.h b/src/client/qwaylandabstractdecoration_p.h index 3220dab9c..42c65be64 100644 --- a/src/client/qwaylandabstractdecoration_p.h +++ b/src/client/qwaylandabstractdecoration_p.h @@ -59,7 +59,7 @@ #include #include #include -#include +#include #include diff --git a/src/client/qwaylandbuffer_p.h b/src/client/qwaylandbuffer_p.h index 8d651f823..9e8cba2e4 100644 --- a/src/client/qwaylandbuffer_p.h +++ b/src/client/qwaylandbuffer_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/client/qwaylandclientexport.h b/src/client/qwaylandclientexport.h deleted file mode 100644 index f49f1aee9..000000000 --- a/src/client/qwaylandclientexport.h +++ /dev/null @@ -1,69 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the plugins of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 3 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL3 included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 3 requirements -** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 2.0 or (at your option) the GNU General -** Public license version 3 or any later version approved by the KDE Free -** Qt Foundation. The licenses are as published by the Free Software -** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-2.0.html and -** https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#ifndef QWAYLANDCLIENTEXPORT_H -#define QWAYLANDCLIENTEXPORT_H - -// -// W A R N I N G -// ------------- -// -// This file is not part of the Qt API. It exists purely as an -// implementation detail. This header file may change from version to -// version without notice, or even be removed. -// -// We mean it. -// - -#include - -QT_BEGIN_NAMESPACE - -#if !defined(Q_WAYLAND_CLIENT_EXPORT) -# if defined(QT_SHARED) -# define Q_WAYLAND_CLIENT_EXPORT Q_DECL_EXPORT -# else -# define Q_WAYLAND_CLIENT_EXPORT -# endif -#endif - -QT_END_NAMESPACE - -#endif //QWAYLANDCLIENTEXPORT_H - diff --git a/src/client/qwaylandclipboard_p.h b/src/client/qwaylandclipboard_p.h index 646861342..d662e512e 100644 --- a/src/client/qwaylandclipboard_p.h +++ b/src/client/qwaylandclipboard_p.h @@ -55,7 +55,7 @@ #include #include -#include +#include #ifndef QT_NO_DRAGANDDROP QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandcursor_p.h b/src/client/qwaylandcursor_p.h index 11333d34d..a7d188f56 100644 --- a/src/client/qwaylandcursor_p.h +++ b/src/client/qwaylandcursor_p.h @@ -53,7 +53,7 @@ #include #include -#include +#include struct wl_cursor; struct wl_cursor_image; diff --git a/src/client/qwaylanddatadevicemanager_p.h b/src/client/qwaylanddatadevicemanager_p.h index 90ca301b3..df8a67aba 100644 --- a/src/client/qwaylanddatadevicemanager_p.h +++ b/src/client/qwaylanddatadevicemanager_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include #ifndef QT_NO_DRAGANDDROP diff --git a/src/client/qwaylanddataoffer_p.h b/src/client/qwaylanddataoffer_p.h index 6368bff9b..07adf342a 100644 --- a/src/client/qwaylanddataoffer_p.h +++ b/src/client/qwaylanddataoffer_p.h @@ -53,7 +53,7 @@ #include -#include +#include #include #ifndef QT_NO_DRAGANDDROP diff --git a/src/client/qwaylanddatasource_p.h b/src/client/qwaylanddatasource_p.h index 9e29ae8b8..fd8601325 100644 --- a/src/client/qwaylanddatasource_p.h +++ b/src/client/qwaylanddatasource_p.h @@ -54,7 +54,7 @@ #include #include -#include +#include #ifndef QT_NO_DRAGANDDROP diff --git a/src/client/qwaylanddecorationfactory_p.h b/src/client/qwaylanddecorationfactory_p.h index 9d4e7a9fb..606d9b89c 100644 --- a/src/client/qwaylanddecorationfactory_p.h +++ b/src/client/qwaylanddecorationfactory_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylanddecorationplugin_p.h b/src/client/qwaylanddecorationplugin_p.h index dd33f3416..c549b24be 100644 --- a/src/client/qwaylanddecorationplugin_p.h +++ b/src/client/qwaylanddecorationplugin_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/client/qwaylanddisplay_p.h b/src/client/qwaylanddisplay_p.h index fae17d535..afbe67651 100644 --- a/src/client/qwaylanddisplay_p.h +++ b/src/client/qwaylanddisplay_p.h @@ -61,7 +61,7 @@ #include #include -#include +#include #include #include diff --git a/src/client/qwaylanddnd_p.h b/src/client/qwaylanddnd_p.h index 464b9837b..bcae8ace9 100644 --- a/src/client/qwaylanddnd_p.h +++ b/src/client/qwaylanddnd_p.h @@ -57,7 +57,7 @@ #include #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandextendedsurface_p.h b/src/client/qwaylandextendedsurface_p.h index 39b85438a..39dc4fcf0 100644 --- a/src/client/qwaylandextendedsurface_p.h +++ b/src/client/qwaylandextendedsurface_p.h @@ -54,7 +54,7 @@ #include #include -#include +#include #include #include diff --git a/src/client/qwaylandinputdevice.cpp b/src/client/qwaylandinputdevice.cpp index de0520890..71be6bdf8 100644 --- a/src/client/qwaylandinputdevice.cpp +++ b/src/client/qwaylandinputdevice.cpp @@ -73,7 +73,7 @@ namespace QtWaylandClient { QWaylandInputDevice::Keyboard::Keyboard(QWaylandInputDevice *p) : mParent(p) , mFocus(0) -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) , mXkbContext(0) , mXkbMap(0) , mXkbState(0) @@ -83,7 +83,7 @@ QWaylandInputDevice::Keyboard::Keyboard(QWaylandInputDevice *p) connect(&mRepeatTimer, SIGNAL(timeout()), this, SLOT(repeatKey())); } -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) bool QWaylandInputDevice::Keyboard::createDefaultKeyMap() { if (mXkbContext && mXkbMap && mXkbState) { @@ -125,7 +125,7 @@ void QWaylandInputDevice::Keyboard::releaseKeyMap() QWaylandInputDevice::Keyboard::~Keyboard() { -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) releaseKeyMap(); #endif if (mFocus) @@ -334,7 +334,7 @@ Qt::KeyboardModifiers QWaylandInputDevice::Keyboard::modifiers() const { Qt::KeyboardModifiers ret = Qt::NoModifier; -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) if (!mXkbState) return ret; @@ -602,7 +602,7 @@ void QWaylandInputDevice::Pointer::pointer_axis(uint32_t time, uint32_t axis, in void QWaylandInputDevice::Keyboard::keyboard_keymap(uint32_t format, int32_t fd, uint32_t size) { -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) if (format != WL_KEYBOARD_KEYMAP_FORMAT_XKB_V1) { close(fd); return; @@ -702,7 +702,7 @@ void QWaylandInputDevice::Keyboard::keyboard_key(uint32_t serial, uint32_t time, if (isDown) mParent->mQDisplay->setLastInputDevice(mParent, serial, window); -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) if (!createDefaultKeyMap()) { return; } @@ -720,7 +720,7 @@ void QWaylandInputDevice::Keyboard::keyboard_key(uint32_t serial, uint32_t time, #endif if (state == WL_KEYBOARD_KEY_STATE_PRESSED -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) && xkb_keymap_key_repeats(mXkbMap, code) #endif ) { @@ -728,7 +728,7 @@ void QWaylandInputDevice::Keyboard::keyboard_key(uint32_t serial, uint32_t time, mRepeatCode = code; mRepeatTime = time; mRepeatText = text; -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) mRepeatSym = sym; #endif mRepeatTimer.setInterval(400); @@ -742,7 +742,7 @@ void QWaylandInputDevice::Keyboard::repeatKey() { mRepeatTimer.setInterval(25); sendKey(mFocus->window(), mRepeatTime, QEvent::KeyRelease, mRepeatKey, modifiers(), mRepeatCode, -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) mRepeatSym, mNativeModifiers, #else 0, 0, @@ -750,7 +750,7 @@ void QWaylandInputDevice::Keyboard::repeatKey() mRepeatText, true); sendKey(mFocus->window(), mRepeatTime, QEvent::KeyPress, mRepeatKey, modifiers(), mRepeatCode, -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) mRepeatSym, mNativeModifiers, #else 0, 0, @@ -765,7 +765,7 @@ void QWaylandInputDevice::Keyboard::keyboard_modifiers(uint32_t serial, uint32_t group) { Q_UNUSED(serial); -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) if (mXkbState) xkb_state_update_mask(mXkbState, mods_depressed, mods_latched, mods_locked, diff --git a/src/client/qwaylandinputdevice_p.h b/src/client/qwaylandinputdevice_p.h index d41bde564..6d458e35d 100644 --- a/src/client/qwaylandinputdevice_p.h +++ b/src/client/qwaylandinputdevice_p.h @@ -51,6 +51,7 @@ // We mean it. // +#include #include #include @@ -64,7 +65,7 @@ #include -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) #include #include #endif @@ -194,7 +195,7 @@ public: QWaylandInputDevice *mParent; QWaylandWindow *mFocus; -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) xkb_context *mXkbContext; xkb_keymap *mXkbMap; xkb_state *mXkbState; @@ -205,7 +206,7 @@ public: uint32_t mRepeatCode; uint32_t mRepeatTime; QString mRepeatText; -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) xkb_keysym_t mRepeatSym; #endif QTimer mRepeatTimer; @@ -216,7 +217,7 @@ private slots: void repeatKey(); private: -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) bool createDefaultKeyMap(); void releaseKeyMap(); #endif diff --git a/src/client/qwaylandintegration_p.h b/src/client/qwaylandintegration_p.h index 3b91313b5..e30a10ea0 100644 --- a/src/client/qwaylandintegration_p.h +++ b/src/client/qwaylandintegration_p.h @@ -51,9 +51,8 @@ // We mean it. // +#include #include - -#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandnativeinterface.cpp b/src/client/qwaylandnativeinterface.cpp index 52c61eec1..c0b675f78 100644 --- a/src/client/qwaylandnativeinterface.cpp +++ b/src/client/qwaylandnativeinterface.cpp @@ -119,7 +119,7 @@ void *QWaylandNativeInterface::nativeResourceForScreen(const QByteArray &resourc #ifndef QT_NO_OPENGL void *QWaylandNativeInterface::nativeResourceForContext(const QByteArray &resource, QOpenGLContext *context) { -#ifdef QT_WAYLAND_GL_SUPPORT +#if QT_CONFIG(opengl) QByteArray lowerCaseResource = resource.toLower(); if (lowerCaseResource == "eglconfig" && m_integration->clientBufferIntegration()) diff --git a/src/client/qwaylandnativeinterface_p.h b/src/client/qwaylandnativeinterface_p.h index 49e52cdcb..63a543ee7 100644 --- a/src/client/qwaylandnativeinterface_p.h +++ b/src/client/qwaylandnativeinterface_p.h @@ -54,7 +54,7 @@ #include #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandqtkey_p.h b/src/client/qwaylandqtkey_p.h index b749bd5f9..155b62540 100644 --- a/src/client/qwaylandqtkey_p.h +++ b/src/client/qwaylandqtkey_p.h @@ -53,7 +53,7 @@ #include -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandscreen_p.h b/src/client/qwaylandscreen_p.h index 64980280a..9c1f46738 100644 --- a/src/client/qwaylandscreen_p.h +++ b/src/client/qwaylandscreen_p.h @@ -52,7 +52,7 @@ // #include -#include +#include #include diff --git a/src/client/qwaylandshellsurface_p.h b/src/client/qwaylandshellsurface_p.h index b51c252fd..e700d5a18 100644 --- a/src/client/qwaylandshellsurface_p.h +++ b/src/client/qwaylandshellsurface_p.h @@ -57,7 +57,7 @@ #include #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandshm_p.h b/src/client/qwaylandshm_p.h index aafe44632..519482d09 100644 --- a/src/client/qwaylandshm_p.h +++ b/src/client/qwaylandshm_p.h @@ -54,7 +54,7 @@ #include #include -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandsubsurface_p.h b/src/client/qwaylandsubsurface_p.h index 0abd168bc..00fb8d8ed 100644 --- a/src/client/qwaylandsubsurface_p.h +++ b/src/client/qwaylandsubsurface_p.h @@ -56,7 +56,7 @@ #include #include -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandtouch_p.h b/src/client/qwaylandtouch_p.h index dc32b84a0..b17bce6ab 100644 --- a/src/client/qwaylandtouch_p.h +++ b/src/client/qwaylandtouch_p.h @@ -54,7 +54,7 @@ #include #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandwindow_p.h b/src/client/qwaylandwindow_p.h index f5988fbd1..ce295a0de 100644 --- a/src/client/qwaylandwindow_p.h +++ b/src/client/qwaylandwindow_p.h @@ -60,7 +60,7 @@ #include #include -#include +#include struct wl_egl_window; diff --git a/src/client/qwaylandwindowmanagerintegration_p.h b/src/client/qwaylandwindowmanagerintegration_p.h index 09a79d48d..463b67ef6 100644 --- a/src/client/qwaylandwindowmanagerintegration_p.h +++ b/src/client/qwaylandwindowmanagerintegration_p.h @@ -58,7 +58,7 @@ #include #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandwlshellsurface_p.h b/src/client/qwaylandwlshellsurface_p.h index af86276bb..89bce5585 100644 --- a/src/client/qwaylandwlshellsurface_p.h +++ b/src/client/qwaylandwlshellsurface_p.h @@ -55,7 +55,7 @@ #include -#include +#include #include #include diff --git a/src/client/qwaylandxdgpopup_p.h b/src/client/qwaylandxdgpopup_p.h index 04416dbb6..e10e5e62b 100644 --- a/src/client/qwaylandxdgpopup_p.h +++ b/src/client/qwaylandxdgpopup_p.h @@ -47,7 +47,7 @@ #include -#include +#include #include #include diff --git a/src/client/qwaylandxdgshell_p.h b/src/client/qwaylandxdgshell_p.h index 8b35e36ab..97a15e46a 100644 --- a/src/client/qwaylandxdgshell_p.h +++ b/src/client/qwaylandxdgshell_p.h @@ -57,7 +57,7 @@ #include #include -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/qwaylandxdgsurface_p.h b/src/client/qwaylandxdgsurface_p.h index 265d3ba80..184ef13eb 100644 --- a/src/client/qwaylandxdgsurface_p.h +++ b/src/client/qwaylandxdgsurface_p.h @@ -56,7 +56,7 @@ #include -#include +#include #include #include diff --git a/src/client/shellintegration/qwaylandshellintegration_p.h b/src/client/shellintegration/qwaylandshellintegration_p.h index 144e58352..ab9b736bb 100644 --- a/src/client/shellintegration/qwaylandshellintegration_p.h +++ b/src/client/shellintegration/qwaylandshellintegration_p.h @@ -51,8 +51,7 @@ // We mean it. // -#include -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/shellintegration/qwaylandshellintegrationfactory_p.h b/src/client/shellintegration/qwaylandshellintegrationfactory_p.h index 0783465a8..3edb0a89d 100644 --- a/src/client/shellintegration/qwaylandshellintegrationfactory_p.h +++ b/src/client/shellintegration/qwaylandshellintegrationfactory_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/client/shellintegration/qwaylandshellintegrationplugin_p.h b/src/client/shellintegration/qwaylandshellintegrationplugin_p.h index be511bfc3..266e6980c 100644 --- a/src/client/shellintegration/qwaylandshellintegrationplugin_p.h +++ b/src/client/shellintegration/qwaylandshellintegrationplugin_p.h @@ -51,7 +51,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/compositor/compositor.pro b/src/compositor/compositor.pro index 935fc2527..dc9000d90 100644 --- a/src/compositor/compositor.pro +++ b/src/compositor/compositor.pro @@ -5,8 +5,6 @@ QT = core gui-private qtHaveModule(quick): QT += quick -qtConfig(opengl):MODULE_DEFINES = QT_WAYLAND_COMPOSITOR_GL - CONFIG -= precompile_header CONFIG += link_pkgconfig diff --git a/src/compositor/compositor_api/qwaylandbufferref.cpp b/src/compositor/compositor_api/qwaylandbufferref.cpp index 6f175de95..9a40fe77d 100644 --- a/src/compositor/compositor_api/qwaylandbufferref.cpp +++ b/src/compositor/compositor_api/qwaylandbufferref.cpp @@ -259,7 +259,7 @@ QImage QWaylandBufferRef::image() const return d->buffer->image(); } -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) /*! * Returns an OpenGL texture for the buffer. \a plane is the index for multi-plane formats, such as YUV. * diff --git a/src/compositor/compositor_api/qwaylandbufferref.h b/src/compositor/compositor_api/qwaylandbufferref.h index 06486ef3a..7dd3a8206 100644 --- a/src/compositor/compositor_api/qwaylandbufferref.h +++ b/src/compositor/compositor_api/qwaylandbufferref.h @@ -37,14 +37,15 @@ #ifndef QWAYLANDBUFFERREF_H #define QWAYLANDBUFFERREF_H +#include #include -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) #include #endif #include -#include +#include struct wl_resource; @@ -99,7 +100,7 @@ public: bool isSharedMemory() const; QImage image() const; -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) QOpenGLTexture *toOpenGLTexture(int plane = 0) const; #endif diff --git a/src/compositor/compositor_api/qwaylandclient.h b/src/compositor/compositor_api/qwaylandclient.h index 50e7baf72..ac651b2b3 100644 --- a/src/compositor/compositor_api/qwaylandclient.h +++ b/src/compositor/compositor_api/qwaylandclient.h @@ -37,7 +37,7 @@ #ifndef QWAYLANDCLIENT_H #define QWAYLANDCLIENT_H -#include +#include #include diff --git a/src/compositor/compositor_api/qwaylandcompositor.cpp b/src/compositor/compositor_api/qwaylandcompositor.cpp index bcee61d8b..29397f64f 100644 --- a/src/compositor/compositor_api/qwaylandcompositor.cpp +++ b/src/compositor/compositor_api/qwaylandcompositor.cpp @@ -35,6 +35,7 @@ ** ****************************************************************************/ +#include "qtwaylandcompositorglobal_p.h" #include "qwaylandcompositor.h" #include "qwaylandcompositor_p.h" @@ -60,7 +61,7 @@ #include "hardware_integration/qwlserverbufferintegration_p.h" #include "hardware_integration/qwlserverbufferintegrationfactory_p.h" -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) #include "hardware_integration/qwlhwintegration_p.h" #endif @@ -80,7 +81,7 @@ #include #include -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) # include # include # include @@ -107,7 +108,7 @@ public: uint32_t code = ke->nativeScanCode; bool isDown = ke->keyType == QEvent::KeyPress; -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) QString text; Qt::KeyboardModifiers modifiers = QWaylandXkb::modifiers(keyb->xkbState()); @@ -143,7 +144,7 @@ public: QWaylandCompositorPrivate::QWaylandCompositorPrivate(QWaylandCompositor *compositor) : display(0) -#if defined (QT_WAYLAND_COMPOSITOR_GL) +#if QT_CONFIG(opengl) , use_hw_integration_extension(true) , client_buffer_integration(0) , server_buffer_integration(0) @@ -354,7 +355,7 @@ QWaylandSurface *QWaylandCompositorPrivate::createDefaultSurface() void QWaylandCompositorPrivate::initializeHardwareIntegration() { -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) Q_Q(QWaylandCompositor); if (use_hw_integration_extension) hw_integration.reset(new QtWayland::HardwareIntegration(q)); @@ -377,7 +378,7 @@ void QWaylandCompositorPrivate::initializeSeats() void QWaylandCompositorPrivate::loadClientBufferIntegration() { -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) Q_Q(QWaylandCompositor); QStringList keys = QtWayland::ClientBufferIntegrationFactory::keys(); QString targetKey; @@ -406,7 +407,7 @@ void QWaylandCompositorPrivate::loadClientBufferIntegration() void QWaylandCompositorPrivate::loadServerBufferIntegration() { -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) QStringList keys = QtWayland::ServerBufferIntegrationFactory::keys(); QString targetKey; QByteArray serverBufferIntegration = qgetenv("QT_WAYLAND_SERVER_BUFFER_INTEGRATION"); @@ -852,7 +853,7 @@ QWaylandSeat *QWaylandCompositor::seatFor(QInputEvent *inputEvent) */ bool QWaylandCompositor::useHardwareIntegrationExtension() const { -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) Q_D(const QWaylandCompositor); return d->use_hw_integration_extension; #else @@ -862,7 +863,7 @@ bool QWaylandCompositor::useHardwareIntegrationExtension() const void QWaylandCompositor::setUseHardwareIntegrationExtension(bool use) { -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) Q_D(QWaylandCompositor); if (use == d->use_hw_integration_extension) return; @@ -892,7 +893,7 @@ void QWaylandCompositor::grabSurface(QWaylandSurfaceGrabber *grabber, const QWay if (buffer.isSharedMemory()) { emit grabber->success(buffer.image()); } else { -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) if (QOpenGLContext::currentContext()) { QOpenGLFramebufferObject fbo(buffer.size()); fbo.bind(); diff --git a/src/compositor/compositor_api/qwaylandcompositor.h b/src/compositor/compositor_api/qwaylandcompositor.h index 8b190d1d2..d0ec85f35 100644 --- a/src/compositor/compositor_api/qwaylandcompositor.h +++ b/src/compositor/compositor_api/qwaylandcompositor.h @@ -37,7 +37,7 @@ #ifndef QWAYLANDCOMPOSITOR_H #define QWAYLANDCOMPOSITOR_H -#include +#include #include #include diff --git a/src/compositor/compositor_api/qwaylandcompositor_p.h b/src/compositor/compositor_api/qwaylandcompositor_p.h index 5255f3d58..e59fdcbb5 100644 --- a/src/compositor/compositor_api/qwaylandcompositor_p.h +++ b/src/compositor/compositor_api/qwaylandcompositor_p.h @@ -49,7 +49,7 @@ // We mean it. // -#include +#include #include #include #include @@ -139,7 +139,7 @@ protected: QList clients; -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) bool use_hw_integration_extension; QScopedPointer hw_integration; QScopedPointer client_buffer_integration; @@ -159,7 +159,7 @@ protected: QtWayland::ClientBufferIntegration * QWaylandCompositorPrivate::clientBufferIntegration() const { -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) return client_buffer_integration.data(); #else return 0; @@ -168,7 +168,7 @@ QtWayland::ClientBufferIntegration * QWaylandCompositorPrivate::clientBufferInte QtWayland::ServerBufferIntegration * QWaylandCompositorPrivate::serverBufferIntegration() const { -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) return server_buffer_integration.data(); #else return 0; diff --git a/src/compositor/compositor_api/qwaylanddestroylistener.h b/src/compositor/compositor_api/qwaylanddestroylistener.h index 580a5c46a..81bbb7bc8 100644 --- a/src/compositor/compositor_api/qwaylanddestroylistener.h +++ b/src/compositor/compositor_api/qwaylanddestroylistener.h @@ -39,7 +39,7 @@ #define QWAYLANDDESTROYLISTENER_H #include -#include +#include struct wl_resource; diff --git a/src/compositor/compositor_api/qwaylanddrag.h b/src/compositor/compositor_api/qwaylanddrag.h index 08ad11018..df1924740 100644 --- a/src/compositor/compositor_api/qwaylanddrag.h +++ b/src/compositor/compositor_api/qwaylanddrag.h @@ -37,7 +37,7 @@ #ifndef QWAYLANDDRAG_H #define QWAYLANDDRAG_H -#include +#include #include #include diff --git a/src/compositor/compositor_api/qwaylandinputmethodcontrol_p.h b/src/compositor/compositor_api/qwaylandinputmethodcontrol_p.h index a4f9ce877..4517f5eee 100644 --- a/src/compositor/compositor_api/qwaylandinputmethodcontrol_p.h +++ b/src/compositor/compositor_api/qwaylandinputmethodcontrol_p.h @@ -48,7 +48,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/compositor/compositor_api/qwaylandkeyboard.cpp b/src/compositor/compositor_api/qwaylandkeyboard.cpp index 5bbec0a45..55381b450 100644 --- a/src/compositor/compositor_api/qwaylandkeyboard.cpp +++ b/src/compositor/compositor_api/qwaylandkeyboard.cpp @@ -35,6 +35,7 @@ ** ****************************************************************************/ +#include "qtwaylandcompositorglobal_p.h" #include "qwaylandkeyboard.h" #include "qwaylandkeyboard_p.h" #include @@ -47,7 +48,7 @@ #include #include -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) #include #include #endif @@ -65,7 +66,7 @@ QWaylandKeyboardPrivate::QWaylandKeyboardPrivate(QWaylandSeat *seat) , modsLocked() , group() , pendingKeymap(false) -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) , keymap_fd(-1) , xkb_state(0) #endif @@ -76,7 +77,7 @@ QWaylandKeyboardPrivate::QWaylandKeyboardPrivate(QWaylandSeat *seat) QWaylandKeyboardPrivate::~QWaylandKeyboardPrivate() { -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) if (xkb_context) { if (keymap_area) munmap(keymap_area, keymap_size); @@ -146,7 +147,7 @@ void QWaylandKeyboardPrivate::keyboard_bind_resource(wl_keyboard::Resource *reso if (resource->version() >= WL_KEYBOARD_REPEAT_INFO_SINCE_VERSION) send_repeat_info(resource->handle, repeatRate, repeatDelay); -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) if (xkb_context) { send_keymap(resource->handle, WL_KEYBOARD_KEYMAP_FORMAT_XKB_V1, keymap_fd, keymap_size); @@ -201,7 +202,7 @@ void QWaylandKeyboardPrivate::modifiers(uint32_t serial, uint32_t mods_depressed void QWaylandKeyboardPrivate::updateModifierState(uint code, uint32_t state) { -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) if (!xkb_context) return; @@ -241,7 +242,7 @@ void QWaylandKeyboardPrivate::maybeUpdateKeymap() return; pendingKeymap = false; -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) if (!xkb_context) return; @@ -261,7 +262,7 @@ void QWaylandKeyboardPrivate::maybeUpdateKeymap() #endif } -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) static int createAnonymousFile(size_t size) { QString path = QStandardPaths::writableLocation(QStandardPaths::RuntimeLocation); @@ -404,7 +405,7 @@ QWaylandKeyboard::QWaylandKeyboard(QWaylandSeat *seat, QObject *parent) connect(keymap, &QWaylandKeymap::optionsChanged, this, &QWaylandKeyboard::updateKeymap); connect(keymap, &QWaylandKeymap::rulesChanged, this, &QWaylandKeyboard::updateKeymap); connect(keymap, &QWaylandKeymap::modelChanged, this, &QWaylandKeyboard::updateKeymap); -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) d->initXKB(); #endif } diff --git a/src/compositor/compositor_api/qwaylandkeyboard_p.h b/src/compositor/compositor_api/qwaylandkeyboard_p.h index fc43853cc..b65dab440 100644 --- a/src/compositor/compositor_api/qwaylandkeyboard_p.h +++ b/src/compositor/compositor_api/qwaylandkeyboard_p.h @@ -49,7 +49,7 @@ // We mean it. // -#include +#include #include #include #include @@ -59,7 +59,7 @@ #include -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) #include #endif @@ -83,7 +83,7 @@ public: void modifiers(uint32_t serial, uint32_t mods_depressed, uint32_t mods_latched, uint32_t mods_locked, uint32_t group); -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) struct xkb_state *xkbState() const { return xkb_state; } uint32_t xkbModsMask() const { return modsDepressed | modsLatched | modsLocked; } #endif @@ -102,7 +102,7 @@ protected: void keyboard_release(Resource *resource) Q_DECL_OVERRIDE; private: -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) void initXKB(); void createXKBKeymap(); void createXKBState(xkb_keymap *keymap); @@ -124,7 +124,7 @@ private: uint32_t group; bool pendingKeymap; -#ifndef QT_NO_WAYLAND_XKB +#if QT_CONFIG(xkbcommon_evdev) size_t keymap_size; int keymap_fd; char *keymap_area; diff --git a/src/compositor/compositor_api/qwaylandkeymap.h b/src/compositor/compositor_api/qwaylandkeymap.h index c543691df..b72807a9b 100644 --- a/src/compositor/compositor_api/qwaylandkeymap.h +++ b/src/compositor/compositor_api/qwaylandkeymap.h @@ -38,7 +38,7 @@ #define QWAYLANDKEYMAP_H #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/compositor/compositor_api/qwaylandoutput_p.h b/src/compositor/compositor_api/qwaylandoutput_p.h index 638575db9..dffde7f98 100644 --- a/src/compositor/compositor_api/qwaylandoutput_p.h +++ b/src/compositor/compositor_api/qwaylandoutput_p.h @@ -50,7 +50,7 @@ // We mean it. // -#include +#include #include #include #include diff --git a/src/compositor/compositor_api/qwaylandoutputmode.h b/src/compositor/compositor_api/qwaylandoutputmode.h index aa44be920..0bcdaa6c3 100644 --- a/src/compositor/compositor_api/qwaylandoutputmode.h +++ b/src/compositor/compositor_api/qwaylandoutputmode.h @@ -37,7 +37,7 @@ #ifndef QWAYLANDOUTPUTMODE_H #define QWAYLANDOUTPUTMODE_H -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/compositor/compositor_api/qwaylandpointer_p.h b/src/compositor/compositor_api/qwaylandpointer_p.h index 54ac72d11..c02f831b7 100644 --- a/src/compositor/compositor_api/qwaylandpointer_p.h +++ b/src/compositor/compositor_api/qwaylandpointer_p.h @@ -49,7 +49,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/compositor/compositor_api/qwaylandquickitem.h b/src/compositor/compositor_api/qwaylandquickitem.h index 821826d69..524813c4c 100644 --- a/src/compositor/compositor_api/qwaylandquickitem.h +++ b/src/compositor/compositor_api/qwaylandquickitem.h @@ -37,7 +37,7 @@ #ifndef QWAYLANDSURFACEITEM_H #define QWAYLANDSURFACEITEM_H -#include +#include #include #include diff --git a/src/compositor/compositor_api/qwaylandresource.h b/src/compositor/compositor_api/qwaylandresource.h index bfb4b0969..32a6d53f4 100644 --- a/src/compositor/compositor_api/qwaylandresource.h +++ b/src/compositor/compositor_api/qwaylandresource.h @@ -38,7 +38,7 @@ #define QWAYLANDRESOURCE_H #include -#include +#include struct wl_resource; diff --git a/src/compositor/compositor_api/qwaylandseat.h b/src/compositor/compositor_api/qwaylandseat.h index 3e90342c7..49c63260e 100644 --- a/src/compositor/compositor_api/qwaylandseat.h +++ b/src/compositor/compositor_api/qwaylandseat.h @@ -41,7 +41,7 @@ #include #include -#include +#include #include #include diff --git a/src/compositor/compositor_api/qwaylandseat_p.h b/src/compositor/compositor_api/qwaylandseat_p.h index eb86aec37..1d6870802 100644 --- a/src/compositor/compositor_api/qwaylandseat_p.h +++ b/src/compositor/compositor_api/qwaylandseat_p.h @@ -50,7 +50,7 @@ #include -#include +#include #include #include @@ -58,10 +58,6 @@ #include #include -#ifndef QT_NO_WAYLAND_XKB -#include -#endif - #include QT_BEGIN_NAMESPACE diff --git a/src/compositor/compositor_api/qwaylandsurface.h b/src/compositor/compositor_api/qwaylandsurface.h index 40753ad47..380436956 100644 --- a/src/compositor/compositor_api/qwaylandsurface.h +++ b/src/compositor/compositor_api/qwaylandsurface.h @@ -38,7 +38,7 @@ #ifndef QWAYLANDSURFACE_H #define QWAYLANDSURFACE_H -#include +#include #include #include diff --git a/src/compositor/compositor_api/qwaylandsurface_p.h b/src/compositor/compositor_api/qwaylandsurface_p.h index 94ec287bd..232631077 100644 --- a/src/compositor/compositor_api/qwaylandsurface_p.h +++ b/src/compositor/compositor_api/qwaylandsurface_p.h @@ -49,7 +49,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/compositor/compositor_api/qwaylandsurfacegrabber.h b/src/compositor/compositor_api/qwaylandsurfacegrabber.h index 28f984102..512bd2ab9 100644 --- a/src/compositor/compositor_api/qwaylandsurfacegrabber.h +++ b/src/compositor/compositor_api/qwaylandsurfacegrabber.h @@ -37,7 +37,7 @@ #ifndef QWAYLANDSURFACEGRABBER_H #define QWAYLANDSURFACEGRABBER_H -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/compositor/compositor_api/qwaylandtouch_p.h b/src/compositor/compositor_api/qwaylandtouch_p.h index 75529134b..9ee3e9c17 100644 --- a/src/compositor/compositor_api/qwaylandtouch_p.h +++ b/src/compositor/compositor_api/qwaylandtouch_p.h @@ -49,7 +49,7 @@ // We mean it. // -#include +#include #include #include #include diff --git a/src/compositor/compositor_api/qwaylandview.h b/src/compositor/compositor_api/qwaylandview.h index 987340034..e19f1ec4b 100644 --- a/src/compositor/compositor_api/qwaylandview.h +++ b/src/compositor/compositor_api/qwaylandview.h @@ -38,7 +38,7 @@ #define QWAYLANDSURFACEVIEW_H #include -#include +#include #include #include diff --git a/src/compositor/extensions/qwaylandwlshell_p.h b/src/compositor/extensions/qwaylandwlshell_p.h index a087f6f75..77229ef03 100644 --- a/src/compositor/extensions/qwaylandwlshell_p.h +++ b/src/compositor/extensions/qwaylandwlshell_p.h @@ -37,7 +37,7 @@ #ifndef QWAYLANDWLSHELL_P_H #define QWAYLANDWLSHELL_P_H -#include +#include #include #include #include diff --git a/src/compositor/global/global.pri b/src/compositor/global/global.pri index e48b8a8c2..29d4f4376 100644 --- a/src/compositor/global/global.pri +++ b/src/compositor/global/global.pri @@ -1,7 +1,7 @@ INCLUDEPATH += global/ HEADERS += \ - global/qwaylandexport.h \ + global/qtwaylandcompositorglobal.h \ global/qwaylandcompositorextension.h \ global/qwaylandcompositorextension_p.h \ global/qwaylandquickextension.h \ diff --git a/src/compositor/global/qtwaylandcompositorglobal.h b/src/compositor/global/qtwaylandcompositorglobal.h new file mode 100644 index 000000000..403f1962a --- /dev/null +++ b/src/compositor/global/qtwaylandcompositorglobal.h @@ -0,0 +1,72 @@ +/**************************************************************************** +** +** Copyright (C) 2016 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of the plugins of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 3 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPL3 included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 3 requirements +** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 2.0 or (at your option) the GNU General +** Public license version 3 or any later version approved by the KDE Free +** Qt Foundation. The licenses are as published by the Free Software +** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-2.0.html and +** https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef QWAYLANDCOMPOSITORGLOBAL_H +#define QWAYLANDCOMPOSITORGLOBAL_H + +// +// W A R N I N G +// ------------- +// +// This file is not part of the Qt API. It exists purely as an +// implementation detail. This header file may change from version to +// version without notice, or even be removed. +// +// We mean it. +// + +#include +#include + +QT_BEGIN_NAMESPACE + +#if !defined(Q_WAYLAND_COMPOSITOR_EXPORT) +# if defined(QT_SHARED) && defined(QT_BUILD_COMPOSITOR_LIB) +# define Q_WAYLAND_COMPOSITOR_EXPORT Q_DECL_EXPORT +# elif defined(QT_SHARED) +# define Q_WAYLAND_COMPOSITOR_EXPORT Q_DECL_IMPORT +# else +# define Q_WAYLAND_COMPOSITOR_EXPORT +# endif +#endif + +QT_END_NAMESPACE + +#endif // QWAYLANDCOMPOSITORGLOBAL_H + diff --git a/src/compositor/global/qtwaylandcompositorglobal_p.h b/src/compositor/global/qtwaylandcompositorglobal_p.h new file mode 100644 index 000000000..629d58292 --- /dev/null +++ b/src/compositor/global/qtwaylandcompositorglobal_p.h @@ -0,0 +1,59 @@ +/**************************************************************************** +** +** Copyright (C) 2016 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of the plugins of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 3 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPL3 included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 3 requirements +** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 2.0 or (at your option) the GNU General +** Public license version 3 or any later version approved by the KDE Free +** Qt Foundation. The licenses are as published by the Free Software +** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-2.0.html and +** https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef QWAYLANDCOMPOSITORGLOBAL_P_H +#define QWAYLANDCOMPOSITORGLOBAL_P_H + +// +// W A R N I N G +// ------------- +// +// This file is not part of the Qt API. It exists purely as an +// implementation detail. This header file may change from version to +// version without notice, or even be removed. +// +// We mean it. +// + +#include +#include +#include + +#endif // QWAYLANDCOMPOSITORGLOBAL_P_H + diff --git a/src/compositor/global/qwaylandcompositorextension.h b/src/compositor/global/qwaylandcompositorextension.h index d666b4f2a..e9aa84609 100644 --- a/src/compositor/global/qwaylandcompositorextension.h +++ b/src/compositor/global/qwaylandcompositorextension.h @@ -37,7 +37,7 @@ #ifndef QWAYLANDEXTENSION_H #define QWAYLANDEXTENSION_H -#include +#include #include #include diff --git a/src/compositor/global/qwaylandexport.h b/src/compositor/global/qwaylandexport.h deleted file mode 100644 index ddfa6aa77..000000000 --- a/src/compositor/global/qwaylandexport.h +++ /dev/null @@ -1,56 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2015 The Qt Company Ltd. -** Contact: http://www.qt.io/licensing/ -** -** This file is part of the QtWaylandCompositor module of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL3$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see http://www.qt.io/terms-conditions. For further -** information use the contact form at http://www.qt.io/contact-us. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 3 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPLv3 included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 3 requirements -** will be met: https://www.gnu.org/licenses/lgpl.html. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 2.0 or later as published by the Free -** Software Foundation and appearing in the file LICENSE.GPL included in -** the packaging of this file. Please review the following information to -** ensure the GNU General Public License version 2.0 requirements will be -** met: http://www.gnu.org/licenses/gpl-2.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#ifndef WAYLANDEXPORT_H -#define WAYLANDEXPORT_H - -#include - -QT_BEGIN_NAMESPACE - -#if !defined(Q_WAYLAND_COMPOSITOR_EXPORT) -# if defined(QT_SHARED) && defined(QT_BUILD_COMPOSITOR_LIB) -# define Q_WAYLAND_COMPOSITOR_EXPORT Q_DECL_EXPORT -# elif defined(QT_SHARED) -# define Q_WAYLAND_COMPOSITOR_EXPORT Q_DECL_IMPORT -# else -# define Q_WAYLAND_COMPOSITOR_EXPORT -# endif -#endif - -QT_END_NAMESPACE - -#endif //WAYLANDEXPORT_H diff --git a/src/compositor/hardware_integration/hardware_integration.pri b/src/compositor/hardware_integration/hardware_integration.pri index 624190a6e..dd892e07a 100644 --- a/src/compositor/hardware_integration/hardware_integration.pri +++ b/src/compositor/hardware_integration/hardware_integration.pri @@ -1,4 +1,4 @@ -contains(QT_CONFIG, opengl) { +qtConfig(opengl) { CONFIG += wayland-scanner WAYLANDSERVERSOURCES += \ ../extensions/server-buffer-extension.xml \ @@ -21,8 +21,6 @@ contains(QT_CONFIG, opengl) { hardware_integration/qwlserverbufferintegrationfactory.cpp \ hardware_integration/qwlserverbufferintegrationplugin.cpp \ hardware_integration/qwlhwintegration.cpp \ - - DEFINES += QT_WAYLAND_COMPOSITOR_GL } else { system(echo "Qt-Compositor configured as raster only compositor") } diff --git a/src/compositor/hardware_integration/qwlclientbufferintegration_p.h b/src/compositor/hardware_integration/qwlclientbufferintegration_p.h index a7de2c0e3..c4bed1002 100644 --- a/src/compositor/hardware_integration/qwlclientbufferintegration_p.h +++ b/src/compositor/hardware_integration/qwlclientbufferintegration_p.h @@ -48,7 +48,7 @@ // We mean it. // -#include +#include #include #include #include diff --git a/src/compositor/hardware_integration/qwlclientbufferintegrationfactory_p.h b/src/compositor/hardware_integration/qwlclientbufferintegrationfactory_p.h index 3c1d856c7..1ed99083b 100644 --- a/src/compositor/hardware_integration/qwlclientbufferintegrationfactory_p.h +++ b/src/compositor/hardware_integration/qwlclientbufferintegrationfactory_p.h @@ -48,7 +48,7 @@ // We mean it. // -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/compositor/hardware_integration/qwlclientbufferintegrationplugin_p.h b/src/compositor/hardware_integration/qwlclientbufferintegrationplugin_p.h index d8bc33fbe..e8fca43f6 100644 --- a/src/compositor/hardware_integration/qwlclientbufferintegrationplugin_p.h +++ b/src/compositor/hardware_integration/qwlclientbufferintegrationplugin_p.h @@ -48,7 +48,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/compositor/hardware_integration/qwlserverbufferintegration_p.h b/src/compositor/hardware_integration/qwlserverbufferintegration_p.h index 3a71f18f7..9a1287fa4 100644 --- a/src/compositor/hardware_integration/qwlserverbufferintegration_p.h +++ b/src/compositor/hardware_integration/qwlserverbufferintegration_p.h @@ -52,7 +52,7 @@ #include #include -#include +#include struct wl_client; struct wl_resource; diff --git a/src/compositor/hardware_integration/qwlserverbufferintegrationfactory_p.h b/src/compositor/hardware_integration/qwlserverbufferintegrationfactory_p.h index b29ddd041..15d54a292 100644 --- a/src/compositor/hardware_integration/qwlserverbufferintegrationfactory_p.h +++ b/src/compositor/hardware_integration/qwlserverbufferintegrationfactory_p.h @@ -48,7 +48,7 @@ // We mean it. // -#include +#include #include QT_BEGIN_NAMESPACE diff --git a/src/compositor/hardware_integration/qwlserverbufferintegrationplugin_p.h b/src/compositor/hardware_integration/qwlserverbufferintegrationplugin_p.h index fc8c3bf1e..6c144d74c 100644 --- a/src/compositor/hardware_integration/qwlserverbufferintegrationplugin_p.h +++ b/src/compositor/hardware_integration/qwlserverbufferintegrationplugin_p.h @@ -48,7 +48,7 @@ // We mean it. // -#include +#include #include #include diff --git a/src/compositor/wayland_wrapper/qwlclientbuffer.cpp b/src/compositor/wayland_wrapper/qwlclientbuffer.cpp index 589ab825b..d52950388 100644 --- a/src/compositor/wayland_wrapper/qwlclientbuffer.cpp +++ b/src/compositor/wayland_wrapper/qwlclientbuffer.cpp @@ -36,7 +36,7 @@ #include "qwlclientbuffer_p.h" -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) #include "hardware_integration/qwlclientbufferintegration_p.h" #include #include @@ -150,7 +150,7 @@ QImage SharedMemoryBuffer::image() const return QImage(); } -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) QOpenGLTexture *SharedMemoryBuffer::toOpenGlTexture(int plane) { Q_UNUSED(plane); diff --git a/src/compositor/wayland_wrapper/qwlclientbuffer_p.h b/src/compositor/wayland_wrapper/qwlclientbuffer_p.h index 78e07ee98..dafb3c5e5 100644 --- a/src/compositor/wayland_wrapper/qwlclientbuffer_p.h +++ b/src/compositor/wayland_wrapper/qwlclientbuffer_p.h @@ -97,7 +97,7 @@ public: bool isSharedMemory() const { return wl_shm_buffer_get(m_buffer); } -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) virtual QOpenGLTexture *toOpenGlTexture(int plane = 0) = 0; #endif @@ -132,7 +132,7 @@ public: QWaylandSurface::Origin origin() const Q_DECL_OVERRIDE; QImage image() const; -#ifdef QT_WAYLAND_COMPOSITOR_GL +#if QT_CONFIG(opengl) QOpenGLTexture *toOpenGlTexture(int plane = 0) Q_DECL_OVERRIDE; private: diff --git a/src/compositor/wayland_wrapper/qwlregion_p.h b/src/compositor/wayland_wrapper/qwlregion_p.h index ca14c7a51..c63cdbc45 100644 --- a/src/compositor/wayland_wrapper/qwlregion_p.h +++ b/src/compositor/wayland_wrapper/qwlregion_p.h @@ -48,7 +48,7 @@ // We mean it. // -#include +#include #include diff --git a/src/compositor/wayland_wrapper/wayland_wrapper.pri b/src/compositor/wayland_wrapper/wayland_wrapper.pri index 388303405..48e55e513 100644 --- a/src/compositor/wayland_wrapper/wayland_wrapper.pri +++ b/src/compositor/wayland_wrapper/wayland_wrapper.pri @@ -24,8 +24,5 @@ SOURCES += \ INCLUDEPATH += wayland_wrapper -qtConfig(xkbcommon-evdev) { +qtConfig(xkbcommon-evdev): \ QMAKE_USE += xkbcommon_evdev -} else { - DEFINES += QT_NO_WAYLAND_XKB -} diff --git a/src/hardwareintegration/client/wayland-egl/wayland-egl.pri b/src/hardwareintegration/client/wayland-egl/wayland-egl.pri index f812144a1..d7634b150 100644 --- a/src/hardwareintegration/client/wayland-egl/wayland-egl.pri +++ b/src/hardwareintegration/client/wayland-egl/wayland-egl.pri @@ -2,7 +2,6 @@ INCLUDEPATH += $$PWD QMAKE_USE += egl wayland-client wayland-egl -DEFINES += QT_EGL_WAYLAND QT += egl_support-private SOURCES += $$PWD/qwaylandeglclientbufferintegration.cpp \ diff --git a/src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri b/src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri index 2658e84b2..e5f3d9174 100644 --- a/src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri +++ b/src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri @@ -2,8 +2,6 @@ QT = waylandcompositor waylandcompositor-private core-private gui-private INCLUDEPATH += $$PWD -DEFINES += QT_NO_OPENGL_ES_3 - QMAKE_USE_PRIVATE += wayland-server for(p, QMAKE_LIBDIR_EGL) { diff --git a/src/imports/compositor/qwaylandmousetracker_p.h b/src/imports/compositor/qwaylandmousetracker_p.h index d90b037ff..45c80208a 100644 --- a/src/imports/compositor/qwaylandmousetracker_p.h +++ b/src/imports/compositor/qwaylandmousetracker_p.h @@ -39,7 +39,7 @@ #include -#include +#include QT_BEGIN_NAMESPACE diff --git a/src/imports/compositor/qwaylandquickcompositorplugin.cpp b/src/imports/compositor/qwaylandquickcompositorplugin.cpp index 28c517fd5..0caa4a357 100644 --- a/src/imports/compositor/qwaylandquickcompositorplugin.cpp +++ b/src/imports/compositor/qwaylandquickcompositorplugin.cpp @@ -59,7 +59,7 @@ #include #include -#include +#include #include "qwaylandmousetracker_p.h" QT_BEGIN_NAMESPACE diff --git a/src/plugins/shellintegration/ivi-shell/ivi-shell.pro b/src/plugins/shellintegration/ivi-shell/ivi-shell.pro index d254b9fc1..baaf1698b 100644 --- a/src/plugins/shellintegration/ivi-shell/ivi-shell.pro +++ b/src/plugins/shellintegration/ivi-shell/ivi-shell.pro @@ -6,11 +6,8 @@ CONFIG += wayland-scanner QMAKE_USE += wayland-client -qtConfig(xkbcommon-evdev) { +qtConfig(xkbcommon-evdev): \ QMAKE_USE += xkbcommon_evdev -} else { - DEFINES += QT_NO_WAYLAND_XKB -} WAYLANDCLIENTSOURCES += \ ../../../3rdparty/protocol/ivi-application.xml \ diff --git a/src/shared/qwaylandxkb.cpp b/src/shared/qwaylandxkb.cpp index 2afdcce8a..3e04467de 100644 --- a/src/shared/qwaylandxkb.cpp +++ b/src/shared/qwaylandxkb.cpp @@ -43,8 +43,6 @@ #include #include -#ifndef QT_NO_WAYLAND_XKB - #include QT_BEGIN_NAMESPACE @@ -377,5 +375,3 @@ QVector QWaylandXkb::toKeysym(QKeyEvent *event) } QT_END_NAMESPACE - -#endif // QT_NO_WAYLAND_XKB diff --git a/src/shared/qwaylandxkb_p.h b/src/shared/qwaylandxkb_p.h index cdebf1b08..230159fbb 100644 --- a/src/shared/qwaylandxkb_p.h +++ b/src/shared/qwaylandxkb_p.h @@ -41,8 +41,6 @@ #ifndef QWAYLANDXKB_H #define QWAYLANDXKB_H -#ifndef QT_NO_WAYLAND_XKB - #include #include #include @@ -65,6 +63,4 @@ public: QT_END_NAMESPACE -#endif // QT_NO_WAYLAND_XKB - #endif diff --git a/sync.profile b/sync.profile index 1276df081..458ee9f23 100644 --- a/sync.profile +++ b/sync.profile @@ -7,6 +7,12 @@ %classnames = ( ); %deprecatedheaders = ( + "QtWaylandClient" => { + "qwaylandclientexport.h" => "QtWaylandClient/qtwaylandclientglobal.h" + }, + "QtWaylandCompositor" => { + "qwaylandexport.h" => "QtWaylandCompositor/qtwaylandcompositorglobal.h" + } ); %classnames = ( "qwaylandquickextension.h" => "QWaylandQuickExtension", diff --git a/tests/auto/compositor/compositor/compositor.pro b/tests/auto/compositor/compositor/compositor.pro index c0b919631..f0cdaf32c 100644 --- a/tests/auto/compositor/compositor/compositor.pro +++ b/tests/auto/compositor/compositor/compositor.pro @@ -7,11 +7,8 @@ QT += core-private gui-private waylandcompositor waylandcompositor-private QMAKE_USE += wayland-client wayland-server -qtConfig(xkbcommon-evdev) { +qtConfig(xkbcommon-evdev) QMAKE_USE += xkbcommon_evdev -} else { - DEFINES += QT_NO_WAYLAND_XKB -} WAYLANDCLIENTSOURCES += \ ../../../../src/3rdparty/protocol/xdg-shell.xml \ -- cgit v1.2.3