[Qt-interest] QStatemachine: Enter state and assignProperty() issue
Mandeep Sandhu
mandeepsandhu.chd at gmail.com
Mon Mar 21 07:17:55 CET 2011
> A few options:
>
> * Explicitly call show()/hide() in your onEntry()/onExit() functions for that
> state.
This was my first thought too when i started seeing the issue.
I think I should call show() _before_ informing the widget callback
that its state has been entered and call hide() _after_ informing the
widget that we are about to leave the state.
>
> * Provide a pair of specialised signals on that state sub-class, emit these
> from the onEntry()/onExit() functions and use these signals rather than the
> property assignment method.
This will help only if the connection to these signals is queued,
right? Otherwise connecting to these signals will be equivalent to
direct function call.
>
> * Use the QAbstractTransition::triggered() signals to toggle the widget
> visibility instead. The transition will happen before the state's onEntry().
> Not sure about the onExit() though so you;d have to check.
Hmmm, I'll check this.
Regards,
-mandeep
>
> HTH,
>
> Sean
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
>
More information about the Qt-interest-old
mailing list