OpenCoverage

qqmlglobal_p.h

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/qml/qml/qqmlglobal_p.h
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3template<class T>-
4T qmlobject_cast(QObject *object)-
5{-
6 if (object
objectDescription
TRUEevaluated 899747 times by 116 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmlcpputils
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinstantiator
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetatype
  • tst_qqmlmoduleplugin
  • tst_qqmlnativeconnector
  • tst_qqmlnotifier
  • tst_qqmlproperty
  • ...
FALSEevaluated 3676 times by 23 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlcomponent
  • tst_qqmlcpputils
  • tst_qqmltypeloader
  • tst_qquickanimations
  • tst_qquickdraghandler
  • tst_qquickgridview
  • tst_qquickitem
  • tst_qquickitem2
  • tst_qquicklistview
  • tst_qquickmousearea
  • tst_qquickmultipointtoucharea
  • tst_qquickpathview
  • tst_qquickpincharea
  • tst_qquickpointerhandler
  • tst_qquickrepeater
  • tst_qquickshortcut
  • tst_qquicktaphandler
  • tst_qquicktext
  • tst_qquickvisualdatamodel
  • tst_qquickwindow
&& QQmlMetaObject::canConvert(object, &reinterpret_cast<T>(object)->staticMetaObject)
QQmlMetaObject...ticMetaObject)Description
TRUEevaluated 703048 times by 99 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlcpputils
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmllistmodel
  • tst_qqmllistreference
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickage
  • tst_qquickanchors
  • tst_qquickangleddirection
  • ...
FALSEevaluated 196699 times by 74 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinstantiator
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetatype
  • tst_qqmlmoduleplugin
  • tst_qqmlnativeconnector
  • tst_qqmlnotifier
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • ...
)
3676-899747
7 return
executed 703048 times by 99 tests: return static_cast<T>(object);
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlcpputils
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmllistmodel
  • tst_qqmllistreference
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickage
  • tst_qquickanchors
  • tst_qquickangleddirection
  • ...
static_cast<T>(object);
executed 703048 times by 99 tests: return static_cast<T>(object);
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlcpputils
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmllistmodel
  • tst_qqmllistreference
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickage
  • tst_qquickanchors
  • tst_qquickangleddirection
  • ...
703048
8 else-
9 return
executed 200375 times by 75 tests: return 0;
Executed by:
  • tst_bindingdependencyapi
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmlcpputils
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinstantiator
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetatype
  • tst_qqmlmoduleplugin
  • tst_qqmlnativeconnector
  • tst_qqmlnotifier
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • ...
0;
executed 200375 times by 75 tests: return 0;
Executed by:
  • tst_bindingdependencyapi
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmlcpputils
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinstantiator
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetatype
  • tst_qqmlmoduleplugin
  • tst_qqmlnativeconnector
  • tst_qqmlnotifier
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • ...
200375
10}-
11-
12inline quint16 qmlSourceCoordinate(int n)-
13{-
14 return
executed 3280 times by 53 tests: return (n > 0 && n <= static_cast<int>( (0x7fff * 2 + 1) )) ? static_cast<quint16>(n) : 0;
Executed by:
  • tst_examples
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldirparser
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlerror
  • tst_qqmlexpression
  • tst_qqmlimport
  • tst_qqmlinfo
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • ...
(n > 0 && n <= static_cast<int>(
executed 3280 times by 53 tests: return (n > 0 && n <= static_cast<int>( (0x7fff * 2 + 1) )) ? static_cast<quint16>(n) : 0;
Executed by:
  • tst_examples
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldirparser
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlerror
  • tst_qqmlexpression
  • tst_qqmlimport
  • tst_qqmlinfo
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • ...
3280
15 (0x7fff * 2 + 1)
executed 3280 times by 53 tests: return (n > 0 && n <= static_cast<int>( (0x7fff * 2 + 1) )) ? static_cast<quint16>(n) : 0;
Executed by:
  • tst_examples
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldirparser
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlerror
  • tst_qqmlexpression
  • tst_qqmlimport
  • tst_qqmlinfo
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • ...
3280
16 )) ? static_cast<quint16>(n) : 0;
executed 3280 times by 53 tests: return (n > 0 && n <= static_cast<int>( (0x7fff * 2 + 1) )) ? static_cast<quint16>(n) : 0;
Executed by:
  • tst_examples
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldirparser
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlerror
  • tst_qqmlexpression
  • tst_qqmlimport
  • tst_qqmlinfo
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • ...
3280
17}-
18-
19inline int qmlSourceCoordinate(quint16 n)-
20{-
21 return
executed 4785 times by 53 tests: return (n == 0) ? -1 : static_cast<int>(n);
Executed by:
  • tst_examples
  • tst_qjsengine
  • tst_qmlcachegen
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldirparser
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlerror
  • tst_qqmlexpression
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • ...
(n == 0) ? -1 : static_cast<int>(n);
executed 4785 times by 53 tests: return (n == 0) ? -1 : static_cast<int>(n);
Executed by:
  • tst_examples
  • tst_qjsengine
  • tst_qmlcachegen
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldirparser
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlerror
  • tst_qqmlexpression
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlmoduleplugin
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmltypeloader
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • ...
4785
22}-
23bool QQml_isFileCaseCorrect(const QString &fileName, int length = -1);-
24-
25-
26-
27-
28-
29-
30inline void QQml_setParent_noEvent(QObject *object, QObject *parent)-
31{-
32 QObjectPrivate *d_ptr = QObjectPrivate::get(object);-
33 bool sce = d_ptr->sendChildEvents;-
34 d_ptr->sendChildEvents = false;-
35 object->setParent(parent);-
36 d_ptr->sendChildEvents = sce;-
37}
executed 437763 times by 131 tests: end of block
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • ...
437763
38-
39class __attribute__((visibility("default"))) QQmlValueTypeProvider-
40{-
41public:-
42 QQmlValueTypeProvider();-
43 virtual ~QQmlValueTypeProvider();-
44-
45 const QMetaObject *metaObjectForMetaType(int);-
46-
47 bool initValueType(int, QVariant&);-
48-
49 QVariant createValueType(int, int, const void *[]);-
50 bool createValueFromString(int, const QString &, void *, size_t);-
51 bool createStringFromValue(int, const void *, QString *);-
52-
53 QVariant createVariantFromString(const QString &);-
54 QVariant createVariantFromString(int, const QString &, bool *);-
55 QVariant createVariantFromJsObject(int, QQmlV4Handle, QV4::ExecutionEngine *, bool*);-
56-
57 bool equalValueType(int, const void *, const QVariant&);-
58 bool storeValueType(int, const void *, void *, size_t);-
59 bool readValueType(const QVariant&, void *, int);-
60 bool writeValueType(int, const void *, QVariant&);-
61-
62private:-
63 virtual const QMetaObject *getMetaObjectForMetaType(int);-
64 virtual bool init(int, QVariant&);-
65-
66 virtual bool create(int, int, const void *[], QVariant *);-
67 virtual bool createFromString(int, const QString &, void *, size_t);-
68 virtual bool createStringFrom(int, const void *, QString *);-
69-
70 virtual bool variantFromString(const QString &, QVariant *);-
71 virtual bool variantFromString(int, const QString &, QVariant *);-
72 virtual bool variantFromJsObject(int, QQmlV4Handle, QV4::ExecutionEngine *, QVariant *);-
73-
74 virtual bool equal(int, const void *, const QVariant&);-
75 virtual bool store(int, const void *, void *, size_t);-
76 virtual bool read(const QVariant&, void *, int);-
77 virtual bool write(int, const void *, QVariant&);-
78-
79 friend __attribute__((visibility("default"))) void QQml_addValueTypeProvider(QQmlValueTypeProvider *);-
80 friend __attribute__((visibility("default"))) void QQml_removeValueTypeProvider(QQmlValueTypeProvider *);-
81-
82 QQmlValueTypeProvider *next;-
83};-
84-
85__attribute__((visibility("default"))) void QQml_addValueTypeProvider(QQmlValueTypeProvider *);-
86__attribute__((visibility("default"))) QQmlValueTypeProvider *QQml_valueTypeProvider();-
87-
88-
89class __attribute__((visibility("default"))) QQmlColorProvider-
90{-
91public:-
92 virtual ~QQmlColorProvider();-
93 virtual QVariant colorFromString(const QString &, bool *);-
94 virtual unsigned rgbaFromString(const QString &, bool *);-
95-
96 virtual QVariant fromRgbF(double, double, double, double);-
97 virtual QVariant fromHslF(double, double, double, double);-
98 virtual QVariant fromHsvF(double, double, double, double);-
99 virtual QVariant lighter(const QVariant &, qreal);-
100 virtual QVariant darker(const QVariant &, qreal);-
101 virtual QVariant tint(const QVariant &, const QVariant &);-
102};-
103-
104__attribute__((visibility("default"))) QQmlColorProvider *QQml_setColorProvider(QQmlColorProvider *);-
105__attribute__((visibility("default"))) QQmlColorProvider *QQml_colorProvider();-
106-
107-
108class __attribute__((visibility("default"))) QQmlGuiProvider-
109{-
110public:-
111 virtual ~QQmlGuiProvider();-
112 virtual QObject *application(QObject *parent);-
113 virtual QObject *inputMethod();-
114 virtual QObject *styleHints();-
115 virtual QStringList fontFamilies();-
116 virtual bool openUrlExternally(QUrl &);-
117 virtual QString pluginName() const;-
118};-
119-
120__attribute__((visibility("default"))) QQmlGuiProvider *QQml_setGuiProvider(QQmlGuiProvider *);-
121__attribute__((visibility("default"))) QQmlGuiProvider *QQml_guiProvider();-
122-
123class QQmlApplicationPrivate;-
124-
125class __attribute__((visibility("default"))) QQmlApplication : public QObject-
126{-
127-
128 public:-
129#pragma GCC diagnostic push-
130 -
131#pragma GCC diagnostic ignored "-Wsuggest-override"-
132 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:-
133#pragma GCC diagnostic ignored "-Wattributes"-
134 __attribute__((visibility("hidden"))) static void qt_static_metacall(QObject *, QMetaObject::Call, int, void **);-
135#pragma GCC diagnostic pop-
136 struct QPrivateSignal {};-
137 -
138 -
139 -
140 -
141 -
142public:-
143 QQmlApplication(QObject* parent=nullptr);-
144-
145 QStringList args();-
146-
147 QString name() const;-
148 QString version() const;-
149 QString organization() const;-
150 QString domain() const;-
151-
152public :-
153 void setName(const QString &arg);-
154 void setVersion(const QString &arg);-
155 void setOrganization(const QString &arg);-
156 void setDomain(const QString &arg);-
157-
158public :-
159 void aboutToQuit();-
160-
161 void nameChanged();-
162 void versionChanged();-
163 void organizationChanged();-
164 void domainChanged();-
165-
166protected:-
167 QQmlApplication(QQmlApplicationPrivate &dd, QObject* parent=nullptr);-
168-
169private:-
170 QQmlApplication(const QQmlApplication &) = delete; QQmlApplication &operator=(const QQmlApplication &) = delete;-
171 inline QQmlApplicationPrivate* d_func() { return
executed 10 times by 2 tests: return reinterpret_cast<QQmlApplicationPrivate *>(qGetPtrHelper(d_ptr));
Executed by:
  • tst_qqmlapplicationengine
  • tst_qqmlecmascript
reinterpret_cast<QQmlApplicationPrivate *>(qGetPtrHelper(d_ptr));
executed 10 times by 2 tests: return reinterpret_cast<QQmlApplicationPrivate *>(qGetPtrHelper(d_ptr));
Executed by:
  • tst_qqmlapplicationengine
  • tst_qqmlecmascript
} inline const QQmlApplicationPrivate* d_func() const { return
never executed: return reinterpret_cast<const QQmlApplicationPrivate *>(qGetPtrHelper(d_ptr));
reinterpret_cast<const QQmlApplicationPrivate *>(qGetPtrHelper(d_ptr));
never executed: return reinterpret_cast<const QQmlApplicationPrivate *>(qGetPtrHelper(d_ptr));
} friend class QQmlApplicationPrivate;
0-10
172};-
173-
174class QQmlApplicationPrivate : public QObjectPrivate-
175{-
176 inline QQmlApplication* q_func() { return static_cast<QQmlApplication *>(q_ptr); } inline const QQmlApplication* q_func() const { return static_cast<const QQmlApplication *>(q_ptr); } friend class QQmlApplication;-
177public:-
178 QQmlApplicationPrivate() {-
179 argsInit = false;-
180 }
executed 18 times by 6 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlapplicationengine
  • tst_qqmlecmascript
  • tst_qquickapplication
  • tst_qquickscreen
  • tst_qquickwindow
18
181-
182 bool argsInit;-
183 QStringList args;-
184};-
185-
186struct QQmlSourceLocation-
187{-
188 QQmlSourceLocation() {}-
189 QQmlSourceLocation(const QString &sourceFile, quint16 line, quint16 column)-
190 : sourceFile(sourceFile), line(line), column(column) {}
executed 98 times by 8 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlprofilerservice
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlvaluetypes
  • tst_qquickpathview
  • tst_qquicktextinput
98
191 QString sourceFile;-
192 quint16 line = 0;-
193 quint16 column = 0;-
194};-
195-
196-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.2.0