That's what the implementation does, and judging from the using code
wasn't quite clear.
Change-Id: I4ca776ba4da83a36162adad2dd595eb39eb0f43d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Rename process.h back to qtcprocess.h
MSVC's "threads" standard header includes <process.h>, and that ends up
including our process.h from Utils.
There already was a hacky workaround in place for a similar issue with
MINGW, but that doesn't work with MSVC because that doesn't have
Simply use a name that doesn't conflict.
Change-Id: I1159cd2096b4f2dbc4a1728d0131dd6edd30ebd3
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>
Add an extra arg to runBlocking() function instead.
Use std::chrono::seconds for timeout.
Change-Id: I7c3c21e8f26a2ccbed157d15083d6ef0b4cd2f7e
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Changes FancyLineEdit to accept two types of validation functions:
AsyncValidationFunction, which returns a QFuture and takes the new text,
or SynchronousValidationFunction.
Especially PathChooser is changed to use async validation function to
improve snappyness of settings pages that do heavy validation,
for instance the Debugger page.
Change-Id: I1677e7d8acc29e36c69a867850304b7913e6ae7e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Make Environment a stack of changes that gets "expanded" to
a full environment before things are actively accessed.
Later this expansion should be done lazily if possible.
Task-number: QTCREATORBUG-28357
Change-Id: If1c7bfdb9f58b81e71c51ed87ee75d6964a47019
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Found by memory analyzer.
Amends b3f82887a3
Change-Id: I580ab0873f5c3556445a87d9fc2c806eeb48c57e
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
The plan is now to keep 'Environment' as the concept name, but
have what is currently 'EnvironmentChange' as implementation,
as keeping a full env vs env change(set) distiction gets messy.
First step is to cut the direct dependency of EnvironmentChange
from a (current) Environment that causes circularity when moving
the implementation.
Change-Id: Id8b512b311071611b750b27af59549ce7c2ce8e6
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Adding a slash to the text in the path chooser for a custom build
directory currently triggers an endless recursion.
This here does not fix the actual problem but at least prevents
the crash.
Task-number: QTCREATORBUG-28682
Change-Id: Ic7d70ccfaccc1fd9437ca41e8b40b027718af6cb
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Since we also license under GPL-3.0 WITH Qt-GPL-exception-1.0,
this applies only to a hypothetical newer version of GPL, that doesn't
exist yet. If such a version emerges, we can still decide to relicense...
While at it, replace (deprecated) GPL-3.0 with more explicit GPL-3.0-only
Change was done by running
find . -type f -exec perl -pi -e "s/LicenseRef-Qt-Commercial OR GPL-3.0\+ OR GPL-3.0 WITH Qt-GPL-exception-1.0/LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0/g" {} \;
Change-Id: I5097e6ce8d10233993ee30d7e25120e2659eb10b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
PathChooserPrivate::expandedPath has a hack that interferes with remote
paths when they are already absolute. This patch short-circuits it to
keep absolute remote paths intact.
Change-Id: I6438842a693653404aa07160de9f68bdbf22519b
Reviewed-by: hjk <hjk@qt.io>
... by a new PathChooser::textChanged signal.
They were both emitted in reaction to the underlying line edit's
textChanged() signal.
Use 'textChanged()' as name to mimic/match the Qt side. This also
makes it more clear on the user code side, when this happens.
Some textChanged() consumers should probably use editingFinished()
instead, but that's left for later changes.
Change-Id: Ib07347f616cbf1c5d09bc2f8671ca860d185d1f9
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Replace the current license disclaimer in files by
a SPDX-License-Identifier.
Task-number: QTBUG-67283
Change-Id: I708fd1f9f2b73d60f57cc3568646929117825813
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Round 1 - focus on headers.
For classes with initial in range [P-R].
Try to keep the same separators between different kind of headers.
Change-Id: I01fb80b93164a7fe4c0bd2cd8f9e4f27523efefa
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
It's a result of a team work consisting of yellow triangle and me.
Change-Id: I8b4812766da70e0785ae71bf0cb71357379e2514
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
As we have a valid context to resolve relative files here
this is a good source for absolute files that don't depend
on QFilePath::absolute{File,}Path or similar.
Change-Id: Iaf592aa746023f80de517703e32e6b80a3d0fd7e
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
Diverts to searchInDirectory(). Use it in some places.
Change-Id: I9e5642f0ae0ed4dd9fb9f34bcaa11a25bd26c690
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Similar to QT_RESTRICTED_CAST_FROM_ASCII to avoid the need for
decorations in user code.
At the same time, drop some convenience constructors and functions
in CommandLine and Icon essentially serving the same purpose.
Change-Id: Ida4e5ac19c2da0a4298a97b2a8e1511d56bbb79d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Makes it a bit clearer that there's no magic path use or similar
beyond this point.
Change-Id: I86c06850d16bf777db05ad23b540d8096926c059
Reviewed-by: David Schulz <david.schulz@qt.io>
For path choosers this makes it easier to change the actual base retrospectively
based on the device for the file path entered by the user.
In other cases "end user code" only knows that something needs to
be added to PATH to get a proper environment. This here lets this
code to specify the change alone without bothering about the base
environment this might be applied to.
Change-Id: I726aaa2fd2feb0bee7158f601aac660b0ac6327b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Manually editing the path inside a PathChooser will trigger some
validation and may end up in constructing some invalid paths
but still marking them as valid.
Beside this it will make the cursor jump to different locations
while typing which ends up in creating even more incorrect paths.
So, avoid creating invalid paths and mark the resulting path
as invalid if it is.
Change-Id: I27f55ae03745474fc6b91c44cdbc307c581fb2f8
Reviewed-by: hjk <hjk@qt.io>
Amends 11a40e02f2.
Environment::searchInPath only works for local setups, the
remote replacement is FilePath::searchOnDevice.
Change-Id: I8a2ba51903d3308ca9198fbf1154779c78e69e63
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
At least for the red marking of valid/invalid.
Change-Id: I91f856f93ba74f6b62a540322c2445691afbf170
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>