diff options
Diffstat (limited to 'src/compositor/compositor_api/qwaylandcompositorquickextensions_p.h')
-rw-r--r-- | src/compositor/compositor_api/qwaylandcompositorquickextensions_p.h | 50 |
1 files changed, 15 insertions, 35 deletions
diff --git a/src/compositor/compositor_api/qwaylandcompositorquickextensions_p.h b/src/compositor/compositor_api/qwaylandcompositorquickextensions_p.h index 4a1763884..7e59a5d6e 100644 --- a/src/compositor/compositor_api/qwaylandcompositorquickextensions_p.h +++ b/src/compositor/compositor_api/qwaylandcompositorquickextensions_p.h @@ -1,31 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2020 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the QtWaylandCompositor module of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL$ -** 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 General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 or (at your option) 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.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-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #ifndef QWAYLANDCOMPOSITORQUICKEXTENSIONS_P_H #define QWAYLANDCOMPOSITORQUICKEXTENSIONS_P_H @@ -49,12 +23,14 @@ #include <QtWaylandCompositor/qwaylandquickcompositor.h> #include <QtWaylandCompositor/qwaylandqtwindowmanager.h> #include <QtWaylandCompositor/qwaylandtextinputmanager.h> +#include <QtCore/private/qglobal_p.h> +#include <QtWaylandCompositor/qwaylandtextinputmanagerv3.h> #include <QtWaylandCompositor/qwaylandqttextinputmethodmanager.h> #include <QtWaylandCompositor/qwaylandidleinhibitv1.h> QT_BEGIN_NAMESPACE -class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandQuickCompositorQuickExtensionContainer : public QWaylandQuickCompositor +class Q_WAYLANDCOMPOSITOR_EXPORT QWaylandQuickCompositorQuickExtensionContainer : public QWaylandQuickCompositor { Q_OBJECT Q_PROPERTY(QQmlListProperty<QWaylandCompositorExtension> extensions READ extensions) @@ -77,12 +53,12 @@ public: &clearFunction); } - static int countFunction(QQmlListProperty<QWaylandCompositorExtension> *list) + static qsizetype countFunction(QQmlListProperty<QWaylandCompositorExtension> *list) { return static_cast<QWaylandQuickCompositorQuickExtensionContainer *>(list->data)->extension_vector.size(); } - static QWaylandCompositorExtension *atFunction(QQmlListProperty<QWaylandCompositorExtension> *list, int index) + static QWaylandCompositorExtension *atFunction(QQmlListProperty<QWaylandCompositorExtension> *list, qsizetype index) { return static_cast<QWaylandQuickCompositorQuickExtensionContainer *>(list->data)->extension_vector.at(index); } @@ -104,10 +80,14 @@ private: // Note: These have to be in a header with a Q_OBJECT macro, otherwise we won't run moc on it -Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_CLASS(QWaylandQtWindowManager, QtWindowManager) -Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_CLASS(QWaylandIdleInhibitManagerV1, IdleInhibitManagerV1) -Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_CLASS(QWaylandTextInputManager, TextInputManager) -Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_CLASS(QWaylandQtTextInputMethodManager, QtTextInputMethodManager) +Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_ELEMENT(QWaylandQtWindowManager, QtWindowManager, 1, 0) +Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_ELEMENT(QWaylandIdleInhibitManagerV1, + IdleInhibitManagerV1, 1, 0) +Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_ELEMENT(QWaylandTextInputManager, TextInputManager, 1, 0) +Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_ELEMENT(QWaylandTextInputManagerV3, TextInputManagerV3, + 1, 0) +Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_NAMED_ELEMENT(QWaylandQtTextInputMethodManager, + QtTextInputMethodManager, 1, 0) QT_END_NAMESPACE |