Absolute File Name: | /home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/quick/handlers/qquickmultipointhandler_p.h |
Switch to Source code | Preprocessed file |
Line | Source | Count |
---|---|---|
1 | - | |
2 | - | |
3 | - | |
4 | - | |
5 | class __attribute__((visibility("default"))) QQuickMultiPointHandler : public QQuickPointerDeviceHandler | - |
6 | { | - |
7 | public: | - |
8 | #pragma GCC diagnostic push | - |
9 | - | |
10 | #pragma GCC diagnostic ignored "-Wsuggest-override" | - |
11 | 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: | - |
12 | #pragma GCC diagnostic ignored "-Wattributes" | - |
13 | __attribute__((visibility("hidden"))) static void qt_static_metacall(QObject *, QMetaObject::Call, int, void **); | - |
14 | #pragma GCC diagnostic pop | - |
15 | struct QPrivateSignal {}; | - |
16 | - | |
17 | - | |
18 | - | |
19 | - | |
20 | public: | - |
21 | explicit QQuickMultiPointHandler(QObject *parent = nullptr, int minimumPointCount = 2); | - |
22 | ~QQuickMultiPointHandler(); | - |
23 | - | |
24 | int minimumPointCount() const { return executed 56 times by 1 test: m_minimumPointCount;return m_minimumPointCount; Executed by:
executed 56 times by 1 test: }return m_minimumPointCount; Executed by:
| 56 |
25 | void setMinimumPointCount(int c); | - |
26 | - | |
27 | int maximumPointCount() const { return executed 6 times by 1 test: m_maximumPointCount >= 0 ? m_maximumPointCount : m_minimumPointCount;return m_maximumPointCount >= 0 ? m_maximumPointCount : m_minimumPointCount; Executed by:
executed 6 times by 1 test: }return m_maximumPointCount >= 0 ? m_maximumPointCount : m_minimumPointCount; Executed by:
| 6 |
28 | void setMaximumPointCount(int maximumPointCount); | - |
29 | - | |
30 | QQuickHandlerPoint centroid() const { return never executed: m_centroid;return m_centroid; never executed: }return m_centroid; | 0 |
31 | - | |
32 | public : | - |
33 | void minimumPointCountChanged(); | - |
34 | void maximumPointCountChanged(); | - |
35 | void pointDistanceThresholdChanged(); | - |
36 | void centroidChanged(); | - |
37 | - | |
38 | protected: | - |
39 | struct PointData { | - |
40 | PointData() : id(0), angle(0) {} never executed: end of block | 0 |
41 | PointData(quint64 id, qreal angle) : id(id), angle(angle) {} executed 99 times by 1 test: end of block Executed by:
| 99 |
42 | quint64 id; | - |
43 | qreal angle; | - |
44 | }; | - |
45 | - | |
46 | bool wantsPointerEvent(QQuickPointerEvent *event) override; | - |
47 | void handlePointerEventImpl(QQuickPointerEvent *event) override; | - |
48 | void onActiveChanged() override; | - |
49 | bool hasCurrentPoints(QQuickPointerEvent *event); | - |
50 | QVector<QQuickEventPoint *> eligiblePoints(QQuickPointerEvent *event); | - |
51 | qreal averageTouchPointDistance(const QPointF &ref); | - |
52 | qreal averageStartingDistance(const QPointF &ref); | - |
53 | qreal averageTouchPointAngle(const QPointF &ref); | - |
54 | qreal averageStartingAngle(const QPointF &ref); | - |
55 | QVector<PointData> angles(const QPointF &ref) const; | - |
56 | static qreal averageAngleDelta(const QVector<PointData> &old, const QVector<PointData> &newAngles); | - |
57 | void acceptPoints(const QVector<QQuickEventPoint *> &points); | - |
58 | bool grabPoints(QVector<QQuickEventPoint *> points); | - |
59 | - | |
60 | protected: | - |
61 | QVector<QQuickEventPoint *> m_currentPoints; | - |
62 | QQuickHandlerPoint m_centroid; | - |
63 | int m_minimumPointCount; | - |
64 | int m_maximumPointCount; | - |
65 | }; | - |
66 | - | |
67 | - | |
68 | - | |
69 | template <> struct QMetaTypeId< QQuickMultiPointHandler * > { enum { Defined = 1 }; static int qt_metatype_id() { static QBasicAtomicInt metatype_id = { 0 }; if (const int id = metatype_id.loadAcquire()) return id; const int newId = qRegisterMetaType< QQuickMultiPointHandler * >("QQuickMultiPointHandler *", reinterpret_cast< QQuickMultiPointHandler * *>(quintptr(-1))); metatype_id.storeRelease(newId); return newId; } }; template <> struct QMetaTypeId< QQmlListProperty<QQuickMultiPointHandler> > { enum { Defined = 1 }; static int qt_metatype_id() { static QBasicAtomicInt metatype_id = { 0 }; if (const int id = metatype_id.loadAcquire()) return id; const int newId = qRegisterMetaType< QQmlListProperty<QQuickMultiPointHandler> >("QQmlListProperty<QQuickMultiPointHandler>", reinterpret_cast< QQmlListProperty<QQuickMultiPointHandler> *>(quintptr(-1))); metatype_id.storeRelease(newId); return newId; } }; | - |
Switch to Source code | Preprocessed file |