summaryrefslogtreecommitdiffstats
path: root/src/corelib/statemachine/qstatemachine_p.h
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2012-07-12 20:00:15 +0200
committerQt by Nokia <qt-info@nokia.com>2012-07-13 12:09:42 +0200
commit058246c53767dc99ff466882cd890db8ebd7bd49 (patch)
treea576b498e4bc9da4ce67c230e195fa617df50e82 /src/corelib/statemachine/qstatemachine_p.h
parent08345c5dac13ecee3c239a79eae4565050493710 (diff)
statemachine: Small refactoring of transition registration
Split the guts of registerTransitions() into a registerTransition() function. This allows a particular transition to be registered, instead of walking the source state's whole list of transitions every time. Move the logic for determining whether a transition should be registered to the state machine, since that's also where the actual registration takes place. Change-Id: I0496dee9454cd77b62cf2768942a82a96b320744 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
Diffstat (limited to 'src/corelib/statemachine/qstatemachine_p.h')
-rw-r--r--src/corelib/statemachine/qstatemachine_p.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/corelib/statemachine/qstatemachine_p.h b/src/corelib/statemachine/qstatemachine_p.h
index 113f17f973..f3291e7d35 100644
--- a/src/corelib/statemachine/qstatemachine_p.h
+++ b/src/corelib/statemachine/qstatemachine_p.h
@@ -170,9 +170,13 @@ public:
void goToState(QAbstractState *targetState);
void registerTransitions(QAbstractState *state);
+ void maybeRegisterTransition(QAbstractTransition *transition);
+ void registerTransition(QAbstractTransition *transition);
+ void maybeRegisterSignalTransition(QSignalTransition *transition);
void registerSignalTransition(QSignalTransition *transition);
void unregisterSignalTransition(QSignalTransition *transition);
#ifndef QT_NO_STATEMACHINE_EVENTFILTER
+ void maybeRegisterEventTransition(QEventTransition *transition);
void registerEventTransition(QEventTransition *transition);
void unregisterEventTransition(QEventTransition *transition);
void handleFilteredEvent(QObject *watched, QEvent *event);