1 | // Copyright (C) 2016 The Qt Company Ltd. |
---|---|
2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only |
3 | |
4 | #ifndef QABSTRACTTRANSITION_P_H |
5 | #define QABSTRACTTRANSITION_P_H |
6 | |
7 | // |
8 | // W A R N I N G |
9 | // ------------- |
10 | // |
11 | // This file is not part of the Qt API. It exists purely as an |
12 | // implementation detail. This header file may change from version to |
13 | // version without notice, or even be removed. |
14 | // |
15 | // We mean it. |
16 | // |
17 | |
18 | #include <private/qobject_p.h> |
19 | |
20 | #include <QtCore/qlist.h> |
21 | #include <QtCore/qpointer.h> |
22 | #include <QtCore/qsharedpointer.h> |
23 | |
24 | QT_REQUIRE_CONFIG(statemachine); |
25 | |
26 | QT_BEGIN_NAMESPACE |
27 | |
28 | class QAbstractState; |
29 | class QState; |
30 | class QStateMachine; |
31 | |
32 | class QAbstractTransition; |
33 | class Q_STATEMACHINE_EXPORT QAbstractTransitionPrivate |
34 | : public QObjectPrivate |
35 | { |
36 | Q_DECLARE_PUBLIC(QAbstractTransition) |
37 | public: |
38 | QAbstractTransitionPrivate() = default; |
39 | |
40 | static QAbstractTransitionPrivate *get(QAbstractTransition *q) |
41 | { return q->d_func(); } |
42 | |
43 | bool callEventTest(QEvent *e); |
44 | virtual void callOnTransition(QEvent *e); |
45 | QState *sourceState() const; |
46 | QStateMachine *machine() const; |
47 | void emitTriggered(); |
48 | |
49 | QList<QPointer<QAbstractState>> targetStates; |
50 | |
51 | Q_OBJECT_BINDABLE_PROPERTY_WITH_ARGS(QAbstractTransitionPrivate, |
52 | QAbstractTransition::TransitionType, transitionType, |
53 | QAbstractTransition::ExternalTransition); |
54 | |
55 | #if QT_CONFIG(animation) |
56 | QList<QAbstractAnimation*> animations; |
57 | #endif |
58 | }; |
59 | |
60 | QT_END_NAMESPACE |
61 | |
62 | #endif |
63 |