aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick
Commit message (Collapse)AuthorAgeFilesLines
* rhi: Make QSGRenderNode usable in Quick3Dv5.15.0-beta2Laszlo Agocs2020-03-113-41/+56
| | | | | | | | | | | | Cannot just rely on a render() function, need a point where the "prepare" step can be performed, outside the main renderpass. Also enables proper m_useDepthBuffer handling for the RHI code path. Task-number: QTBUG-82797 Task-number: QTBUG-82793 Change-Id: I525228e53acefad9f2e6a33d446260a1521d8ae1 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* Remove hard-coded notes for 'Corresponding handler' for QML signalsTopi Reinio2020-03-1021-234/+0
| | | | | | | | QDoc will generate these notes automatically. Task-number: QTBUG-37355 Change-Id: I8ed058ecbbcc630ad0351f6ce167c3fa61936f6f Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Add missing QPainterPath includesUlf Hermann2020-03-091-0/+1
| | | | | | | | | Apparently QPainterPath was transitively included from some other header before. With current qtbase, it is not anymore and the old code fails to compile. Change-Id: I2de3cd72e3cd33a4537f8156298fc757182907fa Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Add missing QPainterPath includesMitch Curtis2020-03-091-0/+1
| | | | | | | | | | | | .../qsgadaptationlayer_p.h(500): error C2079: 'QSGDistanceFieldGlyphCache::GlyphData::path' uses undefined class 'QPainterPath' .../splineeditor.cpp(168): error C2079: 'path' uses undefined class 'QPainterPath' Change-Id: I5f905aa31b24f71c65889047065ab43725fb6733 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Avoid using deprecated QTabletEvent::device()Simon Hausmann2020-03-071-1/+1
| | | | | | | That member was removed in qtbase dev. Change-Id: Ia2e69ee53e154fdb9b8b4c707ac5a463011cf0c1 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Doc: clarify the fontSizeMode property in terms of Rich and Styled textAndy Shaw2020-03-061-0/+6
| | | | | | Fixes: QTBUG-56650 Change-Id: I7b750031f3af368de7f7cebe64a5d1ce77f68408 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2020-03-033-7/+22
|\ | | | | | | | | | | | | | | Conflicts: src/qmlmodels/qqmltableinstancemodel.cpp src/qmlmodels/qqmltableinstancemodel_p.h Change-Id: I89339b1cb41ba27fe30c79530859a1c2bfbecc69
| * QQuickItem: prevent endless loop in focus tab chainWang Chuan2020-03-031-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Since the commit a18ab2a3822e0d, we promote the [startItem] in focus tab chain when it is invisible to prevent endless loop. However the problem still happen if the [startItem] is equal to [firstFromItem] Fixes it by compare the [current] item with the original start item Fixes: QTBUG-81510 Change-Id: Iae0207f39e2b8c4fc6ed0cf36f0a855668accfba Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * QQuickTableView: Immediately delete delegates when possibleUlf Hermann2020-02-281-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | In the dtor we don't need to care about any side effects a direct delete may have. Rather, any deleteLater() may not take effect anymore as the event loop may be gone already. Task-number: QTBUG-82000 Change-Id: I97935dc47fbbfd0c050e80c333c36a05f685c45d Reviewed-by: Joni Poikelin <joni.poikelin@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| * Fix texture coords for the compressed texture atlasMichael Brasser2020-02-211-5/+5
| | | | | | | | | | | | | | | | The texture coords should be based on the actual image size, and not on the padded size. Change-Id: I262b7ca93e26c48324ec892a988f2fc62132175e Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* | Fix building qtdeclarative without QMovie supportJean-Michaël Celerier2020-03-021-1/+1
| | | | | | | | | | | | Change-Id: Id8e8b04e722bd9fc84b6b78530f75cf8d6d96da7 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | doc: fix typo in signal nameRolf Eike Beer2020-03-021-1/+1
| | | | | | | | | | Change-Id: I19b3a78ddbde481af8847a3d340e62d56240de29 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | Deprecate non-const version of saveToFile()Jan Arve Sæther2020-02-282-1/+6
| | | | | | | | | | | | | | It will be removed in Qt 6 Change-Id: I7d8853ce3008bb2c594caa5a23e2964158717fe4 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Properly deprecate QQuickText::doLayout() and get rid of it for Qt6Jan Arve Sæther2020-02-282-1/+10
| | | | | | | | | | | | | | It was only deprecated through its documentation. Change-Id: I0b7bdeec4ed965c3df627a03ab0e539c4e9c2018 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Revision properties and methods added in 5.15Ulf Hermann2020-02-273-5/+5
| | | | | | | | | | Change-Id: I00e3f9535e819d9d0d547c9d3cf50be469cf9339 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* | Propagate the LanguageChange events from the QQuickWindow to the itemsAndy Shaw2020-02-252-0/+8
| | | | | | | | | | | | | | Fixes: QTBUG-78141 Task-number: QTBUG-82020 Change-Id: Id47f8efe77cd3f6bfd330c8759059e19de5a86d2 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Export QQuickRootItem to QMLUlf Hermann2020-02-251-1/+1
| | | | | | | | | | | | | | It was exported in 5.14, so we should probably still do so. Change-Id: Id44783c72fff50aee63d7c5a72f12ff9ca895a6b Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* | QQuickColorSpaceValueType: Version importFabian Kosmale2020-02-251-0/+1
| | | | | | | | | | Change-Id: I9396157f4b85ac075343426b22fff98b436e80d6 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | Revert "Replace call to deprecated QNetworkReply::error method"Timur Pocheptsov2020-02-243-3/+3
| | | | | | | | | | | | | | | | | | This reverts commit e5a4ba4a5573ace08def218b985dde83de0805fb. Reason for revert: it was decided to re-name a signal instead, like it's done in QProcess. Change-Id: I0f393c482d8be506430258d7afd4a0056611831f Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | Warn when requesting unknown RHI backendJohan Klokkhammer Helsing2020-02-241-0/+2
| | | | | | | | | | | | | | When QSG_RHI_BACKEND is set to something we don't recognize. Change-Id: Ifa18cf38bc110e3a96b94fa89abac5bdfd70ba8a Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* | Doc: Fix QQuickTableView snippetUlf Hermann2020-02-244-43/+120
| | | | | | | | | | | | | | | | Use static registration, provide a .pro file, and make it load and show the right file. Change-Id: I949831a399ce00cd8b3d012d8bd4e95a1efcdeb5 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Revert "QQuickItemView: do not set parent to nullptr upon destruction"v5.15.0-beta1Ulf Hermann2020-02-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 5445fcac36d7122d533a2bdf0fcfe6206b7f3ff4. The original commit avoids a warning generated for a dubious use case and breaks controls2 in a non-trivial way as a side effect. We should rather live with the warning. Task-number: QTBUG-82368 Change-Id: I6197bb63036cb25ec3e88f549667519b8f3ff13a Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* | Make qtdeclarative compile with -no-feature-tableteventShawn Rutledge2020-02-204-0/+10
| | | | | | | | | | | | | | | | Amends 8e822e981d91e688799c8670f11dfdf6aaf9e0d1. Fixes: QTBUG-82168 Change-Id: I8d849747a3394ca05d62b674a725d45165f081eb Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2020-02-202-1/+2
|\| | | | | | | Change-Id: I024445b3401a57040d7d67780ea32d2f8b02f41a
| * Doc: list Grid's alignment properties as "since 5.1"Mitch Curtis2020-02-181-0/+1
| | | | | | | | | | | | | | | | | | They were added in 9b801abc3a6967392e27daa35ba7cd802b7164e4 (or 233e83b20512a5e3748542f1c279a5c7ec6310ad, depending on what you ask Gerrit or Git). Change-Id: Ia1c064c04bc3e1a23e6b8caf7d479625368f7fe6 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| * Fix inverted logicMichael Brasser2020-02-171-1/+1
| | | | | | | | | | | | | | A texture has an alpha channel if it is *not* opaque. Change-Id: Ie7fdeb6e622dbb01e19b42877b27f0e0fe8959e2 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* | Rearrange QQuickPixmapKey operator==Shawn Rutledge2020-02-151-2/+5
| | | | | | | | | | | | | | ...to do the comparisons in the same order as the variables are stored. Change-Id: I5faa1daa84757b94993c3135ddfc9a3fd6c10ea6 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | MultiPointTouchArea: update the TouchPoint.x and y properties togetherShawn Rutledge2020-02-152-19/+13
| | | | | | | | | | | | | | | | | | Letting them change sequentially is inconvenient when they are used to drive some sort of smooth stroke (drawing or motion). Fixes: QTBUG-81944 Change-Id: I46c5948dbec927682244daf00a0df3453a0d92a6 Reviewed-by: Michael Brasser <michael.brasser@live.com>
* | Optimize QQuickPixmapCache readImage() slightlyShawn Rutledge2020-02-141-2/+3
| | | | | | | | | | | | | | | | Calling QImageReader::size() twice means calling the image format plugin twice, so it's best to avoid that. Change-Id: I4741e87c7c95252904d0dd9f484a57d953670559 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | QQuickItemView: do not set parent to nullptr upon destructionRichard Moe Gustavsen2020-02-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Setting a delegate item's parent to nullptr will make any bindings to the parent inside the item invalid, and warnings will as such be printed (first seen after 8c72e634b3b0eacbfdee883bfc34994d3c19ed77). I assume the reason for setting the (visual) parent to nullptr is to immediately hide it. So to avoid trigger any bindings, we instead just cull if from the scene graph. It's also dubious why a delegate should have bindings to its parent in the first place, since what ends up being the parent is an implementation detail, and probably not be the item the user expects it to be. Fixes: QTBUG-81976 Change-Id: I7bd8ab91461504b6e79d4aa2ab832be087245c3e Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2020-02-136-46/+70
|\| | | | | | | | | | | | | Conflicts: src/qml/jsruntime/qv4engine.cpp Change-Id: I61f41672e2dfe7e542ca30fed5f173d0a9ee3412
| * Add a null check to QQuickWindowPrivate::rendererAnton Kreuzkamp2020-02-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Afaik there currently is no case in a regular execution where the renderer would actually be null, but for the sake of correctness add a null check as this seems to be the only code location that actually assumes the renderer to be non-null. Additionally, in order to en-/disable custom render modes at runtime, GammaRay actually needs to recreate the renderer and therefore resets the renderer to null in order for QQuickWindowPrivate::syncSceneGraph to recreate it. Thus we need a null check to make sure we don't crash in the short time frame where the renderer is null. Change-Id: Ief5c405f3bc8725d55e22cd33f2164830764e33d Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * QQuickLoader: store statusFabian Kosmale2020-02-122-39/+61
| | | | | | | | | | | | | | | | | | | | This allows us to emit the change signal only when the status has actually changed. Due to alignment restrictions, this does not even change the size of the class. Fixes: QTBUG-82002 Change-Id: I2192bf80e72b92108046780811c3acdab39af518 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| * Mention styleName in the Font QML type documentationAndy Shaw2020-02-111-0/+1
| | | | | | | | | | Change-Id: I1f2ec7b4bb96955f57b3afd4a295f04dbb70987f Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| * Android: Don't include QtQuickParticles in the dependenciesAndy Shaw2020-02-101-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | Before qmlimportscanner it was necessary to mark QtQuickParticles as a dependency, but now it is possible to have qmlimportscanner and androiddeployqt handle all of this for us. So we no longer need to make it an explicit dependency. Task-number: QTBUG-38296 Change-Id: I6e0baefdcf002746af26d8c95fa1f318770cc658 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
| * Fix QAccessibleQuickWindow::focusChild() to return focused descendantPeter Varga2020-02-061-2/+6
| | | | | | | | | | | | | | | | | | | | Same as the focusChild fix for qtbase: a132e02540 Fix QAccessibleWidget::focusChild() to return focused descendant Task-number: QTBUG-78284 Change-Id: Ibc3e3287790ebc879513a5b1a739e3a919e1f038 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | Provide a macro for qmlRegisterTypeNotAvailableUlf Hermann2020-02-122-7/+12
| | | | | | | | | | | | | | | | | | | | | | That is, register QQmlTypeNotAvailable as foreign type under the name given as parameter. Also, statically register QQuickAnimatedImage as unavailable in case of !quick_animatedimage and register it for the right version. Task-number: QTBUG-68796 Change-Id: I2ea292d2aeda66d8ce43b3bccbd3d21663330bd6 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Deliver QTabletEvents to pointer handlersv5.15.0-alpha1Shawn Rutledge2020-02-117-20/+274
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At this time, there are not yet any specialized handlers to do anything specifically with tablet events; but we demonstrate how to use HoverHandler to detect the type of stylus in use, and how to use PointHandler to draw on a Canvas. Unfortunately, events of types TabletEnterProximity and TabletLeaveProximity are not delivered to the window, only to QGuiApplication. So HoverHandler can detect when the stylus is moved out of its parent Item (as long as it's still hovering over the tablet surface), but cannot detect when the stylus leaves the tablet completely. In Qt 5 that would require a custom application subclass (see qtbase/examples/widgets/widgets/tablet/tabletapplication.cpp). Fixes: QTBUG-79660 Change-Id: I81fdb99082dc41c0455085e6b6d3952402bf8742 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | Use the extended QQmlListProperty interface in a few placesUlf Hermann2020-02-077-12/+94
| | | | | | | | | | | | | | Task-number: QTBUG-79263 Change-Id: If518f644b5b9eddbacfb1cb16fbb557127ffcfb2 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Privately export QQuickFlickablePrivate and QQuickTableViewPrivateMitch Curtis2020-02-063-3/+4
| | | | | | | | | | | | | | | | | | We need this to implement header views (for TableView) in qtquickcontrols2. Task-number: QTPM-1300 Change-Id: I03068828cdf6dd79ec6a91c75f68eaf7c224d4a2 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | rhi: Handle beginFrame() failure correctly in threaded render loopLaszlo Agocs2020-02-061-6/+10
| | | | | | | | | | | | | | | | Also add some comments to improve maintainability. Task-number: QTBUG-81740 Change-Id: I4be90768f7a8506b1fb493885062b98be9f4f58a Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | Add required property documentationFabian Kosmale2020-02-062-0/+101
| | | | | | | | | | Change-Id: I9e2c44ddcbb6c7e3a92b2bd7d2492ece0cd0e62d Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2020-02-064-27/+172
|\| | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/qml/types/qqmlbind.cpp src/quick/items/qquicklistview.cpp tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp Change-Id: Id6805c13256ad13d5651011e5dd09bba0ec02987
| * Doc: Remove outdated noteJoni Poikelin2020-02-031-4/+0
| | | | | | | | | | | | | | The behavior described in the note does not apply to Qt 5. Change-Id: Ia4d45ca35d095d6cdc193f276bd52c7ad403b82f Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| * Fix some ListView bugs related to snapping when it had a headerJan Arve Sæther2020-01-301-15/+153
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Most bugs were related to the PullBackHeader header positining mode, for instance the old code did not take into consideration that for the PullBackHeader it was sometimes not sufficient to scroll the view. The header also had to be scrolled independently from the view: We achieve this by hooking on to the same timeline that is used for scrolling the view. (This way, both animations are synchronized, and they start and end at the same time). Change-Id: I75708c0fd8d4741032c04ad9ee144d7a49cf3359 Fixes: QTBUG-76362 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * Get rid of global gadgetPtr in QQmlValueTypeUlf Hermann2020-01-291-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | We should not keep user-created objects in global data structures. This is inherently thread-unsafe and crashes when the user passes static data and later unloads the same. Instead we keep the cached gadgetPtr wrapper objects in the engine now. Fixes: QTBUG-79553 Change-Id: I24ac3e84b572831d1d70b61b8a6001338579e284 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| * QQuickFlickable: fix division by zeroMitch Curtis2020-01-291-4/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The issue could be seen when enabling exceptions and running the following QML code: Flickable { id: flickable anchors.fill: parent contentWidth: 1000 contentHeight: 1000 Text { text: flickable.visibleArea.xPosition } } Change-Id: I615f9f9dc84903fb3a902f416a55e3ce3fece64c Fixes: QTBUG-81098 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | QmlDebug: add new debugtranslationserviceTim Jenssen2020-02-051-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | Users were asking for having the possibility to see where the translated text will not fit in the reserved/available space. This is more a preparation patch to get the right connectors to change the visualization of findings or maybe log this to a file. Task-number: QDS-1463 Change-Id: Ic0a7a930141d6eeb79964e51c0a165c69888cf5d Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | QQmlInstanceModel: refactor recycling signals to base classRichard Moe Gustavsen2020-02-051-13/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that QQmlDelegateModel has an API that handles reusing delegate items (*), we should also move the related signals inside it to be consistent. This will also remove the need to cast the model type in the views before connecting. This patch will also remove warnings that stems from QQuickListView trying to connect to the reuse signals when the model is not a QQmlDelegateModel. *: E.g: virtual ReleaseFlags release(QObject *object, ReusableFlag reusableFlag = NotReusable) = 0; Fixes: QTBUG-81257 Change-Id: Ia8a8f0d68e6ef7edc6c45b414121aaa77632bcd3 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Synthetically reference type registration functionsUlf Hermann2020-02-041-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add unused volatile pointers to the type registration functions in each import plugin. We need to do this in order to prevent the linker from optimizing the registration away. There are two ways for this to happen: When linking statically, the linker will examine the referenced symbols on a per-object base and leave out all unreferenced objects. When linking dynamically, the linker may do the same on a per-library base and drop any unreferenced libraries from the dependencies. Forcing a reference to the type registration function prevents both. The volatile technique allows us to remove the previous qCDebug() hack. Having an unused volatile auto variable should only result in a single memory read as runtime overhead. The qCDebug() technique would generate a read and a block of mostly dead code (as no one would ever use that logging category). Fixes: QTBUG-81622 Change-Id: I255667276dfd355b19baa17b1aad3db406bf1954 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>