[Interest] SignalTranisition: using of signal arguments within onTriggered handler?

Jan Krause jan.krause.no19 at gmail.com
Fri Apr 21 15:26:24 CEST 2017


Hi all,

a transition of a state machine has normally the properties 
trigger/signal, guard, action... a SignalTransition 
(http://doc.qt.io/qt-5/qml-qtqml-statemachine-signaltransition.html) of 
the declarative state machine framework has signal + guard ...

where is the action property?
there is a onTriggered handler -> but how can I use the arguments of the 
trigger signal in the onTriggered handler?

for example:

signal triggerSignal(int myIntParam);
SignalTransition {
   targetState: state_2
   signal: triggerSignal
   guard: myIntParam < 10
   onTriggered: console.log("myIntParam: "+myIntParam)
}

is this possible? or is there an other way to use signal arguments 
within onTriggered?

thanks and cheers
Jan



More information about the Interest mailing list