statemachine/qmouseeventtransition.cpp

Switch to Source codePreprocessed file
LineSource CodeCoverage
1 -
2 -
3 -
4 -
5 -
6class QMouseEventTransitionPrivate : public QEventTransitionPrivate -
7{ -
8 inline QMouseEventTransition* q_func() { return static_cast<QMouseEventTransition *>(q_ptr); } inline const QMouseEventTransition* q_func() const { return static_cast<const QMouseEventTransition *>(q_ptr); } friend class QMouseEventTransition; -
9public: -
10 QMouseEventTransitionPrivate(); -
11 -
12 QBasicMouseEventTransition *transition; -
13}; -
14 -
15QMouseEventTransitionPrivate::QMouseEventTransitionPrivate() -
16{ -
17} -
18 -
19 -
20 -
21 -
22QMouseEventTransition::QMouseEventTransition(QState *sourceState) -
23 : QEventTransition(*new QMouseEventTransitionPrivate, sourceState) -
24{ -
25 QMouseEventTransitionPrivate * const d = d_func(); -
26 d->transition = new QBasicMouseEventTransition(); -
27}
executed: }
Execution Count:1
1
28 -
29 -
30 -
31 -
32 -
33QMouseEventTransition::QMouseEventTransition(QObject *object, QEvent::Type type, -
34 Qt::MouseButton button, -
35 QState *sourceState) -
36 : QEventTransition(*new QMouseEventTransitionPrivate, object, type, sourceState) -
37{ -
38 QMouseEventTransitionPrivate * const d = d_func(); -
39 d->transition = new QBasicMouseEventTransition(type, button); -
40}
executed: }
Execution Count:1
1
41 -
42 -
43 -
44 -
45QMouseEventTransition::~QMouseEventTransition() -
46{ -
47 QMouseEventTransitionPrivate * const d = d_func(); -
48 delete d->transition; -
49}
executed: }
Execution Count:2
2
50 -
51 -
52 -
53 -
54Qt::MouseButton QMouseEventTransition::button() const -
55{ -
56 const QMouseEventTransitionPrivate * const d = d_func(); -
57 return d->transition->button();
executed: return d->transition->button();
Execution Count:2
2
58} -
59 -
60 -
61 -
62 -
63void QMouseEventTransition::setButton(Qt::MouseButton button) -
64{ -
65 QMouseEventTransitionPrivate * const d = d_func(); -
66 d->transition->setButton(button); -
67}
executed: }
Execution Count:1
1
68 -
69 -
70 -
71 -
72 -
73Qt::KeyboardModifiers QMouseEventTransition::modifierMask() const -
74{ -
75 const QMouseEventTransitionPrivate * const d = d_func(); -
76 return d->transition->modifierMask();
never executed: return d->transition->modifierMask();
0
77} -
78 -
79 -
80 -
81 -
82 -
83void QMouseEventTransition::setModifierMask(Qt::KeyboardModifiers modifierMask) -
84{ -
85 QMouseEventTransitionPrivate * const d = d_func(); -
86 d->transition->setModifierMask(modifierMask); -
87}
never executed: }
0
88 -
89 -
90 -
91 -
92QPainterPath QMouseEventTransition::hitTestPath() const -
93{ -
94 const QMouseEventTransitionPrivate * const d = d_func(); -
95 return d->transition->hitTestPath();
never executed: return d->transition->hitTestPath();
0
96} -
97void QMouseEventTransition::setHitTestPath(const QPainterPath &path) -
98{ -
99 QMouseEventTransitionPrivate * const d = d_func(); -
100 d->transition->setHitTestPath(path); -
101}
never executed: }
0
102 -
103 -
104 -
105 -
106bool QMouseEventTransition::eventTest(QEvent *event) -
107{ -
108 const QMouseEventTransitionPrivate * const d = d_func(); -
109 if (!QEventTransition::eventTest(event))
evaluated: !QEventTransition::eventTest(event)
TRUEFALSE
yes
Evaluation Count:10
yes
Evaluation Count:5
5-10
110 return false;
executed: return false;
Execution Count:10
10
111 QStateMachine::WrappedEvent *we = static_cast<QStateMachine::WrappedEvent*>(event); -
112 d->transition->setEventType(we->event()->type()); -
113 return QAbstractTransitionPrivate::get(d->transition)->callEventTest(we->event());
executed: return QAbstractTransitionPrivate::get(d->transition)->callEventTest(we->event());
Execution Count:5
5
114} -
115 -
116 -
117 -
118 -
119void QMouseEventTransition::onTransition(QEvent *event) -
120{ -
121 QEventTransition::onTransition(event); -
122}
executed: }
Execution Count:5
5
123 -
124 -
125 -
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial