diff options
author | Johan Klokkhammer Helsing <johan.helsing@qt.io> | 2018-08-21 16:31:38 +0200 |
---|---|---|
committer | Johan Helsing <johan.helsing@qt.io> | 2018-08-29 06:36:17 +0000 |
commit | ec01fddd6b14fa26d9ae9e9f693c6fd419f5ba2c (patch) | |
tree | a0c8a3a76f61df7e24c29cdc6e7686eaa884f553 /src | |
parent | 9875a14daaec12ca65d3cb4a2aaf2c4582e6191d (diff) | |
download | qtwayland-ec01fddd6b14fa26d9ae9e9f693c6fd419f5ba2c.tar.gz |
Fix incompatibility between QML and C++ instantiated objects
This fixes a source incompatibility introduced in 9ebba7c3a. In Qt 5.11 it was
possible to have the following code:
XdgShellV6 {
property XdgToplevelV6 top
onToplevelCreated: top = toplevel
}
After, 9ebba7c3a, however, this would fail because XdgToplevel refers to
QWaylandXdgToplevelV6ParentClass, while QWaylandXdgShellV6::toplevelCreated
emits a QWaylandXdgToplevelV6.
It would also break instanceof, i.e.:
onToplevelCreated: console.log(toplevel instanceof XdgToplevelV6)
This patch reverts to C++ and QML using the same type (no subclassing for QML
types), but still lets the items have children in QML by putting the macro
inside each class instead.
Task-number: QTBUG-70090
Change-Id: I8efa8f68ebc4dc2289b4a9b96402b0c00d45547d
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/compositor/compositor_api/compositor_api.pri | 1 | ||||
-rw-r--r-- | src/compositor/compositor_api/qwaylandkeymap.h | 2 | ||||
-rw-r--r-- | src/compositor/compositor_api/qwaylandquickchildren.h | 98 | ||||
-rw-r--r-- | src/compositor/compositor_api/qwaylandquickoutput.h | 2 | ||||
-rw-r--r-- | src/compositor/compositor_api/qwaylandquicksurface.h | 2 | ||||
-rw-r--r-- | src/compositor/extensions/qwaylandivisurface.h | 2 | ||||
-rw-r--r-- | src/compositor/extensions/qwaylandwlshell.h | 2 | ||||
-rw-r--r-- | src/compositor/extensions/qwaylandxdgshell.h | 2 | ||||
-rw-r--r-- | src/compositor/extensions/qwaylandxdgshellv5.h | 3 | ||||
-rw-r--r-- | src/compositor/extensions/qwaylandxdgshellv6.h | 2 | ||||
-rw-r--r-- | src/compositor/global/qwaylandquickextension.h | 36 | ||||
-rw-r--r-- | src/imports/compositor/qwaylandquickcompositorplugin.cpp | 27 |
12 files changed, 125 insertions, 54 deletions
diff --git a/src/compositor/compositor_api/compositor_api.pri b/src/compositor/compositor_api/compositor_api.pri index 4a0c0aa6..3df06145 100644 --- a/src/compositor/compositor_api/compositor_api.pri +++ b/src/compositor/compositor_api/compositor_api.pri @@ -27,6 +27,7 @@ HEADERS += \ compositor_api/qwaylandresource.h \ compositor_api/qwaylandsurfacegrabber.h \ compositor_api/qwaylandoutputmode_p.h \ + compositor_api/qwaylandquickchildren.h SOURCES += \ compositor_api/qwaylandcompositor.cpp \ diff --git a/src/compositor/compositor_api/qwaylandkeymap.h b/src/compositor/compositor_api/qwaylandkeymap.h index d96c409b..8058e144 100644 --- a/src/compositor/compositor_api/qwaylandkeymap.h +++ b/src/compositor/compositor_api/qwaylandkeymap.h @@ -42,6 +42,7 @@ #include <QtCore/QObject> #include <QtWaylandCompositor/qtwaylandcompositorglobal.h> +#include <QtWaylandCompositor/qwaylandquickchildren.h> QT_BEGIN_NAMESPACE @@ -51,6 +52,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandKeymap : public QObject { Q_OBJECT Q_DECLARE_PRIVATE(QWaylandKeymap) + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandKeymap) Q_PROPERTY(QString layout READ layout WRITE setLayout NOTIFY layoutChanged) Q_PROPERTY(QString variant READ variant WRITE setVariant NOTIFY variantChanged) Q_PROPERTY(QString options READ options WRITE setOptions NOTIFY optionsChanged) diff --git a/src/compositor/compositor_api/qwaylandquickchildren.h b/src/compositor/compositor_api/qwaylandquickchildren.h new file mode 100644 index 00000000..e1f51f4f --- /dev/null +++ b/src/compositor/compositor_api/qwaylandquickchildren.h @@ -0,0 +1,98 @@ +/**************************************************************************** +** +** Copyright (C) 2018 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 QWAYLANDQUICKCHILDREN_H +#define QWAYLANDQUICKCHILDREN_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. +// + +#ifdef QT_WAYLAND_COMPOSITOR_QUICK +#include <QtQml/QQmlListProperty> +#include <QtCore/QVector> +#endif + +QT_BEGIN_NAMESPACE + +#ifdef QT_WAYLAND_COMPOSITOR_QUICK +#define Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(className) \ + Q_PROPERTY(QQmlListProperty<QObject> data READ data DESIGNABLE false) \ + Q_CLASSINFO("DefaultProperty", "data") \ + public: \ + QQmlListProperty<QObject> data() \ + { \ + return QQmlListProperty<QObject>(this, this, \ + &className::appendFunction, \ + &className::countFunction, \ + &className::atFunction, \ + &className::clearFunction); \ + } \ + static void appendFunction(QQmlListProperty<QObject> *list, QObject *object) \ + { \ + static_cast<className *>(list->data)->m_children.append(object); \ + } \ + static int countFunction(QQmlListProperty<QObject> *list) \ + { \ + return static_cast<className *>(list->data)->m_children.size(); \ + } \ + static QObject *atFunction(QQmlListProperty<QObject> *list, int index) \ + { \ + return static_cast<className *>(list->data)->m_children.at(index); \ + } \ + static void clearFunction(QQmlListProperty<QObject> *list) \ + { \ + static_cast<className *>(list->data)->m_children.clear(); \ + } \ + private: \ + QVector<QObject *> m_children; +#else +#define Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(className) +#endif + +QT_END_NAMESPACE + +#endif // QWAYLANDQUICKCHILDREN_H diff --git a/src/compositor/compositor_api/qwaylandquickoutput.h b/src/compositor/compositor_api/qwaylandquickoutput.h index cd79f14f..5f3749b0 100644 --- a/src/compositor/compositor_api/qwaylandquickoutput.h +++ b/src/compositor/compositor_api/qwaylandquickoutput.h @@ -43,6 +43,7 @@ #include <QtQuick/QQuickWindow> #include <QtWaylandCompositor/qwaylandoutput.h> +#include <QtWaylandCompositor/qwaylandquickchildren.h> QT_BEGIN_NAMESPACE @@ -53,6 +54,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandQuickOutput : public QWaylandOutput, p { Q_INTERFACES(QQmlParserStatus) Q_OBJECT + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandQuickOutput) Q_PROPERTY(bool automaticFrameCallback READ automaticFrameCallback WRITE setAutomaticFrameCallback NOTIFY automaticFrameCallbackChanged) public: QWaylandQuickOutput(); diff --git a/src/compositor/compositor_api/qwaylandquicksurface.h b/src/compositor/compositor_api/qwaylandquicksurface.h index a234b776..258f1a22 100644 --- a/src/compositor/compositor_api/qwaylandquicksurface.h +++ b/src/compositor/compositor_api/qwaylandquicksurface.h @@ -41,6 +41,7 @@ #define QQUICKWAYLANDSURFACE_H #include <QtWaylandCompositor/qwaylandsurface.h> +#include <QtWaylandCompositor/qwaylandquickchildren.h> struct wl_client; @@ -53,6 +54,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandQuickSurface : public QWaylandSurface { Q_OBJECT Q_DECLARE_PRIVATE(QWaylandQuickSurface) + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandQuickSurface) Q_PROPERTY(bool useTextureAlpha READ useTextureAlpha WRITE setUseTextureAlpha NOTIFY useTextureAlphaChanged) Q_PROPERTY(bool clientRenderingEnabled READ clientRenderingEnabled WRITE setClientRenderingEnabled NOTIFY clientRenderingEnabledChanged) public: diff --git a/src/compositor/extensions/qwaylandivisurface.h b/src/compositor/extensions/qwaylandivisurface.h index ce5001d1..65d5bbc8 100644 --- a/src/compositor/extensions/qwaylandivisurface.h +++ b/src/compositor/extensions/qwaylandivisurface.h @@ -41,6 +41,7 @@ #define QWAYLANDIVISURFACE_H #include <QtWaylandCompositor/QWaylandShellSurface> +#include <QtWaylandCompositor/qwaylandquickchildren.h> struct wl_resource; @@ -56,6 +57,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandIviSurface : public QWaylandShellSurfa { Q_OBJECT Q_DECLARE_PRIVATE(QWaylandIviSurface) + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandIviSurface) Q_PROPERTY(QWaylandSurface *surface READ surface NOTIFY surfaceChanged) Q_PROPERTY(uint iviId READ iviId NOTIFY iviIdChanged) diff --git a/src/compositor/extensions/qwaylandwlshell.h b/src/compositor/extensions/qwaylandwlshell.h index 4923b4fb..42188800 100644 --- a/src/compositor/extensions/qwaylandwlshell.h +++ b/src/compositor/extensions/qwaylandwlshell.h @@ -44,6 +44,7 @@ #include <QtWaylandCompositor/QWaylandResource> #include <QtWaylandCompositor/QWaylandShell> #include <QtWaylandCompositor/QWaylandShellSurface> +#include <QtWaylandCompositor/qwaylandquickchildren.h> #include <QtCore/QSize> @@ -87,6 +88,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandWlShellSurface : public QWaylandShellS { Q_OBJECT Q_DECLARE_PRIVATE(QWaylandWlShellSurface) + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandWlShellSurface) Q_PROPERTY(QWaylandSurface *surface READ surface NOTIFY surfaceChanged) Q_PROPERTY(QWaylandWlShell *shell READ shell NOTIFY shellChanged) Q_PROPERTY(QString title READ title NOTIFY titleChanged) diff --git a/src/compositor/extensions/qwaylandxdgshell.h b/src/compositor/extensions/qwaylandxdgshell.h index c2807f77..2b6f6356 100644 --- a/src/compositor/extensions/qwaylandxdgshell.h +++ b/src/compositor/extensions/qwaylandxdgshell.h @@ -41,6 +41,7 @@ #include <QtWaylandCompositor/QWaylandResource> #include <QtWaylandCompositor/QWaylandShell> #include <QtWaylandCompositor/QWaylandShellSurface> +#include <QtWaylandCompositor/qwaylandquickchildren.h> #include <QtCore/QRect> @@ -93,6 +94,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandXdgSurface : public QWaylandShellSurfa { Q_OBJECT Q_DECLARE_PRIVATE(QWaylandXdgSurface) + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandXdgSurface) Q_PROPERTY(QWaylandXdgShell *shell READ shell NOTIFY shellChanged) Q_PROPERTY(QWaylandSurface *surface READ surface NOTIFY surfaceChanged) Q_PROPERTY(QWaylandXdgToplevel *toplevel READ toplevel NOTIFY toplevelCreated) diff --git a/src/compositor/extensions/qwaylandxdgshellv5.h b/src/compositor/extensions/qwaylandxdgshellv5.h index 05b49f6e..f989d04c 100644 --- a/src/compositor/extensions/qwaylandxdgshellv5.h +++ b/src/compositor/extensions/qwaylandxdgshellv5.h @@ -44,6 +44,7 @@ #include <QtWaylandCompositor/QWaylandResource> #include <QtWaylandCompositor/QWaylandShell> #include <QtWaylandCompositor/QWaylandShellSurface> +#include <QtWaylandCompositor/qwaylandquickchildren.h> #include <QtCore/QRect> @@ -98,6 +99,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandXdgSurfaceV5 : public QWaylandShellSur { Q_OBJECT Q_DECLARE_PRIVATE(QWaylandXdgSurfaceV5) + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandXdgSurfaceV5) Q_PROPERTY(QWaylandXdgShellV5 *shell READ shell NOTIFY shellChanged) Q_PROPERTY(QWaylandSurface *surface READ surface NOTIFY surfaceChanged) Q_PROPERTY(QWaylandXdgSurfaceV5 *parentSurface READ parentSurface NOTIFY parentSurfaceChanged) @@ -212,6 +214,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandXdgPopupV5 : public QWaylandShellSurfa { Q_OBJECT Q_DECLARE_PRIVATE(QWaylandXdgPopupV5) + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandXdgPopupV5) Q_PROPERTY(QWaylandXdgShellV5 *shell READ shell NOTIFY shellChanged) Q_PROPERTY(QWaylandSurface *surface READ surface NOTIFY surfaceChanged) Q_PROPERTY(QWaylandSurface *parentSurface READ parentSurface NOTIFY parentSurfaceChanged) diff --git a/src/compositor/extensions/qwaylandxdgshellv6.h b/src/compositor/extensions/qwaylandxdgshellv6.h index 8c5eee8a..b9c47c57 100644 --- a/src/compositor/extensions/qwaylandxdgshellv6.h +++ b/src/compositor/extensions/qwaylandxdgshellv6.h @@ -41,6 +41,7 @@ #include <QtWaylandCompositor/QWaylandResource> #include <QtWaylandCompositor/QWaylandShell> #include <QtWaylandCompositor/QWaylandShellSurface> +#include <QtWaylandCompositor/qwaylandquickchildren.h> #include <QtCore/QRect> @@ -93,6 +94,7 @@ class Q_WAYLAND_COMPOSITOR_EXPORT QWaylandXdgSurfaceV6 : public QWaylandShellSur { Q_OBJECT Q_DECLARE_PRIVATE(QWaylandXdgSurfaceV6) + Q_WAYLAND_COMPOSITOR_DECLARE_QUICK_CHILDREN(QWaylandXdgSurfaceV6) Q_PROPERTY(QWaylandXdgShellV6 *shell READ shell NOTIFY shellChanged) Q_PROPERTY(QWaylandSurface *surface READ surface NOTIFY surfaceChanged) Q_PROPERTY(QWaylandXdgToplevelV6 *toplevel READ toplevel NOTIFY toplevelCreated) diff --git a/src/compositor/global/qwaylandquickextension.h b/src/compositor/global/qwaylandquickextension.h index a0e07dad..c721bcb9 100644 --- a/src/compositor/global/qwaylandquickextension.h +++ b/src/compositor/global/qwaylandquickextension.h @@ -107,42 +107,6 @@ QT_BEGIN_NAMESPACE QList<QObject *> m_objects; \ }; -#define Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(className) \ - class Q_WAYLAND_COMPOSITOR_EXPORT className##QuickParent : public className \ - { \ -/* qmake ignore Q_OBJECT */ \ - Q_OBJECT \ - Q_PROPERTY(QQmlListProperty<QObject> data READ data DESIGNABLE false) \ - Q_CLASSINFO("DefaultProperty", "data") \ - public: \ - QQmlListProperty<QObject> data() \ - { \ - return QQmlListProperty<QObject>(this, this, \ - &className##QuickParent::appendFunction, \ - &className##QuickParent::countFunction, \ - &className##QuickParent::atFunction, \ - &className##QuickParent::clearFunction); \ - } \ - static void appendFunction(QQmlListProperty<QObject> *list, QObject *object) \ - { \ - static_cast<className##QuickParent *>(list->data)->m_children.append(object); \ - } \ - static int countFunction(QQmlListProperty<QObject> *list) \ - { \ - return static_cast<className##QuickParent *>(list->data)->m_children.size(); \ - } \ - static QObject *atFunction(QQmlListProperty<QObject> *list, int index) \ - { \ - return static_cast<className##QuickParent *>(list->data)->m_children.at(index); \ - } \ - static void clearFunction(QQmlListProperty<QObject> *list) \ - { \ - static_cast<className##QuickParent *>(list->data)->m_children.clear(); \ - } \ - private: \ - QVector<QObject *> m_children; \ - }; - QT_END_NAMESPACE #endif /*QWAYLANDQUICKEXTENSION_H*/ diff --git a/src/imports/compositor/qwaylandquickcompositorplugin.cpp b/src/imports/compositor/qwaylandquickcompositorplugin.cpp index f4e72789..1c576b6a 100644 --- a/src/imports/compositor/qwaylandquickcompositorplugin.cpp +++ b/src/imports/compositor/qwaylandquickcompositorplugin.cpp @@ -74,21 +74,12 @@ QT_BEGIN_NAMESPACE Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CONTAINER_CLASS(QWaylandQuickCompositor) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandQuickOutput) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandQuickSurface) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandKeymap) Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandQtWindowManager) Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandIviApplication) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandIviSurface) Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandWlShell) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandWlShellSurface) Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandXdgShellV5) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandXdgSurfaceV5) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandXdgPopupV5) Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandXdgShellV6) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandXdgSurfaceV6) Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandXdgShell) -Q_COMPOSITOR_DECLARE_QUICK_PARENT_CLASS(QWaylandXdgSurface) Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandXdgDecorationManagerV1) Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandTextInputManager) @@ -141,9 +132,9 @@ public: qmlRegisterType<QWaylandQuickItem>(uri, 1, 0, "WaylandQuickItem"); qmlRegisterType<QWaylandQuickHardwareLayer>(uri, 1, 2, "WaylandHardwareLayer"); qmlRegisterType<QWaylandMouseTracker>(uri, 1, 0, "WaylandMouseTracker"); - qmlRegisterType<QWaylandQuickOutputQuickParent>(uri, 1, 0, "WaylandOutput"); - qmlRegisterType<QWaylandQuickSurfaceQuickParent>(uri, 1, 0, "WaylandSurface"); - qmlRegisterType<QWaylandKeymapQuickParent>(uri, 1, 0, "WaylandKeymap"); + qmlRegisterType<QWaylandQuickOutput>(uri, 1, 0, "WaylandOutput"); + qmlRegisterType<QWaylandQuickSurface>(uri, 1, 0, "WaylandSurface"); + qmlRegisterType<QWaylandKeymap>(uri, 1, 0, "WaylandKeymap"); qmlRegisterUncreatableType<QWaylandCompositorExtension>(uri, 1, 0, "WaylandExtension", QObject::tr("Cannot create instance of WaylandExtension")); qmlRegisterUncreatableType<QWaylandClient>(uri, 1, 0, "WaylandClient", QObject::tr("Cannot create instance of WaylandClient")); @@ -161,23 +152,23 @@ public: //This should probably be somewhere else qmlRegisterType<QWaylandQtWindowManagerQuickExtension>(uri, 1, 0, "QtWindowManager"); qmlRegisterType<QWaylandIviApplicationQuickExtension>(uri, 1, 0, "IviApplication"); - qmlRegisterType<QWaylandIviSurfaceQuickParent>(uri, 1, 0, "IviSurface"); + qmlRegisterType<QWaylandIviSurface>(uri, 1, 0, "IviSurface"); qmlRegisterType<QWaylandWlShellQuickExtension>(uri, 1, 0, "WlShell"); - qmlRegisterType<QWaylandWlShellSurfaceQuickParent>(uri, 1, 0, "WlShellSurface"); + qmlRegisterType<QWaylandWlShellSurface>(uri, 1, 0, "WlShellSurface"); qmlRegisterType<QWaylandQuickShellSurfaceItem>(uri, 1, 0, "ShellSurfaceItem"); qmlRegisterUncreatableType<QWaylandXdgShellV5>(uri, 1, 0, "XdgShellV5Base", QObject::tr("Cannot create instance of XdgShellV5Base")); qmlRegisterType<QWaylandXdgShellV5QuickExtension>(uri, 1, 0, "XdgShellV5"); - qmlRegisterType<QWaylandXdgSurfaceV5QuickParent>(uri, 1, 0, "XdgSurfaceV5"); - qmlRegisterType<QWaylandXdgPopupV5QuickParent>(uri, 1, 0, "XdgPopupV5"); + qmlRegisterType<QWaylandXdgSurfaceV5>(uri, 1, 0, "XdgSurfaceV5"); + qmlRegisterType<QWaylandXdgPopupV5>(uri, 1, 0, "XdgPopupV5"); qmlRegisterType<QWaylandTextInputManagerQuickExtension>(uri, 1, 0, "TextInputManager"); qmlRegisterType<QWaylandXdgShellV6QuickExtension>(uri, 1, 1, "XdgShellV6"); - qmlRegisterType<QWaylandXdgSurfaceV6QuickParent>(uri, 1, 1, "XdgSurfaceV6"); + qmlRegisterType<QWaylandXdgSurfaceV6>(uri, 1, 1, "XdgSurfaceV6"); qmlRegisterUncreatableType<QWaylandXdgToplevelV6>(uri, 1, 1, "XdgToplevelV6", QObject::tr("Cannot create instance of XdgShellToplevelV6")); qmlRegisterUncreatableType<QWaylandXdgPopupV6>(uri, 1, 1, "XdgPopupV6", QObject::tr("Cannot create instance of XdgShellPopupV6")); qmlRegisterType<QWaylandXdgShellQuickExtension>(uri, 1, 3, "XdgShell"); - qmlRegisterType<QWaylandXdgSurfaceQuickParent>(uri, 1, 3, "XdgSurface"); + qmlRegisterType<QWaylandXdgSurface>(uri, 1, 3, "XdgSurface"); qmlRegisterUncreatableType<QWaylandXdgToplevel>(uri, 1, 3, "XdgToplevel", QObject::tr("Cannot create instance of XdgShellToplevel")); qmlRegisterUncreatableType<QWaylandXdgPopup>(uri, 1, 3, "XdgPopup", QObject::tr("Cannot create instance of XdgShellPopup")); |