From 22a87fdd95761189f68b937a10d3d52a5a66ae68 Mon Sep 17 00:00:00 2001 From: Tim Jenssen Date: Wed, 7 Jul 2021 13:04:37 +0200 Subject: [PATCH] qmlpuppet: adjust to api changes in Qt 6.2 Change-Id: I3c9139cacb7ff9eb7b8138e0a7f589280a24c13a Reviewed-by: Qt CI Bot Reviewed-by: Tim Jenssen --- .../qmlpuppet/qmlprivategate/qmlprivategate.h | 4 +--- .../qmlprivategate/qmlprivategate_56.cpp | 20 ++++++++----------- 2 files changed, 9 insertions(+), 15 deletions(-) diff --git a/share/qtcreator/qml/qmlpuppet/qmlprivategate/qmlprivategate.h b/share/qtcreator/qml/qmlpuppet/qmlprivategate/qmlprivategate.h index b0b68907edd..6577b3a4f5a 100644 --- a/share/qtcreator/qml/qmlpuppet/qmlprivategate/qmlprivategate.h +++ b/share/qtcreator/qml/qmlpuppet/qmlprivategate/qmlprivategate.h @@ -71,9 +71,7 @@ public: PropertyNameList propertyNameListForWritableProperties(QObject *object, const PropertyName &baseName = PropertyName(), QObjectList *inspectedObjects = nullptr); - PropertyNameList allPropertyNames(QObject *object, - const PropertyName &baseName = PropertyName(), - QObjectList *inspectedObjects = nullptr); + PropertyNameList allPropertyNames(QObject *object); bool hasFullImplementedListInterface(const QQmlListReference &list); void registerCustomData(QObject *object); diff --git a/share/qtcreator/qml/qmlpuppet/qmlprivategate/qmlprivategate_56.cpp b/share/qtcreator/qml/qmlpuppet/qmlprivategate/qmlprivategate_56.cpp index 2f775d05346..f0ef76cb19d 100644 --- a/share/qtcreator/qml/qmlpuppet/qmlprivategate/qmlprivategate_56.cpp +++ b/share/qtcreator/qml/qmlpuppet/qmlprivategate/qmlprivategate_56.cpp @@ -68,8 +68,8 @@ static void addToPropertyNameListIfNotBlackListed( } PropertyNameList allPropertyNamesInline(QObject *object, - const PropertyName &baseName, - QObjectList *inspectedObjects, + const PropertyName &baseName = {}, + QObjectList *inspectedObjects = nullptr, int depth = 0) { QQuickDesignerSupport::PropertyNameList propertyNameList; @@ -136,24 +136,20 @@ PropertyNameList allPropertyNamesInline(QObject *object, } #endif -PropertyNameList allPropertyNames(QObject *object, - const PropertyName &baseName, - QObjectList *inspectedObjects) +PropertyNameList allPropertyNames(QObject *object) { #if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) - return QQuickDesignerSupportProperties::allPropertyNames(object, baseName, inspectedObjects); + return QQuickDesignerSupportProperties::allPropertyNames(object); #elif QT_VERSION >= QT_VERSION_CHECK(5, 15, 0) - return allPropertyNamesInline(object, baseName, inspectedObjects); + return allPropertyNamesInline(object); #else - return QQuickDesignerSupportProperties::allPropertyNames(object, baseName, inspectedObjects); + return QQuickDesignerSupportProperties::allPropertyNames(object); #endif } -PropertyNameList propertyNameListForWritableProperties(QObject *object, - const PropertyName &baseName, - QObjectList *inspectedObjects) +PropertyNameList propertyNameListForWritableProperties(QObject *object) { - return QQuickDesignerSupportProperties::propertyNameListForWritableProperties(object, baseName, inspectedObjects); + return QQuickDesignerSupportProperties::propertyNameListForWritableProperties(object); } void tweakObjects(QObject *object)