forked from qt-creator/qt-creator
Debugger: Get rid of AllowTerminal enum
Call setUseTerminal() instead. Change-Id: I2ef6fb1437cd0cfcaee39bcaeeeb1f887a01a34f Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -91,7 +91,6 @@ public:
|
|||||||
|
|
||||||
// Terminal
|
// Terminal
|
||||||
Process terminalProc;
|
Process terminalProc;
|
||||||
DebuggerRunTool::AllowTerminal allowTerminal = DebuggerRunTool::DoAllowTerminal;
|
|
||||||
|
|
||||||
// DebugServer
|
// DebugServer
|
||||||
Process debuggerServerProc;
|
Process debuggerServerProc;
|
||||||
@@ -163,9 +162,6 @@ void DebuggerRunTool::continueAfterCoreFileSetup()
|
|||||||
|
|
||||||
void DebuggerRunTool::startTerminalIfNeededAndContinueStartup()
|
void DebuggerRunTool::startTerminalIfNeededAndContinueStartup()
|
||||||
{
|
{
|
||||||
if (d->allowTerminal == DoNotAllowTerminal)
|
|
||||||
m_runParameters.setUseTerminal(false);
|
|
||||||
|
|
||||||
// CDB has a built-in console that might be preferred by some.
|
// CDB has a built-in console that might be preferred by some.
|
||||||
const bool useCdbConsole = m_runParameters.cppEngineType() == CdbEngineType
|
const bool useCdbConsole = m_runParameters.cppEngineType() == CdbEngineType
|
||||||
&& (m_runParameters.startMode() == StartInternal
|
&& (m_runParameters.startMode() == StartInternal
|
||||||
@@ -497,7 +493,7 @@ void DebuggerRunTool::setupPortsGatherer()
|
|||||||
runControl()->requestQmlChannel();
|
runControl()->requestQmlChannel();
|
||||||
}
|
}
|
||||||
|
|
||||||
DebuggerRunTool::DebuggerRunTool(RunControl *runControl, AllowTerminal allowTerminal)
|
DebuggerRunTool::DebuggerRunTool(RunControl *runControl)
|
||||||
: RunWorker(runControl)
|
: RunWorker(runControl)
|
||||||
, d(new DebuggerRunToolPrivate)
|
, d(new DebuggerRunToolPrivate)
|
||||||
, m_runParameters(DebuggerRunParameters::fromRunControl(runControl))
|
, m_runParameters(DebuggerRunParameters::fromRunControl(runControl))
|
||||||
@@ -513,7 +509,6 @@ DebuggerRunTool::DebuggerRunTool(RunControl *runControl, AllowTerminal allowTerm
|
|||||||
d->debuggerServerProc.setUtf8Codec();
|
d->debuggerServerProc.setUtf8Codec();
|
||||||
|
|
||||||
d->runId = QString::number(++toolRunCount);
|
d->runId = QString::number(++toolRunCount);
|
||||||
d->allowTerminal = allowTerminal;
|
|
||||||
|
|
||||||
runControl->setIcon(ProjectExplorer::Icons::DEBUG_START_SMALL_TOOLBAR);
|
runControl->setIcon(ProjectExplorer::Icons::DEBUG_START_SMALL_TOOLBAR);
|
||||||
runControl->setPromptToStop([](bool *optionalPrompt) {
|
runControl->setPromptToStop([](bool *optionalPrompt) {
|
||||||
|
@@ -22,9 +22,7 @@ class SubChannelProvider;
|
|||||||
class DEBUGGER_EXPORT DebuggerRunTool : public ProjectExplorer::RunWorker
|
class DEBUGGER_EXPORT DebuggerRunTool : public ProjectExplorer::RunWorker
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
enum AllowTerminal { DoAllowTerminal, DoNotAllowTerminal };
|
explicit DebuggerRunTool(ProjectExplorer::RunControl *runControl);
|
||||||
explicit DebuggerRunTool(ProjectExplorer::RunControl *runControl,
|
|
||||||
AllowTerminal allowTerminal = DoAllowTerminal);
|
|
||||||
~DebuggerRunTool() override;
|
~DebuggerRunTool() override;
|
||||||
|
|
||||||
void start() override;
|
void start() override;
|
||||||
|
@@ -47,10 +47,11 @@ public:
|
|||||||
setProducer([](RunControl *rc) {
|
setProducer([](RunControl *rc) {
|
||||||
rc->requestDebugChannel();
|
rc->requestDebugChannel();
|
||||||
|
|
||||||
auto debugger = new DebuggerRunTool(rc, DebuggerRunTool::DoNotAllowTerminal);
|
auto debugger = new DebuggerRunTool(rc);
|
||||||
DebuggerRunParameters &rp = debugger->runParameters();
|
DebuggerRunParameters &rp = debugger->runParameters();
|
||||||
debugger->setId("RemoteLinuxDebugWorker");
|
debugger->setId("RemoteLinuxDebugWorker");
|
||||||
debugger->setupPortsGatherer();
|
debugger->setupPortsGatherer();
|
||||||
|
rp.setUseTerminal(false);
|
||||||
rp.setAddQmlServerInferiorCmdArgIfNeeded(true);
|
rp.setAddQmlServerInferiorCmdArgIfNeeded(true);
|
||||||
|
|
||||||
rp.setStartMode(AttachToRemoteServer);
|
rp.setStartMode(AttachToRemoteServer);
|
||||||
|
Reference in New Issue
Block a user