From 4a0f32aa4bf4c4f3a70fe0514302294ea30ab6fa Mon Sep 17 00:00:00 2001 From: Pier Luigi Fiorini Date: Sat, 3 Jan 2015 17:03:13 +0100 Subject: [PATCH] Remove output extension This protocol is empty now and is no longer used. Change-Id: I45e79fb86a67b4cebdc307170218fa039b2aa27f Reviewed-by: Giulio Camuffo --- .../wayland/extensions/output-extension.xml | 51 ---------------- src/plugins/platforms/wayland/client.pro | 3 - .../platforms/wayland/qwaylanddisplay.cpp | 6 -- .../platforms/wayland/qwaylanddisplay_p.h | 2 - .../wayland/qwaylandextendedoutput.cpp | 53 ----------------- .../wayland/qwaylandextendedoutput_p.h | 58 ------------------- .../platforms/wayland/qwaylandscreen.cpp | 16 ----- .../platforms/wayland/qwaylandscreen_p.h | 5 -- 8 files changed, 194 deletions(-) delete mode 100644 src/3rdparty/wayland/extensions/output-extension.xml delete mode 100644 src/plugins/platforms/wayland/qwaylandextendedoutput.cpp delete mode 100644 src/plugins/platforms/wayland/qwaylandextendedoutput_p.h diff --git a/src/3rdparty/wayland/extensions/output-extension.xml b/src/3rdparty/wayland/extensions/output-extension.xml deleted file mode 100644 index b1a2f4db7b1..00000000000 --- a/src/3rdparty/wayland/extensions/output-extension.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - Copyright (C) 2015 The Qt Company Ltd. - Contact: http://www.qt.io/licensing/ - - This file is part of the plugins of the Qt Toolkit. - - $QT_BEGIN_LICENSE:BSD$ - You may use this file under the terms of the BSD license as follows: - - "Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are - met: - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in - the documentation and/or other materials provided with the - distribution. - * Neither the name of The Qt Company Ltd nor the names of its - contributors may be used to endorse or promote products derived - from this software without specific prior written permission. - - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." - - $QT_END_LICENSE$ - - - - - - - - - - - - - diff --git a/src/plugins/platforms/wayland/client.pro b/src/plugins/platforms/wayland/client.pro index 00e9cd04a97..08c184a5e59 100644 --- a/src/plugins/platforms/wayland/client.pro +++ b/src/plugins/platforms/wayland/client.pro @@ -44,7 +44,6 @@ WAYLANDCLIENTSOURCES += \ ../3rdparty/protocol/wayland.xml \ ../extensions/surface-extension.xml \ ../extensions/sub-surface-extension.xml \ - ../extensions/output-extension.xml \ ../extensions/touch-extension.xml \ ../extensions/qtkey-extension.xml \ ../extensions/windowmanager.xml \ @@ -69,7 +68,6 @@ SOURCES += qwaylandintegration.cpp \ qwaylandwlshellsurface.cpp \ qwaylandxdgshell.cpp \ qwaylandxdgsurface.cpp \ - qwaylandextendedoutput.cpp \ qwaylandextendedsurface.cpp \ qwaylandsubsurface.cpp \ qwaylandtouch.cpp \ @@ -102,7 +100,6 @@ HEADERS += qwaylandintegration_p.h \ qwaylandwlshellsurface_p.h \ qwaylandxdgshell_p.h \ qwaylandxdgsurface_p.h \ - qwaylandextendedoutput_p.h \ qwaylandextendedsurface_p.h \ qwaylandsubsurface_p.h \ qwaylandtouch_p.h \ diff --git a/src/plugins/platforms/wayland/qwaylanddisplay.cpp b/src/plugins/platforms/wayland/qwaylanddisplay.cpp index b985f10e5b6..6bad56ae3f0 100644 --- a/src/plugins/platforms/wayland/qwaylanddisplay.cpp +++ b/src/plugins/platforms/wayland/qwaylanddisplay.cpp @@ -50,7 +50,6 @@ #include "qwaylandshellintegration_p.h" #include "qwaylandclientbufferintegration_p.h" -#include "qwaylandextendedoutput_p.h" #include "qwaylandextendedsurface_p.h" #include "qwaylandsubsurface_p.h" #include "qwaylandtouch_p.h" @@ -127,7 +126,6 @@ QWaylandDisplay::QWaylandDisplay(QWaylandIntegration *waylandIntegration) , mDndSelectionHandler(0) , mWindowExtension(0) , mSubSurfaceExtension(0) - , mOutputExtension(0) , mTouchExtension(0) , mQtKeyExtension(0) , mTextInputManager(0) @@ -255,10 +253,6 @@ void QWaylandDisplay::registry_global(uint32_t id, const QString &interface, uin mInputDevices.append(inputDevice); } else if (interface == QStringLiteral("wl_data_device_manager")) { mDndSelectionHandler.reset(new QWaylandDataDeviceManager(this, id)); - } else if (interface == QStringLiteral("qt_output_extension")) { - mOutputExtension.reset(new QtWayland::qt_output_extension(registry, id, 1)); - foreach (QPlatformScreen *screen, screens()) - static_cast(screen)->createExtendedOutput(); } else if (interface == QStringLiteral("qt_surface_extension")) { mWindowExtension.reset(new QtWayland::qt_surface_extension(registry, id, 1)); } else if (interface == QStringLiteral("qt_sub_surface_extension")) { diff --git a/src/plugins/platforms/wayland/qwaylanddisplay_p.h b/src/plugins/platforms/wayland/qwaylanddisplay_p.h index 4549d52e6a6..bbd0e871dda 100644 --- a/src/plugins/platforms/wayland/qwaylanddisplay_p.h +++ b/src/plugins/platforms/wayland/qwaylanddisplay_p.h @@ -128,7 +128,6 @@ public: QtWayland::qt_surface_extension *windowExtension() const { return mWindowExtension.data(); } QtWayland::qt_sub_surface_extension *subSurfaceExtension() const { return mSubSurfaceExtension.data(); } - QtWayland::qt_output_extension *outputExtension() const { return mOutputExtension.data(); } QWaylandTouchExtension *touchExtension() const { return mTouchExtension.data(); } QtWayland::wl_text_input_manager *textInputManager() const { return mTextInputManager.data(); } QWaylandHardwareIntegration *hardwareIntegration() const { return mHardwareIntegration.data(); } @@ -189,7 +188,6 @@ private: QScopedPointer mDndSelectionHandler; QScopedPointer mWindowExtension; QScopedPointer mSubSurfaceExtension; - QScopedPointer mOutputExtension; QScopedPointer mTouchExtension; QScopedPointer mQtKeyExtension; QScopedPointer mWindowManagerIntegration; diff --git a/src/plugins/platforms/wayland/qwaylandextendedoutput.cpp b/src/plugins/platforms/wayland/qwaylandextendedoutput.cpp deleted file mode 100644 index d1e8ffe2f9e..00000000000 --- a/src/plugins/platforms/wayland/qwaylandextendedoutput.cpp +++ /dev/null @@ -1,53 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2015 The Qt Company Ltd. -** Contact: http://www.qt.io/licensing/ -** -** This file is part of the plugins of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL21$ -** 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 2.1 or version 3 as published by the Free -** Software Foundation and appearing in the file LICENSE.LGPLv21 and -** LICENSE.LGPLv3 included in the packaging of this file. Please review the -** following information to ensure the GNU Lesser General Public License -** requirements will be met: https://www.gnu.org/licenses/lgpl.html and -** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** As a special exception, The Qt Company gives you certain additional -** rights. These rights are described in The Qt Company LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#include "qwaylandextendedoutput_p.h" - -#include "qwaylandscreen_p.h" - -#include - -#include - -QT_BEGIN_NAMESPACE - -namespace QtWaylandClient { - -QWaylandExtendedOutput::QWaylandExtendedOutput(QWaylandScreen *screen, ::qt_extended_output *extended_output) - : QtWayland::qt_extended_output(extended_output) -{ - Q_UNUSED(screen); -} - -} -QT_END_NAMESPACE diff --git a/src/plugins/platforms/wayland/qwaylandextendedoutput_p.h b/src/plugins/platforms/wayland/qwaylandextendedoutput_p.h deleted file mode 100644 index b3e4c469e50..00000000000 --- a/src/plugins/platforms/wayland/qwaylandextendedoutput_p.h +++ /dev/null @@ -1,58 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2015 The Qt Company Ltd. -** Contact: http://www.qt.io/licensing/ -** -** This file is part of the plugins of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL21$ -** 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 2.1 or version 3 as published by the Free -** Software Foundation and appearing in the file LICENSE.LGPLv21 and -** LICENSE.LGPLv3 included in the packaging of this file. Please review the -** following information to ensure the GNU Lesser General Public License -** requirements will be met: https://www.gnu.org/licenses/lgpl.html and -** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** As a special exception, The Qt Company gives you certain additional -** rights. These rights are described in The Qt Company LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#ifndef QWAYLANDEXTENDEDOUTPUT_H -#define QWAYLANDEXTENDEDOUTPUT_H - -#include -#include - -QT_BEGIN_NAMESPACE - -namespace QtWaylandClient { - -class QWaylandDisplay; -class QWaylandScreen; -class QWaylandExtendedOutput; - -class Q_WAYLAND_CLIENT_EXPORT QWaylandExtendedOutput : public QtWayland::qt_extended_output -{ -public: - QWaylandExtendedOutput(QWaylandScreen *screen, struct ::qt_extended_output *extended_output); -}; - -} - -QT_END_NAMESPACE - -#endif // QWAYLANDEXTENDEDOUTPUT_H diff --git a/src/plugins/platforms/wayland/qwaylandscreen.cpp b/src/plugins/platforms/wayland/qwaylandscreen.cpp index acd125c6275..057515af02b 100644 --- a/src/plugins/platforms/wayland/qwaylandscreen.cpp +++ b/src/plugins/platforms/wayland/qwaylandscreen.cpp @@ -35,7 +35,6 @@ #include "qwaylanddisplay_p.h" #include "qwaylandcursor_p.h" -#include "qwaylandextendedoutput_p.h" #include "qwaylandwindow_p.h" #include @@ -52,7 +51,6 @@ QWaylandScreen::QWaylandScreen(QWaylandDisplay *waylandDisplay, int version, uin , QtWayland::wl_output(waylandDisplay->wl_registry(), id, qMin(version, 2)) , m_outputId(id) , mWaylandDisplay(waylandDisplay) - , mExtendedOutput(0) , mScale(1) , mDepth(32) , mRefreshRate(60000) @@ -62,8 +60,6 @@ QWaylandScreen::QWaylandScreen(QWaylandDisplay *waylandDisplay, int version, uin , m_orientation(Qt::PrimaryOrientation) , mWaylandCursor(new QWaylandCursor(this)) { - // handle case of output extension global being sent after outputs - createExtendedOutput(); } QWaylandScreen::~QWaylandScreen() @@ -152,18 +148,6 @@ QPlatformCursor *QWaylandScreen::cursor() const return mWaylandCursor; } -QWaylandExtendedOutput *QWaylandScreen::extendedOutput() const -{ - return mExtendedOutput; -} - -void QWaylandScreen::createExtendedOutput() -{ - QtWayland::qt_output_extension *extension = mWaylandDisplay->outputExtension(); - if (!mExtendedOutput && extension) - mExtendedOutput = new QWaylandExtendedOutput(this, extension->get_extended_output(output())); -} - QWaylandScreen * QWaylandScreen::waylandScreenFromWindow(QWindow *window) { QPlatformScreen *platformScreen = QPlatformScreen::platformScreenForWindow(window); diff --git a/src/plugins/platforms/wayland/qwaylandscreen_p.h b/src/plugins/platforms/wayland/qwaylandscreen_p.h index 35adee34a5b..e2acac4b3a3 100644 --- a/src/plugins/platforms/wayland/qwaylandscreen_p.h +++ b/src/plugins/platforms/wayland/qwaylandscreen_p.h @@ -45,7 +45,6 @@ namespace QtWaylandClient { class QWaylandDisplay; class QWaylandCursor; -class QWaylandExtendedOutput; class Q_WAYLAND_CLIENT_EXPORT QWaylandScreen : public QPlatformScreen, QtWayland::wl_output { @@ -79,9 +78,6 @@ public: uint32_t outputId() const { return m_outputId; } ::wl_output *output() { return object(); } - QWaylandExtendedOutput *extendedOutput() const; - void createExtendedOutput(); - static QWaylandScreen *waylandScreenFromWindow(QWindow *window); private: @@ -97,7 +93,6 @@ private: int m_outputId; QWaylandDisplay *mWaylandDisplay; - QWaylandExtendedOutput *mExtendedOutput; QRect mGeometry; int mScale; int mDepth;