forked from qt-creator/qt-creator
ProjectExplorer: Allow RunWorker::Starting -> Stopping
Can happen on worker startup, e.g. missing binaries, permissions, ... Change-Id: Ibeee0a6992af80d3486b00890664e83525f17204 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This commit is contained in:
@@ -825,7 +825,9 @@ void RunControlPrivate::continueStart()
|
|||||||
|
|
||||||
void RunControlPrivate::initiateStop()
|
void RunControlPrivate::initiateStop()
|
||||||
{
|
{
|
||||||
checkState(RunControlState::Running);
|
if (state != RunControlState::Starting && state != RunControlState::Running)
|
||||||
|
qDebug() << "Unexpected initiateStop() in state" << stateName(state);
|
||||||
|
|
||||||
setState(RunControlState::Stopping);
|
setState(RunControlState::Stopping);
|
||||||
debugMessage("Queue: Stopping for all workers");
|
debugMessage("Queue: Stopping for all workers");
|
||||||
|
|
||||||
@@ -1214,6 +1216,7 @@ bool RunControlPrivate::isAllowedTransition(RunControlState from, RunControlStat
|
|||||||
|| to == RunControlState::Finishing;
|
|| to == RunControlState::Finishing;
|
||||||
case RunControlState::Starting:
|
case RunControlState::Starting:
|
||||||
return to == RunControlState::Running
|
return to == RunControlState::Running
|
||||||
|
|| to == RunControlState::Stopping
|
||||||
|| to == RunControlState::Finishing;
|
|| to == RunControlState::Finishing;
|
||||||
case RunControlState::Running:
|
case RunControlState::Running:
|
||||||
return to == RunControlState::Stopping
|
return to == RunControlState::Stopping
|
||||||
|
|||||||
Reference in New Issue
Block a user