QJSEngine: Mark convertV2 variant with int parameter as BC-only

We won't need it anymore in Qt7.

Change-Id: Iff8bfd5192d80d7603aaa66da8cb00ab23e60f99
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
This commit is contained in:
Ulf Hermann 2022-11-15 10:53:36 +01:00
parent 8404a6a5d4
commit 1935f13b1d
2 changed files with 5 additions and 1 deletions

View File

@ -828,10 +828,12 @@ bool QJSEngine::convertManaged(const QJSManagedValue &value, QMetaType type, voi
return QV4::ExecutionEngine::metaTypeFromJS(*value.d, type, ptr); return QV4::ExecutionEngine::metaTypeFromJS(*value.d, type, ptr);
} }
#if QT_VERSION < QT_VERSION_CHECK(7,0,0)
bool QJSEngine::convertV2(const QJSValue &value, int type, void *ptr) bool QJSEngine::convertV2(const QJSValue &value, int type, void *ptr)
{ {
return convertV2(value, QMetaType(type), ptr); return convertV2(value, QMetaType(type), ptr);
} }
#endif
bool QJSEngine::convertString(const QString &string, QMetaType metaType, void *ptr) bool QJSEngine::convertString(const QString &string, QMetaType metaType, void *ptr)
{ {

View File

@ -212,7 +212,9 @@ private:
static bool convertManaged(const QJSManagedValue &value, int type, void *ptr); static bool convertManaged(const QJSManagedValue &value, int type, void *ptr);
static bool convertManaged(const QJSManagedValue &value, QMetaType type, void *ptr); static bool convertManaged(const QJSManagedValue &value, QMetaType type, void *ptr);
static bool convertV2(const QJSValue &value, int type, void *ptr); #if QT_VERSION < QT_VERSION_CHECK(7,0,0)
static bool convertV2(const QJSValue &value, int type, void *ptr); // only there for BC reasons
#endif
static bool convertV2(const QJSValue &value, QMetaType metaType, void *ptr); static bool convertV2(const QJSValue &value, QMetaType metaType, void *ptr);
static bool convertString(const QString &string, QMetaType metaType, void *ptr); static bool convertString(const QString &string, QMetaType metaType, void *ptr);