Undo: Fix state entry bug for parallel state groups
This commit reverts c4cef6fae9.
The above fix for QTBUG-25958 (cloned in QTBUG-40219) is not
complete and introduces the regression QTBUG-30049.
Task-number: QTBUG-30049, QTBUG-25958, QTBUG-40219
Change-Id: I3c4b774dce06c13cb4e089f8413a7747cedfd212
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
bb10
parent
bde755558c
commit
4124cd159e
|
|
@ -519,10 +519,6 @@ QList<QAbstractState*> QStateMachinePrivate::computeStatesToEnter(const QList<QA
|
|||
QAbstractState *s = lst.at(j);
|
||||
addStatesToEnter(s, lca, statesToEnter, statesForDefaultEntry);
|
||||
}
|
||||
for (int j = src ? 1 : 0; j < lst.size(); ++j) {
|
||||
QAbstractState *s = lst.at(j);
|
||||
addAncestorStatesToEnter(s, lca, statesToEnter, statesForDefaultEntry);
|
||||
}
|
||||
if (isParallel(lca)) {
|
||||
QList<QAbstractState*> lcac = QStatePrivate::get(lca)->childStates();
|
||||
foreach (QAbstractState* child,lcac) {
|
||||
|
|
@ -720,6 +716,7 @@ void QStateMachinePrivate::addStatesToEnter(QAbstractState *s, QState *root,
|
|||
return;
|
||||
}
|
||||
}
|
||||
addAncestorStatesToEnter(s, root, statesToEnter, statesForDefaultEntry);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1088,7 +1085,6 @@ void QStateMachinePrivate::setError(QStateMachine::Error errorCode, QAbstractSta
|
|||
if (currentErrorState != 0) {
|
||||
QState *lca = findLCA(QList<QAbstractState*>() << currentErrorState << currentContext);
|
||||
addStatesToEnter(currentErrorState, lca, pendingErrorStates, pendingErrorStatesForDefaultEntry);
|
||||
addAncestorStatesToEnter(currentErrorState, lca, pendingErrorStates, pendingErrorStatesForDefaultEntry);
|
||||
} else {
|
||||
qWarning("Unrecoverable error detected in running state machine: %s",
|
||||
qPrintable(errorString));
|
||||
|
|
|
|||
|
|
@ -4704,6 +4704,9 @@ void tst_QStateMachine::propertiesAreAssignedBeforeEntryCallbacks()
|
|||
// QTBUG-25958
|
||||
void tst_QStateMachine::multiTargetTransitionInsideParallelStateGroup()
|
||||
{
|
||||
// TODO QTBUG-25958 was reopened, see https://codereview.qt-project.org/89775
|
||||
return;
|
||||
|
||||
QStateMachine machine;
|
||||
QState *s1 = new QState(&machine);
|
||||
machine.setInitialState(s1);
|
||||
|
|
|
|||
Loading…
Reference in New Issue