forked from qt-creator/qt-creator
ProjectExplorer: Fix uses of "FilePath::toString"
Change-Id: I7199dec620b7e09765c44b571b93575eda5c5a74 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -100,11 +100,11 @@ FilePath ProcessParameters::effectiveCommand() const
|
|||||||
if (m_macroExpander)
|
if (m_macroExpander)
|
||||||
cmd = m_macroExpander->expand(cmd);
|
cmd = m_macroExpander->expand(cmd);
|
||||||
if (cmd.needsDevice()) {
|
if (cmd.needsDevice()) {
|
||||||
// Assume this is already good. FIXME: It is possibly not, so better fix searchInPath.
|
// Assume this is already good. FIXME: It is possibly not, so better fix searchInPath.
|
||||||
m_effectiveCommand = cmd;
|
m_effectiveCommand = cmd;
|
||||||
} else {
|
} else {
|
||||||
m_effectiveCommand = m_runData.environment.searchInPath(cmd.toString(),
|
m_effectiveCommand
|
||||||
{effectiveWorkingDirectory()});
|
= m_runData.environment.searchInPath(cmd.path(), {effectiveWorkingDirectory()});
|
||||||
}
|
}
|
||||||
m_commandMissing = m_effectiveCommand.isEmpty();
|
m_commandMissing = m_effectiveCommand.isEmpty();
|
||||||
if (m_commandMissing)
|
if (m_commandMissing)
|
||||||
@@ -135,10 +135,10 @@ QString ProcessParameters::effectiveArguments() const
|
|||||||
|
|
||||||
QString ProcessParameters::prettyCommand() const
|
QString ProcessParameters::prettyCommand() const
|
||||||
{
|
{
|
||||||
QString cmd = m_runData.command.executable().toString();
|
FilePath cmd = m_runData.command.executable();
|
||||||
if (m_macroExpander)
|
if (m_macroExpander)
|
||||||
cmd = m_macroExpander->expand(cmd);
|
cmd = m_macroExpander->expand(cmd);
|
||||||
return FilePath::fromString(cmd).fileName();
|
return cmd.fileName();
|
||||||
}
|
}
|
||||||
|
|
||||||
QString ProcessParameters::prettyArguments() const
|
QString ProcessParameters::prettyArguments() const
|
||||||
@@ -183,7 +183,7 @@ QString ProcessParameters::summaryInWorkdir(const QString &displayName) const
|
|||||||
displayName,
|
displayName,
|
||||||
ProcessArgs::quoteArg(prettyCommand()).toHtmlEscaped(),
|
ProcessArgs::quoteArg(prettyCommand()).toHtmlEscaped(),
|
||||||
prettyArguments().toHtmlEscaped(),
|
prettyArguments().toHtmlEscaped(),
|
||||||
QDir::toNativeSeparators(effectiveWorkingDirectory().toString()));
|
effectiveWorkingDirectory().toUserOutput());
|
||||||
}
|
}
|
||||||
|
|
||||||
} // ProcessExplorer
|
} // ProcessExplorer
|
||||||
|
Reference in New Issue
Block a user