Commit Graph

62421 Commits

Author SHA1 Message Date
Orgad Shaneh
da0cb254b2 CMake: Support Build File also from header files
Fixes: QTCREATORBUG-26164
Change-Id: Iaa2fdd34cffad07be668ca7142a8ffa2c373d325
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2022-10-12 17:28:49 +00:00
Eike Ziller
9908f623f6 FilePath: Fix sdktool build
Change-Id: I0f8b2c8b3fb36580ee95d439d8034397e42eec1f
Reviewed-by: hjk <hjk@qt.io>
2022-10-12 15:42:11 +00:00
Piotr Mućko
9b47b1575a McuSupport: 3rd party packages creation tests
Change-Id: I0f9ed6c49b28007c617627525fc081ae9152e3f1
Reviewed-by: hjk <hjk@qt.io>
2022-10-12 14:50:41 +00:00
Marcus Tillmanns
a0af1fa927 Utils: Keep User specified SideBar entries in file dialogs
Change-Id: I0b218e889f351a2dc635aca147b82d752ba85205
Reviewed-by: hjk <hjk@qt.io>
2022-10-12 13:41:09 +00:00
Marcus Tillmanns
34fbf6261a FileUtils:: Support non-native filedialog
Change-Id: I71797a31c58f0870a95ac396404721b004741115
Reviewed-by: hjk <hjk@qt.io>
2022-10-12 12:43:28 +00:00
hjk
e8eaf7809b Utils: Don't crash on empty 'find' output
Change-Id: I772718d882ac7744c4f955190b038cd1e78f347d
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2022-10-12 12:24:11 +00:00
hjk
b1471fe61f Utils: Combine some of the iterateWithFind overloads
Change-Id: I668447d0049f2e35cd0c76d2c5708779196167ec
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2022-10-12 08:59:32 +00:00
Christian Kandeler
48755cf7fd Revert "ClangCodeModel: Rename via LSP facilities"
We cannot use clangd's rename facilities yet, as there is a
hardcoded limit of affected files.
This mostly reverts commit 7dc2c6b3b3.

Change-Id: Ie441796569b533948cc028c867175d6f9d4b9d54
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-10-12 08:57:47 +00:00
Marcus Tillmanns
e18bd4b0f8 FSEngine: Invalidate cache after creating a file
Since QFile::open can change the "exists" info of a file,
we have to invalidate the cache entry for the file.
Otherwise code like:
  QFile f(...)
  f.open(QIODevice::WriteOnly);
  f.exists();
might fail the exists check even though the file was created

Change-Id: If80eaf4a5b131cfe7ea4e506292870741c46fff7
Reviewed-by: hjk <hjk@qt.io>
2022-10-12 08:55:54 +00:00
Jarek Kobus
c97cb8b50c MesonProcess: Fix process restart
It looks like MesonProjectParser::m_process may be restarted
directly from process' finished() handler - inside
MesonProjectParser::processFinished(). In this case
the process is directly deleted from its signal handler.
Fix it by releasing the old process and deleting it later.

Don't pass process reference to the other thread when
calling runAsync(). Pass the copy of standard output instead.

Change-Id: I163a3cc86fbdbe8a3d9a19c479f96017f5803f76
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-10-12 06:56:57 +00:00
Christian Stenger
6c362a259c Squish: Fix condition
Amends 5c4441a760.

Change-Id: I1e4148196c6e904d62fd4ce160db517c9c75d1e9
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-10-12 06:27:14 +00:00
Christian Stenger
9ae0399722 Utils: Fix build before Qt6.2
FilePath is used from sdktool as well.
Amends ae58d373b0.

Change-Id: Ia4846b7f8a91fa503c5039c44e65ba21e84e9319
Reviewed-by: hjk <hjk@qt.io>
2022-10-12 06:26:15 +00:00
Orgad Shaneh
e141b9cea3 ExecuteFilter: Update window title when done
The command can change the active branch.

Change-Id: I6fd026e29f8e972e694c249b47e106bfdef783a7
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-10-12 06:15:04 +00:00
Orgad Shaneh
8c1cd7539c Git: Fix removing nested files
* Add -- before file list on add/remove.
* Run in the correct directory.

Fixes: QTCREATORBUG-27405
Change-Id: Ie04cd19981dac465cf70dba8b089fd18a4ecdf8b
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2022-10-11 15:32:13 +00:00
Orgad Shaneh
d2160e8b4f Git: Fix adding existing files in nested directories
Amends 48c56416f5.

Fixes: QTCREATORBUG-27644
Change-Id: I4ef58c017e4fcf8fa48905f7e0b649433b3cac0f
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2022-10-11 15:31:54 +00:00
Jarek Kobus
693db6eef6 UnifiedDiffEditor: Fix '+' on added lines
Amends 15fd4a0754

Change-Id: If74b5437be241303de1e157b7980ef10ef6c060c
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-10-11 14:34:25 +00:00
Orgad Shaneh
aa4f5249a5 Utils: Remove unused include
Change-Id: Ifa40f55444d31d74707b247d6bb471114cc9bb0c
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2022-10-11 14:33:51 +00:00
Jarek Kobus
c50891611a FilePath: Fix absoluteFilePath to behave like absolutePath
Change-Id: Ibb2cba32c40ec9febab5f20c78156481525c8904
Reviewed-by: hjk <hjk@qt.io>
2022-10-11 14:33:35 +00:00
Orgad Shaneh
82b2b2cae9 VCS: Fix misuses of parentDir().absolutePath()
absolutePath() *is* the parent directory.

Change-Id: I59f2c4ae65b265270d432f381258b95c65e53581
Reviewed-by: hjk <hjk@qt.io>
2022-10-11 13:49:50 +00:00
Christian Stenger
5f4612dd07 Squish: Fix handling of object map
Fix resolving the path to the object map and if no
object map exists yet create it.
As on it fix a typo inside the writing of the file.

Change-Id: I832a2f71bbf5c5d4947e3edba8f79a00a3b6a536
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-10-11 13:10:01 +00:00
Christian Stenger
5c4441a760 Squish: Move some helper functions
Allow to reuse them.

Change-Id: Ia13f7f6c7a40066fd7ae46389adc7c9228161a4a
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-10-11 13:09:56 +00:00
Marcus Tillmanns
d74c5301ff Linuxdevice: Add FilePathInfo functions
::filePathInfo and iterateDirectory(..., IterateDirWithInfoCallback, ...)
allow for faster info retrieval by the fsengine, making the listing
of large directories like /bin a lot faster.

Change-Id: I2a21e019e05f5bb08459483747ba2be4530929f4
Reviewed-by: hjk <hjk@qt.io>
2022-10-11 13:09:26 +00:00
Jarek Kobus
39258f5522 QtcProcess: Get rid of setResult()
This isn't meant to be called publicly.

Change-Id: I1a5e5325ac268e1bbfcc34c529cfc3c7e628243c
Reviewed-by: hjk <hjk@qt.io>
2022-10-11 12:34:48 +00:00
Marcus Tillmanns
bcadbe666b Docker: Fix mount arguments
Previously when trying to mount paths that contained spaces or colons
docker create would fail as the -v/--volume syntax does not support
these.

Switching to "--mount" and using the "type=bind" syntax allows to
escape the necessary characters.

Change-Id: If969173505dbf1b36a67dc8b398c58b78941519a
Reviewed-by: hjk <hjk@qt.io>
2022-10-11 12:24:29 +00:00
Christian Stenger
f1fe30ee16 Help: Restore some more object names
Change-Id: I4742d855bc69be3622f823a3d3efe256ad027dc5
Reviewed-by: hjk <hjk@qt.io>
2022-10-11 11:55:49 +00:00
Orgad Shaneh
b81e295f58 Toolchain: Support also concatenated syntax for MSVC included file
For example: /FIC:/Projects/test/config.h

Change-Id: I18dcda6593effa58ece019ce40bca7860cebfc8c
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-10-11 11:32:46 +00:00
Cristian Adam
c1667f9bea CMakePM: Allow default build configurations for presets
Restrict the build types only if CMAKE_BUILD_TYPE or
CMAKE_CONFIGURATION_TYPES cache variables are set.

Change-Id: Ib88dcd5d4a0fca86f86e95815edff1116f896324
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-10-11 11:21:46 +00:00
Cristian Adam
f84bdee045 CMakePM: Allow presets without buildDirectory
CMakePresets v3 relax the requirement of having the buildDirectory
specified.

This way Qt Creator should use its own mechanism of specifying the build
directory.

Change-Id: I6ba69e6a03cdc058e7b8fa540a6fc564356aba63
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-10-11 11:21:41 +00:00
Tasuku Suzuki
52672b5f6c SessionDialog: rename Switch To to Open and reorder buttons
To be consistent with the SessionNameInputDialog that has the button
"... and Open" to switch to a session.
Buttons should be ordered by like a typical file menu
- new
- open(ex- switch to)
- save(rename/clone)
- close(delete)

Change-Id: I875446352100500eaae4b0ecef4faa6442aef539
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-10-11 10:53:29 +00:00
Christian Stenger
5bb928c95f Core: Restore some more object names
Change-Id: I318eda7cfabf840e2fde3d11e77b489a99c43f62
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-10-11 10:51:22 +00:00
Orgad Shaneh
7c623f99d8 Git: Fix pattern for commit hash matching
* Avoid matching mid-word.
* Avoid matching after "mode ".
* Change to raw string literals.

Fixes: QTCREATORBUG-24768
Fixes: QTCREATORBUG-28268
Change-Id: I68abbf3de7928c60e0fe2d944adedaa6db94b1a4
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2022-10-11 10:00:53 +00:00
Marcus Tillmanns
ae58d373b0 Add FSEngine FilePath Cache
To speed up file dialogs we introduce a 1 minute cache for
the FilePathInfo.

A new version of "IDevice::iterateDirectories" allows implementations to
provide the FilePathInfo directly.

DockerDevice implements fetching the filePathInfo during
iterateDirectories which greatly improves the speed again.

Change-Id: I24ac16adb2478cbf16a22012e72fcb8910dcdac5
Reviewed-by: hjk <hjk@qt.io>
2022-10-11 08:53:02 +00:00
Miikka Heikkinen
007a9a46a5 QmlDesigner: Reset item library drag on model detach
Fixes: QDS-7823
Change-Id: If0b758f79dd4a55356d2cd5aefe65fa3e6e321be
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-10-11 08:40:40 +00:00
Jarek Kobus
f5f3bbcc59 Use more Utils::isMainThread()
Change-Id: Ia3c6f6dca53c5d7487b0813de16f06c52af47aa5
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-10-11 07:34:12 +00:00
Jarek Kobus
df2038421e MesonProcess: Remove unused methods, signals and fields
Change-Id: Ic1a25e3800b6938fc3cea23a02f582f1e73c058f
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-10-11 07:26:05 +00:00
Marcus Tillmanns
b7c1e70738 Fix: QtConcurrent build fix
Change-Id: I17df4132e6c0aaee35d9d92e5dc8651f553a58b7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-10-11 06:31:03 +00:00
Ari Parkkila
f50260837c Fix Boot2Qt Device dark theme on Windows
Fixes: QTCREATORBUG-28254
Change-Id: Ie146579d2e52b3336d326c69f864a3beecadee69
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-10-11 05:55:59 +00:00
hjk
19f2a95e1c Nim: Convert to Tr::tr
Change-Id: Iad4641479d566347ef9acdfb0a04f37907ac4a2d
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-10-11 05:48:46 +00:00
hjk
7eac686f29 BareMetal: Remove unused baremetalgdbcommandsdeploystep.{h,cpp}
Change-Id: I57cc268714844cf5f342f4ea169a1c0c32e8b9f9
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-10-11 05:47:47 +00:00
hjk
c4957f9fdb BareMetal: Convert to Tr::tr
Change-Id: I7ac423c13d95b33cad332d2ce9fafb4f658980bc
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-10-11 05:47:24 +00:00
hjk
a43619386b Nim: Inline nimcodestylepreferenceswidget.ui
Change-Id: I4590e6666bd37b428c443ef78731202100040a58
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-10-10 16:34:59 +00:00
hjk
2e38cb6848 Utils: Add an offset parameter to the content writing FilePath function
Use QFile::seek to implement locally and a dd seek based poor man's
implementation on RL and docker.

Change-Id: I241d1c34c00e991845d132ad8edefa1377ba1311
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-10-10 16:08:28 +00:00
Cristian Adam
05acf3e6f4 CMakePM: Do not display duplicated build paths for presets
If we configure a project with presets, build all the configurations,
then delete the CMakeLists.txt.user file to re-configure the presets, we
shouldn't get two entries in the initial configuration dialog.

Change-Id: I9bb234aa54fcce193dbd07dd3aa77e91f639b179
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-10-10 14:48:28 +00:00
Jarek Kobus
e54fb7ab64 Replace missing qAsConst with std::as_const()
Patch missing leftovers after recent batch patch.

Amends 8eb4d52342

Change-Id: I5469b8c10e6844cd1911f719ce3dddbb42697f95
Reviewed-by: hjk <hjk@qt.io>
2022-10-10 14:14:02 +00:00
Cristian Adam
213c879882 CMakePM: Skip default build types for CMakePresets
If a preset has a build directory set, that build directory and build
type should be displayed in the initial configuration dialog.

Change-Id: I884471cb4d482c92ab091a4043d642828318b4d2
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-10-10 14:09:04 +00:00
Miikka Heikkinen
b8f4cd97d1 Fix copying dynamic properties on materials
Fixes: QDS-7803
Change-Id: I24c8cd269965552a62fbbbc521efbff00811fa43
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-10-10 13:53:03 +00:00
Mahmoud Badri
b0fa747565 QmlDesigner: Add "imported" icon to the icons font
Change-Id: I100a382a549b1945d7c7e83de0a3ffa609b5148c
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2022-10-10 13:46:32 +00:00
Christian Kandeler
a0f356aed6 qbs build: Do not build QmlDesigner & friends
Too much maintenance effort for not enough gain.

Change-Id: Ica385bcc93da0dbc7af8e15c07fdd33580de29a7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-10-10 13:43:53 +00:00
Samuel Ghinet
7319eac283 Refactor Assets Library
Extracted the dialogs, the context menu, and the assets view into
separate qml files. Also, reordered some functions in the assets
library model

Task-number: QDS-7344
Change-Id: Ida21b60d30f34723c07b2659a138e14b95598421
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2022-10-10 12:00:23 +00:00
Marcus Tillmanns
ab9fd18af8 QtSupport: Parallelize qt info fetching
Change-Id: Idd3748f4a3a85b46db10ac0eb4f15567fcf4e896
Reviewed-by: hjk <hjk@qt.io>
2022-10-10 11:46:43 +00:00