mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 18:08:10 +00:00
Fixup 9f92fc92
: improve FIXME in SystemcallPrivate::startProcess
I wanted to remove the test Qt >= 5.15, but now I see that it is not possible because of QProcess::splitCommand. Neverthless, the best would be to change parsecmd.
This commit is contained in:
parent
f1d8eb37e3
commit
67c85f54c4
@ -370,6 +370,14 @@ void SystemcallPrivate::startProcess(QString const & cmd, string const & path,
|
||||
cmd_ = cmd;
|
||||
#if (QT_VERSION >= QT_VERSION_CHECK(5, 15, 0))
|
||||
// FIXME pass command and arguments separated in the first place
|
||||
/* The versions of startDetached() and start() that accept a
|
||||
* QStringList object exist since Qt4, but it is only in Qt 5.15
|
||||
* that splitCommand() was introduced and the plain versions of
|
||||
* start/startDetached() have been deprecated.
|
||||
* The cleanest solution would be to have parsecmd() produce a
|
||||
* QStringList for arguments, instead of transforming the string
|
||||
* into something that the QProcess splitter accepts.
|
||||
*/
|
||||
QStringList arguments = QProcess::splitCommand(toqstr(latexEnvCmdPrefix(path, lpath)) + cmd_);
|
||||
QString command = (arguments.empty()) ? QString() : arguments.first();
|
||||
if (arguments.size() == 1)
|
||||
|
Loading…
Reference in New Issue
Block a user