statemachine/qabstractstate.cpp

Switch to Source codePreprocessed file
LineSource CodeCoverage
1 -
2 -
3 -
4 -
5 -
6QAbstractStatePrivate::QAbstractStatePrivate(StateType type) -
7 : stateType(type), isMachine(false), parentState(0) -
8{ -
9}
executed: }
Execution Count:540
540
10 -
11QAbstractStatePrivate *QAbstractStatePrivate::get(QAbstractState *q) -
12{ -
13 return q->d_func();
executed: return q->d_func();
Execution Count:17595
17595
14} -
15 -
16const QAbstractStatePrivate *QAbstractStatePrivate::get(const QAbstractState *q) -
17{ -
18 return q->d_func();
executed: return q->d_func();
Execution Count:13969
13969
19} -
20 -
21QStateMachine *QAbstractStatePrivate::machine() const -
22{ -
23 QObject *par = parent; -
24 while (par != 0) {
evaluated: par != 0
TRUEFALSE
yes
Evaluation Count:402133
yes
Evaluation Count:83
83-402133
25 if (QStateMachine *mach = qobject_cast<QStateMachine*>(par))
evaluated: QStateMachine *mach = qobject_cast<QStateMachine*>(par)
TRUEFALSE
yes
Evaluation Count:401831
yes
Evaluation Count:299
299-401831
26 return mach;
executed: return mach;
Execution Count:401831
401831
27 par = par->parent(); -
28 }
executed: }
Execution Count:299
299
29 return 0;
executed: return 0;
Execution Count:83
83
30} -
31 -
32void QAbstractStatePrivate::callOnEntry(QEvent *e) -
33{ -
34 QAbstractState * const q = q_func(); -
35 q->onEntry(e); -
36}
executed: }
Execution Count:1442
1442
37 -
38void QAbstractStatePrivate::callOnExit(QEvent *e) -
39{ -
40 QAbstractState * const q = q_func(); -
41 q->onExit(e); -
42}
executed: }
Execution Count:1271
1271
43 -
44void QAbstractStatePrivate::emitEntered() -
45{ -
46 QAbstractState * const q = q_func(); -
47 q->entered(QAbstractState::QPrivateSignal()); -
48}
executed: }
Execution Count:1442
1442
49 -
50void QAbstractStatePrivate::emitExited() -
51{ -
52 QAbstractState * const q = q_func(); -
53 q->exited(QAbstractState::QPrivateSignal()); -
54}
executed: }
Execution Count:1271
1271
55 -
56 -
57 -
58 -
59QAbstractState::QAbstractState(QState *parent) -
60 : QObject(*new QAbstractStatePrivate(QAbstractStatePrivate::AbstractState), parent) -
61{ -
62}
never executed: }
0
63 -
64 -
65 -
66 -
67QAbstractState::QAbstractState(QAbstractStatePrivate &dd, QState *parent) -
68 : QObject(dd, parent) -
69{ -
70}
executed: }
Execution Count:540
540
71 -
72 -
73 -
74 -
75QAbstractState::~QAbstractState() -
76{ -
77} -
78 -
79 -
80 -
81 -
82QState *QAbstractState::parentState() const -
83{ -
84 const QAbstractStatePrivate * const d = d_func(); -
85 if (d->parentState != parent())
evaluated: d->parentState != parent()
TRUEFALSE
yes
Evaluation Count:381
yes
Evaluation Count:29356
381-29356
86 d->parentState = qobject_cast<QState*>(parent());
executed: d->parentState = qobject_cast<QState*>(parent());
Execution Count:381
381
87 return d->parentState;
executed: return d->parentState;
Execution Count:29737
29737
88} -
89 -
90 -
91 -
92 -
93 -
94QStateMachine *QAbstractState::machine() const -
95{ -
96 const QAbstractStatePrivate * const d = d_func(); -
97 return d->machine();
executed: return d->machine();
Execution Count:401448
401448
98} -
99bool QAbstractState::event(QEvent *e) -
100{ -
101 return QObject::event(e);
executed: return QObject::event(e);
Execution Count:999
999
102} -
103 -
104 -
105 -
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial