aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qquickapplicationwindow
Commit message (Collapse)AuthorAgeFilesLines
* Add recursion guard to QQuickApplicationWindowPrivate::relayout()Jan Arve Sæther2021-06-162-0/+103
| | | | | | | | | | | | | relayout() might change the size of the header, footer or contentitem When one of those items changes, QQuickApplicationWindowPrivate will get notified by that through QQuickApplicationWindowPrivate::itemGeometryChanged(). itemGeometryChanged() will then call relayout()... (*recursed*). Pick-to: 5.15 6.2 Task-number: QTBUG-87708 Change-Id: I9403952e776afb2be37d009642c65b5520c79341 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Update to latest qml CMake APICraig Scott2021-06-051-1/+1
| | | | | | | | | | | | | | The new qml CMake API places a closer relationship between the backing target and the plugin target. Both are typically created together and they share a lot of common details. Instead of creating them in different parts of the source tree, they are now specified together. The src/imports area has effectively been absorbed into the other corresponding subdirectories below src with this change. Task-number: QTBUG-91621 Change-Id: I9bd32e9eb78c198ccc9db04e2829303cac323502 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Add findViewDelegateItem function to visualtestutils.hMitch Curtis2021-04-221-0/+1
| | | | | | | | | | This helper function finds an item view delegate instance at a given index, ensuring that the view is polished and positioned at the correct index if necessary. Change-Id: Ib133914df723251835be3812c1d0654c07a99f14 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Remove QMake project filesJoerg Bornemann2021-02-111-15/+0
| | | | | | | | | | This includes removal of the corresponding .prev_CMakeLists.txt files. Pick-to: 6.1 Task-number: QTBUG-88742 Change-Id: I4247294258629c92e80914518e9208019090c815 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* Don't copy or assign QKeyEvent instancesVolker Hilsheimer2020-11-111-36/+48
| | | | | Change-Id: Id16f972a7f2c0f3c9c9d2fe1d14b9e0830a85a0a Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* CMake: Regenerate projects to use new qt_internal_ APIAlexandru Croitor2020-10-071-3/+3
| | | | | | | | Modify special case locations to use the new API as well. Task-number: QTBUG-86815 Change-Id: I4a690095fcd4b1141550de86b6820ae2dd579429 Reviewed-by: Cristian Adam <cristian.adam@qt.io>
* Make tests explicitly use Basic where necessaryMitch Curtis2020-10-071-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | The previous commit changes the how the default style is set, and since the tests all assumed that Basic was the default, we now need to ensure it is explicitly set. If we want to, we can revert this patch (or file-by-file) later and ensure that these tests work with all styles. For now, just keep things working as they used to. Tests that use QTEST_QUICKCONTROLS_MAIN are not changed, as they already run with all built-in styles. Tests that don't use types that will cause issues, like tst_qquickcolor, do not need to be changed. tst_snippets can be run manually to produce screenshots, so we specify its style in a qtquickcontrols2.conf file to allow it to be overridden by e.g. application arguments (QQuickStyle::setStyle() takes precedence over all other approaches of setting a style). Change-Id: Ifae7e959f89a41a757c170272038fad139bba04f Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* auto tests: remove all versioning from the test dataRichard Moe Gustavsen2020-09-041-3/+3
| | | | | | | | | | | | The problem is that QtQuick.Controls.macos is only available with revision 6.0. And when importing e.g QtQuick.Controls 2.15, we try to load a style with the same revision. But it simply doesn't exist. So remove all versioning from the tests to also support testing newer styles. Change-Id: I666a93ab03ec4c5dcf2055a363547f8cdac8d25e Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Remove all version numbers from QML importsMitch Curtis2020-08-2612-29/+29
| | | | | | | | | As of Qt 6, the latest version will be used by default. This saves us a lot of effort in terms of version bumps. Task-number: QTBUG-82922 Change-Id: I74eba8185ec3ccc75bc293d4b2ea87d59e2d9928 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Register C++ types declarativelyMitch Curtis2020-08-262-0/+75
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Adapt to the new way of registering C++ types. The types need to be seen at compile time so that code can be generated that invokes them. This patch: - Adds QML_* macros where applicable. - Adapts the build system files to the new way of registering modules. - Splits up the QtQuick.Controls[.*].impl files into their own plugins, as we can only register one QML module per .pro file. - Removes C++ type registration calls in every plugin. - Moves private types from src/quickcontrols2/quickcontrols2.pro to src/quickcontrols2/impl/quickcontrols2-impl.pro. Some of these types need to be exposed to QML, but quickcontrols2.pro is already in use to declare the QtQuick.Controls import (and also provides the public C++ QQuickStyle API), and the new QML_IMPORT_NAME/VERSION syntax only allows one module per project. As some of the types that need to be exposed to QML are also referenced by some C++ code (e.g. tests, etc.), we just move all of the private types to the new library. Follow-up patches will register the QML types declaratively. Task-number: QTBUG-82922 Change-Id: Iaf9ee106237d61701d57a8896f3822304c8151a6 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* ApplicationWindow: remove deprecated overlay APIMitch Curtis2020-06-082-30/+0
| | | | | | | | | | [ChangeLog][Controls][ApplicationWindow] The deprecated overlay properties and attached API were removed. Use the Overlay attached type instead. Task-number: QTBUG-84715 Change-Id: I0781ea55ea502ffe5277385e82492291724d2090 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Skip tests that use graphical effects on Win 7Mitch Curtis2020-05-261-0/+3
| | | | | | | | | It's not clear why these fail, but we can live without the test on Windows 7. Fixes: QTBUG-84443 Change-Id: Ib18dfc8e12528c5086d07d6018cda93fb6e8d30c Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Reduce dependencies on QtGraphicalEffectsMitch Curtis2020-05-131-0/+3
| | | | | | | | - Make QtGraphicalEffects optional in tests - Mention that QtGraphicalEffects is required for relevant examples Change-Id: I3ac7d06add931e0a10c3df7edc4e458ba5519c75 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* CMake: Regenerate projectswip/cmakeAlexandru Croitor2020-03-171-9/+5
| | | | | | Change-Id: Ifd6b2289de6465a010f5f2a32789221767b4d5be Reviewed-by: Leander Beernaert <leander.beernaert@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Regenerate projects to be in syncAlexandru Croitor2019-11-151-3/+3
| | | | | | Change-Id: I3a57449c9025e22414b8337fcffdeb0f4d769af2 Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Convert QtQuickControls2 testsLeander Beernaert2019-10-081-0/+52
| | | | | | | | Initial conversion of QtQuickControls2 tests. Change-Id: I7e09e387ec90f89cc2856c7f7f2cb810b03b7fa3 Reviewed-by: Qt CMake Build Bot Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Tie minor version of all imports to Qt's minor versionMitch Curtis2018-11-0211-26/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | This change makes all Qt Quick Controls 2 imports match the current Qt minor version, which is 12 as of this patch. It also updates all other Qt Quick imports to match. This will also make future version bumps easier as all version numbers in existing code/docs will match. The following commands were used to verify that no old versions remain: for i in `seq 0 11`; do git grep "import QtGraphicalEffects.*1.$i$"; done for i in `seq 0 11`; do git grep "import QtQuick 2.$i$"; done for i in `seq 0 11`; do git grep "import QtQuick.Layouts 1.$i$"; done for i in `seq 0 5`; do git grep "import QtQuick.Controls.*2.$i$"; done for i in `seq 0 11`; do git grep "import QtQuick.Templates 2.$i as T$"; done [ChangeLog] From Qt 5.12 onwards, all import versions in Qt Quick Controls 2 follow the same minor version as Qt's minor version number. For example, the import version for Qt 5.12 is: "import QtQuick.Controls 2.12". Change-Id: I6d87573f20912e041d9c3b7c773cc7bf7b152ec3 Fixes: QTBUG-71095 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* tst_QQuickApplicationWindow: remove workaroundMitch Curtis2018-10-261-5/+0
| | | | | | | | | | 30fcc735 introduced this to work around a crash that was apparently caused by 4c71db75. The commit that added the workaround is now three years old, and removing it fixes a crash that is blocking CI. Change-Id: Iefbb32e00d57e5ad86c43977e10120fdc92a3635 Fixes: QTBUG-70064 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Create and init QQuickTheme from QtQuickControls2PluginJ-P Nurmi2018-05-221-1/+1
| | | | | | | | | | | | | | | Instead of creating and setting the QQuickTheme instance from each style plugin (e.g. QtQuickControls2MaterialStylePlugin), create the QQuickTheme instance in QtQuickControls2Plugin when the style is being resolved, and just pass the instance to be initialized by the style plugin(s). This avoids the problem that QQuickTheme API was virtual, and sub-classes created from plugins would have vtables destroyed before the QQuickTheme was destroyed. Task-number: QTBUG-67062 Task-number: QTBUG-68087 Change-Id: I19e9ced5296b708c2668c30163389cb3da6be7cf Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickTheme: rename themeFont() and themePalette()J-P Nurmi2018-05-221-1/+1
| | | | | | | We don't have the conflicting virtual getters anymore. Change-Id: Ia20bfa0a0b1aa67c35a23270eb0241018f8e0ada Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickTheme: add setters to make getters non-virtualJ-P Nurmi2018-05-221-7/+2
| | | | | | | | | | This allows us to add more themable attributes (on the side of fonts and palettes) after the QQuickTheme API has been made public, because it won't require adding virtuals. Only the resolve() method is virtual. Task-number: QTBUG-67062 Change-Id: I6a5cc8d15aeaa5a9a0fe9b6d2591077f8822daac Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Rename QQuickTheme::current to instanceJ-P Nurmi2018-05-161-2/+2
| | | | | | | | Avoid giving a wrong impression that the theme instance could be changed on the fly. Change-Id: Ifb5078422385d2f15da6a416d89cc9d6f46b0f40 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Add QQuickTheme::ScopeJ-P Nurmi2018-03-151-3/+3
| | | | | | | | | | | Replace the old enums that were originally copied from QPlatformTheme, including irrelevant entries for DockWidget, MdiSubWindow, MessageBox, with a unified enum that will be matched to cover everything needed for theming fonts and palettes for Qt Quick Controls 2. Task-number: QTBUG-67062 Change-Id: Ia99d092f28c00210c0c7f24d4241eb5a5d9ceb5b Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickTheme: cleanup the APIJ-P Nurmi2018-03-151-1/+1
| | | | | | Task-number: QTBUG-67062 Change-Id: Id2f821bd41b72f7bce9885295e89c322eb3332f4 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickTheme: don't inherit QPlatformThemeJ-P Nurmi2018-02-271-6/+5
| | | | | | | | | | | | | | | | Use QPlatformTheme as a fallback instead of inheriting from it. This way, Qt Quick Controls 2 themes don't mess up the fonts and palettes of Qt Quick Controls 1 and Qt Widgets applications. Note: QQuickTheme::Font and QQuickTheme::Palette enums are copies of the respective enums in QPlatformTheme, for now. This is the simplest first step, but later on, we can have our own set of enums that cover controls, such as Switch, that were previously entirely missing from QPlatformTheme. Task-number: QTBUG-51921 Change-Id: I8efe0ba2d03d65bc12b55b533ba9f2fab5320348 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Promote QQuick(Proxy)Theme from libQQC2 to libQQT2J-P Nurmi2018-02-151-1/+1
| | | | | | | | | | QQuickTheme needs to be part of libQtQuickTemplates to be able to provide dark and light palettes (and later, icons). Task-number: QTBUG-63331 Change-Id: If7d3d279a07b6daf6701a1d3cd3686bec1d094b4 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Merge remote-tracking branch 'origin/5.9' into 5.10Liang Qi2017-10-301-2/+12
|\ | | | | | | | | | | | | Conflicts: src/imports/controls/MenuItem.qml Change-Id: Id4cae0e53a58796694ad1fc9f8380b317ee62984
| * Fix outdated BSD license headerKai Koehne2017-10-231-2/+12
| | | | | | | | | | Change-Id: Ibec1396de3e929a229e1550b8045d687aa5a513c Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
* | Merge remote-tracking branch 'origin/5.9' into 5.10J-P Nurmi2017-09-272-4/+67
|/ | | | | | | | | | Conflicts: .gitignore tests/auto/auto.pro tests/auto/qquickmenu/tst_qquickmenu.cpp tests/auto/qquickpopup/tst_qquickpopup.cpp Change-Id: I7e5a7b39d890796fd63a7b24ae19765ab41fecda
* Rename tst_applicationwindow to tst_QQuickApplicationWindowJ-P Nurmi2017-09-2713-0/+1876
Change-Id: If9fc2bb41cf251af71479b25656240e0d3c238d8 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>