Commit Graph

80147 Commits

Author SHA1 Message Date
Miikka Heikkinen
df622c9c3c QmlDesigner: Fix expand all and collapse all in content library
Fixes: QDS-8413
Change-Id: I98931c52f63bbbfd7a42e522a762d77b469df5da
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-12-09 13:27:25 +00:00
Jarek Kobus
1caade7333 VcsBase: Get rid of RunFlags::SilentOutput
In theory in was used only when we passed a non-null
editor together with CommandOutputBindMode::ToVcsWindow
into VcsBaseClientImpl::createCommand(). But there was no
such a case in the whole codebase.

Change-Id: I4b1162141e0849b49c12ee464e635debb62d5353
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-09 13:24:45 +00:00
Jarek Kobus
8d7ced7d83 VcsBase: Get rid of CommandOutputBindMode
Simplify createCommand() implementation. All callers
passed either non-null editor (in this case the
bindMode was always NoBind) or passed a null editor and one
of two values for bindMode (in this case the only
effect was to add (or not) a RunFlags::ShowStdOut flag).

Drop CommandOutputBindMode enum completely and pass
directly RunFlags::ShowStdOut when needed (i.e. in cases
we were passing CommandOutputBindMode::ToVcsWindow).

Change-Id: Ic3af05818933a03f615ba02267403b9f0bd326ba
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-09 13:24:34 +00:00
The Qt Project
e65e5243f8 Merge "Merge remote-tracking branch 'origin/9.0' into qds/dev" into qds/dev 2022-12-09 13:07:47 +00:00
Jarek Kobus
834f89acf2 Remove unused variables
Change-Id: I653f6fa71bb04e049d4e1848a7e38a606692e678
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2022-12-09 13:01:53 +00:00
Amr Essam
944ba4a5be QmlDesigner: fix adding effect to 2D does not work on windows
Effect cannot be added in windows, during to latest changes in QDS-7344
The QFileSystemModel::dataChanged doesn't emit with some file types
So I used Utils::FileSystemWatcher for watching files changes

Task-number: QDS-8452
Change-Id: Id381a78556a3dad56268cec506a0182d4343f0a2
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2022-12-09 12:41:04 +00:00
Jarek Kobus
4ff34cf47f TaskTree test: Use storage for getting the result from task tree
Remove storage() test case, as Storage functionality is fully
tested in processTree().

Change-Id: I05c199cf4cfa2a77493ce54df267b8ed1c2804bc
Reviewed-by: hjk <hjk@qt.io>
2022-12-09 12:09:23 +00:00
Jarek Kobus
7fc9933969 TaskTree: Add a possibility to setup storage handlers
Storage handlers make it possible to pass initial data
into task tree and make it possible to retrieve the output
data from task tree after the task tree finished.

Change-Id: I0bcc12f5e552f55c1d5d89b81521ae9cb7b8b124
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-09 11:47:52 +00:00
Jarek Kobus
dfdeb4d630 TaskTree: Ensure the same storage isn't added twice
Change-Id: I780d61091fea39a4542b4f743593b5062a784ba5
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-09 11:45:26 +00:00
Jarek Kobus
8aa7ec1072 TaskTree: Add hash function for TreeStorageBase
Change-Id: Ia9242e3ca90ab13ee93fa42ebf86d03cc04fb669
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-09 11:44:22 +00:00
Jarek Kobus
cb8d4797b7 TaskTree: Add TreeStorageBase::operator==
Change-Id: I50144978b86f2e5fa89fc35c687b64ed102803e6
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-09 11:42:49 +00:00
Jarek Kobus
162c8f71d3 GenericBuildSystem: Don't store unused expander
The default value of expander = project()->macroExpander()
was never used, as later it was always overwritten.

Change-Id: Iafaa491c4fb68aa6b9153a3647f6470a2aa293e8
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-09 11:40:56 +00:00
Jarek Kobus
fc6b7996b8 Debugger: Pass context object to lambda connections
Remove some unneeded lambda () brackets.
Glue lambda brackets with parameters brackets.

Change-Id: I5df67cf01e497ad39c070a3f138a647762f2c33c
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-09 11:36:09 +00:00
Jarek Kobus
448471a399 VcsBase: Ensure context not null inside vcsExecWithHandler()
When passed context is null use VcsBaseClientImpl as a context.

Amends 287a7c9268

Change-Id: I5817d74207683ae000fc2662920af2d1ff23d5ea
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-09 11:28:29 +00:00
Jarek Kobus
2596f39823 VcsBase: Fix connection in revertAll()
The original intention was to connect to done signal
of the executed command.

Change-Id: I35e1f931a54bf763c3d9ffc71237b1d96cda1343
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-09 11:24:27 +00:00
Artem Sokolovskii
c0f3ef9a82 ClangFormat: Refactor for remote file system support
Change-Id: If44af32e2b3534fb350de9c657b99edd6bb6923a
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2022-12-09 11:17:05 +00:00
Artem Sokolovskii
69abc39aea CodeStyle: Fix save settings without applying
Change-Id: Iebe4c4fb6f3279592e7933981aba69087db558f9
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-12-09 11:17:00 +00:00
Marcus Tillmanns
26f07c62a0 Core: Remove unused Key
Change-Id: Ic3e9e7b994e010fe1b65b8273e74124dc957bdef
Reviewed-by: hjk <hjk@qt.io>
2022-12-09 11:15:39 +00:00
Christian Kandeler
cd12930953 ProjectExplorer: Fix unrelated tooltip appearing
... on clicking into the locator widget.
This removes a workaround for a different problem which is much less
visible. Real solution to be implemented later.
Amends 4c1b3c863c.

Change-Id: I7e7902c90367c8ed59af4e5aabaf5514207b00de
Reviewed-by: hjk <hjk@qt.io>
2022-12-09 11:15:16 +00:00
Jarek Kobus
112835922a VcsBase: Reuse CommandOutputBindMode instead of bool
Reuse it inside vcsExec() and vcsExecWithHandler().

Change-Id: I6ff4044bf43e0883fc46a49718f5f44da87a7e13
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-09 10:29:51 +00:00
Jarek Kobus
46213c82be GitClient: Simplify vcsExec
Get rid of editor arg.
Reorder last two args (to conform to vcsExecWithHandler).

Change-Id: Ia32757ac8b766640b76bef81f1b2e0f5efe4d48c
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-09 10:29:36 +00:00
Jarek Kobus
0cdfac0cb5 GitClient: Introduce execWithEditor()
Change-Id: I3a7edde4b978cb8e99fe0020d69a0a5e3e09c0fb
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-09 10:29:23 +00:00
Jarek Kobus
287a7c9268 VcsBase: Introduce vcsExecWithHandler()
Before, vcsExec() returned already started VcsCommand.
Later, callers of vcsExec() were establishing connections
to the retured VcsCommand::done() signal. However, when
process fails to start (e.g. because of non-existing
executable), the done() signal may be emitted synchonously
from inside VcsCommand::start(). In this scenario
callers of VcsCommand could miss the emission of done()
signal and connect to already finished command.

Instead, provide a vcsExecWithHandler() function which
takes a handler to be called when command finished.
In addition it takes the context object, too.
Don't return VcsCommand from vcsExec() anymore.

Change-Id: I2fb5fbe5d27632ea039c650d37e5d7d1b60cebc0
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-09 10:29:04 +00:00
Mats Honkamaa
e990b828a9 Doc: Document password protection function for shared online apps
You can now password protect applications that you share online.

Task-number: QDS-8538
Change-Id: I856946de3407d1e0b833a8cbf8c3e881ae45414c
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2022-12-09 10:18:00 +00:00
hjk
c08317b5a6 Utils: Remove slash normalization in critical path
Should be done by callers, most notably fromUserInput

Change-Id: I0dec8e3ab76d49d0ddf4da3088499e71c536ab83
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-09 09:24:43 +00:00
Eike Ziller
823eafcda9 Add change log for 9.0.1
And move change log for 8.0.2 to the right location

Change-Id: I135018524eccb3601d6371558c07a8a07d963c94
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2022-12-09 09:13:44 +00:00
Marcus Tillmanns
b3f82887a3 Utils: Change browse button to OptionPushButton
Allows the user to choose whether he wants to browse local files,
or remote files.

Change-Id: I0d262034a5c2df56bea2efca876c9019099e3da9
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-12-09 08:59:13 +00:00
Burak Hancerli
59505310a5 QmlDesigner: fix QDS does not quit when closing it while Splash screen is open macOS
Setting modality prevents the window closing even the mainwindow
is being closed.

Task-number: QDS-8540
Change-Id: Ifa2b185c0548128b35ba680d2bc8bf8c856d7c37
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2022-12-09 08:52:29 +00:00
Jarek Kobus
36be7b8375 Utils: Don't call mutable expressions inside QTC_ASSERT
In order to conform to the theory: "Removing all
QTC_ASSERTs and QTC_CHECKs should not change anything".

Change-Id: I6f5c4486afb422301562d79c662fdde026e4d788
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2022-12-09 08:10:17 +00:00
Jarek Kobus
a6b17d127a VcsBase, Git: Don't use queued connections to VcsCommand
Otherwise, the destructor of VcsCommand could have been
executed in meantime (since it's invoked automatically
after done()) and we might access invalid pointer to the
command inside the done handler.

Change-Id: I031e2281952451d4e01c47f437097a1e7bf8899f
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-08 20:54:49 +00:00
Jarek Kobus
533d969735 GitClient: Remove unused connectRepositoryChanged()
It wasn't implemented, neither.

Change-Id: Ic6cdf70e10b232d326dcc936337a38488adca0ac
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-08 20:54:32 +00:00
Marcus Tillmanns
7d573cfa0b ProjectExplorer: Fix test crash
actionBar can be smaller than statusBar during auto-testing,
which results in a negative value being used in qBound(), which triggers
an assert if min is bigger than max.

Change-Id: I40044cc1d6ded3c7b5e55a9bf93f88a52341237f
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-08 16:21:26 +00:00
Thomas Hartmann
56450a8fe6 QmlDesigner: Update application template for QDS projects
This updates the application template to download
the designer components.

* Added a cmake configure option BUILD_QDS_COMPONENTS
* We use the qds-3.9 branch of qtquickdesigner-components

Change-Id: I046e2c7e648fe9d3cb6cf8d2cec8eb606432bccd
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2022-12-08 15:54:26 +00:00
Jarek Kobus
d0e24654f6 CMakeProjectManager: Pass context object to lambda connections
Remove some unneeded lambda () brackets.
Remove some unneeded lambda return type specifiers.

Change-Id: I9695367d66a151f2611554b9fe5897c1bac7ef5c
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-08 15:28:50 +00:00
Jarek Kobus
6a7f5be0ea PluginGenerator: Fix returning the error message
I bet the original intention was to return a new message,
so we should assing a new value into the passed pointer
rather than change the local copy of a pointer so that it start
pointing to the local variable.

Amends aaa8beab88

Change-Id: I1fdc8f3f4ea43e4814f02dbf615ad128bfc9a059
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-12-08 15:16:15 +00:00
hjk
9e7743494c Utils: Use some of the FilePath convenience functions in FileCrumbLabel
Change-Id: I79f6b52847106bab22454f032407eb6866012362
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-12-08 14:49:03 +00:00
Christian Kandeler
4c1b3c863c ProjectExplorer: Add "Generate" sub-menu to build menu
Preparation for adding more generators.

Task-number: QTCREATORBUG-28149
Change-Id: I4afa183a6fbd8ee88fc978b382f28cf9e52f09e9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-12-08 14:34:52 +00:00
David Schulz
6d8f6ab395 LanguageClient: robustify renaming symbols
Guard against using a symbol support from a deleted client. Additionally
cancel active replace operations and provide a sensible error message.

Change-Id: I92ca0038fa5f6acbb8369a48c4e8051adfadb30e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-12-08 14:27:29 +00:00
Jarek Kobus
154e3df17e CppQuickFixes: Fix possible null dereference
It may happen that we dereference null inside the following
condition:

  if (declarator->postfix_declarator_list)

This may happen in case we entered the "if (!declarator)"
condition, but didn't fulfill the nested
"if (path.at(n - i++)->asPointer())" condition.

Detected by clazy analyzer.

Change-Id: I47135bc5648459e91664a4f65f9752b58248a496
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-08 14:10:53 +00:00
Jarek Kobus
b0e6943491 TextEditorWidget: Ensure non-null source is passed to insertFromMimeData
Detected by clazy analyzer. The possible context was
TextEditorWidget::dropEvent(). In some branches we ensure
that mime is not null, but later we call insertFromMimeData()
unconditionally.

Change-Id: Iee5138bc19d405050eafc9617d3c2ed123b767c7
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-12-08 13:52:12 +00:00
Jarek Kobus
55ba10be38 RemoteLinux: Pass context object to lambda connections
Change-Id: I025c588e7d32be0f940b74acf9421965073cff5c
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-12-08 13:51:06 +00:00
Mahmoud Badri
d0c9bc76cb QmlDesigner: Update textures sources on state change
Also small relevant fixes.

Fixes: QDS-8523
Change-Id: I8125b124024ee18de8c70afbc9f633c3b9265e82
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2022-12-08 13:49:21 +00:00
Jarek Kobus
b67201c410 Git: Simplify ConflictHandler
Don't create QObject instance when handling conflicts.
Operate on static functions only.
Replace destructor of ConflictHandler with finalize() method.

Change-Id: If579edc6213faa50c73a90cedf4b67cf985478ac
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-08 13:46:59 +00:00
Jarek Kobus
f9800bb790 ClangTools: Pass context object to lambda connections
Remove some unneeded lambda () brackets.

Change-Id: I502eb5cd89505fb77c02abf44b7ce19541a8ac2f
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-12-08 13:46:41 +00:00
Aleksei German
37564d267b QmlDesigner: Fix Connections status in ContextMenu
Task-number: QDS-8521
Change-Id: Id0b835fb14b18563d4ecc0c1b2039b9bb181c32c
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Aleksei German <aleksei.german@qt.io>
2022-12-08 13:22:37 +00:00
Miikka Heikkinen
636c9524f9 QmlDesigner: Work around the issue in QtQuick3D 6.4 geometry caching
QQuick3DGeometry::updateSpatialNode can create QSSGRenderGeometry
object with exact same address as a previously created and subsequently
deleted QSSGRenderGeometry object (i.e. the memory location is reused).
If the previous node was not used for the exact same logical geometry,
then you get these artifacts, as QSSGBufferManager uses
QSSGRenderGeometry object pointers in QSSGBufferManager::loadRenderMesh
function to determine if it needs to reload the geometry and what
geometry gets used for each model. The cache still contains data for
the deleted node, which is then matched for the new node with same
address.

This workaround ensures that none of our grid geometries will have the
same generation id and thus will never get improperly matched in
QSSGBufferManager cache.

Task-number: QDS-8516
Change-Id: I017a4ae4a59eef2bb26ade5abf13e8f74f57c4af
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-12-08 12:40:07 +00:00
Cristian Adam
6bef53a818 PE: Add ability to skip vcvarsall.bat /clean_env
By defining QTC_NO_MSVC_CLEAN_ENV one can skip the vcvarsall.bat /
clean_env functionality.

Task-number: QTCREATORBUG-28561
Change-Id: I6392b2278008607042a43a38a2c38669b4b52183
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-12-08 12:21:26 +00:00
hjk
b354421f27 CppEditor: Use FilePath in fileSizeExceedsLimit()
... and adapt caller side.

Change-Id: Idd832101962dcdc8b24f96bebbdb77fd3e29ba7c
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-12-08 12:07:45 +00:00
Mahmoud Badri
e70f909bcf QmlDesigner: Update texture editor and browser after source reset
Fixes: QDS-8520
Change-Id: I9ceca64d75ef1c41633a89a79748265beecd16ea
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Ali Kianian <ali.kianian@qt.io>
2022-12-08 11:32:08 +00:00
Jarek Kobus
5c86f58bdd Boot2qt, Qnx: Pass context object to lambda connections
Change-Id: I64c5ed32035f161920a7ba08fa67de7bee6653a3
Reviewed-by: hjk <hjk@qt.io>
2022-12-08 11:28:24 +00:00