aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.9' into 5.10Liang Qi2017-10-2428-82/+363
|\ | | | | | | | | | | | | | | | | | | Conflicts: src/qml/qml/qqmlimport.cpp src/qml/qml/qqmlimport_p.h src/qml/qml/qqmltypenamecache.cpp Done-with: Ulf Hermann<ulf.hermann@qt.io> Change-Id: I41ba7a592b2659ddf53da6952ea3b456a7bba319
| * QQuickLoader: Use setSize() to resize itemAlexandr Akulich2017-10-202-4/+12
| | | | | | | | | | | | | | | | | | Sequential call of setWidth() and setHeight() results in outdated height on widthChanged() signal. Use setSize() to set width and height at once. Change-Id: I86ff5cef2da912a8855c66a614d5d7d2e71f1de8 Reviewed-by: Risto Avila <risto.avila@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * Extract QSizeChangeListener from tst_quickview to shared test utilsAlexandr Akulich2017-10-205-24/+97
| | | | | | | | | | | | | | The class is useful for other tests Change-Id: Iea287ee7659a7504800763c45ae5dc744360eaa0 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * Update the cursor rectangle when select all is triggeredAndy Shaw2017-10-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When select all is triggered then the cursor rectangle should be updated to ensure that the selection handles are visible if they are displayed on a given platform. For instance, on iOS the loupe handles should appear in this case. This also has the added effect that when using Backspace on the iOS keyboard, it will delete the selected text as opposed to just a single character as it will handle that situation correctly. The tst_qquicktextedit::inputMethodUpdate() test is modified to account for the extra event sent now when selectAll() is called. Task-number: QTBUG-63835 Change-Id: I94fb0576b286c006dd12c65d0b322d712ed2a96f Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
| * Fix outdated BSD license headerKai Koehne2017-10-1720-53/+253
| | | | | | | | | | Change-Id: Icc08925454445fc9497fb3bfd2c26efe90605983 Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
* | Remove blacklisting of tst_QQuickWindow::attachedProperty on WindowsFrederik Gladhorn2017-10-091-1/+0
| | | | | | | | | | | | | | | | | | This has been fixed in qtbase 0257ffe465d89a99f062c366bd7c7cd6d6826b4d Task-number: QTBUG-62177 Change-Id: Ibf4f94195c32569a27aeae3dde7ece11e4cf07b1 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Add test for verifying that event is pre-accepted for event filteringJan Arve Sæther2017-10-051-0/+16
| | | | | | | | | | | | Change-Id: I718bbc8dd617b52e0150a3c29cf34323383c620b Task-number: QTBUG-62631 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Merge remote-tracking branch 'origin/5.9' into 5.10v5.10.0-beta1Liang Qi2017-10-043-0/+33
|\| | | | | | | Change-Id: I75b0099b2b9ebb5cfb6f07b43b90b598743ae033
| * Fix behaviors not working when sub-types declare propertiesSimon Hausmann2017-09-223-0/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | Since commit 81867dfbf9c16d4300727a08eed9b5c6c979e0ba we have an optimization in place to avoid the virtual meta-call when writing properties that cannot be intercepted. Unfortunately that check did not take parent VME meta-objects into account, which triggered the bug. Test case by Harald Hvaal <hhvaal@cisco.com> Task-number: QTBUG-63365 Change-Id: I66cb2967da2c09ca5e38cebd9db2ee6e3ee78f5f Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | replace MultiPointHandler::requiredPointCount with min/max range propsShawn Rutledge2017-09-291-1/+1
| | | | | | | | | | | | | | | | This is more flexible in case someone wants a PinchHandler to respond in the same way for either 2 or 3 touchpoints, for example. Change-Id: I360ce6f0239d86aa92dbebc225e3646883e71100 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | change the type of DragHandler::translation to QVector2D; document itShawn Rutledge2017-09-291-1/+1
| | | | | | | | | | | | | | | | For consistency we use QVector2D to represent relative movements in all Pointer Handlers. Change-Id: I23dc20c360b482a995d232e8a6d7e87d9bd8f600 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | Merge remote-tracking branch 'origin/5.9' into 5.10Lars Knoll2017-09-207-5/+111
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/compiler/qv4compileddata.cpp src/qml/compiler/qv4compileddata_p.h src/qml/jsruntime/qv4engine.cpp src/qml/jsruntime/qv4qmlcontext.cpp src/qml/jsruntime/qv4qmlcontext_p.h src/qml/jsruntime/qv4regexpobject.cpp src/qml/jsruntime/qv4regexpobject_p.h src/qml/types/qqmllistmodel.cpp src/quick/items/qquickanimatedimage_p.h src/quick/scenegraph/qsgrenderloop.cpp tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp Change-Id: If20ef62b2c98bdf656cb2f5d27b1897b754d3dc0
| * QQuickTextEdit: call implicitWidth() even if requireImplicitWidth is trueTim Jenssen2017-09-141-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Before once requireImplicitWidth was set to true by requesting the implicit width, the implicit (and width) was never updated again, even if the text was updated/changed. Adding also a test Task-number: QTBUG-63153 Change-Id: Ie3bac4baeb14c2e69acc43d11a351ac91d5400da Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: J-P Nurmi <jpnurmi@qt.io> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io> Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
| * Add NOTIFY signal for QQuickAnimatedImage::frameCountPal Toth2017-09-131-0/+10
| | | | | | | | | | | | Task-number: QTBUG-62913 Change-Id: Ib561e0ab6582c1df41ae1c75ba304377c00d63f0 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * Add missing math.h include for math functionsJake Petroules2017-09-122-0/+4
| | | | | | | | | | | | | | | | On some platforms, math functions in the std namespace don't work even if cmath is included. Change-Id: Ia71d22b07f508e0584de5320f376fbf4b3a2887b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * Fix issue with programmatic flicking at boundsMichael Brasser2017-09-082-0/+49
| | | | | | | | | | | | | | | | | | Ensure that the same flick consistently produces the same results, by making sure we don't use old timestamps from previous flicks. Task-number: QTBUG-62939 Change-Id: Ie738076abba66d38ff505292925e9441c38a3c95 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * tst_qquickmultipointtoucharea nonOverlapping: add visual feedbackShawn Rutledge2017-09-051-5/+35
| | | | | | | | | | | | | | | | | | It's difficult to troubleshoot autotests like this without being able to either see what's happening while it runs or test it manually. Task-number: QTBUG-59960 Change-Id: Iba7b03036f2f631c9b6d34d563ebae2de77acf1f Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | rename TapHandler.isPressed property to pressedShawn Rutledge2017-09-125-12/+12
| | | | | | | | | | | | | | | | | | This is for the sake of convention. Unfortunately (and the reason it wasn't done this way at the outset), it may prevent us from ever having a signal called "pressed" in this handler or its base class. Change-Id: Iafa117410e0e33562290b87df59bc8c0085c217d Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | don't re-deliver events to an item which already filteredShawn Rutledge2017-09-111-4/+1
| | | | | | | | | | | | | | | | | | That is, if the filtering parent intercepts an event (returns true from childMouseEventFilter), it does not also need direct delivery of the same event. Change-Id: I24003f72875b309fa10b2d316916c5f86702cb57 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | Add test for mouse event propagation and filteringJan Arve Sæther2017-09-081-0/+349
| | | | | | | | | | Change-Id: I190936abda0900822e758a19be5308a5e1da586f Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | Blacklist tst_QQuickShape tests on macOS CI runsTor Arne Vestbø2017-09-071-0/+8
| | | | | | | | | | | | | | | | Can not be reproduced locally on 10.11 or 10.12. Task-number: QTBUG-63035 Change-Id: I0d9bfc123be8e580ca143aacb41f2a5d9e34cbc6 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* | rename QQuickEventPoint pos properties to positionShawn Rutledge2017-09-052-3/+3
| | | | | | | | | | | | | | | | For consistency we always spell it out, although it does make some of these properties inconveniently verbose. Change-Id: I64a08c3aa261c0ab89e09472dd47510abafbf7ca Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* | Remove isValid from QQuickPointerEventFrederik Gladhorn2017-08-301-2/+0
| | | | | | | | | | | | | | | | | | | | | | We don't seem to have any use for invalid points, so let's remove the concept. The debug code first checks the valid property, but then unconditionally accesses the event, showing that we never had any invalid event in there in the first place. Change-Id: I5f8aac16c519f06a151198902cc98097eafacaa8 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Use QRandomGenerator instead of q?randThiago Macieira2017-08-232-5/+6
| | | | | | | | | | Change-Id: Icd0e0d4b27cb4e5eb892fffd14b5285d43f4afbf Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Merge "Merge remote-tracking branch 'origin/5.9' into dev" into refs/staging/devSimon Hausmann2017-08-186-51/+206
|\ \
| * | Merge remote-tracking branch 'origin/5.9' into devSimon Hausmann2017-08-186-51/+206
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/compiler/qqmltypecompiler.cpp src/qml/jsruntime/qv4qmlcontext.cpp src/qml/jsruntime/qv4qobjectwrapper.cpp src/qml/qml/qqmlcustomparser.cpp src/qml/qml/qqmlimport.cpp src/qml/qml/qqmlimport_p.h src/qml/qml/qqmlmetatype.cpp src/qml/qml/qqmlmetatype_p.h src/qml/qml/qqmltypenamecache.cpp src/qml/qml/qqmltypenamecache_p.h src/qml/qml/qqmltypewrapper.cpp src/qml/qml/qqmltypewrapper_p.h src/qml/qml/qqmlvmemetaobject.cpp src/qml/util/qqmladaptormodel.cpp Change-Id: Ic959d03e6f9c328fb02710d9abbb0f27cddde131
| | * QQuickTextInput: Allow going from an Acceptable to an Intermediate stateAndy Shaw2017-08-151-0/+75
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When editing text with a validator set then it can happen that it would no longer be in the acceptable state. This ensures that it does not prevent editing the text when an input mask is used to go back to an Intermediate state. Change-Id: I6da533d18035e9da468939c28a961bc8f2f3090b Reviewed-by: Robin Burchell <robin.burchell@crimson.no> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| | * Fix ListView::StrictlyEnforceRange with resizing delegateMichael Brasser2017-08-092-0/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When fixupPosition is called for a ListView with StrictlyEnforceRange, the original reason for the move is lost, and the fixup is applied immediately. There are already checks for whether the view is moving, so expand these checks to include movement caused by highlight. Change-Id: I25f771b9a529d31dc28acb9f91fcd2b582428200 Task-number: QTBUG-33568 Reviewed-by: Robin Burchell <robin.burchell@crimson.no>
| | * Fix flaky failure in attachedProperty() autotestJan Arve Saether2017-08-032-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QVERIFY(QTest::qWaitForWindowActive(&view)) sometimes failed. This was because at that point, "view" already had been active, then turned inactive again due to that the "extraWindow" had become active. The fix is to not show the "extraWindow" immediately from the QML file, but to postpone displaying the "extraWindow" to after we have verified that the "view" has become active. Change-Id: Ic008a332a736a3b7ab29ad9b2bfeb1eef0d7c19d Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| | * tst_QQuickDropArea: Pass with High DPI scalingFriedemann Kleint2017-08-021-10/+14
| | | | | | | | | | | | | | | | | | | | | Apply device pixel ratio where appropriate. Change-Id: I166604faa3f332f800822abdbbee7b8caacf2f54 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
| | * tst_qquickwindow: Make touch tests pass with High DPI scalingFriedemann Kleint2017-08-021-40/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rewrite the tests to use QTouchEvent::TouchPoint instead of QWindowSystemInterface::TouchPoint and use the convenience functions QWindowSystemInterfacePrivate to scale them. Use the new API consisting of position and ellipsis instead of the QRect based API. Change-Id: I26f672ef77fe12ef5e9609b61567397bc0808b5e Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | | Tests: Clean up inclusion of util.pri and debugutil.priUlf Hermann2017-08-173-3/+0
|/ / | | | | | | | | | | | | | | | | | | | | When we include debugutil.pri, we always want util.pri, too. We can as well nest the inclusions. Also, setting the include path is much easier from within the .pri files than from outside. Change-Id: I1205bdc3051e16e635d4ea9626f44e51002ddb50 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Rename shape example files to get rid of the old pathitem termLaszlo Agocs2017-08-091-2/+2
| | | | | | | | | | | | | | | | QQuickShape used to be known as QQuickPathItem. Avoid the old name in publicly exposed components. Change-Id: I70bed142e1e82c48c496ab98384318e08fba99c7 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Merge "Merge branch 'wip/pointerhandler' into dev" into refs/staging/devShawn Rutledge2017-08-0933-26/+3887
|\ \
| * \ Merge branch 'wip/pointerhandler' into devShawn Rutledge2017-08-0833-26/+3887
| |\ \ | | | | | | | | | | | | Change-Id: Ifae425744d69779a661c7465d33163a7d53fb8a4
| | * | Fix some bugs related to child mouse filteringwip/pointerhandlerJan Arve Saether2017-08-081-0/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Only abort event delivery early if event that got filtered was accepted (previously we aborted as soon as the event got filtered, even if the event was filtered, but explicitly *not* accepted) - If the event that got filtered was *not* accepted, we do not abort event delivery, but we need to remove the item from the list of target items that we will deliver to later - If childMouseEventFilter returns true it should not automatically mean that the event was accepted. Change-Id: I2f2415379061131af1d5102e03d01f010e1a8168 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
| | * | Merge remote-tracking branch 'origin/dev' into wip/pointerhandlerShawn Rutledge2017-08-084-4/+107
| | |\ \ | | | | | | | | | | | | | | | Change-Id: I0af7b0c3e0a21aae68c82ec11c5ca579c1661ce9
| | * \ \ Merge remote-tracking branch 'origin/dev' into wip/pointerhandlerJan Arve Saether2017-07-1136-88/+729
| | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/quick/shared/LauncherList.qml src/quick/items/qquickevents.cpp src/quick/items/qquickevents_p_p.h src/quick/items/qquickwindow.cpp tests/auto/quick/touchmouse/tst_touchmouse.cpp Change-Id: Id692d291455093fc72db61f1b854f3fc9190267b
| | * | | | Update according to new "point" API of single handlerJan Arve Saether2017-05-311-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ia67dd04333a7879362819e1bb2a891c1f92b7069 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | | | Add autotest for DragHandlerShawn Rutledge2017-05-299-0/+904
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I46f7e2c16b775723a08aa192845d490046231990 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
| | * | | | Add tst_multipointtoucharea_interop autotestShawn Rutledge2017-05-274-0/+399
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | to test interoperability of PointerHandlers with conventional touch- handling Items (with MultiPointTouchArea being the prototypical instance) Change-Id: Id19f312b17b70df072d66cd91816d2b19250a500 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | | | Add tst_PointerHandlers::touchReleaseOutsideShawn Rutledge2017-05-261-0/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | to verify when a point is pressed on a PointerHandler, dragged outside, and released, the handler gets a release event, or a cancel. Change-Id: Icdcb67c5549aca605bc6e7b425978760330ba270 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
| | * | | | tst_qquickpointerhandler: Test grab changesShawn Rutledge2017-05-241-61/+90
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now an Event could represent a QEvent, a PointerEvent, or a call to onGrabChanged, so we can test the sequence more thoroughly. Change-Id: Ib935cda8dfc87c37d917989423615688dc9c260c Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | | | Fix autotests to run with the new APIJan Arve Saether2017-05-231-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 5d4f488bf30f5650051d6cc226a75dbd17cd9a70 changed some APIs, but it forgot to update all autotests. Change-Id: I2a0ca14dbc1a0dddcbad597389c00d5e6f6c8b79 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | | | Move properties into grouped "point" propertyJan Arve Saether2017-05-231-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I80000110a2e0ca69210322a0fcc587d86158358e Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | | | tst_qquickpointerhandler: Remove unused includes; better debug outputShawn Rutledge2017-05-191-19/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I1e0539fe24e19ca15641fa4007488b33c24ab8ba Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
| | * | | | tst_flickableinterop: test buttons with all gesturePolicy valuesShawn Rutledge2017-05-154-12/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: If3d9e10bb54fc75a7e72bc6367de3e083611a45f Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
| | * | | | tst_qquickpointerhandler: use QScopedPointer; improvementsShawn Rutledge2017-05-112-85/+113
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's now standard practice in autotests to use QScopedPointer to manage the window so that it doesn't need to be deleted (or would be left dangling if the test fails). It's nice to be able to see the bounds of the EventItem. Test not only the order of the event types received, but the EventPoint state, and where they were received. Of course PointerEvents go only to PointerHandlers in this test so far... but now we can distinguish filtered events from events which were received via the QQuickItem virtual function overrides. Change-Id: I4830a431bedb7101c8c980ab3260d23b5852b645 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | | | touchmouse autotest: add debug operator for the test-specific Event typeShawn Rutledge2017-05-111-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's nice to be able to do qDebug() << eventItem->eventList when troubleshooting behavior in case of test failure. Change-Id: I2b50d5b092a0c9eb4eab3105be66a36aedf871bb Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | | | Default QQuickItem::acceptTouchEvents to true until Qt 6Shawn Rutledge2017-05-103-4/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a partial revert of 1457df74f4c1d770e1e820de8cd082be1bd2489e to avoid making a mandatory API change so soon. Change-Id: I05040579fa36d3dc5ef7616861f6d17adf500d2c Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>