From 1144b07ebb690706271efc4027b329f87f3a51e2 Mon Sep 17 00:00:00 2001 From: Matthias Koefferlein Date: Sun, 2 Jun 2024 19:11:17 +0200 Subject: [PATCH] Compatibility with Qt 6.7 --- scripts/mkqtdecl6/mkqtdecl.conf | 10 +++--- src/gsiqt/qt6/QtCore/QtCore.pri | 1 - src/gsiqt/qt6/QtCore/gsiDeclQTimeZone.cc | 40 --------------------- src/gsiqt/qt6/QtCore/gsiQtExternals.h | 4 --- src/gsiqt/qt6/QtGui/gsiDeclQPointerEvent.cc | 6 +--- 5 files changed, 7 insertions(+), 54 deletions(-) diff --git a/scripts/mkqtdecl6/mkqtdecl.conf b/scripts/mkqtdecl6/mkqtdecl.conf index 71db9834b..50d119977 100644 --- a/scripts/mkqtdecl6/mkqtdecl.conf +++ b/scripts/mkqtdecl6/mkqtdecl.conf @@ -132,6 +132,7 @@ drop_class "QContainerInfo" drop_class "QContiguousCache" drop_class "QContiguousCacheData" drop_class "QContiguousCacheTypedData" +drop_class "QDeferredDeleteEvent" # was a mistake, I think drop_class "QEnableSharedFromThis" drop_class "QException" # (TODO) no mapping yet drop_class "QExplicitlySharedDataPointer" @@ -258,7 +259,6 @@ drop_class "QStringBuilder" drop_class "QStringBuilder" drop_class "QStringBuilderBase" drop_class "QStringBuilderCommon" -# @@@ drop_class "QStringConverterBase" drop_class "QStringDecoder", /EncodedData/ drop_class "QStringEncoder", /DecodedData/ drop_class "QStringListIterator" @@ -460,6 +460,8 @@ drop_method "QTextCodec", /QTextCodec::codecForName\(const\s+QByteArray/ # clash drop_method "QTextCodec", /QTextCodec::toUnicode\(const\s+QByteArray/ # clashes with const char * variant drop_method "QTextCodec", /QTextCodec::fromUnicode\(const\s+QChar\s+\*/ # requires real QChar * drop_method "QTextEncoder", /QTextEncoder::fromUnicode\(const\s+QChar\s+\*/ # requires real QChar * +drop_method "QTimeZone", /::operator\s*==/ # no longer supported on Qt 6.7 +drop_method "QTimeZone", /::operator\s*!=/ # no longer supported on Qt 6.7 drop_method "", /::operator\s*==\(const\s+QVariant\s*&\w+,\s*const\s+QVariantComparisonHelper/ # requires QVariantComparisonHelper drop_method "", /::operator\s*!=\(const\s+QVariant\s*&\w+,\s*const\s+QVariantComparisonHelper/ # requires QVariantComparisonHelper drop_method "QByteArrayMatcher", /QByteArrayMatcher::indexIn\(const\s+QByteArray/ # clashes with const char * variant @@ -535,7 +537,6 @@ no_copy_ctor "QBasicMutex" no_copy_ctor "QMapDataBase" no_copy_ctor "QChildEvent" no_copy_ctor "QDynamicPropertyChangeEvent" -no_copy_ctor "QDeferredDeleteEvent" no_copy_ctor "QEvent" no_copy_ctor "QPropertyNotifier" no_copy_ctor "QPropertyObserver" @@ -859,6 +860,7 @@ include "QWindow", [ "", "", "", "", "", "" ] include "QOffscreenSurface", [ "", "" ] include "QScreenOrientationChangeEvent", [ "", "" ] +include "QPointerEvent", [ "" ] # needed for Qt 6.7 drop_method "QWindow", /QWindow::handle/ # QPlatformWindow not available drop_method "QScreen", /QScreen::handle/ # QPlatformScreen not available @@ -1284,8 +1286,8 @@ include "QOcspCertificateStatus", [ "" ] # global enum without o include "QDtlsError", [ "" ] # global enum without own header drop_class "QTlsPrivate" # private data -drop_class "QOcspResponse" # @@@ TODO: debug -drop_method "QSslSocket", /QSslSocket::ocspResponses\(/ # @@@ TODO: debug +drop_class "QOcspResponse" # TODO: debug +drop_method "QSslSocket", /QSslSocket::ocspResponses\(/ # TODO: debug drop_method "QUrlInfo", /QUrlInfo::QUrlInfo\(.*permissions/ # too many arguments (13) drop_method "QHostAddress", /QHostAddress::QHostAddress\(\s*(const\s*)?quint8\s*\*/ # requires char *, a string version is available for IPv6 diff --git a/src/gsiqt/qt6/QtCore/QtCore.pri b/src/gsiqt/qt6/QtCore/QtCore.pri index 6f70a8192..9dbcef016 100644 --- a/src/gsiqt/qt6/QtCore/QtCore.pri +++ b/src/gsiqt/qt6/QtCore/QtCore.pri @@ -40,7 +40,6 @@ SOURCES += \ $$PWD/gsiDeclQDeadlineTimer.cc \ $$PWD/gsiDeclQDebug.cc \ $$PWD/gsiDeclQDebugStateSaver.cc \ - $$PWD/gsiDeclQDeferredDeleteEvent.cc \ $$PWD/gsiDeclQDir.cc \ $$PWD/gsiDeclQDirIterator.cc \ $$PWD/gsiDeclQDynamicPropertyChangeEvent.cc \ diff --git a/src/gsiqt/qt6/QtCore/gsiDeclQTimeZone.cc b/src/gsiqt/qt6/QtCore/gsiDeclQTimeZone.cc index ddbd33e76..bcef6b084 100644 --- a/src/gsiqt/qt6/QtCore/gsiDeclQTimeZone.cc +++ b/src/gsiqt/qt6/QtCore/gsiDeclQTimeZone.cc @@ -397,25 +397,6 @@ static void _call_f_offsetFromUtc_c2175 (const qt_gsi::GenericMethod * /*decl*/, } -// bool QTimeZone::operator!=(const QTimeZone &other) - - -static void _init_f_operator_excl__eq__c2205 (qt_gsi::GenericMethod *decl) -{ - static gsi::ArgSpecBase argspec_0 ("other"); - decl->add_arg (argspec_0); - decl->set_return (); -} - -static void _call_f_operator_excl__eq__c2205 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret) -{ - __SUPPRESS_UNUSED_WARNING(args); - tl::Heap heap; - const QTimeZone &arg1 = gsi::arg_reader() (args, heap); - ret.write ((bool)((QTimeZone *)cls)->operator!= (arg1)); -} - - // QTimeZone &QTimeZone::operator=(const QTimeZone &other) @@ -435,25 +416,6 @@ static void _call_f_operator_eq__2205 (const qt_gsi::GenericMethod * /*decl*/, v } -// bool QTimeZone::operator==(const QTimeZone &other) - - -static void _init_f_operator_eq__eq__c2205 (qt_gsi::GenericMethod *decl) -{ - static gsi::ArgSpecBase argspec_0 ("other"); - decl->add_arg (argspec_0); - decl->set_return (); -} - -static void _call_f_operator_eq__eq__c2205 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret) -{ - __SUPPRESS_UNUSED_WARNING(args); - tl::Heap heap; - const QTimeZone &arg1 = gsi::arg_reader() (args, heap); - ret.write ((bool)((QTimeZone *)cls)->operator== (arg1)); -} - - // QTimeZone::OffsetData QTimeZone::previousTransition(const QDateTime &beforeDateTime) @@ -792,9 +754,7 @@ static gsi::Methods methods_QTimeZone () { methods += new qt_gsi::GenericMethod ("nextTransition", "@brief Method QTimeZone::OffsetData QTimeZone::nextTransition(const QDateTime &afterDateTime)\n", true, &_init_f_nextTransition_c2175, &_call_f_nextTransition_c2175); methods += new qt_gsi::GenericMethod ("offsetData", "@brief Method QTimeZone::OffsetData QTimeZone::offsetData(const QDateTime &forDateTime)\n", true, &_init_f_offsetData_c2175, &_call_f_offsetData_c2175); methods += new qt_gsi::GenericMethod ("offsetFromUtc", "@brief Method int QTimeZone::offsetFromUtc(const QDateTime &atDateTime)\n", true, &_init_f_offsetFromUtc_c2175, &_call_f_offsetFromUtc_c2175); - methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QTimeZone::operator!=(const QTimeZone &other)\n", true, &_init_f_operator_excl__eq__c2205, &_call_f_operator_excl__eq__c2205); methods += new qt_gsi::GenericMethod ("assign", "@brief Method QTimeZone &QTimeZone::operator=(const QTimeZone &other)\n", false, &_init_f_operator_eq__2205, &_call_f_operator_eq__2205); - methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QTimeZone::operator==(const QTimeZone &other)\n", true, &_init_f_operator_eq__eq__c2205, &_call_f_operator_eq__eq__c2205); methods += new qt_gsi::GenericMethod ("previousTransition", "@brief Method QTimeZone::OffsetData QTimeZone::previousTransition(const QDateTime &beforeDateTime)\n", true, &_init_f_previousTransition_c2175, &_call_f_previousTransition_c2175); methods += new qt_gsi::GenericMethod ("standardTimeOffset", "@brief Method int QTimeZone::standardTimeOffset(const QDateTime &atDateTime)\n", true, &_init_f_standardTimeOffset_c2175, &_call_f_standardTimeOffset_c2175); methods += new qt_gsi::GenericMethod ("swap", "@brief Method void QTimeZone::swap(QTimeZone &other)\n", false, &_init_f_swap_1510, &_call_f_swap_1510); diff --git a/src/gsiqt/qt6/QtCore/gsiQtExternals.h b/src/gsiqt/qt6/QtCore/gsiQtExternals.h index 35c5bb656..65898a2c9 100644 --- a/src/gsiqt/qt6/QtCore/gsiQtExternals.h +++ b/src/gsiqt/qt6/QtCore/gsiQtExternals.h @@ -153,10 +153,6 @@ class QDebugStateSaver; namespace gsi { GSI_QTCORE_PUBLIC gsi::Class &qtdecl_QDebugStateSaver (); } -class QDeferredDeleteEvent; - -namespace gsi { GSI_QTCORE_PUBLIC gsi::Class &qtdecl_QDeferredDeleteEvent (); } - class QDir; namespace gsi { GSI_QTCORE_PUBLIC gsi::Class &qtdecl_QDir (); } diff --git a/src/gsiqt/qt6/QtGui/gsiDeclQPointerEvent.cc b/src/gsiqt/qt6/QtGui/gsiDeclQPointerEvent.cc index b28a5b7f9..496fe82f3 100644 --- a/src/gsiqt/qt6/QtGui/gsiDeclQPointerEvent.cc +++ b/src/gsiqt/qt6/QtGui/gsiDeclQPointerEvent.cc @@ -27,11 +27,7 @@ * This file has been created automatically */ -#include -#include -#include -#include -#include +#include #include "gsiQt.h" #include "gsiQtGuiCommon.h" #include