aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquickwindow
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2013-12-162-0/+39
|\ | | | | | | | | | | | | | | | | Conflicts: src/quick/items/qquickitem.cpp src/quick/items/qquicktext.cpp tests/auto/quick/qquicklistview/tst_qquicklistview.cpp Change-Id: I0bc5786098193c2c40b6fd8905de75d90f6ed0cf
| * Only emit focusObjectChanged when an actual change occurs.Michael Brasser2013-12-062-0/+19
| | | | | | | | | | | | | | Change-Id: If18b460a8773e5cac597c02c51836b79711c20f4 Done-with: Matthew Vogt <matthew.vogt@jollamobile.com> Reviewed-by: Simon Hausmann <simon.hausmann@digia.com> Reviewed-by: Alan Alpert <aalpert@blackberry.com>
| * Ensure that QML Windows respect the default platform window stateTor Arne Vestbø2013-11-301-0/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'visible' property of a Window would be set on the baseclass QWindow like any other property during QML component creation, which would cause create() to be called and the platform window would be created. This left the 'visibility' of the QML window as Windowed, not respecting the platform defaults for how windows should be shown. The user would have to explicitly set "visibility: Window.AutomaticVisibility" for this default to apply, which doesn't make sense -- it should be the default. We solve this by deferring setVisible and setVisibility on the window until the component is complete and we have a full picture of its state. We then ask the platform for the default state based on the window flags (ensuring that eg "flags: Qt.Popup" will not result in maximized windows on iOS and Android), and apply the deferred visibility. The deferred visibility may still be 'false', but setting the window state makes sense anyways, so that a later "visible = true" will apply the default window state. Deferring platform window creation until the geometry has been potentially set from user code also has the benefit that the platform window can check the geometry and apply a default geometry if it's null. This was not possible when the 'visible' property was a regular property, as you could not know if the user's geometry changes would come after platform window creation. Task-number: QTBUG-35174 Change-Id: Icf3236187992048a85b2196c059f9b54699041a4 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com> Reviewed-by: Robin Burchell <robin+qt@viroteck.net> Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
* | Fix delivery of QEvents to QQuickItemsDaniel d'Andrada2013-11-291-0/+97
|/ | | | | | | | | | | Make them go through QObject::event() and comply to filtering from objects passsed to QObject::installEventFilter() Task-number: QTBUG-32004 Change-Id: Ib6972e7f5e588bee986ae5f2d69aa6fccb58af95 Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Alan Alpert <aalpert@blackberry.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Use one render loop per QQuickWindowGunnar Sletta2013-10-301-7/+7
| | | | | | | | | | | | | | | | | | | See the task for the full reasoning behind this patch. The threaded renderloop has been refactored to have one window per thread. This is mostly a simplification of the current code path where for loops over multiple windows are turned into if (window). The QSGContext has been split into two classes, QSGRenderContext for which there is one per OpenGLContext. The rest of the patch is name changes and a couple of cleanups in the hopes of simplifying this change. Task-number: QTBUG-33993 Change-Id: I31c81f9694d7da7474a72333169be38de62613c4 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Fix and re-enable constantUpdateOnWindow test.Gunnar Sletta2013-10-111-15/+33
| | | | | Change-Id: I0015ea58bfd673352405642153a038b72d44aa37 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* Unskip test which now passes.Gunnar Sletta2013-10-111-3/+0
| | | | | Change-Id: Ifccab1ef822a9bb455d442f6b13711887a399d6e Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* Skip failing test for nowAlan Alpert2013-09-161-0/+3
| | | | | | | | | It's been difficult to reproduce locally and is blocking CI. Skipping test while we look into the error. Task-number: QTBUG-33516 Change-Id: I77f00a024143e12d19526d0b52593cc2d128cedf Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Merge branch 'stable' into devSergio Ahumada2013-09-061-16/+15
|\ | | | | | | | | | | | | | | | | Conflicts: src/qml/debugger/qv8debugservice.cpp src/qml/qml/v8/qv8engine.cpp tests/auto/quick/qquickitem/qquickitem.pro Change-Id: Ic4a1dcdd8b8a84155d2f2abefdf1da5c3a56af31
| * Fix some style issues in tst_qquickwindowJosh Faust2013-08-191-16/+15
| | | | | | | | | | | | Change-Id: I5802f10f9aaff3e443696644d07203160fbc3b91 Reviewed-by: hjk <hjk121@nokiamail.com> Reviewed-by: Alan Alpert <aalpert@blackberry.com>
* | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2013-08-192-6/+63
|\| | | | | | | | | | | | | | | Conflicts: tests/auto/quick/qquickgridview/qquickgridview.pro tests/auto/quick/qquickitem/qquickitem.pro Change-Id: Ic54cafbdda1ac22757d2ee65dcc63a1b167c7556
| * Unset the cursor when an Item is unparentedDaiwei Li2013-08-141-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | It's possible for a cursor to get stuck if an item gets deleted. QQuickItemPrivate::derefWindow sets the cursorItem in QQuickWindowPrivate to 0, but doesn't unset the cursor. This causes the cursor to get stuck until the user hovers their mouse over an item that has a cursor set. Change-Id: I1d5d3ff13d69c76e4f8fe86b1f5b669bb714ecca Reviewed-by: Alan Alpert <aalpert@blackberry.com>
| * Fix hover event crashJosh Faust2013-08-122-0/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | It was possible for a hover event to be sent to a QQuickItem that has already been scheduled to be deleted (through deleteLater()). This lead to an access on an already-freed object when the leave event is generated. This change ensures that the item is part of a scene before generating the hover enter event. Task-number: QTBUG-32771 Change-Id: I69adb6bbd0ae52c70a6bda4e6c918b7671549a4c Reviewed-by: Alan Alpert <aalpert@blackberry.com>
* | Merge "Merge branch 'stable' into dev" into refs/staging/devSergio Ahumada2013-08-061-1/+1
|\|
| * Fix tst_qquickwindow for fullscreen platformsRafael Roquetto2013-07-251-1/+1
| | | | | | | | | | | | Change-Id: I040282f1bf1a2a8f212b9c7192a5ffaa2dbfdfb8 Reviewed-by: Wolfgang Bremer <wbremer@blackberry.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* | Merge branch 'dev' of ssh://codereview.qt-project.org/qt/qtdeclarative into ↵Simon Hausmann2013-06-244-2/+151
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | wip/v4 Conflicts: src/imports/qtquick2/plugins.qmltypes src/qml/debugger/qv8debugservice.cpp src/qml/qml/qml.pri src/qml/qml/qqmlcompiler.cpp src/qml/qml/qqmlcomponent.cpp src/qml/qml/qqmlcontext.cpp src/qml/qml/qqmldata_p.h src/qml/qml/qqmlengine_p.h src/qml/qml/qqmljavascriptexpression.cpp src/qml/qml/qqmlxmlhttprequest.cpp src/qml/qml/v4/qv4bindings.cpp src/qml/qml/v4/qv4irbuilder.cpp src/qml/qml/v4/qv4jsonobject_p.h src/qml/qml/v8/qqmlbuiltinfunctions.cpp src/qml/qml/v8/qv8bindings.cpp src/qml/qml/v8/qv8contextwrapper.cpp src/qml/qml/v8/qv8listwrapper.cpp src/qml/qml/v8/qv8qobjectwrapper.cpp src/qml/qml/v8/qv8qobjectwrapper_p.h src/qml/qml/v8/qv8sequencewrapper_p_p.h src/qml/qml/v8/qv8typewrapper.cpp src/qml/qml/v8/qv8valuetypewrapper.cpp src/qml/types/qqmldelegatemodel.cpp src/quick/items/context2d/qquickcanvasitem.cpp src/quick/items/context2d/qquickcontext2d.cpp sync.profile tests/auto/qml/qjsengine/tst_qjsengine.cpp tests/benchmarks/qml/animation/animation.pro tools/qmlprofiler/qmlprofiler.pro Change-Id: I18a76b8a81d87523247fa03a44ca334b1a2360c9
| * Add QQuickWindow::closing signal, and ability to ignore the eventShawn Rutledge2013-05-082-0/+53
| | | | | | | | | | | | | | | | | | | | | | An application can implement onClosing() and set closeEvent.accepted = false to delay the closing (for example to prompt the user to save changes). Depends on change I9abed47fca02a002b78727f98d678a824854adfc in qtbase. Task-number: QTBUG-31019 Change-Id: Icfd4a03ecef3621bdbbee2e2c3157b897a9b6524 Reviewed-by: Alan Alpert (Personal) <416365416c@gmail.com>
| * Added doc and test for active and requestActivate in QQuickWindowLiang Qi2013-04-303-0/+82
| | | | | | | | | | | | | | | | Autotest is included. Change-Id: I0f8614b502f1e51cab5612fee283c929e078108b Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com> Reviewed-by: Liang Qi <liang.qi@digia.com>
| * Implement QQuickWindow::grabWindow() for isVisible=falseGunnar Sletta2013-04-261-2/+16
| | | | | | | | | | | | | | Webkit uses this for testing. Change-Id: I4539e169a02592fb6c0062903917d4dd23a4303c Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@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-1/+0
| | | | | | | | | | 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>
* skip failing constantUpdatesOnWindow test for nowShawn Rutledge2013-03-011-0/+1
| | | | | | | | This test tries to render some frames and count them; but even 10 frames in one second seems to be too many to expect on the CI Macs. Change-Id: Id9cd700499101ca10afeddee89bc183fef7d30d3 Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
* Make sure exposeEvents trigger a render passGunnar Sletta2013-02-211-0/+24
| | | | | | | | We needs this on non-compositing window managers to trigger repaints on partial updates. Change-Id: Ied5f3e854173c5e00ad7e1222aeb66eb9c96158c Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* Improved animations in the new render loopGunnar Sletta2013-02-193-1/+79
| | | | | | | | | | | | | | | | | | | | To advance animations in line with vsync, we used a dedicated event from the rendering thread which we fired immediately after sync. This is a bit elaborate as we know in Gui when sync is complete and we can just animate there and then. This means we can remove all animation logic from the rendering thread, making it simpler. I also updated the syncAndRender pass so that it does not render anything if the scene graph reported no changes during the sync pass. This will prevent non-visual animations and property updates from triggering render passes which will save quite a few cycles. Change-Id: I62bb5484f0673f99abe726fca5a9b424f6b0a317 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com> Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* Complete rewrite of threaded render loop.Gunnar Sletta2013-01-183-1/+96
| | | | | | | | | | | | | | | | This change starts using the superior implementation of the scene graph render loop which has been worked on in the scenegraph-playground project for a while. It uses a far more straightforward locking/sync paradigm compared to the existing one and is less deadlock and error prone. It also enables the scene graph thread to run on its own when the GUI thread is blocked, enabling threaded animations. This changes also introduces a naming change inside Qt Quick from "Window Manager" -> "Render Loop" as that fits better to what the code does. Change-Id: I1c2170ee04fcbef79660bd7dae6cace647cdb276 Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* Merge branch 'stable' into devGunnar Sletta2013-01-171-1/+1
|\ | | | | | | | | | | | | | | Conflicts: src/qml/doc/qtqml.qdocconf src/quick/doc/qtquick.qdocconf Change-Id: I087fa14720995a5e53c43567dc4a3c29eb9992a9
| * 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>
* | Do not force focus for non-focused windows.Gunnar Sletta2013-01-171-0/+5
|/ | | | | | | | | | If a QQuickWindow comes to screen but is not the focus window, such as if it is a child window of another window, it should not have focus by default. Change-Id: If9015bbc179bb101178b3bc8de176a1c71c46023 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Andy Nichols <andy.nichols@digia.com>
* Renamed QQuickItem::pos property to positionShawn Rutledge2012-11-291-14/+14
| | | | | | | | | Abbreviated property names are less descriptive so we don't have many of them. Might as well be consistent. QWindow::pos was already renamed. Change-Id: Ib52673e68e7dc902b2f8942dba6b899074b2538b Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* Renamed QWindow::pos property to positionShawn Rutledge2012-11-091-11/+11
| | | | | | | | | | Abbreviated properties are to be avoided, and this is a new class so we have a good opportunity to avoid it before the release. Related to qtbase change I19c00b54b1d2712f9418e8bcf56e35a8008b89ef Change-Id: Ibd5cd10814c8cbd2b1f6e49b70782c7768d2366d Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* Remove interim compatibility measuresAlan Alpert2012-10-161-14/+14
| | | | | | | | Also update some variables in qtdeclarative which failed to update rootItem->contentItem. Change-Id: Id34e29546a22a74a7ae2ad90ee3a8def6fc541d3 Reviewed-by: Alan Alpert <416365416c@gmail.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>
* Stabilize QQuickWindow tests a bitGunnar Sletta2012-08-173-32/+36
| | | | | Change-Id: I11a28e203c978e5675b088a5bb999c34b46f80da Reviewed-by: aavit <qt_aavit@ovi.com>
* Don't use compatibility headersPaul Olav Tvete2012-08-031-1/+1
| | | | | | | Cleaning up after the QWindowSystemInterface header change. Change-Id: Icc2df3cfd441bf6b113602f17d9b843fbc8c75ba Reviewed-by: Lars Knoll <lars.knoll@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>
* Add includes for QWindowSystemInterfacePaul Olav Tvete2012-08-011-0/+1
| | | | | | | QWindowsystemInterface will no longer be a public class Change-Id: Ibd815d377cbd553e8c3e99e99b337a9854647001 Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
* Implement strict mode for qmldir modulesMatthew Vogt2012-07-312-1/+2
| | | | | | | | | | | | | | | Allow a module's qmldir to contain a module directive, which when present specifies 'strict mode' import processing. In strict mode, type registrations are only permitted into the namespace identified in the qmldir file's module directive. In addition, any type registrations to that namespace originating from other modules are treated as error conditions. Task-number: QTBUG-26551 Change-Id: I081bde2d3b83d3f28524440177fb2cd1ccee34ad Reviewed-by: Chris Adams <christopher.adams@nokia.com> Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
* Fix resolution of cursor when items are overlapping.Andrew den Exter2012-07-261-0/+143
| | | | | | | | | | | | If MouseArea with cursorShapes are overlapping then cursor shape of the foremost item under the mouse cursor should be shown, but because the hover events are delivered to the foremost items first the opposite is occuring. This makes QQuickWindow responsible for correctly setting its own cursor instead of relying on items to work it out amongst themselves. Change-Id: Iedf144c583dfa3d1ff441e19db9601b5e171902a Reviewed-by: Martin Jones <martin.jones@nokia.com>
* QtQuick: Remove usages of qWaitForWindowShown(QWindow *).Friedemann Kleint2012-07-241-1/+1
| | | | | Change-Id: I722e20b2fb8d8c6c19c6f3f2cb16910d7433e9a4 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* QtDeclarative: Remove usage of deprecated qWaitForWindowShown().Friedemann Kleint2012-07-191-12/+13
| | | | | | | | | | | - 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>
* QQuickCanvas renamesAlan Alpert2012-07-178-0/+1163
QQuickCanvas is now called QQuickWindow QQuickCanvas::rootItem is now QQuickWindow::contentItem QQuickItem::canvas is now QQuickItem::window QQuickItem::ItemChangeData::canvas is also renamed window QQuickCanvas::grabFrameBuffer is now QQuickWindow::grabWindow The functions related to the color property have dropped the clear from their names. The first three changes have interim compatibility measures in place to ease the transition. Change-Id: Id34e29546a22a74a7ae2ad90ee3a8def6fc541d2 Reviewed-by: Martin Jones <martin.jones@nokia.com>