Commit Graph

62421 Commits

Author SHA1 Message Date
Jarek Kobus
aa3f467ee2 ProcessInterface: Add readyRead() signal
And get rid of readyReadStandard[Output/Error]() signals.
Get rid of readAllStandard[Output/Error]() accessors, as
this data is passed with readyRead() signal.

Task-number: QTCREATORBUG-27358
Change-Id: I01341feba650e650761f97e90f83b6042c899251
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-12 14:00:14 +00:00
Jarek Kobus
4ca336762e ProcessInterface: Add done() signal
And get rid of errorOccurred() and finished() signals.
Get rid of resultData() accessor, as this data is passed
with done() signal.

Task-number: QTCREATORBUG-27358
Change-Id: I677bbd174cceea6d8f5a989f961222c417992b60
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-12 14:00:03 +00:00
Jarek Kobus
00acccfd3d QtcProcess: Fix terminate() for process launcher
ProcessLauncherImpl::terminate() was behaving the same as
ProcessLauncherImpl::kill() in case of process launcher
implementation - in both cases the launcher
immediately returned confirmation about receiving the
close request and was putting the corresponding
process into its reaper. However, the issue with this approach
is that we can't receive anymore any potential ready
read signal from the process being terminated after
a call to terminate().

The fix is to diverge the behavior of terminate()
and kill() of ProcessLauncherImpl. The behavior of kill()
remains the same, while terminate() just instructs the
process launcher to start termination without putting
the process into the reaper, yet.

Add a test that checks for any possible zombies.

We run the RecursiveBlockingProcess recursively. The most
nested process blocks. After a short wait we terminate
the outermost process. With this test we are trying to see
if terminating the middle process terminates also its
children and doesn't leave zombies.

Before we execute the test (and also by the end of this test)
we call Singleton::deleteAll() in order to ensure that reaping
of previously running processes has finished. We ensure the
number of running processtestapps is zero. Later, we ensure that
the leaf process was already started and the number of running
processtestapps equals the depth of recursion.

Fix apparent bug in getLocalProcessesUsingProc().

Change-Id: I7e2bc46ad5ca22f26620da86fbaf0fa00a7db3c3
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-04-12 13:59:41 +00:00
Christian Stenger
fea22eadb6 LanguageClient: Silence warning
Change-Id: Ia58f7620b553df196d5b6de2c8ff1593e5396897
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-04-12 10:52:40 +00:00
hjk
2ea397f11d QmlProjectManager: Avoid use of RunControl::runConfiguration()
The RunConfiguration might change and even die after the runcontrol
starts.

Change-Id: I628f3ae26c21fb41388b6104497ce5a6a6704c8a
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-12 08:46:42 +00:00
hjk
6db23acc1f TextEditor: Compile fix with current Qt dev
Most likely some .pch / NO_CAST_FROM_ASCII problem somewhere, but I got

  src/plugins/texteditor/storagesettings.cpp: In member function ‘QVariantMap TextEditor::StorageSettings::toMap() const’:
  src/plugins/texteditor/storagesettings.cpp:76:5: error: use of deleted function ‘QVariant::QVariant(T) [with T = char*; typename std::enable_if<disjunction_v<std::is_pointer<_Tp>, std::is_member_pointer<_Tp> >, bool>::type <anonymous> = false]’
   76 |

and the char * conversion seems wrong in any case.

Change-Id: Iac5df53547dc61b65b0d8c4087ca1f6366664b2f
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-12 08:44:44 +00:00
hjk
530b9ae85a ProjectExplorer: Copy more RunConfiguration data to RunControl
The aspects are now responsible for defining what data needs
to be copied and also to provide a suitable interface (kind
of source-compatible to direct use) for access.

The important change here is that RunControl::aspect(...) doesn't
need to access RunControl::runConfiguration() in fully aspectified
RunConfigurations anymore. In not-fully aspectified the runConfig
access is moved to the user code to make the problem visible there.
Long term, aspectification should be finished.

As an additional benefit, the resolving of macros etc can
now be done at the correct time.

Change-Id: I690d9f8f696ce9b4efd42082ba3f81b514efcb77
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-04-12 08:43:09 +00:00
David Schulz
24b4a7be74 Python: add pip package information
Change-Id: Iea55d1491b49156d8bef32c5d4045efde4bc92fe
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-04-12 08:24:40 +00:00
Jarek Kobus
2794b5e543 tst_QtcProcess: Get rid of lineCallbackIntern() test
This test introduced some additional private API to QtcProcess.
This makes refactorings of QtcProcess harder, as we need to
handle this artificial code working.

We have a real lineCallback() test instead which doesn't
employ this private API.

Change-Id: Idbc314210cecc2044e1ccc298e5d3e0a9747e811
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-11 15:26:10 +00:00
Thomas Hartmann
d68095fae6 StudioWelcome: Track download and opening of examples
Change-Id: I5e992f6accd8a5eadf7f814c90c98190832e02a3
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-04-11 14:41:38 +00:00
Artem Sokolovskii
7574ec3e21 ClangFormat: Add the logical settings management
Now there are changeable and unchangeable settings,
as it works for usual codestyle settings.
They save parallel with codestyle settings but in another dir.
In general, the behavior became similar to usual codestyle settings.

ToDo: Make indenter use this settings instead standard one and
instead project settings when "override" checkbox is checked.

Change-Id: I639dbda296932bf9b967a11f1cc4fda120415ed9
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-11 14:03:22 +00:00
Thomas Hartmann
f29614a5ce StudioPlugin: Remove timer
Task-number: QDS-6617
Change-Id: I401f38dbbd419137ca9239d0c1d67e1dc2446b25
Reviewed-by: Kimmo Leppälä <kimmo.leppala@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-04-11 13:18:26 +00:00
Christian Kandeler
514ceb25e9 ClangCodeModel: Prevent recursive delete of FollowSymbolData
Fixes: QTCREATORBUG-27323
Change-Id: I3bcff6516e197b62b1a3772e6db598038c5977c9
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-04-11 12:27:51 +00:00
Assam Boudjelthia
daebcfdca9 Android: fix typo in previous refactoring for AndroidRunnerWorker
Pre-start adb commands were executed for a second time instead of
the post-finish commands because of typo in variable name, which
now is renamed to avoid confusion.

Amends 1372dfdf7f.

Change-Id: Ia89c7835f4a7b9a4d187479962b591b5980387b8
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-11 11:44:12 +00:00
Christian Stenger
2f64cf4779 CppEditor: Do not crash on anonymous classes
While performing generate getters and setters we crashed
when using members of anonymous classes.

Change-Id: I27dc8da950345aa4e26ddb1da3914edcffad5af3
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-04-11 10:44:15 +00:00
David Schulz
0180f24552 Core: Fix search results painting for odd dpi scale factor
Fixes: QTCREATORBUG-27321
Change-Id: Iab697e120ab644219ba50a7d9efc2cf258d0c756
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2022-04-11 08:12:48 +00:00
Christian Kandeler
06ce449a01 ClangCodeModel: Fix another output argument mis-detection
We need to relax the range check: In expressions such as x.y->z, the
second argument for the operator->call is x.y, not just y.

Fixes: QTCREATORBUG-27352
Change-Id: Ida542c11c129630f0a1d301508ec5f8076eb9902
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-04-11 07:16:22 +00:00
Jarek Kobus
53a3504aac ApplicationLauncher: Connect to QtcProcess::done() signal
Instead of connecting to errorOccurred() and finished() signals.

Change-Id: I661a789211eb0d789cf3d1939527be4b58850dd4
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2022-04-11 06:52:56 +00:00
Jarek Kobus
936c44f367 Introduce ProcessResultData
It should be useful when reimplementing ProcessInterface.
It replaces 4 virtual methods with just 1.

Task-number: QTCREATORBUG-27358
Change-Id: I2dafbfbc25f8f016ff2aa19c1a176335a4a7498c
Reviewed-by: hjk <hjk@qt.io>
2022-04-11 06:51:51 +00:00
Jarek Kobus
104bbfc713 AndroidSettingsWidget: Connect to QtcProcess::done() signal
Instead of connecting to errorOccurred() and finished() signals.

Change-Id: If802368f1f084e5990458942b3ef94517a0cfdff
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-08 18:50:07 +00:00
Jarek Kobus
a6fc7727a1 Get rid of SftpSession
Should be substituted by FilePath actions using remote paths.

Change-Id: Ib1e3913cc94d417045cbe6b922284a2f8ab6d71f
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>
2022-04-08 15:12:22 +00:00
Jarek Kobus
5715d433f4 Get rid of SftpFileSystemModel
It's being replaced with DeviceFileSystemModel.

Change-Id: I062f2a873ecede9755527e8ee7b8b4d578289c4b
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2022-04-08 11:50:15 +00:00
Jarek Kobus
5d27ca72d4 Use DeviceFileSystemModel in SelectRemoteFileDialog
Instead of SftpFileSystemModel.

Change-Id: Icbb3cf6147fc1266b3aa763f72c919be7b329390
Reviewed-by: hjk <hjk@qt.io>
2022-04-08 11:49:55 +00:00
Christian Kandeler
ec51347144 Update qbs submodule
... to HEAD of 1.22 branch.

Change-Id: I29a2f4723de433806ec86872fb9d271d65a3b627
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-04-08 11:09:06 +00:00
Alesandro Portale
3d2c5ee81c Android: Align Android SDK display names with Android Studio
Let the SDK packages have the same names as in Android Studio. Including
the code name (in brackets) makes things easier for people like me who
remember sweets better than numbers.

Fixes: QTCREATORBUG-27161
Change-Id: Iedf2d1ebaf5405669c49536258143db5c7570a9e
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
2022-04-08 10:31:28 +00:00
Marcus Tillmanns
4340d18371 dockerplugin: Solve UI fixme's for 8.0
Shortened some lines as requested.

Change-Id: I5d145e8cd28ed1036915a5d1611f0257efd9b023
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2022-04-08 09:42:54 +00:00
Christian Stenger
a835c45d8c QmlDesigner: Fix compile with Qt5
Amends ca5efe7880. Forgotten in later patchsets of 1fd9b13101.

Change-Id: I07827d66d4d4dfe039c04c3724edff354ada9c49
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2022-04-08 08:34:42 +00:00
Miikka Heikkinen
be284f24c0 QmlDesigner: Add configuration for qsb shader generator tool
Added default ShaderTool configuration block to new project template
and use information specified there to generate qsb shaders.

The args property specifies command line argument for qsb tool.
The files property specifies files for which qsb tool is run for.

E.g.:

ShaderTool {
    args: "-s --glsl \"100 es,120,150\" --hlsl 50 --msl 12"
    files: [ "content/shaders/*" ]
}

Fixes: QDS-6590
Change-Id: I3bab0db21d20f486f9f25c1437a27ddb7fb47396
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Samuel Ghinet <samuel.ghinet@qt.io>
2022-04-08 07:58:20 +00:00
Miikka Heikkinen
1fd9b13101 QmlDesigner: Fix build with Qt5
Amends ca5efe7880.

Change-Id: Idea65116baca345c2dff0777b6dbe285bfc4bbe4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-04-08 07:33:20 +00:00
Jarek Kobus
6e666b3bfd Introduce DeviceFileSystemModel
This is going to replace SftpFileSystemModel.

That's needed before planed removal of SshConnection in order
to not to use SftpSession class.

Change-Id: I97f0ffd3418f7e71819ac95048a75e4a17901c71
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>
2022-04-08 06:39:28 +00:00
Miikka Heikkinen
cbcbc4d950 QmlDesigner: Fix HDR image thumbnail generation
Algorithm for wrong target image format was used.

Fixes: QDS-6608
Change-Id: Icb5f8fc6b185c85eb3d783ce31e7d57175c3d37b
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-04-08 06:10:05 +00:00
Miikka Heikkinen
ca5efe7880 QmlDesigner: Hide advanced 3D model import options
Only simple options are shown by default.

Fixes: QDS-6574
Change-Id: Idb642d80ca8867dce95d3db4509d2ee454aa2be1
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-08 06:09:36 +00:00
Christian Stenger
d0e854e390 QmlJSTools: Fix compile with Qbs
Amends 87e52ad189. While at it reorder includes to
match QC style.

Change-Id: I8bbfdd4db9409a7348e7a2cbcb954972a2a2f9b4
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-04-08 04:57:00 +00:00
Alessandro Portale
7c4df8d23e WebAssembly: Fix "emrun --browser" call with latest emsdk
emsdk's emrun now requires additional PATH entries in order to detect a
web browser location. At least on Windows.

Therefore, as a fix, use the build configuration environment instead of
an empty one for the emsdk call.

Fixes: QTCREATORBUG-27239
Change-Id: Ibe256265bd70f39693594f739403c415108fd981
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-04-07 17:12:07 +00:00
Marcus Tillmanns
42b60e3ec9 dockerplugin: Backwards-compatibility
Change-Id: I6c94274a8e2a6b9036c93b36daece3fa7cdc66cc
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-04-07 14:14:42 +00:00
Marcus Tillmanns
3af260b782 docker-plugin: fix daemon state
Changed daemon state to actually check the docker runtime to determine
if its available or not.

Change-Id: I9e183658dfc7c34e229aec2a332cf303793284e5
Reviewed-by: hjk <hjk@qt.io>
2022-04-07 12:58:48 +00:00
Erik Verbruggen
1d63eaee23 Change two paths from QString to FilePath
Fixes: QTCREATORBUG-27144
Change-Id: I41ecc2e96b61a5a8383ef710b558f65e93c5b591
Reviewed-by: Piotr Mućko <piotr.mucko@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-04-07 12:26:57 +00:00
Xavier BESSON
87e52ad189 Line length for QML/JS editing automatic formatting
Adding parameters to functions in the QML/JS formatter
Adding widget and setting to the QML/JS editing settings

Fixes: QTCREATORBUG-23411
Change-Id: Ib9d3ac3b22443e81cd636fbc276c6544dab1511b
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@qt.io>
2022-04-07 11:42:37 +00:00
Jarek Kobus
4762d54401 DockerDevice: Connect to QtcProcess::done() signal
Instead of connecting to errorOccurred() and finished() signals.

Change-Id: I0dd1d35aa48bfb7769623ff5735a7abd644d180f
Reviewed-by: hjk <hjk@qt.io>
2022-04-07 10:45:39 +00:00
Thomas Hartmann
b2866068ba QmlDesigner: Use standard camelcase ids for telemetry ids
Change-Id: I28d7744899bc476eb64f9ec5877d1821fdf64926
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-04-07 10:35:34 +00:00
Christian Kandeler
3cdec51eaf CppEditor: Properly handle function types as template arguments
... when creating getters and setters.

Fixes: QTCREATORBUG-27133
Change-Id: Ia77147a270fb1229c765ff9d5f03aa243d51fe97
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-04-07 08:20:22 +00:00
Christian Kandeler
f27c4214f8 ClangCodeModel: Better icon for static class members
... in completions. Apparently, clangd uses the LSP type "property" for
static members.

Task-number: QTCREATORBUG-27289
Change-Id: Ib296dbade6b2e7c38a761b27b2c024ea98a89523
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-04-07 08:19:05 +00:00
Eike Ziller
ca480ec601 Merge remote-tracking branch 'origin/7.0'
Change-Id: I9a7a9a5579f1f4e277e7927eefb1bab9ca60ad4a
2022-04-07 09:51:40 +02:00
Marcus Tillmanns
bcfe2bc25a utils: Add additional tooltip to ElidingLabel
In case you want to set a real Tooltip for an eliding label

Added tests in tst_manual_widgets_infolabel

Change-Id: I72bcbf672415ce439c14e260e364fcd2f85fc733
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-04-07 07:28:22 +00:00
David Schulz
221b52d01a Core: fix OptionsPopup positioning
Do not limit the popups coordinates to positive y coordinates, since
Monitors above the main monitor have a negative y coordinate. Use the
the available geometry of the parent widgets screen to check for
sensible coordinates instead.

Fixes: QTCREATORBUG-27341
Change-Id: I6e1572f7b2d3c83feafcf71392e265e14e6b457d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-04-07 04:08:07 +00:00
Thomas Hartmann
3da441f4d1 QmlDesigner: Fix compound alias properties
Change-Id: I5d58b6b740af71ef10010548429e1d12f97c620c
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-04-06 16:02:06 +00:00
Jarek Kobus
097b862712 AndroidDeviceManager: Connect to QtcProcess::done() signal
Instead of connecting to errorOccurred() and finished() signals.
Make some cleanup in usages of Utils:: namespace.

Change-Id: I5d784d1938d6aac1dd760c663b60c23378318096
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-04-06 15:48:15 +00:00
Jarek Kobus
e9f1ff9193 RsyncDeployService: Connect to QtcProcess::done() signal
Instead of connecting to errorOccurred() and finished() signals.

Change-Id: If18ff8431efa7f3b45212fe737f66fb4eb6c6fb5
Reviewed-by: hjk <hjk@qt.io>
2022-04-06 13:54:54 +00:00
Jarek Kobus
8816759a85 GenericLinuxDeviceTester: Connect to QtcProcess::done() signal
Instead of connecting to errorOccurred() and finished() signals.

Change-Id: I507b05cfc979db56ac7101432dd20acb68848d48
Reviewed-by: hjk <hjk@qt.io>
2022-04-06 13:54:45 +00:00
Jarek Kobus
7f6b5a3bd4 SshDeviceProcess: Emit done() signal
Emit done() signal along with errorOccurred(FailedToStart)
and finished() signals.

Change-Id: I52db46e1c7fd44434514bac62b3df8eb0b9a4dc2
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2022-04-06 13:54:27 +00:00