Commit Graph

68765 Commits

Author SHA1 Message Date
Assam Boudjelthia
cae4dd01a8 Android: Skip "Build APK" for non-app builds
For projects using Qt 5.15 and Qt 6, the deployment settings
file is generated by CMake/qmake and not Qt Creator, so if
such file doesn't exist or it's been generated by Qt Creator,
we can assume the project is not an android app.

This is mainly a workaround for now to avoid a more involved
fix which would need to potentially remove the method
AndroidManager::deploymentSettings() (and it's use cases) which
is used to generate a minimal version of deployment settings
file, which was added some time ago where the build system
CMake and Qt wasn't handling that generation, but now with Qt
5.15 and Qt 6, that shouldn't be a concern of Qt Creator.

Fixes: QTCREATORBUG-27167
Fixes: QTBUG-111334
Task-number: QTCREATORBUG-26888
Change-Id: I15657f3b67acc52c28c92e6af24668f778432a19
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-22 11:22:26 +00:00
Christian Stenger
c5818cfe6d Utils: Fix pathchooser handling for aspects
..especially when entering a path manually. Fixes some
soft asserts regarding the call guard and re-allows to
type a backslash directly to separate path from sub-path
instead of using wild workarounds like adding a dummy
character and adding the backslash before this.

Change-Id: I8cc8aaccf414d0fd9acc03d7c69e10ddd88dbfd9
Reviewed-by: hjk <hjk@qt.io>
2023-05-22 11:18:31 +00:00
Marco Bubke
90ea280b8e Sqlite: Update to 3.42
Change-Id: I7e4587b662d7623d084e020e20fcbb65bbeb54f0
Reviewed-by: Burak Hancerli <burak.hancerli@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2023-05-22 10:16:43 +00:00
Marco Bubke
f68421a53f QmlDesigner: Add move contructors
Because of adding a default destructor is removing the move construtor
we add default move contructor.

Change-Id: Ic253e3173956389b11c0aa04204ea27f00c0e9b3
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-05-22 10:14:03 +00:00
Marco Bubke
be824148be Sqlite: Improve transaction by inversion of control
Using a callable makes it possible to omit the commit call. It is now
called by the withDeferredTransaction and withImmediateTransaction
function.

Change-Id: I9b7bfa7e32f269fe8fcba2fe5e1218e73f5846d1
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
2023-05-22 10:07:40 +00:00
Jarek Kobus
d8ed764611 TaskTree: Bring the documentation back
It vanished after recent move into Tasking lib.

Amends f84199f8b7

Change-Id: I561784c82285de41c2e29c257940678eeeccb5eb
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-05-22 09:51:51 +00:00
Jarek Kobus
c9638ff642 TaskTree: Fix docs about empty Group and different workflows
Add tests for empty Group with different workflow policies.
Add tests for successful / failing task in a Group with
different workflow policies.

Change-Id: I50129713f836d2146b119ceb73b5ae43abf01639
Reviewed-by: hjk <hjk@qt.io>
2023-05-22 09:22:38 +00:00
Eike Ziller
355589f4c2 Fossil: Remove unused variable
Change-Id: I4a55ccacc6daccab653666c943f6aeb931e11c89
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2023-05-22 08:57:30 +00:00
hjk
dfcfea478e PerfProfiler: Re-organize general command line construction
... to avoid unnecessary argument splitting.

Also, make a potentially missing access to the settings
more noticeable to the user.

Task-number: QTCREATORBUG-28701
Change-Id: I7b7f7f5f6a68357dbec064516370bacbf00746dc
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-05-22 07:56:51 +00:00
Eike Ziller
07934fadcf Examples: Use Qt logging instead of environment variable
Use logging category qtc.examples instead of a custom
QTC_DEBUG_EXAMPLESMODEL environment variable.

Change-Id: Idbd6d4b29dbd7b9e8c5976eca6efeb232bf7fa5f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-05-22 07:42:13 +00:00
hjk
d0881f5542 Utils: Remove a unused aspect ctor parameters
Change-Id: I6e3c6ce7b04a7817f35da10f1975ae2fec62b9e4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-05-22 07:16:23 +00:00
hjk
d740a355bb Utils: Rework CheckableMessageBox
Remove function overloads, thes are hard to read, to use and to extend.
I'd even argue this should be a plain default ctor and a few setters +
exec(), pretty much like Process::start() nowadays.

Move "decider" magic into a structure that can be filled ad-hoc outside
checkablemessagebox.cpp paving the ground for:

...removing  aspect dependency from CheckableMessageBox, Instead, add a
convenience function to BoolAspect.  Arguably, the latter is not needed
and could be done on the user side.

Use pointers instead of mutable references for in-out parameter.
Makes the "specialness" visible on the user side.

Pass ICore::settings() centrally as done elsewhere to reduce line noise
on the user side.

Change-Id: Ibb366353d1ea35401723fd05ce05672617a0a8fd
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-05-22 06:40:13 +00:00
Marcus Tillmanns
c0ebf227a7 ProjectExplorer: Fix inverted if statement
Change-Id: I94c9d8d5ff335ee53002fdb1ea75ca882e858d71
Reviewed-by: hjk <hjk@qt.io>
2023-05-22 06:02:28 +00:00
Assam Boudjelthia
e6875aa01e Android: don't stop deployment if kit's abis list is empty
If the kit's detected abis list is empty for some reason,
avoid blocking the deployment process.

Fixes: QTCREATORBUG-27103
Change-Id: I9e7b01c123666f087c6d48e56af6e6637e147442
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-05-20 08:14:12 +00:00
Jarek Kobus
c098b261dc TaskTree: Refactor Group internal data
Introduce the GroupData structure. In this way it's easily
possible to add extra properties of already used types, e.g. int.

It's also possible to easily create elements with multiple
properties.

Simplify internal TaskItem::Type enum.

Get rid of special ParallelLimit and Workflow elements.
Provide global parallelLimit() and workflowPolicy() functions.

Make global items (e.g. parallel, stopOnDone, etc...) const.

Change-Id: Ic5628255b542fd6c5a5565b055ff11804c8d7b68
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 15:30:15 +00:00
Jarek Kobus
56fda87389 TaskTree: Get rid of OnGroup... elements
Change-Id: Id1b600999d2051eff8d2207db8235ad08eb6e663
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 15:30:04 +00:00
Jarek Kobus
0793b945f3 TaskTree: Replace usages of OnGroup... with onGroup... functions
Change-Id: I06ce6c917ac28b6362ad2cdef42355e5aa28f4eb
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 15:29:55 +00:00
Jarek Kobus
04382d39a0 TaskTree: Introduce onGroup...() functions
The OnGroup... elements are going to be replaced with
these functions.

Change-Id: Ia271a89062cc9c6b18384607b20b1f68d273bcde
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 15:29:42 +00:00
Jarek Kobus
ceff14303a TaskTree: Prepare for OnGroup... -> onGroup... renaming
Change-Id: I52b695999b53b80fb8dbb77895080f6c1b86a58f
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 15:29:35 +00:00
hjk
6f31d87444 Use more FilePathAspect
Change-Id: Ib348df1460f8610607251498b07010df58d51ddf
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-19 15:07:17 +00:00
hjk
0c425540de Fossil: Replace one qAsConst
Change-Id: Ia03f9aa81d41e03b9611da823c6999082d243864
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-05-19 14:52:48 +00:00
hjk
c597961d7d Beautifier: Simplify GeneralSettings implementation
Change-Id: Ib8b8f0b1cab3d9bbacf24009c0bd546660c19906
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-05-19 14:37:35 +00:00
hjk
40d7fcc1d4 Utils: Remove check against 'autoapply' for some volatile aspect value
This was based on the wrong assumption that on !autoapply aspects
(i.e.  aspects in settings pages the non-applied value would never be
needed by user code. This is, however, not the case when e.g.
temporary checkbox states or values in comboboxes are used to
enable/disable parts of the ui while interacting with the page.

Change-Id: I4fe6a0df8137083a0a0faecc3ba20792caa5a747
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-19 14:32:40 +00:00
Alessandro Portale
b1b9f54de7 WebAssembly: Make caching code less cryptic
Change-Id: Ib768e6f41fe8c5218875287dd0e60c76cbe0053e
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 14:03:34 +00:00
hjk
22af1a0255 Core: Even terser layout setup for option pages
Change-Id: Id39c841da70c87d47c125903b390a75c4414cc2f
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-05-19 12:35:30 +00:00
hjk
d4cf9b667b Conan: Simplify plugin setup
Change-Id: Ic60d2626384c2d15b81614f51db447a197640156
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-05-19 12:35:05 +00:00
Ali Kianian
c9649513d1 QmlDesigner: Show texture id in the Material Browser
Task-number: QDS-9051
Change-Id: I98ba9d9e4dd26d616a0fd3186539ad6aeb23a842
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2023-05-19 12:28:01 +00:00
Ali Kianian
5b8d79e7a7 QmlDesigner: Consider DockWidget size in floating mode
Task-number: QDS-9836
Change-Id: Ic7f95b8feb757c021a88110b7d529b1720fe83d0
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2023-05-19 12:25:28 +00:00
Alessandro Portale
b0f68a916f Vcpkg: Use Utils::FilePathAspect
Change-Id: I7532536186d500748e3ad30794801436c0a997e2
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 10:32:11 +00:00
Alessandro Portale
5acecd4ef9 WebAssembly: Base Settings handling on Core::PagedSettings
Change-Id: If28afd8046367eb1b8b12e54d2dae4235dbc821f
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 09:55:30 +00:00
Jarek Kobus
7501d7587f TaskTree: Introduce WorkflowPolicy::StopOnFinished
The policy is useful mainly in parallel mode.
It stops executing the Group when any task finishes.
It reports the task's result.

Change-Id: I7aa98365cdc4c1eb869ab419d42d0cc5438d43bf
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 08:40:24 +00:00
Jarek Kobus
7bfc3197aa TaskTree: Add missing include
Amends 9c78ef983a

Change-Id: Id912771b2d23c6856233705a054c0e8e1e9b5a41
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 08:33:16 +00:00
Jarek Kobus
3763370ab9 TaskTree: Add Q_DISABLE_COPY_MOVE() into internal classes
Change-Id: I1b599902dfeebed93378a4d38bd3deb786f572b9
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 07:38:59 +00:00
Jarek Kobus
c603e01535 TaskTree: Don't derive TaskNode from QObject
It reduces the time spent inside TaskTree::setupRoot()
by ~30% for big trees (~7000 tasks).

Change-Id: Ic65ed0fdf511977d9cc2fe22bdac814516e9883d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 07:34:38 +00:00
Jarek Kobus
5ae82a88cf TaskTree tasks: Make task naming consistent
Task-number: QTCREATORBUG-29102
Change-Id: I96dfde58b684a3b48704778b92cdf2f869bbb7b1
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-05-19 07:29:10 +00:00
Jarek Kobus
376c1cf246 FileStreamWriter: Add some comments into d'tor
When d'tor of the parent Async<void> runs, it busy waits
for the WriteBuffer's thread to finish, and afterwards
QObject's d'tor deletes the child WriteBuffer object.

Change-Id: Ifc696b3e56735e697d8c54c2471f89e323d3c0d1
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-05-19 07:23:57 +00:00
Jarek Kobus
2b174a763f FileStreamer: Reuse TaskTree::runBlocking()
Reuse it also in FileSystemAccessTest.

Change-Id: I6ce1c926bd5d3a617b8badb0905e7b2fd58b4745
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-05-19 07:17:46 +00:00
Jarek Kobus
9c78ef983a TaskTree: Add runBlocking() helpers
To be used in non-main threads and in autotests.

Change-Id: If37be854f65c9cfe94eb781a28dc8db4365809e1
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-05-19 07:16:48 +00:00
Alessandro Portale
caad8074de WebAssembly: Prevent null pointer access
The detector.device can be nullptr

Amends: cacc4aeede

Change-Id: I5b9b6aa722c8e6e8a96d05cdf2f1b214735db858
Reviewed-by: hjk <hjk@qt.io>
2023-05-17 15:37:16 +00:00
The Qt Project
7057962e44 Merge "Merge remote-tracking branch 'origin/10.0'" 2023-05-17 14:23:50 +00:00
Christian Kandeler
aa5ddaf412 ClangCodeModel: Let user decide how to do the header/source switch
While clangd's AST matching can find source files at any location, it also
has a number of annoying bugs that break the functionality for some
users. This patch brings back the previous "try built-in first" logic, but
also lets users choose their preferred backend.

Task-number: QTCREATORBUG-29175
Change-Id: I6b854ed05652e6468509e5748a83a8f9bf76fc20
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-05-17 13:52:40 +00:00
Jarek Kobus
5abb1959c5 ScopedTimer: Make it possible to provide optional message string
When optional message argument is provided, both macros
print the message instead of __FILE__ and __LINE__ info.

It helps to ease the identification of the exact place in code
when many macros are added - custom message may be more
informative that the file and line location.

Change-Id: I7a3ccbdaca2858b44dcbd51a8f9330160dab73e9
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-05-17 13:43:32 +00:00
hjk
5ad790d5c8 FakeVim: Maintain highlighting on split
Fixes: QTCREATORBUG-28914
Change-Id: I4e0b82e49bd97f19eb513f21e1dc405ea9f0700c
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-05-17 13:24:41 +00:00
Eike Ziller
8e8ebc8f88 Merge remote-tracking branch 'origin/10.0'
Conflicts:
	coin/instructions/build.yaml

Change-Id: I697b0107e75c6259989247de2180437d7987ff37
2023-05-17 14:55:02 +02:00
David Schulz
b2e30e7ef8 Utils: add Position::fromCursor with tests
Change-Id: I1cd989eaf7e75bc04f171989f9f9fe932402abef
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-05-17 12:53:22 +00:00
Eike Ziller
2cd2324963 CheckableMessageBox: Simplify checkbox setup
If the dialog is shown, the checkbox must be unchecked, because
otherwise the dialog would not have been shown.

Change-Id: I34e8034975baef710997e0cdb3c7d2f8b0c94cd2
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-05-17 12:13:34 +00:00
Christian Stenger
8121575067 Core: Fix item view find
...when there is only one matching item and we are starting
search from there.

Change-Id: Icfffd37d9330c83058fb81356762e72b183f24e8
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-05-17 11:40:01 +00:00
hjk
95d21f3966 Use new FilePathAspect in a few more places
Change-Id: I910a802255c8d54a31313dcccb0d1a48ec577b7a
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-17 11:22:48 +00:00
Eike Ziller
a928fee108 Separate session loading from project manager
Move the generic parts to session manager and let the project manager
load its parts separately.

Change-Id: I14ee3311ab0c0f40444674b82cee1e4bb0fb9daf
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-05-17 11:07:21 +00:00
Eike Ziller
b512f414bd Session: Minimize direct use of reader when loading sessions
Instead of directly reading things like the project list from the
reader, add a map of "session values" in the session and read these from
the reader once, then use the session to access these values while
loading the details of the session. This is in preparation of separating
the session loading from projectexplorer.

This is similar to Session::(set)Value. We cannot use the same
(set)Value methods directly though, because of differences in the
handling of these values during implict and explicit default session
loading.

Change-Id: I9a4f38a9f958734d20d6e6eb7253f9e44ba1285e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-05-17 11:04:55 +00:00