From 322a8481a754109b7dd8306598fce39f49e57ad9 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Wed, 11 May 2011 12:48:14 +0200 Subject: unify application launcher between platforms purge abstractprocess and winguiprocess. they serve no purpose. applications can have stdio on windows as well, in addition to the windows debug channel. Task-number: QTCREATORBUG-4822 --- src/libs/utils/consoleprocess.cpp | 52 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 51 insertions(+), 1 deletion(-) (limited to 'src/libs/utils/consoleprocess.cpp') diff --git a/src/libs/utils/consoleprocess.cpp b/src/libs/utils/consoleprocess.cpp index d484be901c..0c7c8702c8 100644 --- a/src/libs/utils/consoleprocess.cpp +++ b/src/libs/utils/consoleprocess.cpp @@ -30,10 +30,25 @@ ** **************************************************************************/ -#include "consoleprocess.h" +#include "consoleprocess_p.h" namespace Utils { +ConsoleProcess::~ConsoleProcess() +{ + stop(); +} + +void ConsoleProcess::setMode(Mode m) +{ + d->m_mode = m; +} + +ConsoleProcess::Mode ConsoleProcess::mode() const +{ + return d->m_mode; +} + QString ConsoleProcess::modeOption(Mode m) { switch (m) { @@ -47,6 +62,41 @@ QString ConsoleProcess::modeOption(Mode m) return QLatin1String("run"); } +qint64 ConsoleProcess::applicationPID() const +{ + return d->m_appPid; +} + +int ConsoleProcess::exitCode() const +{ + return d->m_appCode; +} // This will be the signal number if exitStatus == CrashExit + +QProcess::ExitStatus ConsoleProcess::exitStatus() const +{ + return d->m_appStatus; +} + +void ConsoleProcess::setWorkingDirectory(const QString &dir) +{ + d->m_workingDir = dir; +} + +QString ConsoleProcess::workingDirectory() const +{ + return d->m_workingDir; +} + +void ConsoleProcess::setEnvironment(const Environment &env) +{ + d->m_environment = env; +} + +Environment ConsoleProcess::environment() const +{ + return d->m_environment; +} + QString ConsoleProcess::msgCommChannelFailed(const QString &error) { return tr("Cannot set up communication channel: %1").arg(error); -- cgit v1.2.1