QMetaObject: Fix version check for deprecated methods
We don't want them in Qt 7.0.0, either. As a drive-by, also guard the implementation with the same check. Change-Id: I21b181e5563ebc2b247d6c5ad005bb76224f0daf Reviewed-by: Marc Mutz <marc.mutz@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit 115a38613c0ed0ea1d6c82d927809074cb69f385) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
1bfa58f11c
commit
3192d46c39
@ -199,6 +199,7 @@ private:
|
||||
|
||||
enum { MaximumParamCount = 11 }; // up to 10 arguments + 1 return value
|
||||
|
||||
#if QT_VERSION < QT_VERSION_CHECK(7, 0, 0)
|
||||
/*!
|
||||
\since 4.5
|
||||
\obsolete [6.5] Please use the variadic overload of this function
|
||||
@ -244,6 +245,7 @@ QObject *QMetaObject::newInstance(QGenericArgument val0,
|
||||
|
||||
return newInstanceImpl(this, paramCount, parameters, typeNames, nullptr);
|
||||
}
|
||||
#endif
|
||||
|
||||
/*!
|
||||
\fn template <typename... Args> QObject *QMetaObject::newInstance(Args &&... arguments) const
|
||||
|
@ -78,7 +78,7 @@ struct QMethodRawArguments
|
||||
void **arguments;
|
||||
};
|
||||
|
||||
#if QT_VERSION <= QT_VERSION_CHECK(7, 0, 0)
|
||||
#if QT_VERSION < QT_VERSION_CHECK(7, 0, 0)
|
||||
class Q_CORE_EXPORT QGenericArgument
|
||||
{
|
||||
public:
|
||||
@ -485,7 +485,7 @@ struct Q_CORE_EXPORT QMetaObject
|
||||
|
||||
#endif
|
||||
|
||||
#if QT_VERSION <= QT_VERSION_CHECK(7, 0, 0)
|
||||
#if QT_VERSION < QT_VERSION_CHECK(7, 0, 0)
|
||||
QObject *newInstance(QGenericArgument val0,
|
||||
QGenericArgument val1 = QGenericArgument(),
|
||||
QGenericArgument val2 = QGenericArgument(),
|
||||
|
Loading…
x
Reference in New Issue
Block a user