aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlmetatype.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/tqtc/lts-6.2.8' into ↵Tarja Sundqvist2024-02-201-0/+4
|\ | | | | | | | | | | | | | | | | tqtc/lts-6.2-opensource Conflicts solved in a file: dependencies.yaml Change-Id: Ib4083daa41a689b937d2aeb522e93e3aab0be1c4
| * QQmlMetaType: Clear property caches on qmlClearTypeRegistrationsUlf Hermann2023-02-171-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | Otherwise we may retain dangling pointers referencing invalid property caches. Some metaobjects are created on the heap. If the memory manager decides to re-use the heap space for new metaobjects, we can retrieve the invalid property caches. Task-number: QTBUG-110933 Change-Id: Ic00bb852151bcf58ba6ae798a6bf2cea686a9e10 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> (cherry picked from commit 6937f2e50dd60c58350a464eb83ba9d11c7146f9)
* | Merge remote-tracking branch 'origin/tqtc/lts-6.2.6' into ↵Tarja Sundqvist2023-03-011-27/+30
|\| | | | | | | | | | | tqtc/lts-6.2-opensource Change-Id: Ie5a87ae61d8ed0429225353ad46e5232d60f4daa
| * QQmlProxyMetaObject: Ignore properties/methods of non-creatable proxiesAndrei Golubev2022-07-221-27/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Qt/QML allows marking a type with QML_EXTENDED_NAMESPACE(Type) where Type is a Q_OBJECT. In this case, we have a Type-specific meta object but do not have an extension function to create the object of that Type with, causing us a subtle runtime crash. The crash in fact happens when we attempt to access a shadowed property through the extension object (which surely fails since there's no extension object) Fix this by excluding properties and methods when cloning the metaobject for the proxy if we know that the proxy cannot be created. This somewhat matches what the documentation says about QML_EXTENDED_NAMESPACE: When we have a Q_OBJECT/Q_GADGET, methods and properties of that are not exposed As a drive by, add the same check to the QQmlMetaType::proxyData(). While untested, this seems logical since the proxy data assumes valid creation function in this case as well Fixes: QTBUG-103081 Fixes: QTBUG-104700 Change-Id: I63c6e535d4df5169e0279eb2f588593f43a70640 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> (cherry picked from commit 218eb5f5712dd920459cb0108fcd305d653352bc) Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* | Revert "Update commercial license headers"Tarja Sundqvist2022-11-241-21/+21
|/ | | | | | | | | | | This reverts commit 74089697cf2a4961fb697100555b17ae2342d734. Revert of commercial license headers is required for the Qt 6.2.x opensource releases, Qt 6.2.5 onwards. Task-number: QTBUG-107760 Change-Id: Id49069cb5e5f261da185fd082dfb71deb259d387 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Update commercial license headersTarja Sundqvist2022-06-041-21/+21
| | | | | | | | | | | | | | | Updated header.COMM to the files in tqtc-qtdeclarative. Examples, tests, or documentation files are not updated. The commercial license header may contain some additional lines so that its line count equals with the earlier license header. Reason for this is that some autotests use hard coded line numbers and a change in the line count causes failures in tests. Task-number: QTQAINFRA-4941 Change-Id: I32f554b0a8cb527f74d46f3c02b0e745d9fc5ddf Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* QQmlMetaType: Don't duplicate notify signals for extended typesUlf Hermann2022-02-241-14/+14
| | | | | | | | | | | | | We have to add the methods first, so that the properties can be associated with their proper notification signals once we add them. If we add the properties first, the "missing" notification signals are synthesized. Fixes: QTBUG-101155 Change-Id: I1aacbf33a24f7a98d05dece77c804bd7cba8a041 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> (cherry picked from commit 57614680f760068c1db39888beba46944f409ff0) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* qmlmodels: Move QModelIndex from QtQmlMaximilian Goldstein2022-02-221-14/+0
| | | | | | | | | | | | Moves the QModelIndex value types from QtQml to QtQml.Models as they cannot otherwise be properly resolved in tooling. Fixes: QTBUG-100338 Change-Id: I30fc18b388974238ba8353e87ef09f57f8ceabd1 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> (cherry picked from commit e2864d6aa97d246546514ec0f97263574d19ec47) Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Protect unregisterInternalCompositeType() against null metatype dataUlf Hermann2021-08-301-5/+7
| | | | | | | | | | | | This may be called on shutdown when the data is already gone. Fixes: QDS-4390 Change-Id: I89de5fc1e66fca4318939179ed356620110b08e9 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io> (cherry picked from commit 98af4ab983b9b33c6f5cdb71f6f4f4dd7419aa30) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Avoid querying the file system for qmldir files for locked modulesUlf Hermann2021-08-181-12/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the user explicitly locks a module using qmlProtectModule, we don't load any additional qmldir files afterwards. In particular, this means you can only do that with modules that don't contain qmldir files or with modules for which the qmldir files have already been loaded in all engines that need them. This is in contrast to the "weak" locking we automatically perform when loading a plugin. When importing the module again after loading a plugin we do want to re-evaluate the qmldir directives. If the module is imported from a different engine than before, we also have to search for the qmldir file again. Amends commit 914e0300792856ddac9b99b20a8d88dd6f087fa6. [ChangeLog][QtQml] The pre-5.15 behavior of qmlProtectModule() has mostly been restored: If you explicitly protect a module, the QML engine will never look for any qmldir files or plugins for that module again. This severely limits what you can do with such a module. However, once all affected engines have loaded the module, protecting it can be a useful optimization. In contrast to pre-5.15, the qmldir cache for such modules continues to be re-used even after they are locked. Therefore, in QML engines that have loaded the module before, you can expect any "prefer" or "import" directives and any composite types to still be available after protecting the module. Fixes: QTBUG-85591 Change-Id: Ia4edd860e2ddda5e0c419e1ce9764f10f32ace1f Reviewed-by: Thorbjørn Lindeijer <bjorn@lindeijer.nl> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Fawzi Mohamed <fawzi.mohamed@qt.io> (cherry picked from commit d0dc91158d0b44d9e1b73c3b0dacdd6699741ad7) Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Rename QQmlMetaType::metaObjectForMetaType into metaObjectForValueTypeUlf Hermann2021-06-081-2/+2
| | | | | | | | It really only works for value types and it's not intended to do anythign else. The name should reflect this. Change-Id: Ib73bf7e9655971f7826fe72145e2d2fab363363c Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Do not auto-clean components with live inline componentsUlf Hermann2021-04-091-1/+11
| | | | | | | | | | The inline components do not hold a strong reference to their outer type because that would be a reference cycle. Fixes: QTBUG-92236 Pick-to: 5.15 6.0 6.1 Change-Id: I6d76a114352653210f0ece6c198cf761d3b4eda1 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Un-special case QQmlPropertyValueTypeFabian Kosmale2021-03-311-2/+0
| | | | | Change-Id: I5123f72fea4198505c27678dbaaea26313b2327c Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* QQmlMetaTypeData: Purge custom string convertersFabian Kosmale2021-03-301-33/+0
| | | | | | | | | Those were never exposed anyway. color, date, etc. are handled by the less generic converters in qqmlstringconverters_p.h. Change-Id: I43a94acda08344de742440dd3b956a7077096b11 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
* QQmlMetaType: Remove qmlLists memberFabian Kosmale2021-03-191-65/+15
| | | | | | | | | | | | | | | | | | | | | | | | | Instead of using a hashmap which maps a QML lists metatype to its list element's metatype, we can just store a pointer in the list metatype to the element metatype. Moreover, listType now returns a metatype. This is a preparation for converting enginePriv->rawMetaObjectForType(typeId) to metaType.metaObject() calls once we can actually retrieve the metaobject from QML metatypes. The QML metatype interface classes are moved into a header, so that Qt for Python can use the same classes. This does not affect types registered from C++, as those use a different mechanism. Task-number: QTBUG-88766 Task-number: QTBUG-82931 Task-number: QTBUG-87134 Change-Id: I330c2bbe4ac92072a333c001750f7504b56df478 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Remove QQmlMetaType::isQObjectFabian Kosmale2021-03-051-8/+0
| | | | | | | | All callers do have a metatype which they can query instead. Task-number: QTBUG-82931 Change-Id: I2ff514354a43d677da963d4239333fc66a42df59 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Simplify QQmlPropertyData::flagsForProperty; remove typeCategoryFabian Kosmale2021-03-051-20/+0
| | | | | | | | | | | | | | We do not need to call QQmlMetaType::typeCategory. The information whether a type is a QObject or a QML list type is already stored in the metaobject, and checked in the earlier if branches. Thus, typeCategory could only ever return Unknown. As this removes the only real caller of QQmlMetaType::typeCategory, we can remove the function. QQmlEnginePrivate::typeCategory also called it, but wasn't called itself (and is now also removed) . Change-Id: Iea6055ba44de4d71334f40895e7ce85c3230f3d9 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Unregister value types when tearing down QML typesUlf Hermann2021-02-121-3/+114
| | | | | | | | | Move the value type registry into QQmlMetaTypeData. This way we can conveniently drop the relevant entries when unregistering a type. Fixes: QTBUG-86946 Change-Id: Id024a34a8b2b622fd9417fc0e52864b43c66cc01 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Don't register invalid metatypes in QQmlMetaTypeDataUlf Hermann2021-01-251-5/+0
| | | | | | | | If the original type's ID is not valid, then QQmlMetaTypePrivate's ID is also not valid. Change-Id: Ia727e7dc99b1954b4c6fa9b599e8edc0ef9b3212 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQmlMetaType: Remove lists setFabian Kosmale2020-12-111-5/+6
| | | | | | | | | | The information can be found in the metatype. Task-number: QTBUG-88766 Change-Id: I6c460e3100057498b17d9ed74d2e85b609a6ab4c Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io> Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* QQmlMetaType: Get rid of objectsFabian Kosmale2020-12-111-8/+6
| | | | | | | | | | | Use the information from the metatype instead. Task-number: QTBUG-88765 Task-number: QTBUG-88766 Change-Id: Ie0a748861388e8c36f5f607ccd5aba4d6049b930 Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io> Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Clean up (QQmlEnginePrivate|QQmlMetaType)::toQObjectFabian Kosmale2020-12-111-1/+1
| | | | | | | | | | | | | | | All the necessary information is contained in the QVariant's metatype, so we can use that. This removes the need to acquire the data pointer lock. The method in QQmlEnginePrivate now simply forwards to QQmlMetaType; in a later commit, all usages of the forwarding functions from QQmlEnginePrivate will be replaced with the equivalents from QQmlMetaType, so that they can be removed from QQmlEnginePrivate. Task-number: QTBUG-88766 Change-Id: Iebcda9b18b4952fff2c7c1aeae210c677c6869b8 Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io> Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* QtQml: Integrate sequences with registration macrosUlf Hermann2020-11-111-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | You get to write QML_SEQUENTIAL_CONTAINER(value_type) now, and qmltyperegistrar will generate a sensible registration call from that. A registration might look like this: struct MyStringListForeign { Q_GADGET QML_ANONYMOUS QML_SEQUENTIAL_CONTAINER(QString) QML_FOREIGN(MyStringList) QML_ADDED_IN_VERSION(3, 1) }; It's unfortunate that we need to use a metaobject to transfer all of this information, but there is no other sensible way. Transform the containers defined in qv4sequenceobject.cpp to use the new style, and move them out of the builtins, into QtQml. Recognize that only one of them was ever tested, and add tests for the rest. Task-number: QTBUG-82443 Change-Id: I3a30f9e27266bb575eea26c5daf5dad1ec461cc5 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QML: Allow singleton types to be extendedUlf Hermann2020-11-021-13/+26
| | | | | | | | | It seems we never stated that singletons can not be extended in our documentation. Therefore this is technically a bug fix and doesn't need separate documentation. Change-Id: I7877289bd5a52ecf709f80ba1975137981ec65f0 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QML: Allow namespaces as extensions to typesUlf Hermann2020-11-021-1/+1
| | | | | | | | | | | | | | | | | This way we can access the enums of namespaces as properties of the primary type. This is achieved by: 1. Making enums of extended types available in the base type 2. Allowing the extension to be specified as plain metaObject rather than as type name. 3. Refraining from creating the extension if the create function does not exist. The goal of this is to declare the Qt namespace in a civilized way, but will also help with cleaning up the QtQuick value types and their enums. Change-Id: I13399741d30ce38d1bff753cfa1b11e72ccfbf6a Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qqmlmetatypemodule: Fix maximumMinorVersion() returning bad valuesMaximilian Goldstein2020-10-271-1/+2
| | | | | | | | maximumMinorVersion() needs to ignore unspecified values as they are not versions in themselves. Change-Id: I7c91cf4b8320fd6636eb1be10b069cf885797ee1 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Adjust to QMetaObjectBuilder::MetaObjectFlags changeFabian Kosmale2020-10-211-1/+1
| | | | | Change-Id: I2f9b39fda6c25e57985a32864c85a50b7d6d0231 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Adapt QMutexLocker to qtbase changeFabian Kosmale2020-10-181-1/+1
| | | | | Change-Id: Ica9561a42217f5a509a6e84e9e48036ec6348e48 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QQmlMetaType: Cast the type interfaces to const when deletingUlf Hermann2020-10-121-2/+2
| | | | | | | | We don't need them to be mutable, and the return type of the function will become const soon. Change-Id: I3016d80df31db981d47296e468e93336d3a79ce1 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Allow optional imports in qmldir filesUlf Hermann2020-10-081-1/+1
| | | | | | | | | | This is useful for modules that select their imports at runtime using qmlRegisterModuleImport(). We can list all possible variants as optional imports so that tools can see what types might be available. Task-number: QTBUG-87130 Change-Id: I8a37bdde79aef3619fd1f05e5ea6781d521afa88 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQmlMetaType: Grudgingly accept uppercase value typesUlf Hermann2020-10-051-3/+7
| | | | | | | We throw a warning instead of an error. Change-Id: I0f5886a2d46582405ae1d57879ccb3937e27950f Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Use factory functions and ctors for creating value typesUlf Hermann2020-10-021-0/+1
| | | | | | | | | | As you can extend value types with QML_EXTENDED we may as well allow a factory function in the extended type. Furthermore, if the original type allows construction from QJSValue, we may just use that. In turn, we can get rid of the value type providers now. Change-Id: I9124ea47537eab6c33d7451080ab2fff942eaa7b Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* V4: Rewrite qv4sequenceobject based on QMetaSequenceUlf Hermann2020-10-021-1/+38
| | | | | | | | | | This avoids the template explosion and makes the mechanism extendable. You can now register additional anonymous sequential containers. Fixes: QTBUG-71574 Task-number: QTBUG-82443 Change-Id: I5b9ed9af1533a3b7df8fc5bb37bbb73b8304e592 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Allow proper registration of value typesUlf Hermann2020-09-231-3/+13
| | | | | | | | | | | | | | | | | | | | You can now have an extension object on a value type that offers additional properties. This is how we model the QtQuick value types. It allows us to retrieve the extension's metaobject without using the virtual functions in the value type provider. As before, this mechanism is still rather dangerous and not fit for public consumption. It relies on the extension object having exactly the same layout as the original value type, and it hides any properties the original value type might expose. Furthermore we enforce now that gadgets should have lowercase names. The ones that didn't before are split up into an anonymous value type and a namespace that contains all the addressable bits. Task-number: QTBUG-82443 Change-Id: Ic93d6764538d6ccc0774b3c5648eee08ba0939c0 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Avoid various warnings about deprected QMetaType methodsUlf Hermann2020-09-161-1/+1
| | | | | Change-Id: I8f4b2703fdd08ff341904219cec33c321e0511c7 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QQmlMetaType: Unregister metatype interfaces before deleting themUlf Hermann2020-09-151-2/+6
| | | | | | | Otherwise the type may be retained in the aliases map. Change-Id: If6fbca53a417d76ad21548bea10f68401feb5c8c Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Do proper memory management on the metatype interfaces we createLars Knoll2020-08-281-4/+32
| | | | | | | | | | Those interfaces are always registered in pairs. Add an external refcount to CompositeMetaTypeIds, and do registration and de-registration through this class. Change-Id: I4f3a53ad935a43a734d6506ffc768f507b48ee1f Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Fix QtQml after QMetaType/QVariant changes in Qt CoreLars Knoll2020-08-281-7/+6
| | | | | Change-Id: I2a983cf8188e88d80d3b7726208d821427eb8f3c Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Remove deprecated functions involving attached property IDsFabian Kosmale2020-08-251-24/+0
| | | | | | | | | | | [ChangeLog][QML] The deprecated functions qmlAttachedPropertiesObjectById and qmlAttachedPropertiesObject(int *, const QObject *, const QMetaObject *, bool) have been removed. Use the qmlAttachedPropertiesObject(QObject *, QQmlAttachedPropertiesFunc, bool) overload of qmlAttachedPropertiesObject instead. Change-Id: I6bc8315557733dc2f51b2ffdebeec51873b74b2b Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Adapt to new members in QMetaTypeInterfaceUlf Hermann2020-07-151-0/+2
| | | | | | Change-Id: If355b891651b77fcc4e0ad5cc5db789807b83c11 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Add userdata callback to qml registrationMaximilian Goldstein2020-07-101-0/+1
| | | | | | | This is needed in order to remove PySide2's qml type limit. Change-Id: I331d9e31574a744eb9085222d58ea8a8789e0e31 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* QQmlMetaTypeData: Key nameToType by QHashedStringUlf Hermann2020-06-291-1/+2
| | | | | | | | | As the new QMultiHash does not store a separate copy of the key for each value, we'd get dangling string references when the "wrong" values were removed. Change-Id: I4ccf6db8bdbf4d38ef393b66b61b285ce763f5c2 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Match specific module imports also for versionless QML importsUlf Hermann2020-06-291-15/+26
| | | | | | | | | | Previously, if you registered a module import for a specific version X of a module, and the user imported the module without specifying a version, the module import would not be carried out even if X was the version actually imported. Change-Id: I853ed6f275501cf4cbd4e5a360985e67b07f3773 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Discern between "auto" and versioned imports in qmldirsUlf Hermann2020-06-241-8/+39
| | | | | | | | | | | | | You can now import the latest version, a specific version, or, "auto" which is the same version as the parent module. [ChangeLog][QtQml] You can now procedurally add module imports to modules, using qmlRegisterModuleImport(). However, actual import statements in qmldir files should be preferred wherever possible. Fixes: QTBUG-84899 Change-Id: I3b32dd8b07a19d31b6538b9a6bb436840862f345 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Lock all type modules of the same URI when importing a pluginUlf Hermann2020-06-181-4/+18
| | | | | | | | | | | | | A plugin may provide multiple versions of the same types. If we don't lock them all, a further plugin may later mess with the ones we didn't lock. The code clearly attempts to prevent such a situation. Of course, a plugin may still register types under a wholly different URI, and sidestep this mechanism. However, in contrast to exposing multiple major versions from the same plugin, this is not recommended. Change-Id: Ib8d8bbeec8e738020c6d07aedcc4664157b80dcf Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQmlMetaTypeData: Use a better container for the type modulesUlf Hermann2020-06-181-49/+29
| | | | | | | | | | | We often want to retrieve all type modules of a specific URI, no matter what version. Use a sorted vector to make those available without iterating all modules. Also, use a unique_ptr rather than manual memory management. Sorting the pointers should be fairly cheap, and we also don't have to store the keys anymore. Change-Id: I132c2ec3817afab1d60c3ba832d0b907ff6bfeb0 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Port QtDeclarative from QStringRef to QStringViewKarsten Heimrich2020-06-161-1/+1
| | | | | | | | Task-number: QTBUG-84319 Change-Id: I2dcfb8a2db98282c7a1acdad1e6f4f949f26df15 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Un-pimpl QQmlModuleImportUlf Hermann2020-06-101-1/+1
| | | | | | | There is no point in having that pimpl'd. Change-Id: I9e3f6671ca178ea3f58fd0488dbb291a38656685 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQmlMetaType: Drop unneeded second arguments to QHash::value()Ulf Hermann2020-06-091-3/+3
| | | | | Change-Id: I351785ed33e7b28f2241a113c96ca32fae4b8111 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQmlTypePrivate: do not abuse volatile for atomicFabian Kosmale2020-06-091-1/+1
| | | | | | | | | | Instead of using volatile, use proper atomics for thread safe access. Moreover, we don't gain anything by using bitfields here, as we have space for 4 bools due to alignment reasons anyway. Therefore using bools does not create any overhead. Change-Id: I390acd935656efcb20265ddb67fa0059f3f18118 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>