QStateMachine and signals
I've build a QStateMachine
it changes states base on the signals
Seems to work
except if I emit signals in the loop it still move only on state
(dose not seem to que the signals)
I did wrote a slot to see the signals and
I do get all the signals in the slot
However QStateMachine only move one state (instead of 3)
for example
for (int i = 0; i < 3; ++i)
{
emit goNextState();
}
but it only moves one state
What do I need to do?
Thank you
Ross
Re: QStateMachine and signals
can you post some of your relevant code
Re: QStateMachine and signals
Hi,
Are the connections Queued? So I think that if multiple signals are emmited and the connection is Quedued then, them will be joined as only one signal.
If you are not using threads you can try using Direct connections.
If you are using threads maybe sending an dummy int value(different on every emit) on the signal will force the eventLoop to execute all the slots.