aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquickstates
Commit message (Collapse)AuthorAgeFilesLines
* Remove the qmake project filesFabian Kosmale2021-01-151-11/+0
| | | | | | | | | Remove all qmake project files, except for examples which are used to test that qmake continues to work. Change-Id: Ic4abb72dc2dcd75df7a797c56056b6b3c5fe62ac Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Do not revert properties of deleted objectsAlexey Edelev2021-01-142-0/+116
| | | | | | | | | | If state contains revert action of properties of deleted objects, we should avoid adding them to apply list Fixes: QTBUG-85106 Pick-to: 5.15 Change-Id: Iff57eb9958a054476096f6d951ab7390277a2b39 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* CMake: Regenerate projects to use new qt_internal_ APIAlexandru Croitor2020-10-061-3/+3
| | | | | | | | Modify special case locations to use the new API as well. Task-number: QTBUG-86815 Change-Id: I3b964e3baf0cc7040830156dac30358ea1152801 Reviewed-by: Cristian Adam <cristian.adam@qt.io>
* Do not resolve URLs when assigning them to a propertyUlf Hermann2020-06-221-1/+1
| | | | | | | | | | | | | | | We don't know in advance if a URL is part of the source code and should be relative to the current element, or if it is part of the application data and should not be touched. [ChangeLog][QtQml][Important Behavior Changes] URLs are not resolved or intercepted anymore when assigning them to a "url" property. Instead they are resolved and possibly intercepted when used to access an actual resource. Fixes: QTBUG-76879 Change-Id: Iaa2385aff2c13aa71a12e57385d9afb5dc60a073 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* CMake: Update Apple platform defines after rename in qtbaseTor Arne Vestbø2020-03-171-2/+2
| | | | | Change-Id: Ia0a075e3199eab735f9b289873beeb8730ebc47e Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Regenerate qtdeclarativeAlexandru Croitor2020-02-121-5/+2
| | | | | | | Change-Id: I48d7fd306f3d1b161a8e73029282ee591b1ef612 Reviewed-by: Leander Beernaert <leander.beernaert@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Liang Qi <liang.qi@qt.io>
* Regenerate all projects with new CMake API versionAlexandru Croitor2019-11-151-3/+3
| | | | | | Change-Id: Ie0db35f674137c229eaf049616f38f8e818f7092 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Regenerate testsAlexandru Croitor2019-11-141-11/+2
| | | | | | Change-Id: I67a6c8f1659e7b471a4fcb92a2699292cf4eea81 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Merge remote-tracking branch 'origin/dev' into wip/cmakeAlexandru Croitor2019-10-142-0/+89
|\ | | | | | | | | | | | | Removed dependencies.yaml because we don't use it yet in wip/cmake. Fixed conflict in qmlcachegen.cpp. Change-Id: Ie1060c737bee1daa85779903598e5b6d5020d922
| * ParentChange: Restore old position correctlyFabian Kosmale2019-10-112-0/+89
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ParentChange does floating point math in doChange to calculate the correct position. Unfortunately, while doing the conversion, we accumulate rounding errors in the presence of rotations. Those can lead to visual glitches, as observed in QTBUG-68176. This patch avoids the issue by storing the old values and resetting to them in restore. Fixes: QTBUG-68176 Change-Id: I6ebe1ccbc601838aa664cdc723e0cd58c95e785a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Add QtDeclarative Test CoverageLeander Beernaert2019-08-141-0/+51
|/ | | | | | | | | | | | | | | | | | | | | | All tests compile and run on a developer build. These tests are failing: tst_qqmlsqldatabase Fails due to missing sql driver tst_qqmlsqldatabase Fails in wip/qt6 tst_ququicklayouts Fails in wip/qt6 tst_flickableinterop Fails in wip/qt6 tst_qquickpinchandler Fails in wip/qt6 tst_qquickflickable Fails in wip/qt6 tst_qquickgridview Fails in wip/qt6 tst_qquickimage Fails due to missing jpeg plugin tst_qquicklistview Fails in wip/qt6 tst_qquicktext Fails in wip/qt6 tst_qquickcanvasitem Fails in wip/qt6 tst_scenegraph Fails due to missing jpeg plugin tst_TestFiltering Fails in wip/qt6 Change-Id: I4b9d69c118e23c095cb72ad5a67653fc30943bb1 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* use boolean for when propertyFabian Kosmale2019-07-022-0/+15
| | | | | | | | | | | | QQuickState used to store "when" as a QQmlBinding to reduce state oscillation. It is unclear whether this is still an issue, but it breaks if a user sets "when" to a primitive value like "true" or "1". Fixes: QTBUG-76838 Change-Id: If400e5b1283687838ed252be2dfa52067f44564e Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Add test for the duplicate state name warningAlbert Astals Cid2018-10-252-0/+25
| | | | | Change-Id: Id5524d7553ef37fbbc84157a4a4c7251e477f215 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* use nullptr consistently (clang-tidy)Shawn Rutledge2018-02-261-110/+110
| | | | | | | | | | | | | From now on we prefer nullptr instead of 0 to clarify cases where we are assigning or testing a pointer rather than a numeric zero. Also, replaced cases where 0 was passed as Qt::KeyboardModifiers with Qt::NoModifier (clang-tidy replaced them with nullptr, which waas wrong, so it was just as well to make the tests more readable rather than to revert those lines). Change-Id: I4735d35e4d9f42db5216862ce091429eadc6e65d Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* QML: Remove internal field padding from QQuickAnchorPrivate.Erik Verbruggen2016-05-101-2/+2
| | | | | | | | | | | | | | | | | Don't store QQuickAnchorLine, but store both fields separately in QQuickAnchorPrivate. This prevents padding of QQuickAnchorLine, saving 48 bytes on x86_64 (or any platform where structs are 8-byte aligned). On x86_64, this also removes ~180 instructions for each QQuickAnchor creation/removal, and speeds up the constructor by 25%. While in the neighborhood, do a drive-by change and merge QQuickAnchorLine::AnchorLine and QQuickAnchors::Anchor by removing the former. Change-Id: I50ab6252b1903f5f1a075174e6185c3048a8f8ec Reviewed-by: Robin Burchell <robin.burchell@viroteck.net> Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-04-081-0/+0
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change also fixes the build of two benchmarks, tst_affectors and tst_emission. Conflicts: src/plugins/qmltooling/qmldbg_native/qmldbg_native.pro src/qml/qml/ftw/qhashfield_p.h tests/benchmarks/particles/affectors/tst_affectors.cpp tests/benchmarks/particles/emission/tst_emission.cpp tests/benchmarks/qml/pointers/pointers.pro tests/benchmarks/qml/pointers/tst_pointers.cpp tests/benchmarks/qml/qmltime/qmltime.pro tests/benchmarks/qml/qquickwindow/qquickwindow.pro Change-Id: I595309d1e183c18371cb9b07af6e4681059de3b2
| * Purge sRGB chunks from PNG in tests.Edward Welbourne2016-03-291-0/+0
| | | | | | | | | | | | | | | | | | | | | | | | Subjects each *.png file that matched grep -law "sRGB" to: pngcrush -ow -brute -rem allb -reduce Various tools grumble about sRGB tables in PNG images; and our handling of them doesn't pay attention to these, so purging them makes the images smaller with no loss to the images. Change-Id: I9e4dc3aec97cd32bc8ac216fadeaf7669c49647c Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* | Updated license headersJani Heikkinen2016-01-201-17/+12
| | | | | | | | | | | | | | | | | | | | | | | | From Qt 5.7 -> tools & applications are lisenced under GPL v3 with some exceptions, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new GPL-EXCEPT header instead of LGPL21 one (in those files which will be under GPL 3 with exceptions) Change-Id: I04760a0801837cfc516d1c7c02d4f503f6bb70b6 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | Remove CONFIG += parallel_test.Friedemann Kleint2015-09-051-1/+0
| | | | | | | | | | | | | | The keyword no longer has a meaning for the new CI. Change-Id: I699f2881e291cce02a6a608a8710638886e38daa Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | Remove QT_DISABLE_DEPRECATED_BEFORE=0 from tests not using deprecated API.Friedemann Kleint2015-09-031-1/+0
|/ | | | | Change-Id: I691b8ddff60b5f16f06d32b379c76e87f44f84a9 Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* tests/quick: Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b).Friedemann Kleint2015-07-271-2/+2
| | | | | | | | | | | | - Replace Q[TRY]_VERIFY(pointer == 0) by Q[TRY]_VERIFY(!pointer). - Replace Q[TRY]_VERIFY(smartPointer == 0) by Q[TRY]_VERIFY(smartPointer.isNull()). - Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b) and add casts where necessary. The values will then be logged should a test fail. Change-Id: Ib9f4c2486af23c47990be4b9e004b965de226dcc Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Make bindings refcountedLars Knoll2015-06-101-4/+4
| | | | | | | | | | | Refcounting our bindings greatly simplifies our memory management of the objects and ensures we safely clean them all up. In addition, it allows us to remove the m_mePtr and weak reference handling from QQmlAbstractBinding as we can safely handle this through the same mechanism. Change-Id: If23ebc8be276096146952b0008b62018f5d57faf Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Fixed a memory-leak when changing property bindings in states.Robert Griebl2015-03-252-0/+41
| | | | | | | | | Bindings that were still stored in the revert-list when the state was destructed were not deleted before. This could lead to considerable memory leaks in big applications. Change-Id: I73250f7d03a42c25ca729c18082125fd8f3c8989 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-121-7/+7
| | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Change-Id: I61120571787870c0ed17066afb31779b1e6e30e9 Reviewed-by: Iikka Eklund <iikka.eklund@theqtcompany.com>
* Update license headers and add new licensesJani Heikkinen2014-08-251-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 & LICENSE.GPLv2 - Removed LICENSE.GPL Change-Id: I84a565e2e0caa3b76bf291a7d188a57a4b00e1b0 Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
* Fix translations in states causing failing assertionsSimon Hausmann2014-04-282-0/+32
| | | | | | | | | | | | | This is a smaller fix suitable for the release branch, merely adding support for translations to the bytearray compilation step for states and ensuring a consistent error message when qsTr is used in list models. The proper fix will be done in dev that eliminates the entire intermediate QByteArray storage for custom compilers. Task-number: QTBUG-38492 Change-Id: If5171f16eb742c718e48b8bbcb265b0c241cd5e7 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Fix rounding behavior of Qml when assigning doubles to integer propertiesSimon Hausmann2013-11-051-1/+1
| | | | | | | | | | | | The engine used to round, but that is inconsistent with ECMAScript's way of converting doubles to integers by truncation. With this patch we can also enable the propagation of integer type information into the IR, but we have to be careful not to utilize it when writing properties. Change-Id: I04af4879ba5131349eca2eeff2b27f4598f5267b Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Fix compilation with built-in v4vm JS engineSimon Hausmann2013-04-151-1/+1
| | | | | Change-Id: Ieda9267e296acf6392a5461f4cfb9233a7a409a0 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Autotests w CONFIG+=parallel_test don't depend on activation or focusShawn Rutledge2013-03-041-2/+1
| | | | | | | | | | If the test does requestActivate() or relies on isFocusWindow(), the test cannot be parallel_test. Also, a lot of the tests don't actually need the window to be active, only exposed; and waiting only for exposed is likely to make them more stable. Change-Id: I0845b9b12ddf7f0c8906d9738a3e26d46ab98820 Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-101-1/+1
| | | | | | Change-Id: I6c3bd7bebe3d62d1cfd0fa6334544c9db8398c76 Reviewed-by: Akseli Salovaara <akseli.salovaara@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* All QWindow properties that have "window" in them have been renamed.Shawn Rutledge2012-11-081-1/+1
| | | | | | | Depends on patch Ie4424ec15fbdef6b29b137f90a2ae33f173edd21 in qtbase. Change-Id: I9614cc2c7ed119c663b3f6f99267483e291e529c Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-231-24/+24
| | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: Ie7f5d49ed8235d7a7845ab68f99ad1c220e64d5c Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Make QQmlScriptString opaque.Michael Brasser2012-08-031-7/+8
| | | | | | | | Allow for future optimization by encapsulating the raw script data. Change-Id: I1863103e8e6d74ede60593cabb240e16f2ae657e Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
* Set the Qt API level to compatibility mode in all tests.Thiago Macieira2012-08-011-0/+1
| | | | | | | | | | Qt 5.0 beta requires changing the default to the 5.0 API, disabling the deprecated code. However, tests should test (and often do) the compatibility API too, so turn it back on. Task-number: QTBUG-25053 Change-Id: I6988c2360e9d88916311374a0c910bfc5b607439 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* QtDeclarative: Remove usage of deprecated qWaitForWindowShown().Friedemann Kleint2012-07-191-1/+1
| | | | | | | | | | | - Replace by qWaitForWindowExposed() or qWaitForWindowActive() where applicable. - Use QVERIFY to verify success. - Stabilize some tests by checking for 'active', add missing call to show(). Change-Id: I6cae063e44a3839760ed9f61dacb26cd1717118d Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* More robust tracking of signal handler expression ownership.Michael Brasser2012-05-012-0/+45
| | | | | | | Reference count the expressions, and improve testing. Change-Id: I810509eae1c7608b367e9ff5f7891a294667a692 Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Adapt to Qt5 meta-object changesKent Hansen2012-03-131-1/+1
| | | | | | | | | | | | | | | | | | | QMetaMethod::signature() has been renamed to methodSignature(), and it now returns a QByteArray. Also, the new function QMetaMethod::isValid() should be used to determine whether a method is valid, instead of relying on signature() returning a 0 pointer. Where it makes sense, the existing code that was using signature() and parameterTypes() has been changed to use the new API QMetaMethod::name(), parameterCount(), and parameterType(int). Also, in the new meta-object revision (7), the QMetaObject stringdata member is now of type QByteArrayData*. QFastMetaBuilder will be ported to generate the new format, but for now it's sufficient to reinterpret_cast the stringdata assignment to keep it compiling. Change-Id: Ie340ef17bcebc3afa4aae6450dfe2d06e4d881a4 Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
* Remove unneeded dependencies to QtWidgets and QtOpenGLLars Knoll2012-03-121-1/+1
| | | | | Change-Id: I43bb54524f5786a838073df8812107dda7b0d56e Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Changed quick tests to work from install directoryKurt Korbatits2012-03-071-3/+1
| | | | | | | | | - Changed tests to use TESTDATA - added check for cross_compile option to skip when sources not available Change-Id: I1f382794ff982bbc07fc20438a4e4a8c8b8d565f Reviewed-by: Michael Brasser <michael.brasser@nokia.com> Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* Rename QDeclarative symbols to QQuick and QQmlMatthew Vogt2012-02-2457-0/+2712
Symbols beginning with QDeclarative are already exported by the quick1 module. Users can apply the bin/rename-qtdeclarative-symbols.sh script to modify client code using the previous names of the renamed symbols. Task-number: QTBUG-23737 Change-Id: Ifaa482663767634931e8711a8e9bf6e404859e66 Reviewed-by: Martin Jones <martin.jones@nokia.com>