From d1fef0ea517a163003a26edd8ba89b33f05d64dc Mon Sep 17 00:00:00 2001 From: hjk Date: Wed, 29 May 2019 19:12:45 +0200 Subject: [PATCH] ProjectExplorer: Add a Runnable::setCommandLine() Change-Id: I9b6a782e143dca8519cdc57171557bd3893df921 Reviewed-by: Christian Kandeler --- src/plugins/projectexplorer/runcontrol.cpp | 6 ++++++ src/plugins/projectexplorer/runcontrol.h | 1 + 2 files changed, 7 insertions(+) diff --git a/src/plugins/projectexplorer/runcontrol.cpp b/src/plugins/projectexplorer/runcontrol.cpp index a358df38f3b..f90a8fd48c0 100644 --- a/src/plugins/projectexplorer/runcontrol.cpp +++ b/src/plugins/projectexplorer/runcontrol.cpp @@ -1554,4 +1554,10 @@ CommandLine Runnable::commandLine() const return CommandLine(FilePath::fromString(executable), commandLineArguments); } +void Runnable::setCommandLine(const CommandLine &cmdLine) +{ + executable = cmdLine.executable().toString(); + commandLineArguments = cmdLine.arguments(); +} + } // namespace ProjectExplorer diff --git a/src/plugins/projectexplorer/runcontrol.h b/src/plugins/projectexplorer/runcontrol.h index 040520991d0..fbb1c151ff1 100644 --- a/src/plugins/projectexplorer/runcontrol.h +++ b/src/plugins/projectexplorer/runcontrol.h @@ -74,6 +74,7 @@ public: Runnable() = default; Utils::CommandLine commandLine() const; + void setCommandLine(const Utils::CommandLine &cmdLine); QString executable; QString commandLineArguments;