aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* CMake: Fix framework buildsAlexandru Croitor2020-09-291-1/+1
| | | | | | | | | | | After 5c1ed8bb74ee4eed9ffc9537b880104445b43cd7 in qtbase, the framework version was changed from '6' to 'A'. qtdeclarative had the '6' hardcoded for the qmldevtools module. Switch it to 'A'. Fixes: QTBUG-87031 Change-Id: I21a9e83dfe27904cd67a14371bbc8bb008175dc1 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQItemPriv::localizedTouchEvent: don't skip parents of passive grabbersShawn Rutledge2020-09-281-0/+12
| | | | | | | | | | | | | Some subtests of tst_FlickableInterop::touchAndDragHandlerOnFlickable() check whether Flickable can continue to filter child mouse events, even when the only thing going on is that we are delivering a TouchUpdate QTouchEvent to a TapHandler inside the Flickable's content item (such as inside a ListView delegate) due to its having a passive grab. So during filtering only, localizedTouchEvent() needs to localize the event for any item that has passive grabbers somewhere in its children. Change-Id: Icff0438ddba97bd916feedc9dcd6a71ae47671e5 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* qmllint: Consistently spell "Warning"Ulf Hermann2020-09-282-3/+3
| | | | | | | There was one place where it was written in lower case. Change-Id: Id953fa6c260502ab5bca8cfa061c817bb5a70581 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qmllint: Make imports localUlf Hermann2020-09-286-99/+169
| | | | | | | | | Imports are not transitive. qmllint gets this wrong so far. Fixing it reveals two tests where we use types we haven't imported. Import the relevant modules. Change-Id: I45f3229468d54137f97d6b699f3a98a1349bc412 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Port from devicePixelRatioF() to devicePixelRatio()Morten Johan Sørvig2020-09-2813-27/+27
| | | | | | | This ports all of QtDeclarative. Change-Id: Ie6eb4d96b4d49fbed1e8be514d03e331549cd712 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* qqmlimport: Use stable_partition instead of stable_sortFabian Kosmale2020-09-283-14/+26
| | | | | | | | | | | | We do not actually need to sort the imports list, we just require that all inline component imports come before all other imports. This avoids triggering a MSVC STL debug assertion about the used Compare function not actually creating a strict ordering. Fixes: QTBUG-86989 Pick-to: 5.15 Change-Id: I381852392545287ec02b186fcb4f33be3ae95b33 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Update dependencies on 'dev' in qt/qtdeclarativeQt Submodule Update Bot2020-09-281-1/+1
| | | | | Change-Id: I914e75daaa118e4789c456253f0da8a6139886e3 Reviewed-by: Daniel Smith <Daniel.Smith@qt.io>
* Export QQmlLocale symbolsVolker Hilsheimer2020-09-281-4/+4
| | | | | | | | | After 8e222a70d19d5eef616e1d6306415da64fbab4cb, QQmlLocale is a namespace and doesn't export any symbols. Export the member functions explicitly, as they are needed by Qt Quick Controls. Change-Id: I867cb5c0325c6c19200408b514c086c8057c82a9 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Blacklist a few more on macOSShawn Rutledge2020-09-264-0/+10
| | | | | | Task-number: QTBUG-86729 Change-Id: I49fb86e867afeee2f0567dc3498598b249ae5e08 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Handle ungrab and grab-cancel consistently; inform handlersShawn Rutledge2020-09-2611-76/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Call onGrabChanged on Pointer Handlers during grab transitions: this was missing in a97759a336c597327cb82eebc9f45c793aec32c9. Flickable needs to receive an ungrab by child-event-filtering, in order to set its pressed state back to false (as in the cancelOnHide autotest). This is best done as a result of the QPointingDevice::grabChanged signal, while trying to send the ungrab to the item that was the grabber, rather than as a special case. Thus, QQuickWindowPrivate::onGrabChanged (the handler for the QPointingDevice::grabChanged signal) is now the only place from which we call QQuickItem::mouseUngrabEvent() and touchUngrabEvent(). But the result is that they are called in more cases than before, so some tests need adjustment. touchUngrabEvent() is not sent unless the event is available and we can verify that all points have been released. This is important for MultiPointTouchArea: it will react by ending interaction with all points at once. Another thing that's important to MPTA and multi-touch handlers is that QQuickWindowPrivate::deliverPointerEvent() must not clear grabbers of points that are not yet released, in the case that only some points are. QQuickWindowPrivate::removeGrabber() now calls QPointingDevicePrivate::removeGrabber() with its optional cancel argument, so that it will emit either a cancel or an ungrab transition. That's only relevant for Pointer Handlers, whereas QQuickItem mouseUngrabEvent and touchUngrabEvent don't make a distinction. Task-number: QTBUG-86729 Change-Id: Idf03aef2e2182398e0fc4a606c0ddbb2aaed5681 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qmllint: Use a hash for scripts read from qmldir filesUlf Hermann2020-09-252-5/+5
| | | | | | | You cannot use the same name multiple times anyway (for now) Change-Id: I957340273772a1c5cf0a9da840a305bc8b311e95 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* TypeDescriptionReader: Don't export C++ names as QML namesUlf Hermann2020-09-257-42/+63
| | | | | | | | | | | | | | This is just wrong. The types are not visible in QML under their C++ names. Indeed, this way we reveal a number of places where we confuse the names. Fix those in turn. Furthermore, one of the tests was incorrect. The qmltypes files did not contain an export entry for one of the types, and therefore the type was formally anonymous in QML. However, we did access it via its C++ name. Fix that by exporting the C++ name. Change-Id: I8dd96334076b90fb174daf5b285d622f96495f56 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qmllint: Split available names into exported, imported, C++ namesUlf Hermann2020-09-254-44/+79
| | | | | | | | | | exported names are the names a component intends to export. imported names are the names the importing component sees, possibly adding a prefix. C++ names are only used in qmltypes files for non-composite types. Change-Id: I843e34f07a026a06931ed76d72a3cce98e3e5552 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* cmake: enable colorresolving benchmarkFabian Kosmale2020-09-252-1/+29
| | | | | Change-Id: I15321e9940b1b9d5a1ae6f1296bf9466ca4f4262 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Update dependencies on 'dev' in qt/qtdeclarativeQt Submodule Update Bot2020-09-251-2/+2
| | | | | Change-Id: I7c423f41dd19c9ad1503c34512acbbbd7a1ba651 Reviewed-by: Daniel Smith <Daniel.Smith@qt.io>
* Blacklist various failing testsShawn Rutledge2020-09-256-0/+23
| | | | | | | | | | | | tst_qqflickable::nestedStopAtBounds, nestedSliderUsingTouch tst_QQuickMouseArea::preventStealing, nestedFlickableStopAtBounds tst_QQuickMultiPointTouchArea::inFlickable2, inFlickableWithPressDelay tst_QQuickPathView::nestedinFlickable, touchButtonOnFlickable, touchGrabCausesMouseUngrab tst_qqmlpropertycache::derivedGadgetMethod Task-number: QTBUG-86729 Change-Id: Ie11a50c25f90fde2636b05a72f51640643b33dec Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQuickTextControl: Adapt to API change for retrieveData()Ulf Hermann2020-09-252-2/+2
| | | | | Change-Id: I7010c3fc1e922672eece4e2fee15e747ff21589c Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Adapt to changes in QMetaSequenceInterface and iterablesUlf Hermann2020-09-251-7/+7
| | | | | | | | metaSequence() became metaContainer() and we should ask for canConvert() as there are two ways to convert to a container. Change-Id: Iba868491ff9d2cc8fc89de1cab29818b834b53f4 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQmlDirParser: Treat dependencies like importsUlf Hermann2020-09-256-28/+38
| | | | | | | In particular, allow auto and latest versions. Change-Id: I4a6b26112950d066ae2d8a37dc0e9fa1dec24724 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* ScopeTree: Remove the "name" propertyUlf Hermann2020-09-255-23/+25
| | | | | | | It was rarely used and only caused confusion. Use internalName instead. Change-Id: I196b1d77db04a2cb6e3cd0447d34ce9bae0b9cd5 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qmllint: Clarify the meaning of the various names a scope can haveUlf Hermann2020-09-255-21/+25
| | | | | | | ... and notice that they are misused everywhere. Change-Id: I2254993dc5d11e967e7e83c6f0efb37fa17744be Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qmllint: Keep scopes mutable until all the imports are resolvedUlf Hermann2020-09-254-13/+13
| | | | | Change-Id: I48601019d0e200eae9d52c3a9db45913cdd9d0f8 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* ScopeTree: Add provisions for supplying types to methodsUlf Hermann2020-09-252-9/+44
| | | | | | | | | We want to proactively fill in all the types when constructing the ScopeTree so that we don't have to carry an undue number of imports around. Change-Id: I209d88568434c36073c11216dcd052babe5e3dae Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* CMake: Rename internal functions to contain qt_internalAlexandru Croitor2020-09-251-4/+10
| | | | | | | | | Offer compatibility wrapper functions until we update all of the Qt repos to use the new names. Task-number: QTBUG-86815 Change-Id: I834ac1d5d6549bd4e33b9916a2198a7a03c0d183 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* qmllint: Mark scopes read from QML files as compositeUlf Hermann2020-09-251-0/+1
| | | | | Change-Id: I3e46a62595bfc05cdf9ee4233a27cd744b080ab9 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* qmllint: Move import handling code into separate classUlf Hermann2020-09-252-64/+126
| | | | | | | | This still messes up the association between scopes and imports, but at least it encapsulates the issue better. Change-Id: I67239495e61ee10d18e6c4b3e837560a42650710 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Blacklist tests flickable.nestedPressDelay, gridview.snapOneRowShawn Rutledge2020-09-242-0/+4
| | | | | | Task-number: QTBUG-86729 Change-Id: I061147b99c957a9b0d15b2f3305e26c9e2a99989 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Stabilize tst_QQuickListView::parentBindingShawn Rutledge2020-09-242-2/+8
| | | | | | | | | | Some platforms aren't registering their mouse devices yet, and we don't want false failures in CI because of that, so just register a mouse, even if it ends up being an extra one a lot of times. Task-number: QTBUG-86729 Change-Id: Ia3a91e3d1e4fb8df90352555c9a7ec6ea18bf6fe Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Get rid of QMutableEventPoint::stationaryWithModifiedPropertyShawn Rutledge2020-09-243-13/+10
| | | | | | | | | | | | Omitting stationary points from touch events is such a marginal optimization that this code probably isn't worth maintaining. It wasn't implemented correctly this time either, according to the tst_QQuickMultiPointTouchArea::stationaryTouchWithChangingPressure() test. Task-number: QTBUG-77142 Change-Id: I1ccc8ffe0451d6417add2b03c063ac1aebe36e8e Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Blacklist tst_qquickwindow::cleanupGrabsOnReleaseShawn Rutledge2020-09-241-0/+2
| | | | | | Task-number: QTBUG-86729 Change-Id: I9d592ae48d26851938d57d52620af12c2086054a Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Blacklist maiop::dragHandlerInSiblingStealingGrabFromMouseAreaViaTouchShawn Rutledge2020-09-241-0/+2
| | | | | | Task-number: QTBUG-86729 Change-Id: Ib2585663d8cc213ccd14d1fa5d3bd854062b09c9 Reviewed-by: Daniel Smith <Daniel.Smith@qt.io>
* qmllint: Don't dump imported enums into the current scopeUlf Hermann2020-09-244-5/+21
| | | | | | | | | This bit of code has never fulfilled any discernable function. Enum access is done elsewhere. Add a test case to prove that access to enums from QtQml's plugins.qmltypes still works. Change-Id: I62fd6c1ec748c88205aa20367ee06d7a33502fa1 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQuickDrag: Do not crash when changing supportedActionsFabian Kosmale2020-09-231-0/+2
| | | | | | | Fixes: QTBUG-82157 Pick-to: 5.15 Change-Id: I9d694dd543f41b1ce2b6976983d03a3dc659245d Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* QQmlTypeCompiler: Resolve aliases earlierFabian Kosmale2020-09-231-11/+12
| | | | | | | | | This is a prequisite for determining whether a change handler of an alias should use its change signal, or whether it can use the alias target's bindable interface. Change-Id: I6f5220a6889601327cb478479c7c9e58f1a64d97 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Condense the different value type creation functions into oneUlf Hermann2020-09-236-51/+26
| | | | | | | They all did the same thing. Change-Id: I7661b19ad16c0713d46c4df337899e3897349b2e Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Eliminate QQmlValueTypeProvider::storeValueType()Ulf Hermann2020-09-234-51/+4
| | | | | | | | | | | | It was only used for QColor. The string representation of QColor was funneled through the color provider to get a numerical RGBA value and that one was passed to storeValueType() which would create a QColor object. The RGBA value was retrieved by creating a QColor object. We can just directly create the QColor from the string, and we can use the generic create() method for that. Change-Id: If36775830882237e5e36f748872ce23530c3bb71 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Eliminate QQmlValueTypeProvider::createVariantFromString()Ulf Hermann2020-09-234-75/+1
| | | | | | | This can be expressed as constructing the variant from a QJSValue. Change-Id: I3140958469423acdc498e26129e349bcfb601198 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Eliminate QQmlValueTypeProvider::createFromStringUlf Hermann2020-09-237-123/+71
| | | | | | | It can be expressed as a special case of create() with a QJSValue. Change-Id: I7342026ad694077d2780dd8a852714fa72dd68d0 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Remove QQmlValueTypeProvider::variantFromJsObjectUlf Hermann2020-09-234-137/+93
| | | | | | | This can be expressed in terms of create(). Change-Id: Id1950390bf4a1c9dfd9364ea351b81c75eb7e28f Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* QQmlValueTypeProvider: Pass arguments as QJSValueUlf Hermann2020-09-234-99/+62
| | | | | | | | This is so that we can replace them with factory functions as a next step. Change-Id: Ic8619e4e779bd3e47471642c556601555758697b Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Allow proper registration of value typesUlf Hermann2020-09-2318-324/+425
| | | | | | | | | | | | | | | | | | | | 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>
* Fix ubsan errorAllan Sandfeld Jensen2020-09-231-5/+9
| | | | | | | | memcpy can't officially copy from nullptr, not even 0 bytes. Pick-to: 5.15 Change-Id: Ie6ede9a861cb2ae7ab35a50db5aa6c82cea6ad76 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Map swap interval 0 to NoVSync with all the APIsLaszlo Agocs2020-09-232-2/+16
| | | | | | | | | What exactly this will cause is another question. But at least now the traditional OpenGL way of setting the QSurfaceFormat's swapInterval 0 will have an effect with the other APIs as well. Change-Id: I6d50952502a70e84828ed87347e2a948299f6f42 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Avoid crash when module version cannot be resolvedEskil Abrahamsen Blomfeldt2020-09-231-1/+5
| | | | | | | | | | | | | | | When QQmlMetaType::latestModuleVersion() returned an invalid version, we would fail importStaticPlugin() without adding any error. Since we unconditionally called takeFirst() on the errors list, we would later crash. The precondition here is that any failure adds an error, so we now assert to make this explicit. Also, add a simple module not found error when we can't resolve it. Change-Id: I7a13775b2ef56d95b7738ac53e58501b8c68895f Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Prevent crash when destroying asynchronous LoaderJoni Poikelin2020-09-233-1/+69
| | | | | | | Fixes: QTBUG-86255 Pick-to: 5.15 Change-Id: I30488b64d910a1409a43e2e98ee7ab084aec33d2 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* QQmlPropertyCapture: Replace list with forward listFabian Kosmale2020-09-222-1/+11
| | | | | | | | This required adding one missing function from QFieldList to QForwardFieldList, but saves one pointer and one quint32. Change-Id: I022fcd2e6bffe39b2d01f4664fd2ab154445fb00 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* tst_qqmllanguage: Use namespaces for registering enum containersUlf Hermann2020-09-222-9/+13
| | | | | | | The uppercase names indicate that we don't actually want value types. Change-Id: Id9b64be8770b7fcf49e668dfd0994e9c4e85b948 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* CMake: Regenerate projects before API changeAlexandru Croitor2020-09-224-28/+2
| | | | | | | Task-number: QTBUG-86815 Change-Id: I834513b93cf495ff9075d4cd541ed425e2ccbc15 Reviewed-by: Cristian Adam <cristian.adam@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Fix compilation for OpenVG pluginEskil Abrahamsen Blomfeldt2020-09-2210-34/+30
| | | | | | | Adapt to changes in RHI and Qt 6 in general. Change-Id: I1f8f148530e8ca1db482430b6147fc5fbba9f813 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Replace QmlVoidT with std::void_tUlf Hermann2020-09-221-14/+11
| | | | | | | Now that we can use C++17 we don't need to invent our own. Change-Id: I6c6e02ac9b48f2fbe88160e7f9ebf9655092c9fc Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>