Bring messages pane to front when triggering an external tool or
command, write output silently and flash when tool finishes or fails.
Also bring pane to front if file renaming or removing fails (this should
happen only as a direct consequence of the user choosing this action).
Task-number: QTCREATORBUG-24430
Change-Id: Ib47431bd57a9c05bfdbfb03ad4c7cd38bdf3ddd1
Reviewed-by: hjk <hjk@qt.io>
In Qt 5.15 QProcess::startDetached(const QString &command) overload
got deprecated, and in Qt 6 it has disappeared.
We substiture it by setting explicitly the program and
arguments on browserProc. In order to properly separate
the command into program name and arguments we use
Utils::QtcProcess::splitArgs(). We also handle the case
when a path to file browser was not specified, and the case
when starting a file browser failed and the error was empty.
Task-number: QTCREATORBUG-24098
Change-Id: Ie9c9581b303407ddc5c64264576ad39ec0894bdb
Reviewed-by: hjk <hjk@qt.io>
Gone in Qt6. Write into a string buffer and bulk convert and write that
into the file with QTextCodec.
Task-number: QTCREATORBUG-24098
Change-Id: I266e90e166a22c8b34b2963458af1cc4f5d2df82
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
... and use it to improve the user experience when removing several files
at once from a project.
Fixes: QTCREATORBUG-24385
Change-Id: I8e8c39ee9dc0046f1715a5143a7649fab06e5ad8
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
There are very few reasons to use mainWindow() directly.
Especially for modal dialogs, using dialogParent() is important, since
that guarantees the stacking order in case of other dialogs currently
being open.
Change-Id: I7ad2c23c5034b43195eb35cfe405932a7ea003e6
Reviewed-by: hjk <hjk@qt.io>
Most often, a terminal with system environment is needed.
Provide it as direct context menu entry, and leave the
additional entries for build and run environment (which
are probably more seldom used) as sub-menu as before,
but rename it to "Open Terminal with >".
Change-Id: I148395ca1e62eafff8844ba91db269a12b053de9
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
More in line with QFileInfo terminonlogy which appears to be
best-of-breed within Qt.
Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
qt 5.8 made QProcess::startDetached()'s behavior consistent with
start(), which means it won't open a console any more. however, qtc
relied on this (unspecified) behavior.
the correct solution is to add a static function startTerminalEmulator()
to ConsoleProcess, which already has most of the necessary code anyway.
Task-number: QTCREATORBUG-17439
Change-Id: Icf04666869ce6593555302a54c49331a29846a99
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
It was too crowded to add anything to it. Split it into "interface" and
"system" related pages.
Change-Id: I2aa7984de4d672ca000e991b0cfb32a3f706c988
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
PageIds are supposed to be unique, so the CategoryId can be determined
from the PageId. Look for PageIds in the already expanded categories
first before searching through expensive categories.
Change-Id: I006beb0df6183453163ac1810fe59a306a0f52b1
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
Qt 5.3 is the minimum requirement these days. Remove all fallback code
from sources and project files.
Change-Id: If6188a471197acadda4d6baee71804ba1a8026c6
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Otherwise the options dialog might appear behind the current "dialog"
(for example the "new" wizards).
Also, take ICore::dialogParent as default.
Change-Id: I4578e269db5763842a942549a45ec8cdd6b28b5d
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
We have many buttons that open the options dialog, and many of these use
different terms.
Change-Id: I073fe2a23569c6f4174a2fb6567359c89cb2427c
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
This is used to get a platform-agnostic handle on "command line
arguments". It essentially wraps a single QString on Windows,
and a QStringList everywhere else.
As a consequence, several occurrences of #ifdef Q_OS_*
can be removed from the codebase.
Change-Id: Ic93118c1bd0bce0ebb58f416d395dbaebb861772
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
The methods Utils::UnixUtils::fileBrowser and
Utils::UnixUtils::substituteFileBrowserParameters are both declared when
compiling on MacOS, but their implementation is not compiled into
libutils. So this gives linker errors.
Change-Id: I0befb607dda0a83d681068f8236167ba88918460
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
e8b5c6dfcca3fc139049136b42459e7840efed7 :
Provide terminal emulator functionality in ConsoleProcess for
Windows as well.
e833b794b3 :
Use Core::Id().
Change-Id: Idad2bd2180e9a5dd2d1266496e340726435835d3
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Mostly use HostOsInfo instead of direct macros.
Change-Id: Ic6da7c987268fc8a0d06057e17c5bc0b131cbcb2
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
QTBUG-3570 doesn't look like being fixed in Qt5.
Change-Id: Icddcd0e98899c9a8ac01b99783bb9450dcbe952b
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Made add and remove operations of ResourceEditor VCS-aware. Also, remove
operation now can remove files from filesystem.
FileUtils::removeFile() and VcsManager::promptToAdd functions were
extracted from ProjectExplorer to prevent code duplication.
RemoveFileDialog was also moved to coreplugin.
Change-Id: Ia51127288030e52ce9475b369e56ea034dfa5d1e
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
Renaming supports version control.
To prevent code duplication part of ProjectExplorerPlugin::renameFile
implementation was separated into FileUtils::renameFile.
Change-Id: I28481bea89d0824339e5db025ceb7216713bd5a0
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>