aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick
Commit message (Collapse)AuthorAgeFilesLines
...
* | Merge remote-tracking branch 'origin/5.4' into devSimon Hausmann2015-01-163-2/+20
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/qml/jsruntime/qv4context_p.h src/qml/jsruntime/qv4debugging.cpp src/qml/jsruntime/qv4engine.cpp src/qml/jsruntime/qv4functionobject_p.h src/qml/jsruntime/qv4qobjectwrapper.cpp src/quick/scenegraph/shaders/visualization.frag tests/auto/qml/qjsengine/tst_qjsengine.cpp Change-Id: I492e8546c278f80a300a2129e9a29d861e144a30
| * TextEdit: fix construction time text cacheJ-P Nurmi2015-01-081-0/+12
| | | | | | | | | | | | | | | | | | | | | | QQuickTextEdit does not apply cached text to the underlying document until component construction is complete. However, if text() was called during the construction (eg. because of a binding), it would blindly overwrite the cached text with (still) empty document content. Task-number: QTBUG-41583 Change-Id: I6c5c1b6283d70d8a5ec2c8bd986095ee3c35a14c Reviewed-by: Pierre Rossi <pierre.rossi@theqtcompany.com>
| * Change Qt bugtracker URL to qt.ioAlex Blasche2014-12-161-1/+1
| | | | | | | | | | | | Change-Id: I3dde034b2a36c324df9f4e1fd2e05a07a7237c04 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * QML: fix warning in testsErik Verbruggen2014-12-091-1/+7
| | | | | | | | | | | | | | | | Mark unused fields as Q_UNUSED. They are still "used" to check if the compiler will generate warnings/errors (which it shouldn't). Change-Id: I38e1668e88d94ab8f26a92a06f5207b77369e136 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* | Fix flick() with ListView.SnapToItem at bounds.Michael Brasser2015-01-132-0/+39
| | | | | | | | | | | | | | | | | | | | Previously flick() would not always allow flicking to the very end of a ListView if ListView.SnapToItem were set. Stop ListView from adding overshoot, and then incorrectly correcting, if we are flicking exactly to the end of a list. Change-Id: Iad56e433bc1ba7d62f0553c4355469c9861df919 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* | Improve startup of bindings using QQuickScreenSimon Hausmann2015-01-121-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We can optimistically initialize the underlying QScreen to the primary screen and this way ensure that in the common case the evaluation of bindings using the screen's attached properties results in correct calculations on startup. This way we can avoid re-evaluating the bindings again later. Previously on startup all the returned values were zero and the bindings got evaluated again once a window was assigned. Change-Id: I98ba5905953f0b5054d924919239d178570250d3 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com> Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | Add Window.width and Window.height attached propertiesJ-P Nurmi2015-01-092-0/+8
| | | | | | | | | | | | | | | | [ChangeLog][QtQuick] Added Window.width and Window.height attached properties Change-Id: I3ef590a0d3e6fa660ed88992d5ae843deb09c7bc Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Stabilize the drag related autotests for higher dpi displaysLars Knoll2015-01-092-8/+8
| | | | | | | | | | | | | | | | Higher DPI displays might have a larger StartDragDistance (at least on X11), breaking the autotest on these displays. Change-Id: I9768a245a7654665dd9f718100289e9416d8c855 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* | Default to threaded when using opengl32Laszlo Agocs2014-12-121-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This appplies only when using opengl32.dll. When using ANGLE or when using another non-opengl32 DLL, the "windows" single-threaded loop is chosen, just like before. One badly written autotest is fixed. We must never assume that performing some QQuickWindow related work will leave a context current on the main thread. The assumption worked by accident with the single-threaded render loop. [ChangeLog][QtQuick] Changed to use the threaded render loop by default on Windows when running with desktop OpenGL (opengl32.dll). Change-Id: I21798622c19ca510a97a96c19c1e70e29f086e3a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.4' into devSimon Hausmann2014-12-0915-42/+60
|\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/jsruntime/qv4arraydata.cpp src/qml/jsruntime/qv4context_p.h src/qml/jsruntime/qv4globalobject.cpp src/qml/jsruntime/qv4internalclass.cpp src/quick/items/qquicktext_p.h src/quick/items/qquicktextedit_p.h src/quick/items/qquicktextinput_p.h Change-Id: If07e483e03197cb997ef47a9c647a479cdb09f4c
| * QML: fix warning in testsErik Verbruggen2014-12-091-23/+0
| | | | | | | | | | | | | | Remove unused function that wouldn't be emitted anyway. Change-Id: I623d5d44bca9a1358cf9e66ff557992aba9ae451 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
| * Merge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into ↵Simon Hausmann2014-12-0910-10/+10
| |\ | | | | | | | | | refs/staging/5.4
| | * Merge remote-tracking branch 'origin/5.4.0' into 5.4Simon Hausmann2014-12-0510-10/+10
| | |\ | | | | | | | | | | | | Change-Id: I5978bab8a4fde4c2ee33907fd81f49cb69e4fb26
| | | * qttest: make findChild available only for QtTest 1.1Fawzi Mohamed2014-12-0510-10/+10
| | | | | | | | | | | | | | | | | | | | Change-Id: I4ceb1a969bd4296b82f899088b02b5e8cf100bcd Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
| * | | Quick: fix testErik Verbruggen2014-12-091-1/+1
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | /Users/erik/dev/qt5-stable/qtdeclarative/tests/auto/quick/qquickgridview/tst_qquickgridview.cpp:1561:60: warning: adding 'int' to a string does not append to the string [-Wstring-plus-int] items << qMakePair(QString("new item " + j), QString::number(j)); ~~~~~~~~~~~~^~~ Change-Id: I94bd952abf82a8f174772482330b5fdd636578ad Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
| * | Merge remote-tracking branch 'origin/5.4.0' into 5.4Simon Hausmann2014-12-021-0/+5
| |\| | | | | | | | | | Change-Id: I89bbb2977350a03c156d531f810d08a5560ffbb3
| | * Skip tst_qquickwindow::headless() when using ANGLE/Windows.Friedemann Kleint2014-12-021-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | The test crashes frequently. Task-number: QTBUG-42967 Change-Id: Ic17c6187bfa657154a9b04eb9c5b9a3de291cb1e Reviewed-by: Andrew Knight <andrew.knight@theqtcompany.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
| * | Stabilize tst_qquickflickable.Friedemann Kleint2014-11-281-4/+20
| |/ | | | | | | | | | | | | | | | | - Use one engine per test - Use QQuickView for the margins test - Verify QWindow cleanup. Change-Id: Id2a10b56101832c362822963a2a7bd1d66daa143 Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
| * QQuickWindow autotest: verify that onClosing can block close()Shawn Rutledge2014-11-071-0/+20
| | | | | | | | | | | | Task-number: QTBUG-40093 Change-Id: I800259f45d95736172d500494e68042180178e93 Reviewed-by: Caroline Chao <caroline.chao@theqtcompany.com>
| * Stabilize tst_QQuickAccessibleJan Arve Sæther2014-11-061-4/+0
| | | | | | | | | | | | | | | | There is no reason to wait for the window to activate Task-number: QTBUG-42355 Change-Id: I5faaff5bddd367e6dd57a6a922011c87c847148e Reviewed-by: Tony Sarajärvi <tony.sarajarvi@digia.com>
| * Add attached Window::contentItem propertyJ-P Nurmi2014-11-052-0/+4
| | | | | | | | | | | | | | | | | | This is essential to the Qt Quick Controls for implementing floating text selection handle popups. Change-Id: Ibae65110a5db6d65dacd197fef3ad567d11342dc Reviewed-by: Alan Alpert <aalpert@blackberry.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Allow setting the source rect on QSGSimpleTextureNodeJocelyn Turcotte2014-11-191-0/+58
| | | | | | | | | | | | | | | | This allows the QtQuick 2D Renderer to get this information without having to extract it from the QSGGeometry. Change-Id: Iec99c4bc910fea9c7d0e6712a418787254a70cb2 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
* | QQuickRepeater::clear: Remove items from the end backwards.Robin Burchell2014-11-072-0/+69
| | | | | | | | | | | | | | | | | | | | | | This way, the indices for itemRemoved will make sense consistently. This was broken with 5f5aba5b6e690ca54e66f41b93474f7e67e83c8b, dated November 2011. Task-number: QTBUG-42243 Change-Id: I5fecfd4174049f51e0cec90e40e6332de5d5bf01 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | Merge remote-tracking branch 'origin/5.4' into devSimon Hausmann2014-10-317-10/+232
|\| | | | | | | Change-Id: I30f9c925631991ceb22339d1333936faecffbaf4
| * text input: always let cursor rect have a width == 1Richard Moe Gustavsen2014-10-301-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of using a cursor width of null when a cursor delegate is set, we should to use a value of 1. Otherwise the rect we e.g return from cursorRect() will be invalid. An alternative would be to use the width of the delegate, but that was found to be controversial. On iOS we saw a bug with this when telling iOS to position text spelling popups underneath the cursor. Since the cursor rect we got was invalid (zero-width), no popup would show. Change-Id: Ice51b9a1bd33f331183e3acec61b7d9c0f5163cd Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
| * Repeater & itemviews: fix setModel() JS array handlingJ-P Nurmi2014-10-294-0/+114
| | | | | | | | | | | | | | | | | | | | | | | | QVariant comparison in setModel() started failing because JS arrays are now passed as a QJSValue. Re-assigning the same array content should not trigger a model change. This change restores the old behavior it had before, when JS arrays were passed as QVariantLists. Change-Id: I1882b3531f2893b116dbd817edeecab1ae812ce8 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
| * Remove mouse grabber if touch used for mouse emulation has been grabbedDaniel d'Andrada2014-10-292-10/+97
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If an item grabs a touch that is currently being used for mouse pointer emulation, the current mouse grabber should lose the mouse as mouse events will no longer be generated from that touch point. Example of what happens without this patch: -User touches a MouseArea. It gets pressed. -Some other item grabs that touch. -This touch eventually ends. -The MouseArea would still be pressed. And what will happens instead after this patch: -User touches a MouseArea. It gets pressed. -Some other item grabs that touch. -The MouseArea gets canceled and released -This touch eventually ends. Change-Id: I24114f18be564553a4a768243bb20379affe7a8f Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-10-2915-37/+473
|\| | | | | | | | | | | | | | | | | Conflicts: src/quick/items/qquickaccessibleattached_p.h src/quick/items/qquickwindow.cpp src/quick/scenegraph/qsgthreadedrenderloop.cpp Change-Id: I8bf07487a75f9d1b0d6efa5914dd06875fc9654d
| * Fix crash in SpriteSequenceAlex Blasche2014-10-243-0/+146
| | | | | | | | | | | | | | | | | | | | When QML declares sprites and goalSprite in wrong order the goalsprite attempts to set it on null spriteEngine. This patch ensures that the order doesn't matter anymore. Task-number: QTBUG-40595 Change-Id: I57f1c8754b2e2af91e0c7f72d1d67fec3ad4ede5 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
| * Relayout rich text when width increasesEskil Abrahamsen Blomfeldt2014-10-231-0/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In updateSize() we were trying to force relayouts for RichText when the width changes by always setting widthExceeded to true. But further down in the same function, we overwrote this with textWidth() < idealWidth(), which doesn't work, because both properties are the wrapped width of the document and should only differ if the text cannot be wrapped properly. The result was that when increasing the width of a Text element, we would hit the optimization and skip the relayout. [ChangeLog][Text] Fixed Text with the RichText format to correctly update wrapping when the width of the element grows. Change-Id: I5fd87052a5ba7e8ee2549be0cfac4adc8ddf8290 Task-number: QTBUG-33020 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
| * Screen attached property: expose devicePixelRatio propertyShawn Rutledge2014-10-232-0/+3
| | | | | | | | | | | | | | Change-Id: I08b22766b3e389b7d27ca4c56729f550b0647a08 Reviewed-by: Jens Bache-Wiig <jensbw@gmail.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| * Support Accessible.ignored on non-leaf itemsJan Arve Saether2014-10-214-4/+166
| | | | | | | | | | | | | | | | | | | | Ignoring items with children will make the children appear as children of the parent of the ignored item. Since setAccessibleFlagAndListener now only sets the flag we also rename the function to just setAccessible Change-Id: I79fc311509a3e454b4698274c63ad0e879fb93e3 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
| * Make test more robust against ignored children.Jan Arve Saether2014-10-204-33/+84
| | | | | | | | | | | | | | | | With the upcoming change that changes the semantics of Accessible.ignored, some assumptions in the test does not hold anymore. Change-Id: I9b34f1ecc61fc0d4e8abe5a5505a5bcff44501d4 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
| * Fix tst_qquickpositioners on OS XFrederik Gladhorn2014-10-201-0/+3
| | | | | | | | | | | | Done-with: Jan Arve Sæther Change-Id: Iff66f62167a5977354319aac311d2cb81d9f3842 Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
| * PathView: Fix QML engine thinking currentItem is null when it's notSérgio Martins2014-10-102-0/+42
| | | | | | | | | | | | | | | | QML didn't re-evaluate any bindings using currentItem because a notification was missing. Change-Id: Icdaa3022e0b01644a060e577d87f011b4ea9fabb Reviewed-by: Alan Alpert <aalpert@blackberry.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-10-0917-299/+80
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/quick/items/context2d/qquickcanvasitem.cpp src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp src/quick/scenegraph/coreapi/qsgrenderer.cpp src/quick/scenegraph/qsgadaptationlayer.cpp src/quick/scenegraph/qsgrenderloop.cpp src/quick/scenegraph/qsgthreadedrenderloop.cpp src/quick/scenegraph/qsgwindowsrenderloop.cpp src/quick/scenegraph/util/qsgatlastexture.cpp src/quick/scenegraph/util/qsgtexture.cpp src/quick/util/qquickprofiler_p.h Change-Id: Ie274c3baf72a8a0711c87d67238d68e2b2887429
| * Temporarily skip tst_qquickframebufferobject when using ANGLE.Friedemann Kleint2014-10-091-0/+4
| | | | | | | | | | | | | | Task-number: QTBUG-41815 Change-Id: I5c6ec36a4f8830d95e1d4904d1be41d752757339 Reviewed-by: Andrew Knight <andrew.knight@digia.com> Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
| * QQuickWindow autotest: focus transferred to parent on window closeShawn Rutledge2014-10-091-3/+0
| | | | | | | | | | | | | | | | | | | | | | These bugs were fixed so XFAIL is no longer necessary in the autotest (change da0c74550f0e8a21239896d6aead6e05f85eb695 in qtbase). Task-number: QTBUG-33423 Task-number: QTBUG-39809 Change-Id: Ia89554b9f54aca7ef6c6ac6b474ca2bb9c0f5629 Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com> Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
| * Add orientationUpdateMask to QQuickScreenAlex Blasche2014-09-302-0/+4
| | | | | | | | | | | | Task-number: QTBUG-38699 Change-Id: I173b7e53c27dba336351572859f7c9aeafe07ef9 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
| * Revert "Temporarily mark grab()/item.layer tests insignificant under ANGLE"Andrew Knight2014-09-302-36/+0
| | | | | | | | | | | | | | | | | | This reverts commit 6b31418a1b5d9be47df5ed61747e8a5fb225acfa. These tests now pass with the latest ANGLE. Change-Id: If812d430e69f0d39a970e9119ebc1f2e5b4886dc Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
| * Partially revert "Disable tests on failing ANGLE config"Andrew Knight2014-09-301-3/+0
| | | | | | | | | | | | | | | | | | This partially reverts commit fa29df24bd2792f5eb64e4ff21a116b2c5f5384c. The sprite sequence test now passes in CI under MSVC2010. Change-Id: Ie8f7abdd2ff00db377b1ef3f221c5048c430c067 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
| * Fix cleanup of non-threaded render loops.Gunnar Sletta2014-09-241-11/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | They would unconditionally call cleanupNodesOnShutdown on hide(), but QQuickWindow::sceneGraphInvalidated would only be emitted if this was the last window being hidden, leading to an inconsistent state in the application. Since the non-threaded render loops do not support releasing resources (there is one OpenGL context and one QSGRenderContext shared between all windows) we delay cleanup until the window is destroyed. This change also make the render loops track the windows until they are destroyed, similar to what the threaded one does. The purpose of this is to, in the case of dangling windows, only trigger invalidation of the scene graph when the last QQuickWindow is destroyed through QSGRenderLoop::cleanup(). Task-number: QTBUG-41210 Change-Id: I7e12a4f726ebb3e7935c822b6046abb3590c583a Reviewed-by: Ulf Hermann <ulf.hermann@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
| * Fix clip state tracking in Context2DMatt Fischer2014-09-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A recent change (f45fe58ad2aa741c90b756643da75f1a6bc2fdf6) introduced the concept of clipping being disabled for a context, so that it can start with no clip path set. However, this state is not properly tracked, so an attempt to restore a context state which has no clip path does not work properly. This change adds this information to the Clip command, so that it can be properly restored. This patch also re-enables a test case which was supposed to check this behavior, but had been disabled. Task-number: QTBUG-40312 Change-Id: I3fd5626ecfcc1298a81931828cbb590290098a92 Reviewed-by: Ulf Hermann <ulf.hermann@digia.com> Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
| * Make tst_qquickanimations more reliableUlf Hermann2014-09-191-30/+37
| | | | | | | | | | | | | | | | | | As we usually don't get realtime guarantees we cannot rely on exact sleep times. This change relaxes our expactations in that regard. Task-number: QTBUG-29062 Change-Id: I54dfb7a28d6bb46479aedb9f943f5ff4db2df701 Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
| * Remove tst_dialogs - moved to qtquickcontrolsJ-P Nurmi2014-09-184-207/+1
| | | | | | | | | | | | | | | | QtQuick.Dialogs were moved from qtdeclarative to qtquickcontrols already in Qt 5.3, but the auto test was forgotten. Change-Id: I5c74e45b9ee2302f1d20fb476af6a93879913a28 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
| * Fix QQuickText::lineLaidOutRelayout autotest on OS XJan Arve Saether2014-09-171-5/+6
| | | | | | | | | | | | | | | | QTextLine::height() can be different that QTextLine::rect().height() Task-number: QTBUG-37829 Change-Id: I7fa93d50e29397237220ba111baa3bd1a56b88f2 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
| * Make Canvas test case independent of chosen font.Ulf Hermann2014-09-161-1/+6
| | | | | | | | | | | | | | | | | | 0/0 is not always a red pixel after rendering "Hello" in red. The chosen font has an influence on that. Looking for some red pixel in row 0 is pretty safe. Change-Id: I669548c3c9d8cd25d720998fd9ba31c1f480e4e3 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
| * Wait longer for image to be loaded in canvas item testUlf Hermann2014-09-161-1/+1
| | | | | | | | | | | | | | 200ms can be too short if the system is busy Change-Id: I4f9c6bcbec93d511b5b5e9d531450f3ffd22cb0c Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
| * autotests: fix build on iOSRichard Moe Gustavsen2014-09-111-1/+1
| | | | | | | | | | Change-Id: Idf854ad4f868e873582731dfa6b0253ac5b17c5c Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* | Fixed AnimatedSprite to respect 'loops' properlyJan Arve Saether2014-10-063-0/+179
| | | | | | | | | | | | | | | | | | Previously, AnimatedSprite could stop before it had performed its desired number of loops. Task-number: QTBUG-36338 Change-Id: I9485886681f55d410786f27b4f6afdc72a058202 Reviewed-by: Michael Brasser <michael.brasser@live.com>