OpenCoverage

qquickcustomaffector_p.h

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/particles/qquickcustomaffector_p.h
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4class QQuickCustomAffector : public QQuickParticleAffector-
5{-
6 public:-
7#pragma GCC diagnostic push-
8 -
9#pragma GCC diagnostic ignored "-Wsuggest-override"-
10 static const QMetaObject staticMetaObject; virtual const QMetaObject *metaObject() const; virtual void *qt_metacast(const char *); virtual int qt_metacall(QMetaObject::Call, int, void **); static inline QString tr(const char *s, const char *c = nullptr, int n = -1) { return staticMetaObject.tr(s, c, n); } __attribute__ ((__deprecated__)) static inline QString trUtf8(const char *s, const char *c = nullptr, int n = -1) { return staticMetaObject.tr(s, c, n); } private:-
11#pragma GCC diagnostic ignored "-Wattributes"-
12 __attribute__((visibility("hidden"))) static void qt_static_metacall(QObject *, QMetaObject::Call, int, void **);-
13#pragma GCC diagnostic pop-
14 struct QPrivateSignal {};-
15 -
16 -
17 -
18 -
19-
20public:-
21 explicit QQuickCustomAffector(QQuickItem *parent = 0);-
22 void affectSystem(qreal dt) override;-
23-
24 QQuickDirection * position() const-
25 {-
26 return
never executed: return m_position;
m_position;
never executed: return m_position;
0
27 }-
28-
29 QQuickDirection * velocity() const-
30 {-
31 return
never executed: return m_velocity;
m_velocity;
never executed: return m_velocity;
0
32 }-
33-
34 QQuickDirection * acceleration() const-
35 {-
36 return
never executed: return m_acceleration;
m_acceleration;
never executed: return m_acceleration;
0
37 }-
38-
39 void positionReset()-
40 {-
41 m_position = &m_nullVector;-
42 }
never executed: end of block
0
43-
44 void velocityReset()-
45 {-
46 m_velocity = &m_nullVector;-
47 }
never executed: end of block
0
48-
49 void accelerationReset()-
50 {-
51 m_acceleration = &m_nullVector;-
52 }
never executed: end of block
0
53-
54 bool relative() const-
55 {-
56 return
never executed: return m_relative;
m_relative;
never executed: return m_relative;
0
57 }-
58-
59-
60public :-
61 void affectParticles(QQmlV4Handle particles, qreal dt);-
62-
63 void positionChanged(QQuickDirection * arg);-
64-
65 void velocityChanged(QQuickDirection * arg);-
66-
67 void accelerationChanged(QQuickDirection * arg);-
68-
69 void relativeChanged(bool arg);-
70-
71public :-
72 void setPosition(QQuickDirection * arg)-
73 {-
74 if (m_position != arg
m_position != argDescription
TRUEevaluated 6 times by 2 tests
Evaluated by:
  • tst_examples
  • tst_qquickcustomaffector
FALSEnever evaluated
) {
0-6
75 m_position = arg;-
76 positionChanged(arg);-
77 }
executed 6 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickcustomaffector
6
78 }
executed 6 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickcustomaffector
6
79-
80 void setVelocity(QQuickDirection * arg)-
81 {-
82 if (m_velocity != arg
m_velocity != argDescription
TRUEevaluated 4 times by 2 tests
Evaluated by:
  • tst_examples
  • tst_qquickcustomaffector
FALSEnever evaluated
) {
0-4
83 m_velocity = arg;-
84 velocityChanged(arg);-
85 }
executed 4 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickcustomaffector
4
86 }
executed 4 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickcustomaffector
4
87-
88 void setAcceleration(QQuickDirection * arg)-
89 {-
90 if (m_acceleration != arg
m_acceleration != argDescription
TRUEevaluated 4 times by 2 tests
Evaluated by:
  • tst_examples
  • tst_qquickcustomaffector
FALSEnever evaluated
) {
0-4
91 m_acceleration = arg;-
92 accelerationChanged(arg);-
93 }
executed 4 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickcustomaffector
4
94 }
executed 4 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickcustomaffector
4
95-
96 void setRelative(bool arg)-
97 {-
98 if (m_relative != arg
m_relative != argDescription
TRUEevaluated 6 times by 2 tests
Evaluated by:
  • tst_examples
  • tst_qquickcustomaffector
FALSEnever evaluated
) {
0-6
99 m_relative = arg;-
100 relativeChanged(arg);-
101 }
executed 6 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickcustomaffector
6
102 }
executed 6 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickcustomaffector
6
103-
104protected:-
105 bool isAffectConnected();-
106 bool affectParticle(QQuickParticleData *d, qreal dt) override;-
107-
108private:-
109 void affectProperties(const QList<QQuickParticleData*> particles, qreal dt);-
110 QQuickDirection * m_position;-
111 QQuickDirection * m_velocity;-
112 QQuickDirection * m_acceleration;-
113-
114 QQuickDirection m_nullVector;-
115 bool m_relative;-
116};-
117-
118-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.2.0