diff options
Diffstat (limited to 'src/tools')
-rw-r--r-- | src/tools/androiddeployqt/main.cpp | 25 | ||||
-rw-r--r-- | src/tools/bootstrap/bootstrap.pro | 1 | ||||
-rw-r--r-- | src/tools/moc/collectjson.cpp | 4 | ||||
-rw-r--r-- | src/tools/moc/generator.cpp | 52 | ||||
-rw-r--r-- | src/tools/moc/keywords.cpp | 25 | ||||
-rw-r--r-- | src/tools/moc/moc.cpp | 26 | ||||
-rw-r--r-- | src/tools/moc/moc.h | 2 | ||||
-rw-r--r-- | src/tools/moc/token.h | 1 | ||||
-rw-r--r-- | src/tools/moc/util/generate_keywords.cpp | 1 | ||||
-rw-r--r-- | src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp | 3 | ||||
-rw-r--r-- | src/tools/uic/cpp/cppwriteinitialization.h | 2 | ||||
-rw-r--r-- | src/tools/uic/main.cpp | 7 | ||||
-rw-r--r-- | src/tools/uic/qclass_lib_map.h | 4 | ||||
-rw-r--r-- | src/tools/uic/ui4.cpp | 30 | ||||
-rw-r--r-- | src/tools/uic/ui4.h | 90 | ||||
-rw-r--r-- | src/tools/uic/utils.h | 2 |
16 files changed, 160 insertions, 115 deletions
diff --git a/src/tools/androiddeployqt/main.cpp b/src/tools/androiddeployqt/main.cpp index d993518665..9912539a84 100644 --- a/src/tools/androiddeployqt/main.cpp +++ b/src/tools/androiddeployqt/main.cpp @@ -128,6 +128,7 @@ struct Options , jarSigner(false) , installApk(false) , uninstallApk(false) + , qmlImportScannerBinaryPath() {} enum DeploymentMechanism @@ -231,6 +232,9 @@ struct Options QStringList initClasses; QStringList permissions; QStringList features; + + // Override qml import scanner path + QString qmlImportScannerBinaryPath; }; static const QHash<QByteArray, QByteArray> elfArchitecures = { @@ -523,6 +527,8 @@ Options parseOptions() options.jarSigner = true; } else if (argument.compare(QLatin1String("--aux-mode"), Qt::CaseInsensitive) == 0) { options.auxMode = true; + } else if (argument.compare(QLatin1String("--qml-importscanner-binary"), Qt::CaseInsensitive) == 0) { + options.qmlImportScannerBinaryPath = arguments.at(++i).trimmed(); } } @@ -606,6 +612,10 @@ void printHelp() " dependencies into the build directory and update the XML templates.\n" " The project will not be built or installed.\n" " --apk <path/where/to/copy/the/apk>: Path where to copy the built apk.\n" + " --qml-importscanner-binary <path/to/qmlimportscanner>: Override the\n" + " default qmlimportscanner binary path. By default the\n" + " qmlimportscanner binary is located using the Qt directory\n" + " specified in the input file.\n" " --help: Displays this information.\n\n", qPrintable(QCoreApplication::arguments().at(0)) ); @@ -927,6 +937,12 @@ bool readInputFile(Options *options) } { + const QJsonValue qmlImportScannerBinaryPath = jsonObject.value(QLatin1String("qml-importscanner-binary")); + if (!qmlImportScannerBinaryPath.isUndefined()) + options->qmlImportScannerBinaryPath = qmlImportScannerBinaryPath.toString(); + } + + { const QJsonValue applicationBinary = jsonObject.value(QLatin1String("application-binary")); if (applicationBinary.isUndefined()) { fprintf(stderr, "No application binary defined in json file.\n"); @@ -1703,10 +1719,15 @@ bool scanImports(Options *options, QSet<QString> *usedDependencies) if (options->verbose) fprintf(stdout, "Scanning for QML imports.\n"); - QString qmlImportScanner = options->qtInstallDirectory + QLatin1String("/bin/qmlimportscanner"); + QString qmlImportScanner; + if (!options->qmlImportScannerBinaryPath.isEmpty()) { + qmlImportScanner = options->qmlImportScannerBinaryPath; + } else { + options->qtInstallDirectory + QLatin1String("/bin/qmlimportscanner"); #if defined(Q_OS_WIN32) - qmlImportScanner += QLatin1String(".exe"); + qmlImportScanner += QLatin1String(".exe"); #endif + } if (!QFile::exists(qmlImportScanner)) { fprintf(stderr, "qmlimportscanner not found: %s\n", qPrintable(qmlImportScanner)); diff --git a/src/tools/bootstrap/bootstrap.pro b/src/tools/bootstrap/bootstrap.pro index bfd199a8ba..b68bed436e 100644 --- a/src/tools/bootstrap/bootstrap.pro +++ b/src/tools/bootstrap/bootstrap.pro @@ -103,7 +103,6 @@ SOURCES += \ ../../corelib/tools/qcommandlineoption.cpp \ ../../corelib/tools/qcryptographichash.cpp \ ../../corelib/tools/qhash.cpp \ - ../../corelib/tools/qlist.cpp \ ../../corelib/tools/qmap.cpp \ ../../corelib/tools/qringbuffer.cpp \ ../../corelib/tools/qpoint.cpp \ diff --git a/src/tools/moc/collectjson.cpp b/src/tools/moc/collectjson.cpp index 4029bca5e9..fe499151cb 100644 --- a/src/tools/moc/collectjson.cpp +++ b/src/tools/moc/collectjson.cpp @@ -83,7 +83,9 @@ int collectJson(const QStringList &jsonFiles, const QString &outputFile) } } - for (const QString &jsonFile: jsonFiles) { + QStringList jsonFilesSorted = jsonFiles; + jsonFilesSorted.sort(); + for (const QString &jsonFile : qAsConst(jsonFilesSorted)) { QFile f(jsonFile); if (!f.open(QIODevice::ReadOnly)) { fprintf(stderr, "Error opening %s for reading\n", qPrintable(jsonFile)); diff --git a/src/tools/moc/generator.cpp b/src/tools/moc/generator.cpp index 8d4fb2efc6..f41b0e8ba4 100644 --- a/src/tools/moc/generator.cpp +++ b/src/tools/moc/generator.cpp @@ -194,7 +194,6 @@ static bool qualifiedNameEquals(const QByteArray &qualifiedName, const QByteArra void Generator::generateCode() { - bool isQt = (cdef->classname == "Qt"); bool isQObject = (cdef->classname == "QObject"); bool isConstructible = !cdef->constructorList.isEmpty(); @@ -237,7 +236,7 @@ void Generator::generateCode() // const int constCharArraySizeLimit = 65535; fprintf(out, "struct qt_meta_stringdata_%s_t {\n", qualifiedClassNameIdentifier.constData()); - fprintf(out, " QByteArrayData data[%d];\n", strings.size()); + fprintf(out, " const uint offsetsAndSize[%d];\n", strings.size()*2); { int stringDataLength = 0; int stringDataCounter = 0; @@ -260,11 +259,8 @@ void Generator::generateCode() // stringdata.stringdata member, and 2) the stringdata.data index of the // QByteArrayData being defined. This calculation relies on the // QByteArrayData::data() implementation returning simply "this + offset". - fprintf(out, "#define QT_MOC_LITERAL(idx, ofs, len) \\\n" - " Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \\\n" - " qptrdiff(offsetof(qt_meta_stringdata_%s_t, stringdata0) + ofs \\\n" - " - idx * sizeof(QByteArrayData)) \\\n" - " )\n", + fprintf(out, "#define QT_MOC_LITERAL(ofs, len) \\\n" + " uint(offsetof(qt_meta_stringdata_%s_t, stringdata0) + ofs), len \n", qualifiedClassNameIdentifier.constData()); fprintf(out, "static const qt_meta_stringdata_%s_t qt_meta_stringdata_%s = {\n", @@ -274,7 +270,7 @@ void Generator::generateCode() int idx = 0; for (int i = 0; i < strings.size(); ++i) { const QByteArray &str = strings.at(i); - fprintf(out, "QT_MOC_LITERAL(%d, %d, %d)", i, idx, str.length()); + fprintf(out, "QT_MOC_LITERAL(%d, %d)", idx, str.length()); if (i != strings.size() - 1) fputc(',', out); const QByteArray comment = str.length() > 32 ? str.left(29) + "..." : str; @@ -452,7 +448,7 @@ void Generator::generateCode() // // Generate internal qt_static_metacall() function // - const bool hasStaticMetaCall = !isQt && + const bool hasStaticMetaCall = (cdef->hasQObject || !cdef->methodList.isEmpty() || !cdef->propertyList.isEmpty() || !cdef->constructorList.isEmpty()); if (hasStaticMetaCall) @@ -534,10 +530,7 @@ void Generator::generateCode() // // Finally create and initialize the static meta object // - if (isQt) - fprintf(out, "QT_INIT_METAOBJECT const QMetaObject QObject::staticQtMetaObject = { {\n"); - else - fprintf(out, "QT_INIT_METAOBJECT const QMetaObject %s::staticMetaObject = { {\n", cdef->qualified.constData()); + fprintf(out, "QT_INIT_METAOBJECT const QMetaObject %s::staticMetaObject = { {\n", cdef->qualified.constData()); if (isQObject) fprintf(out, " nullptr,\n"); @@ -547,7 +540,7 @@ void Generator::generateCode() fprintf(out, " QtPrivate::MetaObjectForType<%s>::value(),\n", purestSuperClass.constData()); else fprintf(out, " nullptr,\n"); - fprintf(out, " qt_meta_stringdata_%s.data,\n" + fprintf(out, " qt_meta_stringdata_%s.offsetsAndSize,\n" " qt_meta_data_%s,\n", qualifiedClassNameIdentifier.constData(), qualifiedClassNameIdentifier.constData()); if (hasStaticMetaCall) @@ -561,9 +554,6 @@ void Generator::generateCode() fprintf(out, " qt_meta_extradata_%s,\n", qualifiedClassNameIdentifier.constData()); fprintf(out, " nullptr\n} };\n\n"); - if(isQt) - return; - if (!cdef->hasQObject) return; @@ -1221,18 +1211,22 @@ void Generator::generateStaticMetacall() fprintf(out, "%s(", f.name.constData()); int offset = 1; - int argsCount = f.arguments.count(); - for (int j = 0; j < argsCount; ++j) { - const ArgumentDef &a = f.arguments.at(j); - if (j) - fprintf(out, ","); - fprintf(out, "(*reinterpret_cast< %s>(_a[%d]))",a.typeNameForCast.constData(), offset++); - isUsed_a = true; - } - if (f.isPrivateSignal) { - if (argsCount > 0) - fprintf(out, ", "); - fprintf(out, "%s", "QPrivateSignal()"); + if (f.isRawSlot) { + fprintf(out, "QMethodRawArguments{ _a }"); + } else { + int argsCount = f.arguments.count(); + for (int j = 0; j < argsCount; ++j) { + const ArgumentDef &a = f.arguments.at(j); + if (j) + fprintf(out, ","); + fprintf(out, "(*reinterpret_cast< %s>(_a[%d]))",a.typeNameForCast.constData(), offset++); + isUsed_a = true; + } + if (f.isPrivateSignal) { + if (argsCount > 0) + fprintf(out, ", "); + fprintf(out, "%s", "QPrivateSignal()"); + } } fprintf(out, ");"); if (f.normalizedType != "void") { diff --git a/src/tools/moc/keywords.cpp b/src/tools/moc/keywords.cpp index 7da8d94efc..cc7d747f5b 100644 --- a/src/tools/moc/keywords.cpp +++ b/src/tools/moc/keywords.cpp @@ -30,12 +30,12 @@ // DO NOT EDIT. static const short keyword_trans[][128] = { - {0,0,0,0,0,0,0,0,0,568,565,0,0,0,0,0, + {0,0,0,0,0,0,0,0,0,579,576,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 568,252,566,569,8,38,239,567,25,26,236,234,30,235,27,237, + 579,252,577,580,8,38,239,578,25,26,236,234,30,235,27,237, 22,22,22,22,22,22,22,22,22,22,34,41,23,39,24,43, 0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8, - 8,21,8,8,8,8,8,8,8,8,8,31,571,32,238,8, + 8,21,8,8,8,8,8,8,8,8,8,31,582,32,238,8, 0,1,2,3,4,5,6,7,8,9,8,8,10,11,12,13, 14,8,15,16,17,18,19,20,8,8,8,36,245,37,248,0}, {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, @@ -177,7 +177,7 @@ static const short keyword_trans[][128] = { {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,42,0,0,0,28,0, - 574,574,574,574,574,574,574,574,574,574,0,0,0,0,0,0, + 585,585,585,585,585,585,585,585,585,585,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, @@ -336,7 +336,7 @@ static const short keyword_trans[][128] = { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,0,0,0,573,0,0,0,0,572, + 0,0,0,0,0,0,0,0,0,0,584,0,0,0,0,583, 0,0,0,0,0,0,0,0,0,0,0,0,0,258,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, @@ -378,7 +378,7 @@ static const short keyword_trans[][128] = { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,475,424,408,416,380,0,484,0,0,0,0,364,358, + 0,0,0,475,424,408,416,380,0,484,0,0,0,565,364,358, 386,0,557,472,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, @@ -1021,11 +1021,22 @@ static const struct {CHARACTER, 0, 79, 563, CHARACTER}, {CHARACTER, 0, 78, 564, CHARACTER}, {Q_REVISION_TOKEN, 0, 0, 0, CHARACTER}, + {CHARACTER, 0, 79, 566, CHARACTER}, + {CHARACTER, 0, 67, 567, CHARACTER}, + {CHARACTER, 0, 95, 568, CHARACTER}, + {CHARACTER, 0, 73, 569, CHARACTER}, + {CHARACTER, 0, 78, 570, CHARACTER}, + {CHARACTER, 0, 67, 571, CHARACTER}, + {CHARACTER, 0, 76, 572, CHARACTER}, + {CHARACTER, 0, 85, 573, CHARACTER}, + {CHARACTER, 0, 68, 574, CHARACTER}, + {CHARACTER, 0, 69, 575, CHARACTER}, + {Q_MOC_INCLUDE_TOKEN, 0, 0, 0, CHARACTER}, {NEWLINE, 0, 0, 0, NOTOKEN}, {QUOTE, 0, 0, 0, NOTOKEN}, {SINGLEQUOTE, 0, 0, 0, NOTOKEN}, {WHITESPACE, 0, 0, 0, NOTOKEN}, - {HASH, 0, 35, 570, HASH}, + {HASH, 0, 35, 581, HASH}, {PP_HASHHASH, 0, 0, 0, NOTOKEN}, {BACKSLASH, 0, 0, 0, NOTOKEN}, {CPP_COMMENT, 0, 0, 0, NOTOKEN}, diff --git a/src/tools/moc/moc.cpp b/src/tools/moc/moc.cpp index b562416c31..625725e5a1 100644 --- a/src/tools/moc/moc.cpp +++ b/src/tools/moc/moc.cpp @@ -328,6 +328,11 @@ void Moc::parseFunctionArguments(FunctionDef *def) def->arguments.removeLast(); def->isPrivateSignal = true; } + if (def->arguments.size() == 1 + && def->arguments.constLast().normalizedType == "QMethodRawArguments") { + def->arguments.removeLast(); + def->isRawSlot = true; + } } bool Moc::testFunctionAttribute(FunctionDef *def) @@ -648,6 +653,11 @@ void Moc::parse() case Q_CLASSINFO_TOKEN: parseClassInfo(&def); break; + case Q_MOC_INCLUDE_TOKEN: + // skip it, the namespace is parsed twice + next(LPAREN); + lexemUntil(RPAREN); + break; case ENUM: { EnumDef enumDef; if (parseEnum(&enumDef)) @@ -691,6 +701,9 @@ void Moc::parse() case Q_DECLARE_METATYPE_TOKEN: parseDeclareMetatype(); break; + case Q_MOC_INCLUDE_TOKEN: + parseMocInclude(); + break; case USING: if (test(NAMESPACE)) { while (test(SCOPE) || test(IDENTIFIER)) @@ -823,6 +836,9 @@ void Moc::parse() case Q_CLASSINFO_TOKEN: parseClassInfo(&def); break; + case Q_MOC_INCLUDE_TOKEN: + parseMocInclude(); + break; case Q_INTERFACES_TOKEN: parseInterfaces(&def); break; @@ -1560,6 +1576,16 @@ void Moc::parseDeclareMetatype() metaTypes.append(typeName); } +void Moc::parseMocInclude() +{ + next(LPAREN); + QByteArray include = lexemUntil(RPAREN); + // remove parentheses + include.remove(0, 1); + include.chop(1); + includeFiles.append(include); +} + void Moc::parseSlotInPrivate(ClassDef *def, FunctionDef::Access access) { next(LPAREN); diff --git a/src/tools/moc/moc.h b/src/tools/moc/moc.h index 04814b85a1..4d3d32a6ac 100644 --- a/src/tools/moc/moc.h +++ b/src/tools/moc/moc.h @@ -115,6 +115,7 @@ struct FunctionDef bool isConstructor = false; bool isDestructor = false; bool isAbstract = false; + bool isRawSlot = false; QJsonObject toJson() const; static void accessToJson(QJsonObject *obj, Access acs); @@ -256,6 +257,7 @@ public: void parseInterfaces(ClassDef *def); void parseDeclareInterface(); void parseDeclareMetatype(); + void parseMocInclude(); void parseSlotInPrivate(ClassDef *def, FunctionDef::Access access); void parsePrivateProperty(ClassDef *def); diff --git a/src/tools/moc/token.h b/src/tools/moc/token.h index 0cc163f9e4..c11ec6a38c 100644 --- a/src/tools/moc/token.h +++ b/src/tools/moc/token.h @@ -179,6 +179,7 @@ QT_BEGIN_NAMESPACE F(Q_SCRIPTABLE_TOKEN) \ F(Q_PRIVATE_PROPERTY_TOKEN) \ F(Q_REVISION_TOKEN) \ + F(Q_MOC_INCLUDE_TOKEN) \ F(SPECIAL_TREATMENT_MARK) \ F(MOC_INCLUDE_BEGIN) \ F(MOC_INCLUDE_END) \ diff --git a/src/tools/moc/util/generate_keywords.cpp b/src/tools/moc/util/generate_keywords.cpp index 9248e9e2e7..c2cfe37fab 100644 --- a/src/tools/moc/util/generate_keywords.cpp +++ b/src/tools/moc/util/generate_keywords.cpp @@ -243,6 +243,7 @@ static const Keyword keywords[] = { { "Q_SCRIPTABLE", "Q_SCRIPTABLE_TOKEN" }, { "Q_PRIVATE_PROPERTY", "Q_PRIVATE_PROPERTY_TOKEN" }, { "Q_REVISION", "Q_REVISION_TOKEN" }, + { "Q_MOC_INCLUDE", "Q_MOC_INCLUDE_TOKEN" }, { "\n", "NEWLINE" }, { "\"", "QUOTE" }, { "\'", "SINGLEQUOTE" }, diff --git a/src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp b/src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp index 9825596f3d..0493265164 100644 --- a/src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp +++ b/src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp @@ -72,9 +72,8 @@ static const char includeList[] = static const char forwardDeclarations[] = "QT_BEGIN_NAMESPACE\n" + "#include <QtCore/qcontainerfwd.h>\n" "class QByteArray;\n" - "template<class T> class QList;\n" - "template<class Key, class Value> class QMap;\n" "class QString;\n" "class QStringList;\n" "class QVariant;\n" diff --git a/src/tools/uic/cpp/cppwriteinitialization.h b/src/tools/uic/cpp/cppwriteinitialization.h index ab996a2800..0a6ddbb3c8 100644 --- a/src/tools/uic/cpp/cppwriteinitialization.h +++ b/src/tools/uic/cpp/cppwriteinitialization.h @@ -85,7 +85,7 @@ namespace CPP { struct WriteInitialization : public TreeWalker { - using DomPropertyList = QList<DomProperty*>; + using DomPropertyList = QVector<DomProperty*>; using DomPropertyMap = QHash<QString, DomProperty*>; WriteInitialization(Uic *uic); diff --git a/src/tools/uic/main.cpp b/src/tools/uic/main.cpp index d6c63de869..6f342fb398 100644 --- a/src/tools/uic/main.cpp +++ b/src/tools/uic/main.cpp @@ -80,10 +80,6 @@ int runUic(int argc, char *argv[]) noImplicitIncludesOption.setDescription(QStringLiteral("Disable generation of #include-directives.")); parser.addOption(noImplicitIncludesOption); - QCommandLineOption noStringLiteralOption(QStringList() << QStringLiteral("s") << QStringLiteral("no-stringliteral")); - noStringLiteralOption.setDescription(QStringLiteral("Deprecated. The use of this option won't take any effect.")); - parser.addOption(noStringLiteralOption); - QCommandLineOption postfixOption(QStringLiteral("postfix")); postfixOption.setDescription(QStringLiteral("Postfix to add to all generated classnames.")); postfixOption.setValueName(QStringLiteral("postfix")); @@ -134,9 +130,6 @@ int runUic(int argc, char *argv[]) } language::setLanguage(language); - if (parser.isSet(noStringLiteralOption)) - fprintf(stderr, "The -s, --no-stringliteral option is deprecated and it won't take any effect.\n"); - QString inputFile; if (!parser.positionalArguments().isEmpty()) inputFile = parser.positionalArguments().at(0); diff --git a/src/tools/uic/qclass_lib_map.h b/src/tools/uic/qclass_lib_map.h index 8cebe65a00..841144133f 100644 --- a/src/tools/uic/qclass_lib_map.h +++ b/src/tools/uic/qclass_lib_map.h @@ -635,7 +635,6 @@ QT_CLASS_LIB(QIconEngineFactoryInterface, QtGui, qiconengineplugin.h) QT_CLASS_LIB(QIconEnginePlugin, QtGui, qiconengineplugin.h) QT_CLASS_LIB(QIconEngineFactoryInterfaceV2, QtGui, qiconengineplugin.h) QT_CLASS_LIB(QIconEnginePluginV2, QtGui, qiconengineplugin.h) -QT_CLASS_LIB(QImageTextKeyLang, QtGui, qimage.h) QT_CLASS_LIB(QImage, QtGui, qimage.h) QT_CLASS_LIB(QImageIOHandler, QtGui, qimageiohandler.h) QT_CLASS_LIB(QImageIOHandlerFactoryInterface, QtGui, qimageiohandler.h) @@ -644,9 +643,6 @@ QT_CLASS_LIB(QImageReader, QtGui, qimagereader.h) QT_CLASS_LIB(QImageWriter, QtGui, qimagewriter.h) QT_CLASS_LIB(QMovie, QtGui, qmovie.h) QT_CLASS_LIB(QPicture, QtGui, qpicture.h) -QT_CLASS_LIB(QPictureIO, QtGui, qpicture.h) -QT_CLASS_LIB(QPictureFormatInterface, QtGui, qpictureformatplugin.h) -QT_CLASS_LIB(QPictureFormatPlugin, QtGui, qpictureformatplugin.h) QT_CLASS_LIB(QPixmap, QtGui, qpixmap.h) QT_CLASS_LIB(QPixmapCache, QtGui, qpixmapcache.h) QT_CLASS_LIB(QAbstractItemDelegate, QtWidgets, qabstractitemdelegate.h) diff --git a/src/tools/uic/ui4.cpp b/src/tools/uic/ui4.cpp index f52a8bd7d4..ed00e2c3fd 100644 --- a/src/tools/uic/ui4.cpp +++ b/src/tools/uic/ui4.cpp @@ -862,13 +862,13 @@ void DomActionGroup::setElementActionGroup(const QVector<DomActionGroup *> &a) m_actionGroup = a; } -void DomActionGroup::setElementProperty(const QList<DomProperty *> &a) +void DomActionGroup::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; } -void DomActionGroup::setElementAttribute(const QList<DomProperty *> &a) +void DomActionGroup::setElementAttribute(const QVector<DomProperty *> &a) { m_children |= Attribute; m_attribute = a; @@ -944,13 +944,13 @@ void DomAction::write(QXmlStreamWriter &writer, const QString &tagName) const writer.writeEndElement(); } -void DomAction::setElementProperty(const QList<DomProperty *> &a) +void DomAction::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; } -void DomAction::setElementAttribute(const QList<DomProperty *> &a) +void DomAction::setElementAttribute(const QVector<DomProperty *> &a) { m_children |= Attribute; m_attribute = a; @@ -1058,13 +1058,13 @@ void DomButtonGroup::write(QXmlStreamWriter &writer, const QString &tagName) con writer.writeEndElement(); } -void DomButtonGroup::setElementProperty(const QList<DomProperty *> &a) +void DomButtonGroup::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; } -void DomButtonGroup::setElementAttribute(const QList<DomProperty *> &a) +void DomButtonGroup::setElementAttribute(const QVector<DomProperty *> &a) { m_children |= Attribute; m_attribute = a; @@ -1717,13 +1717,13 @@ void DomLayout::write(QXmlStreamWriter &writer, const QString &tagName) const writer.writeEndElement(); } -void DomLayout::setElementProperty(const QList<DomProperty *> &a) +void DomLayout::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; } -void DomLayout::setElementAttribute(const QList<DomProperty *> &a) +void DomLayout::setElementAttribute(const QVector<DomProperty *> &a) { m_children |= Attribute; m_attribute = a; @@ -1938,7 +1938,7 @@ void DomRow::write(QXmlStreamWriter &writer, const QString &tagName) const writer.writeEndElement(); } -void DomRow::setElementProperty(const QList<DomProperty *> &a) +void DomRow::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; @@ -1983,7 +1983,7 @@ void DomColumn::write(QXmlStreamWriter &writer, const QString &tagName) const writer.writeEndElement(); } -void DomColumn::setElementProperty(const QList<DomProperty *> &a) +void DomColumn::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; @@ -2059,7 +2059,7 @@ void DomItem::write(QXmlStreamWriter &writer, const QString &tagName) const writer.writeEndElement(); } -void DomItem::setElementProperty(const QList<DomProperty *> &a) +void DomItem::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; @@ -2268,13 +2268,13 @@ void DomWidget::setElementClass(const QStringList &a) m_class = a; } -void DomWidget::setElementProperty(const QList<DomProperty *> &a) +void DomWidget::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; } -void DomWidget::setElementAttribute(const QList<DomProperty *> &a) +void DomWidget::setElementAttribute(const QVector<DomProperty *> &a) { m_children |= Attribute; m_attribute = a; @@ -2386,7 +2386,7 @@ void DomSpacer::write(QXmlStreamWriter &writer, const QString &tagName) const writer.writeEndElement(); } -void DomSpacer::setElementProperty(const QList<DomProperty *> &a) +void DomSpacer::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; @@ -5984,7 +5984,7 @@ void DomDesignerData::write(QXmlStreamWriter &writer, const QString &tagName) co writer.writeEndElement(); } -void DomDesignerData::setElementProperty(const QList<DomProperty *> &a) +void DomDesignerData::setElementProperty(const QVector<DomProperty *> &a) { m_children |= Property; m_property = a; diff --git a/src/tools/uic/ui4.h b/src/tools/uic/ui4.h index 94cdb40b6f..90b17f7027 100644 --- a/src/tools/uic/ui4.h +++ b/src/tools/uic/ui4.h @@ -472,11 +472,11 @@ public: inline QVector<DomActionGroup *> elementActionGroup() const { return m_actionGroup; } void setElementActionGroup(const QVector<DomActionGroup *> &a); - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); - inline QList<DomProperty*> elementAttribute() const { return m_attribute; } - void setElementAttribute(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementAttribute() const { return m_attribute; } + void setElementAttribute(const QVector<DomProperty *> &a); private: // attribute data @@ -487,8 +487,8 @@ private: uint m_children = 0; QVector<DomAction *> m_action; QVector<DomActionGroup *> m_actionGroup; - QList<DomProperty*> m_property; - QList<DomProperty*> m_attribute; + QVector<DomProperty *> m_property; + QVector<DomProperty *> m_attribute; enum Child { Action = 1, @@ -519,11 +519,11 @@ public: inline void clearAttributeMenu() { m_has_attr_menu = false; } // child element accessors - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); - inline QList<DomProperty*> elementAttribute() const { return m_attribute; } - void setElementAttribute(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementAttribute() const { return m_attribute; } + void setElementAttribute(const QVector<DomProperty *> &a); private: // attribute data @@ -535,8 +535,8 @@ private: // child element data uint m_children = 0; - QList<DomProperty*> m_property; - QList<DomProperty*> m_attribute; + QVector<DomProperty *> m_property; + QVector<DomProperty *> m_attribute; enum Child { Property = 1, @@ -581,11 +581,11 @@ public: inline void clearAttributeName() { m_has_attr_name = false; } // child element accessors - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); - inline QList<DomProperty*> elementAttribute() const { return m_attribute; } - void setElementAttribute(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementAttribute() const { return m_attribute; } + void setElementAttribute(const QVector<DomProperty *> &a); private: // attribute data @@ -594,8 +594,8 @@ private: // child element data uint m_children = 0; - QList<DomProperty*> m_property; - QList<DomProperty*> m_attribute; + QVector<DomProperty *> m_property; + QVector<DomProperty *> m_attribute; enum Child { Property = 1, @@ -891,11 +891,11 @@ public: inline void clearAttributeColumnMinimumWidth() { m_has_attr_columnMinimumWidth = false; } // child element accessors - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); - inline QList<DomProperty*> elementAttribute() const { return m_attribute; } - void setElementAttribute(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementAttribute() const { return m_attribute; } + void setElementAttribute(const QVector<DomProperty *> &a); inline QVector<DomLayoutItem *> elementItem() const { return m_item; } void setElementItem(const QVector<DomLayoutItem *> &a); @@ -925,8 +925,8 @@ private: // child element data uint m_children = 0; - QList<DomProperty*> m_property; - QList<DomProperty*> m_attribute; + QVector<DomProperty *> m_property; + QVector<DomProperty *> m_attribute; QVector<DomLayoutItem *> m_item; enum Child { @@ -1023,14 +1023,14 @@ public: void write(QXmlStreamWriter &writer, const QString &tagName = QString()) const; // child element accessors - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); private: // child element data uint m_children = 0; - QList<DomProperty*> m_property; + QVector<DomProperty *> m_property; enum Child { Property = 1 @@ -1047,14 +1047,14 @@ public: void write(QXmlStreamWriter &writer, const QString &tagName = QString()) const; // child element accessors - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); private: // child element data uint m_children = 0; - QList<DomProperty*> m_property; + QVector<DomProperty *> m_property; enum Child { Property = 1 @@ -1082,8 +1082,8 @@ public: inline void clearAttributeColumn() { m_has_attr_column = false; } // child element accessors - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); inline QVector<DomItem *> elementItem() const { return m_item; } void setElementItem(const QVector<DomItem *> &a); @@ -1098,7 +1098,7 @@ private: // child element data uint m_children = 0; - QList<DomProperty*> m_property; + QVector<DomProperty *> m_property; QVector<DomItem *> m_item; enum Child { @@ -1136,11 +1136,11 @@ public: inline QStringList elementClass() const { return m_class; } void setElementClass(const QStringList &a); - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); - inline QList<DomProperty*> elementAttribute() const { return m_attribute; } - void setElementAttribute(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementAttribute() const { return m_attribute; } + void setElementAttribute(const QVector<DomProperty *> &a); inline QVector<DomRow *> elementRow() const { return m_row; } void setElementRow(const QVector<DomRow *> &a); @@ -1183,8 +1183,8 @@ private: // child element data uint m_children = 0; QStringList m_class; - QList<DomProperty*> m_property; - QList<DomProperty*> m_attribute; + QVector<DomProperty *> m_property; + QVector<DomProperty *> m_attribute; QVector<DomRow *> m_row; QVector<DomColumn *> m_column; QVector<DomItem *> m_item; @@ -1227,8 +1227,8 @@ public: inline void clearAttributeName() { m_has_attr_name = false; } // child element accessors - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); private: // attribute data @@ -1237,7 +1237,7 @@ private: // child element data uint m_children = 0; - QList<DomProperty*> m_property; + QVector<DomProperty *> m_property; enum Child { Property = 1 @@ -2805,14 +2805,14 @@ public: void write(QXmlStreamWriter &writer, const QString &tagName = QString()) const; // child element accessors - inline QList<DomProperty*> elementProperty() const { return m_property; } - void setElementProperty(const QList<DomProperty *> &a); + inline QVector<DomProperty *> elementProperty() const { return m_property; } + void setElementProperty(const QVector<DomProperty *> &a); private: // child element data uint m_children = 0; - QList<DomProperty*> m_property; + QVector<DomProperty *> m_property; enum Child { Property = 1 diff --git a/src/tools/uic/utils.h b/src/tools/uic/utils.h index 34c4ab23d4..bd543c7bb7 100644 --- a/src/tools/uic/utils.h +++ b/src/tools/uic/utils.h @@ -42,7 +42,7 @@ inline bool toBool(const QString &str) inline QString toString(const DomString *str) { return str ? str->text() : QString(); } -inline QHash<QString, DomProperty *> propertyMap(const QList<DomProperty *> &properties) +inline QHash<QString, DomProperty *> propertyMap(const QVector<DomProperty *> &properties) { QHash<QString, DomProperty *> map; for (DomProperty *p : properties) |