@@ -238,11 +238,7 @@ PyObject* PythonQtConvertListOfValueTypeToPythonList(const void* /*QList<T>* */
238238{
239239 ListType* list = (ListType*)inList;
240240 static const int innerType = PythonQtMethodInfo::getInnerTemplateMetaType (QByteArray (PythonQtUtils::typeNameFromMetaTypeId (metaTypeId)));
241- #if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
242241 if (innerType == QMetaType::UnknownType) {
243- #else
244- if (innerType == QVariant::Invalid) {
245- #endif
246242 std::cerr << " PythonQtConvertListOfValueTypeToPythonList: unknown inner type " << PythonQtUtils::typeNameFromMetaTypeId (metaTypeId) << std::endl;
247243 }
248244 PyObject* result = PyTuple_New (list->size ());
@@ -259,11 +255,7 @@ bool PythonQtConvertPythonListToListOfValueType(PyObject* obj, void* /*QList<T>*
259255{
260256 ListType* list = (ListType*)outList;
261257 static const int innerType = PythonQtMethodInfo::getInnerTemplateMetaType (QByteArray (PythonQtUtils::typeNameFromMetaTypeId (metaTypeId)));
262- #if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
263258 if (innerType == QMetaType::UnknownType) {
264- #else
265- if (innerType == QVariant::Invalid) {
266- #endif
267259 std::cerr << " PythonQtConvertPythonListToListOfValueType: unknown inner type " << PythonQtUtils::typeNameFromMetaTypeId (metaTypeId) << std::endl;
268260 }
269261 bool result = false ;
@@ -363,11 +355,7 @@ PyObject* PythonQtConvertPairToPython(const void* /*QPair<T1,T2>* */ inPair, int
363355 innerType1 = PythonQtUtils::metaTypeIdFromTypeName (names.at (0 ).trimmed ());
364356 innerType2 = PythonQtUtils::metaTypeIdFromTypeName (names.at (1 ).trimmed ());
365357 }
366- #if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
367358 if (innerType1 == QMetaType::UnknownType || innerType2 == QMetaType::UnknownType) {
368- #else
369- if (innerType1 == QVariant::Invalid || innerType2 == QVariant::Invalid) {
370- #endif
371359 std::cerr << " PythonQtConvertPairToPython: unknown inner type " << PythonQtUtils::typeNameFromMetaTypeId (metaTypeId) << std::endl;
372360 }
373361 PyObject* result = PyTuple_New (2 );
@@ -388,11 +376,7 @@ bool PythonQtConvertPythonToPair(PyObject* obj, void* /*QPair<T1,T2>* */ outPair
388376 innerType1 = PythonQtUtils::metaTypeIdFromTypeName (names.at (0 ).trimmed ());
389377 innerType2 = PythonQtUtils::metaTypeIdFromTypeName (names.at (1 ).trimmed ());
390378 }
391- #if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
392379 if (innerType1 == QMetaType::UnknownType || innerType2 == QMetaType::UnknownType) {
393- #else
394- if (innerType1 == QVariant::Invalid || innerType2 == QVariant::Invalid) {
395- #endif
396380 std::cerr << " PythonQtConvertPythonToPair: unknown inner type " << PythonQtUtils::typeNameFromMetaTypeId (metaTypeId) << std::endl;
397381 }
398382 bool result = false ;
@@ -433,11 +417,7 @@ PyObject* PythonQtConvertListOfPairToPythonList(const void* /*QList<QPair<T1,T2>
433417{
434418 ListType* list = (ListType*)inList;
435419 static int innerType = PythonQtMethodInfo::getInnerTemplateMetaType (QByteArray (PythonQtUtils::typeNameFromMetaTypeId (metaTypeId)));
436- #if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
437420 if (innerType == QMetaType::UnknownType) {
438- #else
439- if (innerType == QVariant::Invalid) {
440- #endif
441421 std::cerr << " PythonQtConvertListOfPairToPythonList: unknown inner type " << PythonQtUtils::typeNameFromMetaTypeId (metaTypeId) << std::endl;
442422 }
443423 PyObject* result = PyTuple_New (list->size ());
@@ -456,11 +436,7 @@ bool PythonQtConvertPythonListToListOfPair(PyObject* obj, void* /*QList<QPair<T1
456436{
457437 ListType* list = (ListType*)outList;
458438 static int innerType = PythonQtMethodInfo::getInnerTemplateMetaType (QByteArray (PythonQtUtils::typeNameFromMetaTypeId (metaTypeId)));
459- #if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
460439 if (innerType == QMetaType::UnknownType) {
461- #else
462- if (innerType == QVariant::Invalid) {
463- #endif
464440 std::cerr << " PythonQtConvertPythonListToListOfPair: unknown inner type " << PythonQtUtils::typeNameFromMetaTypeId (metaTypeId) << std::endl;
465441 }
466442 bool result = false ;
@@ -498,11 +474,7 @@ PyObject* PythonQtConvertIntegerMapToPython(const void* /*QMap<int, T>* */ inMap
498474 QList<QByteArray> names = innerTypes.split (' ,' );
499475 innerType = PythonQtUtils::metaTypeIdFromTypeName (names.at (1 ).trimmed ());
500476 }
501- #if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
502477 if (innerType == QMetaType::UnknownType) {
503- #else
504- if (innerType == QVariant::Invalid) {
505- #endif
506478 std::cerr << " PythonQtConvertIntegerMapToPython: unknown inner type " << PythonQtUtils::typeNameFromMetaTypeId (metaTypeId) << std::endl;
507479 }
508480
@@ -530,11 +502,7 @@ bool PythonQtConvertPythonToIntegerMap(PyObject* val, void* /*QMap<int, T>* */ o
530502 QList<QByteArray> names = innerTypes.split (' ,' );
531503 innerType = PythonQtUtils::metaTypeIdFromTypeName (names.at (1 ).trimmed ());
532504 }
533- #if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
534505 if (innerType == QMetaType::UnknownType) {
535- #else
536- if (innerType == QVariant::Invalid) {
537- #endif
538506 std::cerr << " PythonQtConvertPythonToIntegerMap: unknown inner type " << PythonQtUtils::typeNameFromMetaTypeId (metaTypeId) << std::endl;
539507 }
540508 bool result = false ;
0 commit comments