aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Doc: Clarify DelegateModelGroup::setGroups() descriptionSze Howe Koh2020-08-301-7/+2
| | | | | | | | The previous description had an awkward structure and was duplicated. Pick-to: 5.15 Change-Id: I46dbc804e1c907198364f441fd46eb853db97e6a Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
* Update dependencies on 'dev' in qt/qtdeclarativeQt Submodule Update Bot2020-08-281-2/+2
| | | | | Change-Id: I07e874941490941834091ef4aa0f308a99ebc60b Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Use OpenType font weightsJonas Karlsson2020-08-288-19/+15
| | | | | | Task-number: QTBUG-42248 Change-Id: Ib26d4945307b630b054e270b3213e1c9ad0d5357 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* Do not incorrectly leave srcAlpha and dstAlpha set to the defaultsLaszlo Agocs2020-08-281-2/+2
| | | | | | | | | | | | TargetBlend defaults to One, OneMinusSrcAlpha, One, OneMinusSrcAlpha when it comes to srcColor, dstColor, srcAlpha, dstAlpha. When setting a blending different than our standard premultiplied alpha, srcAlpha and dstAlpha must be set too. Otherwise what we get is something that is not equivalent to Qt 5's glBlendFunc() call. Change-Id: Ied03669edae9dcf3ec4c9c5b560195511db8d00b Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Do proper memory management on the metatype interfaces we createLars Knoll2020-08-285-21/+86
| | | | | | | | | | 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-289-109/+107
| | | | | Change-Id: I2a983cf8188e88d80d3b7726208d821427eb8f3c Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Update dependencies in qtdeclarativeLars Knoll2020-08-281-2/+2
| | | | | Change-Id: I0af3891f46f97fe45f89c60fa8e8b533acd8de15 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Fix a bunch of compiler warningsLars Knoll2020-08-284-6/+7
| | | | | | Taks-number: QTBUG-86234 Change-Id: I4c945edecdbe55bc5587c18599d49dfb82ade1eb Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Use QPalette::resolveMask() and setResolveMask() where necessaryShawn Rutledge2020-08-283-5/+5
| | | | | | | This is needed after qtbase b77a3f47c9d6f4fd68a687e3bdb38e550d2810ad. Change-Id: I41cf66d51dad7209c21d9e4049497a1f911e132a Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Always group the metaType and listType togetherLars Knoll2020-08-286-23/+19
| | | | | | | | They are always created and destroyed together, so grouping them makes the required memory management of them easier. Change-Id: Ia1980f31f9bdff6a1accd229bc8380ae153edf67 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQuickCanvas: Skip failing test for nowFabian Kosmale2020-08-281-0/+2
| | | | | | | | | | font::toString now outputs more information, so the test would need to be adjusted. However,we priorize geting the dependency update in over fixing the test for now. Task-number: QTBUG-86304 Change-Id: I44182b6115752a4cfb177e07b862f9e018613edf Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Remove deprecated registration functionsFabian Kosmale2020-08-273-44/+2
| | | | | | | | | | | | | | [ChangeLog][QML] Removed qmlRegisterType overload taking no arguments, use qmlRegisterAnonymousType instead, or switch to declarative type registration with QML_ANONYMOUS. Removed overloads of qmlRegisterExtendedType and qmlRegisterInterface which did not take a version argument. Use the overloads providing a version, or swtich to declarative type registration with QML_EXTENDED and QML_INTERFACE. Change-Id: Iadcc53d7ebe5cae40856b69efc33293fd0208c1f Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Document QML_FOREIGN_NAMESPACE() macroFawzi Mohamed2020-08-271-1/+20
| | | | | Change-Id: I5793df82849f06e2d870335c3c17902e452399a4 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* new builtins.qmltypesFawzi Mohamed2020-08-271-1614/+826
| | | | | | | | | | | manually mantained qmltypes files with the builtintypes (as defined in ECMA-262) This is a best match effort, unfortunately we cannot (yet?) express all the semantic of ECMAScript, but we try to be close to it. Fixes: QTBUG-83815 Change-Id: I0572114ff9f2d5a0855c62def824551cba8be655 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* import Qt namespace in QtQmlFawzi Mohamed2020-08-273-6/+33
| | | | | | | | | | | | | | | | | | | | | | | | Introduces and uses the QML_FOREIGN_NAMESPACE to declare the Qt namespace in QtQml, and exports all the enumerations in the Qt namespace, and makes them available also in QtQml/plugins.qmltypes Please note that this does *not* remove the special QV4::QtObject as it contains much more than the enumerations. Having two object registered as Qt (the complete QV4::QtObject added to the global properties in ExecutionEngine::initializeGlobal, and QtInQml registered by the qmltyperegistrar) gives problems, if the partial one overrides the complete one. For this reason the classinfo QML.ManualRegistration (no public macro until shown to be more generally useful) is introduced and used to ensure that QtInQml generates only documentation (plugins.qmltypes), and no registration that might conflict with QtObject. This makes the current builtins.qmltypes redundant. Fixes: QTBUG-84897 Change-Id: Iffc96cd3e1d9f9d7d047ee60221a4b0928f53005 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Follow layoutMirroring in Layout marginsDavid Edmundson2020-08-264-1/+56
| | | | | | | | | | | | | | | If a layout is laid out left to right using the layoutDirection property, we want left Margins on the left, and rightMargin still on the right However, if a layout is mirrored, not only should the layout direction change but also the left margin should now be on the right and vice versa. Task-number: QTBUG-62989 Pick-to: 5.15 Change-Id: Iaae4bc436fd1eb7f1947869563ac325f3d6b79bb Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Remove deprecated QQuickWindow::sendEventFabian Kosmale2020-08-262-60/+0
| | | | | | | | | | | [ChangeLog][QQuickWindow] Removed the obsolete QQuickWindow::sendEvent function. Use QCoreApplication::sendEvent instead. Change-Id: I583ea8f87b870b136315efa4e1105de484e5f1ab Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Remove deprecated function QJSValue::engineFabian Kosmale2020-08-264-105/+0
| | | | | | | | | [ChangeLog][QJSValue] The deprecated function QJSValue::engine() has been removed. Change-Id: I2be35379e0a9e51f5371a2c98b955282955b7147 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* CMake: Use strict C++ (no GNU extensions) when compiling qml modulesAlexandru Croitor2020-08-261-0/+1
| | | | | | | | Uses the new function exposed by qtbase, to mimic CONFIG += c++_strict from qmake. Change-Id: I972cd899f8e4c7b51e792e0e20433d016d4ac4b6 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* CMake: Regenerate load(qt_app) projectsAlexandru Croitor2020-08-261-6/+5
| | | | | | | | Use the new qt_internal_add_app function. Task-number: QTBUG-85757 Change-Id: I455443a29511c809d2ad87073b2ae685fdbf27ae Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Make sure that header is self-containedKai Koehne2020-08-261-0/+1
| | | | | | | | | Since qtbase commit f741a12de11c9 qimage.h doesn't include qobject.h anymore. Task-number: QTBUG-82615 Change-Id: I9422bcc049bc34271c91e341017881a18857d155 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* tst_qqmlqt: Avoid warning in testFabian Kosmale2020-08-263-13/+10
| | | | | | | | | | | | | The test files still contained a property to test functionality which was in the end discarded; thus passing the wrong number of arguments to functions and causing a warning. We simply remove them as they are not needed anywhere. Amends 19850f129881a04c36c51859454bf71ed688f28a As a drive by, replace the obsolete variant with var. Change-Id: If0b3dcd6d8a339a569c39ce304b68fecd3d72779 Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* [Fix] Use the sourceDir if specifiedAssam Boudjelthia2020-08-261-5/+6
| | | | | | | | | | Android is passing the test path via QUICK_TEST_SOURCE_DIR but it was set to ":/" no matter what. Pick-to: 5.15 Change-Id: If0e6615999019cf1869a237056d41e35b5be12f1 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
* Remove deprecated functions involving attached property IDsFabian Kosmale2020-08-256-103/+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>
* Remove deprecated QJSEngine::installTranslatorFunctions functionFabian Kosmale2020-08-252-38/+0
| | | | | | | | | [ChangeLog][QJSEngine] The deprecated installTranslatorFunctions() has been removed. Use installExtensions() with TranslationExtension instead. Change-Id: I58345793ea154ec37d0c64f13c958193e6fa461b Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Add "we mean it" comment to private headerVolker Hilsheimer2020-08-251-0/+11
| | | | | | | | Fixes warning from build system. Change-Id: If6c7885fa19f17b5821142176b6239bb337a6022 Pick-to: 5.15 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* CMake: Rename example conflicting with qtquick3dAlexandru Croitor2020-08-252-7/+63
| | | | | | Fixes: QTBUG-86205 Change-Id: I38992501abb86a4328527283ad8924ec886ea8c8 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* qmllistcompositor_p.h: Fix deprecated-copy errorMaximilian Goldstein2020-08-241-12/+0
| | | | | | Fixes: QTBUG-86025 Change-Id: I83ce650e788aecdf4bebfc6a6a4331554f2c6be5 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Update dependencies on 'dev' in qt/qtdeclarativeDaniel Smith2020-08-241-2/+2
| | | | | Change-Id: I64c8f82a68aeb08d214761c407b1ce52017f4555 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Doc: fix Qt Quick Test headerMitch Curtis2020-08-241-0/+1
| | | | | | | | It's QtQuickTest, not QQuickTest. Pick-to: 5.15 Change-Id: Ic28d11814bdbc5a3de61235205617878250ea0e9 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Unify "variant" and "var" properties in QMLFabian Kosmale2020-08-2421-616/+9
| | | | | | | | | | | | | | | | | | | | variant and var properties differ in two important ways: - variant properties trigger "magic" string conversions: variant v1: "red" // contains a QColor var v2: "red" // contains a string - variant properties behave differently for value types: they create copies, instead of references. However, as variant properties were marked as obsolete and this behavior was effetively undocumented, it should be safe to give "variant" "var semantics". With this change, we can also avoid doing magic conversions when storing data in QVariant properties of QObjects/QGadgets Change-Id: I549b1beb98e6af9639c1ee81f316bda513d5ff65 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Remove qml statemachine plugin from qtdeclarativeKarsten Heimrich2020-08-2364-4657/+1
| | | | | | Task-number: QTBUG-80316 Change-Id: I584b699a1eec88117f343870bd2cd01075da64f7 Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
* Adapt to qtbase changesFabian Kosmale2020-08-2313-28/+31
| | | | | | | | | | | The internal QVariant constructor taking a QMetaTypeId has been removed. Thus, construct QMetaTypes where necessary from the id, or avoid a QMetaType -> ID -> QMetaType roundtrip where we already have a metatype. Also fix a few missing includse that were previously transitively included. Change-Id: I56ce92281d616108a4ff80fe5052b919d1282357 Reviewed-by: Fawzi Mohamed <fawzi.mohamed@qt.io>
* Update dependencies on 'dev' in qt/qtdeclarativeQt Submodule Update Bot2020-08-231-2/+2
| | | | | Change-Id: Ia3e429a2c132c116a8bc0f779392c316c39bde27 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* tst_qqmltypeloader: Adapt to network redirection change in qtbaseFabian Kosmale2020-08-231-0/+15
| | | | | | | | | | | d12afeff4097dd78f1311511e0c8f74e1a810d47 in qtbase changed the default from manual to NoLessSafeRedirectPolicy. The redirect test however relies on us being able to handle redirections manually. Restore the old behavior in the test by installing a QNetworkManagerAccessFactory which returns QNAMs with the old behavior. Change-Id: I69ccf39189e79dbea6b1734e99c56e36858af208 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* tst_qquickaccessible: Adapt to QVariant::isNull changeFabian Kosmale2020-08-231-2/+4
| | | | | | | | | isNull does not cascade anymore to its contained type's isNull function. Thus, adjust the test to check string emptiness in a saner way. Change-Id: Ia7376010e8a13dcaa5ddc9328525c0771d032ebc Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove last remaining use of QStringRefKarsten Heimrich2020-08-231-1/+1
| | | | | Change-Id: I91685ac4cf1f5186d58252587fb8c7d7375372b2 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Qt6QmlMacros.cmake: support multiple versions in QT_QML_SOURCE_VERSIONMitch Curtis2020-08-231-6/+9
| | | | | | Task-number: QTBUG-86174 Change-Id: Ibd3755898ac5d292ee3d5b188a5a95f7d2f627dd Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Add override behaviors to QQmlListPropertyUnai IRIGOYEN2020-08-2210-1/+200
| | | | | | | | | | | | [ChangeLog][QQmlListProperty] When overriding a QQmlListProperty in a derived QML type, the default behavior is to append the derived class elements to the base class ones. This introduces a macro to allow replacing the base type contents either always or if the property is not the default one. Fixes: QTBUG-77529 Change-Id: Ib1abbf52e341c043344c347c612928b47856fb3e Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* QQuickLoader: make sure the status property change properlyWang Chuan2020-08-222-0/+5
| | | | | | | | | | | | | When we call [setSource] in qml, we will try to convert a qml value to a string which indicate the url we want to load. However, if this value is undefined, it will convert to a string with content "undefined", and then cause loading error. More worse, if there is a qml file named "undefined", it will be loaded to the Loader. Pick-to: 5.15 Fixes: QTBUG-85938 Change-Id: I5b192ba84aa29532e547349bbf37d413c107d8e4 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQmlObjectCreator: fix member func call with this == nullptrEvgeniy A. Dushistov2020-08-223-1/+21
| | | | | | | | | | | | | | | | The test example is based on qtvirtualkeyboard/src/virtualkeyboard/content/components/PopupList.qml Luckily ((QQmlPropertyCache *)nullptr) -> property(-1) is ended without access to this, so this was not caught before. But this is UB, plus I can not run Qt and my application compiled with -fsanitizer=X, because of it crashed after the first member function call with nullptr as this Fixes: QTBUG-85605 Change-Id: If6a71fde9a14cc4f73139dfa0e6ee3005453104d Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQuickLoader: make sure the status property change properlyWang Chuan2020-08-223-0/+39
| | | | | | | | | | | | Since the invocation of [setSource] in qml will clear the old source url first, it is hard to decide whether we have changed the source url, especially when we call [setSource] with an empty string, and the loader's status won't change properly. Pick-to: 5.15 Fixes: QTBUG-85938 Change-Id: If61a33c790a4fd6562611c4c50756bc5e213363a Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qmllint: fix import java scripts from moduleEvgeniy A. Dushistov2020-08-227-0/+36
| | | | | | Fixes: QTBUG-86183 Change-Id: I4809cb5a408eb4e668f802cf0d7b7a872d1ed4b7 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* tst_qqmlenginedebugservice: Adapt to QVariant comparison changeFabian Kosmale2020-08-221-7/+13
| | | | | | | | | | | QVariant::operator== won't do the needed conversions anymore, so we have to apply them manually. In contrast to operator==, convert is not const, so we have to apply it to a copy of the variant. Change-Id: Ic55c2791038dbc9e45dcdcb163828cb7ca93a29e Reviewed-by: Fawzi Mohamed <fawzi.mohamed@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Adapt to QNetworkRequest changeFawzi Mohamed2020-08-201-0/+1
| | | | | | | | | | | | | | | | In d12afeff4097dd78f1311511e0c8f74e1a810d47 the default for redirection handling was changed from manual to NoLessSafeRedirectPolicy. This makes the redirection handling asynchronous, leading to a failure in tst_qqmlxmlhttprequest::redirects. In it the request is not finished after component.completeCreate(). Thus the property dataOK is read before being set to true, and the test fails. This change reestablishes the ManualRedirectPolicy, giving the old behavior, and fixes a failure blocking CI. Change-Id: I525b1229b4ce8cfb814bdb66f86f745ea05c1b5c Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qmlformat: fix handling of "if else" inside "if" in "if else"Evgeniy A. Dushistov2020-08-204-15/+57
| | | | | | Fixes: QTBUG-86060 Change-Id: I7a191c451793bf4e1f6a2bd02ceb36b5957136c2 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Weak compare for value types in QMLFawzi Mohamed2020-08-201-1/+47
| | | | | | | | | | | | QPoint, QPointF, QRect, QRectF,... are basically equivalent in QML JS where int and double are stored as double, but QVariant now has a stricter equality comparison, which breaks code. Make QQmlValueTypeWrapper::isEqual perform the weaker comparison. This fixes a regression in tst_qqmlvaluetypes and tst_qqmlvaluetypeproviders which blocked CI. Change-Id: I0fe1cab17092190ff6cf2a01310943d72d932073 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* tst_qqmllanguage: Fix failure due to stricter equality of QVariantFawzi Mohamed2020-08-201-1/+4
| | | | | | | add explicit conversion to QDate to handle strict comparison Change-Id: I5e2ce46e13dc2b1580fc463f88d2cd8401371235 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* tst_qjsengine: Fix comparison related failuresFawzi Mohamed2020-08-201-3/+8
| | | | | | | | | | | | The new QMetaType/QVariant comparison is strict, so that several comparisons now fail. so we try to convert before comparing. Remaining ugliness: QString -> QChar conversion not provided, so change input to string QVariant(static_cast<QObject *>(x)) != QVariant(x) if x is a subclass of QObject. Change-Id: Ie0b7ba40d36a5e935976d1947d95295c48cd0c23 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Fix tst_qqmlproperty failures due to stricter QVariantMaximilian Goldstein2020-08-201-3/+3
| | | | | Change-Id: Ie1f0ee6ae076e50053a19b19e48fe6e996696a69 Reviewed-by: Fawzi Mohamed <fawzi.mohamed@qt.io>