aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto
Commit message (Collapse)AuthorAgeFilesLines
* Fix crashes when incubating objects asynchronously with initial propertiesSimon Hausmann2016-05-183-0/+75
| | | | | | | | | | | | This is a regression from commit 94e337fa95425d259e81b4d21f4d0853108553bd where we accidentally ended up not having a calling QML context set anymore when initializing the properties on newly incubated objects as provided by the caller. The QML context is necessary as for example when we set a URL property, the URL can be relative and it will be resolved to the base url of the context when written, such as in in QQmlPropertyPrivate::write. Change-Id: I1d896381fc92f653a7d76f4d82174bca48828f5e Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* blacklist the qmlextensionplugins example for testingOswald Buddenhagen2016-05-131-0/+1
| | | | | | | | | it requires a special import search path. it would be possible to hack this into the test launcher, but that doesn't seem worth it (there are other plugin examples already). Change-Id: I147b802c690933803cb8f9cf35210618957a6998 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* remove blacklisting of tiger and fonts examplesOswald Buddenhagen2016-05-131-2/+0
| | | | | | | the associated bugs are marked as fixed for a long time. Change-Id: If8c8710bdf4b7b1962c9749b701cbd335d938fdb Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* adjust example naming convention test to "new" structureOswald Buddenhagen2016-05-131-5/+4
| | | | | Change-Id: I42ec26bd3c2ffa32ae8c5323f7c0a0343d12ce2f Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* make use of COPIESOswald Buddenhagen2016-05-131-6/+3
| | | | | Change-Id: I479c9523a89be1d64364e8205daa5860e16882cc Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Revert "Temporarily blacklist importsPath change on Windows"Simon Hausmann2016-05-021-2/+0
| | | | | | | | | | This reverts commit 91a96d1de9c3d3f8d598ee8fbcf2d1868635ec46. I've been told that the race condition in the networking stack has been fixed on Windows. Change-Id: Ica038229e8e164a199332288ed140ca6a1d3104c Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* AnimatedImage: Fix value of sourceSize propertyTobias Koenig2016-05-021-0/+23
| | | | | | | | | | Cache the source size of the internal QMovie object during the change of the 'source' property to ensure that always a valid source size is returned without emitting more sourceSizeChanged() signals than necessary. Change-Id: I637b80efb133197b7345b09fcf8a7bb80c5643c9 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* Fix crash when trying to call a property of the scope or context objectSimon Hausmann2016-05-012-0/+25
| | | | | | | | | | For calls on properties of the scope or context object the thisObject parameter in the callData is a reference to the QmlContext, not a real object - therefore the toString conversion fails. Task-number: QTBUG-52340 Change-Id: I08d01cc5c05920c2fac46ddd40fa41e630bcade3 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* QQuickDragAttached: fix updating of "active" propertyAlberto Mardegan2016-04-261-0/+46
| | | | | | | | | The d->active member variable should be changed regardless of the value of Drag.dragType. Task-number: QTBUG-52540 Change-Id: I7fa39ccf11b1200e9c2f6fe57cba58657b6cff74 Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
* Also match QJSValue conversion types in MatchScore.Michael Bruning2016-04-202-0/+14
| | | | | | | | | | | | | | | This had the effect that overloaded methods were always mapped to the wrong slot. [ChangeLog][QtQml][Important Behavior Changes] When matching the method signature of a invokable method to the slot in the metaobject, the matching function now assigns the best match to a QJSValue if the parameter actually is a QJSValue. This corrects the previous behavior, where QJSValue and int were given the same match score even though QJSValue would have been the best match. Task-number: QTBUG-51746 Change-Id: I906e7b006ee5af92ea760ed1625e5047aef123bf Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Revert "Fixed MouseArea threshold with preventStealing"Michal Klocek2016-04-201-11/+0
| | | | | | | | | | | This reverts commit e1400b5b4d8311769ad3b9f631479ee2b0271197, which breaks qtlocation unit tests for drag support. It is no longer possible to drag markers in mapviewer. Task-number: QTBUG-52534 Change-Id: If713a8e45f64ea898f38fe3e39561ebc266403b2 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com> Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* Fixed MouseArea threshold with preventStealingFilippo Cucchetto2016-04-191-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | When preventStealing is true both keepMouseGrab() and d->stealMouse are true. This in turn enable the dragging immediately since the condition "keepMouseGrab() && d->stealMouse && !d->drag->active()" is true. Conversely when preventStealing is false the dragging is enabled in the next move event since keepMouseGrab() and d->stealMouse are set true inside the last "if" "!keepMouseGrab() && ...check threshold..". This patch adds a new boolean flag for storing if we detected a drag motion (so we exceeded the threshold) and enable the dragging iff this flag is true. With this change: - if preventStealing is true (and so keepMouseGrab() and d->stealMouse) the additional d->overThresHold prevent the start of dragging. At the same time the last if (!keepMouseGrab()) cannot be executed since keepMouseGrab is true and we still check for the threshold being exceeded. - if preventStealing is false, we still check for exceeding the threshold and if this happen we enter in the last "if" since !keepMousegrab() && d->overThreshold is true taking the mouseGrab as without this patch Task-number: QTBUG-52534 Change-Id: I2b14d3048b6f8223c90ce5e2fd26e7ca706cb56a Reviewed-by: Michael Brasser <michael.brasser@live.com> Reviewed-by: Robin Burchell <robin.burchell@viroteck.net> Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
* activate QtQuick designer support testsTim Jenssen2016-04-191-0/+1
| | | | | Change-Id: I5540eda05e6e4d7ab01c85b1da32e8677a9c332d Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Occasionally trim the type cacheUlf Hermann2016-04-192-0/+38
| | | | | | | | | | | | As loaded components are kept in a cache, they are never removed by the garbage collector. So, if you periodically create new components, they leak. This change adds a floating threshold for the number of components. When that threshold is surpassed trimCache() is called and unneeded components are removed. Task-number: QTBUG-42055 Change-Id: I30e3e4ee287f6d34376713668009c67614a50e0c Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* tst_qquickanimatedimage::mirror_notRunning(): fix initializer.Edward Welbourne2016-04-151-5/+1
| | | | | | | | | | Initializing paused to isPlaying() then checking it subsequently agrees with isPaused() is an obvious copy-and-paste bug in the test, which was meant to check runtime state wasn't changed by a snapshot. Task-number: QTBUG-36717 Change-Id: I7a206b07071b862dbe4c0331af6bc32157a415b2 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Fix memory corruption when calling Array.unshift()Simon Hausmann2016-04-141-0/+15
| | | | | | | | | | The dequeue offset won't wrap around when n > offset. [ChangeLog][QtQml] Fix crash with Array.unshift() Task-number: QTBUG-52065 Change-Id: I5e8b89ec964cd6397100442a5239254bca989a3f Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* Instantiate static Qml plugins declaring QQmlExtensionInterface onlySebastian Lösch2016-04-1121-19/+144
| | | | | | | | | | When instantiating static plugins no check is done whether the QQmlExtensionInterface is declared. Therefore all user plugins are instantiated in the Qml thread, which may cause problems. Task-number: QTBUG-52012 Change-Id: Ia91ec5ec7b2a9721bd11e3648cdc161855b4454e Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* QQuickText,QQuickTextInput: Fully qualify enumerations in changed() signals.Friedemann Kleint2016-04-072-2/+2
| | | | | | | | | | | Similar to change 85b64e701b2eaecdd30a7e0e079e2c80dd846fec. Fixes test warnings: QWARN : tst_qquicktextinput::mouseSelectionMode_accessors() QSignalSpy: Unable to handle parameter 'mode' of type 'SelectionMode' of method 'mouseSelectionModeChanged', use qRegisterMetaType to register it. QWARN : tst_qquicktext::textFormat() QSignalSpy: Unable to handle parameter 'textFormat' of type 'TextFormat' of method 'textFormatChanged', use qRegisterMetaType to register it. Change-Id: I9105eb31ce3d6203602649e24835f4fb0ddb25fd Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* Purge sRGB chunks from PNG in tests.Edward Welbourne2016-03-2912-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>
* Remove empty .pro fileJoerg Bornemann2016-03-241-0/+0
| | | | | Change-Id: Ia85ced87b9cb0ad2093bdfc4abcf222929bc8bd5 Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
* Handle duration of zero in QML animatorsDavid Edmundson2016-03-171-0/+35
| | | | | | | | | Handle a duration of zero in animators using the same approach as animations. Task-number: QTBUG-39766 Change-Id: I1628292ad259ec5ec5d3bb0770440efa5fa6dad0 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* AnimatedSprite: don't access deleted scene graph nodesJ-P Nurmi2016-03-031-0/+22
| | | | | | | | | | | | | It’s a bad idea to store a scene graph paint node as a member variable. First of all, it should not access the node outside updatePaintNode(), that is, outside the render thread. Secondly, the node is owned by the scene graph and may be nuked whenever the scene graph feels so. Some creative re-parenting easily triggers a case where AnimatedSprite ends up accessing a node that was already deleted by the scene graph. Change-Id: I89205ac36333a2fcb094121afa61b6409fda5883 Task-number: QTBUG-51162 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* Properly signal errors when accessing lowercase enum valuesThomas McGuire2016-02-249-1/+94
| | | | | | Task-number: QTBUG-46758 Change-Id: I14e394021c231bda5552c8d1c98f20c903a62f12 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Validate Binding only when it is enabledNikita Krupenko2016-02-243-0/+54
| | | | | | | | | | | | Not validate binding if it is disabled and validate when it became enabled. This helps to get read of warnings about not existing property that started to appear since 61ce37de40711ef2d4a6b4989d8183e1711fc47d. Task-number: QTBUG-48623 Change-Id: I4aa92896c04b146a79e606842c1d33661b3f5a70 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com> Reviewed-by: Tobias Koenig <tobias.koenig@kdab.com> Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.6.0' into 5.6Liang Qi2016-02-158-0/+179
|\ | | | | | | Change-Id: Ib4eb5c3572cb5ec11eb744572ec796dc7e70456d
| * Fix crash in Installer Framework when used with Qt 5.6Simon Hausmann2016-02-021-0/+26
| | | | | | | | | | | | | | | | | | IFW uses QQmlV4Function in a QJSEngine environment, so there is no QML context. Up to commit cc98678f404cd49750076795f39b31bfa36c80c3 that would work. Let's fall back to the root context as scope if we don't have a qml context. Change-Id: Ib240746a95a0d16d61620f97abc31e4c74f36723 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
| * Merge 5.6 into 5.6.0Oswald Buddenhagen2016-02-026-0/+77
| |\ | | | | | | | | | Change-Id: I971229ff050c98258729ad70d9e06b89e5bbf617
| * | QQuickItem: fix another infinite loop in nextItemInFocusChain()Liang Qi2016-01-307-0/+153
| | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-50516 Change-Id: I6a1513b22401b0fe45da758a239ad82038b83264 Reviewed-by: Zsombor Egri <zsombor.egri@canonical.com> Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | | GridView: Sanitize visible items after model insertionGabriel de Dietrich2016-02-132-0/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is basically the same patch as 35d8d060b8621cfd, but this time for GridView instead of ListView. The major difference is that GridView seems to do the right thing when the model insertions happen after the visible index. That explains the missing part of the patch in applyInsertionChange() as compared to the same function in QQuickListView. Also, QQuickGridView auto-tests are a bit more robust than their ListView counterpart. So no changes were necessary to existing test cases. Task-number: QTBUG-48870 Change-Id: I19b24c4d84a1a4cef4fdb3ddd3381d0c6b93a76a Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* | | Factor out testing code for QTBUG_48870_fastModelUpdatesGabriel de Dietrich2016-02-133-91/+103
| | | | | | | | | | | | | | | | | | | | | This is going to be reused for QQuickGridview's counterpart. Change-Id: I3eaf272229b0e45dfc8c0b78ba94d57c72f9cc5d Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
* | | Fix Animators in itemview and positioner transitionsJ-P Nurmi2016-02-112-0/+88
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In itemview/positioner transitions, Animator's target-property is never explicitly set. QQuickItemViewTransition passes the animation target as a "default target" instead. This change adds missing handling for the default target. QQuickItemViewTransition sets up default "x" and "y" state actions. If Animator drives opacity, scale, or basically anything else than x/y animations, it failed to extract the from/to values from the state action list. This change fixes the issue that if the default state actions do not match the animator property (x/y vs. scale/opacity), it uses from/to values specified on the animator itself. Before, it did that only if the default state action list was empty. This is not the case with itemview/positioner transitions. Change-Id: I0f15e20bc860ddec23e59efebbc9cd346317f4de Task-number: QTBUG-50908 Reviewed-by: Gunnar Sletta <gunnar@sletta.org> Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* | | Window attached property: fix notifier signalsJ-P Nurmi2016-02-021-0/+5
| |/ |/| | | | | | | | | | | | | | | The change notifiers must be emitted when an item's window is reset. Otherwise any existing bindings don't get re-evaluated, and in worst scenario one ends up with dangling pointers. Change-Id: I6075957f1447bb8628d25bd822345e45837c027a Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
* | QML: do not wrap property values of type QVariant.Erik Verbruggen2016-01-271-0/+18
| | | | | | | | | | | | | | | | | | | | When reading a propety from a QGadget or a QObject, the values are stored in a QVariant and later unwrapped/converted to the correct JavaScript type. However, if the property value is a QVariant, it does not need to wrap it (again) in a QVariant. Change-Id: I633d3194f82b6032fc15d9994c4dee5e5609fd21 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | Don't check for revisions when assigning to grouped propertiesLars Knoll2016-01-274-0/+39
| | | | | | | | | | | | | | | | | | | | This leads to wrong behavior in some cases, where we reject valid revisions, and there is probably no case, where this could lead to a conflict for the user of the API. Change-Id: I1614332cf4c07c6a227551612331dd69b2ae71f3 Task-number: QTBUG-40043 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | Fix don't delete singletons objects owned by C++BogDan Vatra2016-01-251-0/+20
|/ | | | | | | | | | Don't delete singletons objects that are created only from C++ and have explicitSetObjectOwnership flag set, explicitSetObjectOwnership flag is set only by QQmlEngine::setObjectOwnership. Task-number: QTBUG-49865 Change-Id: I0ef658c2094e67b5cd9a1585e273144dfcee736a Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Pass Qt.include() URLs through the URL interceptor if presentKevin Krammer2016-01-237-0/+37
| | | | | | | | | | | | | JavaScript files loaded by the Qt.include() function did not get passed through the QQmlEngine's URL interceptor, while those loaded by import statements did. Now both include variants have the resolved URL passed through the interceptor, e.g. an installed QQmlFileSelector Task-number: QTBUG-50483 Change-Id: Ife75e6b644687f3fb04048a311e570cdcbab8c6d Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* tst_qquicklistview: Move a number of window instances to use scoped pointers.Robin Burchell2016-01-221-227/+115
| | | | | | | | | These are exception safe (not that that matters greatly here) but more importantly idiot-proof. A number of tests weren't cleaning up windows properly before. Change-Id: Ieca676c8eea54d3c2a1d9e4738133acdb2b370fe Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Clean up QV4DataCollectorUlf Hermann2016-01-221-1/+18
| | | | | | | | | | We don't need to pass debuggers and engines around as the data collector already has all the necessary information. Also, the exception collect job is only used in the test case, so we don't need to define it in the collector. Change-Id: I3197dd5c2d99e95465aa787097c6f8bf8aee794e Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* V4 Debugger: Avoid looking up values in debugger threadUlf Hermann2016-01-221-65/+73
| | | | | | | | | | | | To avoid interaction with the engine from the debugger thread we move the value lookup functionality into the data collector, and drop the RefHolder. Also, we define some more debugger jobs to move the work the request handlers do into the GUI thread. Task-number: QTBUG-50481 Change-Id: Ia73ebd01e715f13110ef010a766e9b0a1e202df9 Reviewed-by: Nils Jeisecke <jeisecke@saltation.de> Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Merge "Merge remote-tracking branch 'origin/5.5' into 5.6" into refs/staging/5.6Simon Hausmann2016-01-212-0/+42
|\
| * Merge remote-tracking branch 'origin/5.5' into 5.6Liang Qi2016-01-192-0/+42
| |\ | | | | | | | | | Change-Id: Ieb48911638b5c1acdfd4dee8aa19dca9be99a1f6
| | * MouseArea: fixed a crash in propagate()Liang Qi2015-11-262-0/+42
| | | | | | | | | | | | | | | | | | | | | | | | Should not propagate without window. Task-number: QTBUG-49100 Change-Id: Ieda3a8357283f8d07d4ffc0cc62c4e15645d7e5a Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | | QQuickItem: fix an infinite loop nextItemInFocusChain()Liang Qi2016-01-202-0/+31
| | | | | | | | | | | | | | | | | | | | | | | | When isTabFence is set to true and no children. Task-number: QTBUG-50516 Change-Id: I8430336fde7ab041797f8f9d9dfe5b9d56fecddd Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | | Provide access to signal parameters in SignalTransition::onTriggered.Michael Brasser2016-01-192-0/+159
|/ / | | | | | | | | | | | | Change-Id: Ib74d3f5e9a357a86b818e27dd7249e2ecdf1e513 Task-number: QTBUG-46897 Reviewed-by: Brett Stottlemyer <bstottle@ford.com> Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | qmlplugindump test: added check.Marco Benelli2016-01-181-0/+1
| | | | | | | | | | | | | | | | Added a check on meta object revisions, in order to verify regressions on QTBUG-49284. Change-Id: I616875157d2b36db0a984338ba9d6a7c5a83a240 Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
* | tst_qquicklistview: Share window in stickyPositioning test.Robin Burchell2016-01-151-2/+2
| | | | | | | | | | | | | | | | | | Since it has a lot of table driven tests, if we reuse the window like the other table driven tests do, the total time is a lot lower (~2 seconds lower for just this test for me). Change-Id: I01ce38442f70d592d70ba584df3e0783956ebeaf Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | QQuickItemView: Take sticky header/footer into account for ↵Robin Burchell2016-01-152-10/+74
| | | | | | | | | | | | | | | | | | | | | | positionViewAtIndex(). When using an overlaid header or footer, we must adjust the position we come up with by the appropriate size in order to end up at the correct place. Change-Id: I218b9aef7fdf37f56ffb63dc395f97045b55a186 Task-number: QTBUG-50097 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | Set CMP0056 to NEW only if it exists for the running cmake versionStephen Kelly2016-01-081-1/+3
| | | | | | | | | | Change-Id: Id3dfaba678f1891adbc31fcd379481ad9271198e Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | don't rely on transitive dependenciesOswald Buddenhagen2016-01-052-0/+4
| | | | | | | | | | Change-Id: Ide872b452e02ebefb3eeb51464c8d59e8bf58bc4 Reviewed-by: Jake Petroules <jake.petroules@theqtcompany.com>
* | Fix value changed logic for ValueTypeProvider typesFrank Meerkoetter2016-01-042-0/+108
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix broken value changed logic for types implemented through the ValueTypeProvider interface (QtQuick and Qt3d). It affects vector2d, vector3d, ... The signal was not emitted for the cases where the new value was equal to the default value of a given type. Also add a unit test to cover this area. Change-Id: I9491b0462c78fecc4c704ea36921611c1bd6b2ee Task-number: QTBUG-50204 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>