OpenCoverage

qqmlvaluetype.cpp

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/qml/qml/qqmlvaluetype.cpp
Source codeSwitch to Preprocessed file
LineSourceCount
1/****************************************************************************-
2**-
3** Copyright (C) 2016 The Qt Company Ltd.-
4** Contact: https://www.qt.io/licensing/-
5**-
6** This file is part of the QtQml module of the Qt Toolkit.-
7**-
8** $QT_BEGIN_LICENSE:LGPL$-
9** Commercial License Usage-
10** Licensees holding valid commercial Qt licenses may use this file in-
11** accordance with the commercial license agreement provided with the-
12** Software or, alternatively, in accordance with the terms contained in-
13** a written agreement between you and The Qt Company. For licensing terms-
14** and conditions see https://www.qt.io/terms-conditions. For further-
15** information use the contact form at https://www.qt.io/contact-us.-
16**-
17** GNU Lesser General Public License Usage-
18** Alternatively, this file may be used under the terms of the GNU Lesser-
19** General Public License version 3 as published by the Free Software-
20** Foundation and appearing in the file LICENSE.LGPL3 included in the-
21** packaging of this file. Please review the following information to-
22** ensure the GNU Lesser General Public License version 3 requirements-
23** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.-
24**-
25** GNU General Public License Usage-
26** Alternatively, this file may be used under the terms of the GNU-
27** General Public License version 2.0 or (at your option) the GNU General-
28** Public license version 3 or any later version approved by the KDE Free-
29** Qt Foundation. The licenses are as published by the Free Software-
30** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3-
31** included in the packaging of this file. Please review the following-
32** information to ensure the GNU General Public License requirements will-
33** be met: https://www.gnu.org/licenses/gpl-2.0.html and-
34** https://www.gnu.org/licenses/gpl-3.0.html.-
35**-
36** $QT_END_LICENSE$-
37**-
38****************************************************************************/-
39-
40#include "qqmlvaluetype_p.h"-
41#include "qqmlmetatype_p.h"-
42-
43#include <private/qqmlglobal_p.h>-
44#include <QtCore/qdebug.h>-
45#include <private/qmetaobjectbuilder_p.h>-
46#include <private/qqmlmodelindexvaluetype_p.h>-
47#include <private/qmetatype_p.h>-
48-
49QT_BEGIN_NAMESPACE-
50-
51namespace {-
52-
53struct QQmlValueTypeFactoryImpl-
54{-
55 QQmlValueTypeFactoryImpl();-
56 ~QQmlValueTypeFactoryImpl();-
57-
58 bool isValueType(int idx);-
59-
60 const QMetaObject *metaObjectForMetaType(int);-
61 QQmlValueType *valueType(int);-
62-
63 QQmlValueType *valueTypes[QVariant::UserType];-
64 QHash<int, QQmlValueType *> userTypes;-
65 QMutex mutex;-
66};-
67-
68QQmlValueTypeFactoryImpl::QQmlValueTypeFactoryImpl()-
69{-
70 for (unsigned int ii = 0; ii < QVariant::UserType; ++ii)
ii < QVariant::UserTypeDescription
TRUEevaluated 296960 times by 132 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
FALSEevaluated 290 times by 132 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
290-296960
71 valueTypes[ii] = nullptr;
executed 296960 times by 132 tests: valueTypes[ii] = nullptr;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
296960
72-
73 // See types wrapped in qqmlmodelindexvaluetype_p.h-
74 qRegisterMetaType<QItemSelectionRange>();-
75}
executed 290 times by 132 tests: end of block
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
290
76-
77QQmlValueTypeFactoryImpl::~QQmlValueTypeFactoryImpl()-
78{-
79 qDeleteAll(valueTypes, valueTypes + QVariant::UserType);-
80 qDeleteAll(userTypes);-
81}
executed 290 times by 132 tests: end of block
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
290
82-
83bool QQmlValueTypeFactoryImpl::isValueType(int idx)-
84{-
85 if (idx >= (int)QVariant::UserType) {
idx >= (int)QVariant::UserTypeDescription
TRUEevaluated 99947 times by 100 tests
Evaluated by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlprofilerservice
  • tst_qqmlproperty
  • tst_qqmlsettings
  • tst_qqmltimer
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • ...
FALSEevaluated 316994 times by 67 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • ...
99947-316994
86 return (valueType(idx) != nullptr);
executed 99947 times by 100 tests: return (valueType(idx) != nullptr);
Executed by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlprofilerservice
  • tst_qqmlproperty
  • tst_qqmlsettings
  • tst_qqmltimer
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • ...
99947
87 } else if (idx >= 0
idx >= 0Description
TRUEevaluated 316994 times by 67 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • ...
FALSEnever evaluated
0-316994
88 && idx != QVariant::StringList
idx != QVariant::StringListDescription
TRUEevaluated 315432 times by 66 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • ...
FALSEevaluated 1562 times by 9 tests
Evaluated by:
  • tst_qqmlapplicationengine
  • tst_qqmlecmascript
  • tst_qquickanimationcontroller
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquicklayouts
  • tst_qquickvisualdatamodel
  • tst_quicktestmainwithsetup
  • tst_testfiltering
1562-315432
89 && idx != QMetaType::QObjectStar
idx != QMetaType::QObjectStarDescription
TRUEevaluated 313094 times by 59 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsonbinding
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • ...
FALSEevaluated 2338 times by 29 tests
Evaluated by:
  • tst_examples
  • tst_qjsengine
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlvaluetypes
  • tst_qquickanimationcontroller
  • tst_qquickgridview
  • tst_qquickitemlayer
  • tst_qquicklayouts
  • tst_qquicklistview
  • tst_qquickmousearea
  • tst_qquickpathview
  • tst_qquickrepeater
  • ...
2338-313094
90 && idx != QMetaType::VoidStar
idx != QMetaType::VoidStarDescription
TRUEevaluated 313094 times by 59 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsonbinding
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • ...
FALSEnever evaluated
0-313094
91 && idx != QMetaType::Nullptr
idx != QMetaType::NullptrDescription
TRUEevaluated 313084 times by 59 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsonbinding
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • ...
FALSEevaluated 10 times by 2 tests
Evaluated by:
  • tst_examples
  • tst_qqmlecmascript
10-313084
92 && idx != QMetaType::QVariant
idx != QMetaType::QVariantDescription
TRUEevaluated 312768 times by 59 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsonbinding
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • ...
FALSEevaluated 316 times by 2 tests
Evaluated by:
  • tst_examples
  • tst_qqmlenginedebugservice
316-312768
93 && idx != QMetaType::QLocale) {
idx != QMetaType::QLocaleDescription
TRUEevaluated 312734 times by 59 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsonbinding
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • ...
FALSEevaluated 34 times by 1 test
Evaluated by:
  • tst_qqmlvaluetypes
34-312734
94 return true;
executed 312734 times by 59 tests: return true;
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsonbinding
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • ...
312734
95 }-
96-
97 return false;
executed 4260 times by 31 tests: return false;
Executed by:
  • tst_examples
  • tst_qjsengine
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlpropertymap
  • tst_qqmlvaluetypes
  • tst_qquickanimationcontroller
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquickitemlayer
  • tst_qquicklayouts
  • tst_qquicklistview
  • tst_qquickmousearea
  • ...
4260
98}-
99-
100const QMetaObject *QQmlValueTypeFactoryImpl::metaObjectForMetaType(int t)-
101{-
102 switch (t) {-
103 case QVariant::Point:
executed 146 times by 5 tests: case QVariant::Point:
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlproperty
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickmousearea
146
104 return &QQmlPointValueType::staticMetaObject;
executed 146 times by 5 tests: return &QQmlPointValueType::staticMetaObject;
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlproperty
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickmousearea
146
105 case QVariant::PointF:
executed 361188 times by 24 tests: case QVariant::PointF:
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_qqmlecmascript
  • tst_qqmllistmodel
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickanimationcontroller
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • tst_qquickdynamicpropertyanimation
  • tst_qquickflickable
  • tst_qquickgridview
  • tst_qquickitem
  • tst_qquickitem2
  • tst_qquicklayouts
  • tst_qquicklistview
  • tst_qquickpincharea
  • tst_qquickpositioners
  • tst_qquicktaphandler
  • tst_quicktestmainwithsetup
  • tst_testfiltering
361188
106 return &QQmlPointFValueType::staticMetaObject;
executed 361188 times by 24 tests: return &QQmlPointFValueType::staticMetaObject;
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_qqmlecmascript
  • tst_qqmllistmodel
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickanimationcontroller
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • tst_qquickdynamicpropertyanimation
  • tst_qquickflickable
  • tst_qquickgridview
  • tst_qquickitem
  • tst_qquickitem2
  • tst_qquicklayouts
  • tst_qquicklistview
  • tst_qquickpincharea
  • tst_qquickpositioners
  • tst_qquicktaphandler
  • tst_quicktestmainwithsetup
  • tst_testfiltering
361188
107 case QVariant::Size:
executed 240 times by 8 tests: case QVariant::Size:
Executed by:
  • tst_examples
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickanimatedimage
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickimage
  • tst_qquickshadereffect
240
108 return &QQmlSizeValueType::staticMetaObject;
executed 240 times by 8 tests: return &QQmlSizeValueType::staticMetaObject;
Executed by:
  • tst_examples
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickanimatedimage
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickimage
  • tst_qquickshadereffect
240
109 case QVariant::SizeF:
executed 220 times by 7 tests: case QVariant::SizeF:
Executed by:
  • tst_examples
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdynamicpropertyanimation
  • tst_sharedimage
220
110 return &QQmlSizeFValueType::staticMetaObject;
executed 220 times by 7 tests: return &QQmlSizeFValueType::staticMetaObject;
Executed by:
  • tst_examples
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdynamicpropertyanimation
  • tst_sharedimage
220
111 case QVariant::Rect:
executed 200 times by 3 tests: case QVariant::Rect:
Executed by:
  • tst_qqmlproperty
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
200
112 return &QQmlRectValueType::staticMetaObject;
executed 200 times by 3 tests: return &QQmlRectValueType::staticMetaObject;
Executed by:
  • tst_qqmlproperty
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
200
113 case QVariant::RectF:
executed 848 times by 15 tests: case QVariant::RectF:
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmllistmodel
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickanimationcontroller
  • tst_qquickdesignersupport
  • tst_qquickdynamicpropertyanimation
  • tst_qquickitem2
  • tst_qquickitemlayer
  • tst_qquicklayouts
  • tst_quicktestmainwithsetup
  • tst_testfiltering
848
114 return &QQmlRectFValueType::staticMetaObject;
executed 848 times by 15 tests: return &QQmlRectFValueType::staticMetaObject;
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmllistmodel
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickanimationcontroller
  • tst_qquickdesignersupport
  • tst_qquickdynamicpropertyanimation
  • tst_qquickitem2
  • tst_qquickitemlayer
  • tst_qquicklayouts
  • tst_quicktestmainwithsetup
  • tst_testfiltering
848
115 case QVariant::EasingCurve:
executed 698 times by 7 tests: case QVariant::EasingCurve:
Executed by:
  • tst_examples
  • tst_qqmlenginedebugservice
  • tst_qquickanimations
  • tst_qquickflickable
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
698
116 return &QQmlEasingValueType::staticMetaObject;
executed 698 times by 7 tests: return &QQmlEasingValueType::staticMetaObject;
Executed by:
  • tst_examples
  • tst_qqmlenginedebugservice
  • tst_qquickanimations
  • tst_qquickflickable
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
698
117 case QVariant::ModelIndex:
executed 148 times by 4 tests: case QVariant::ModelIndex:
Executed by:
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qquickpathview
  • tst_qquickvisualdatamodel
148
118 return &QQmlModelIndexValueType::staticMetaObject;
executed 148 times by 4 tests: return &QQmlModelIndexValueType::staticMetaObject;
Executed by:
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qquickpathview
  • tst_qquickvisualdatamodel
148
119 case QVariant::PersistentModelIndex:
executed 56 times by 1 test: case QVariant::PersistentModelIndex:
Executed by:
  • tst_qqmlitemmodels
56
120 return &QQmlPersistentModelIndexValueType::staticMetaObject;
executed 56 times by 1 test: return &QQmlPersistentModelIndexValueType::staticMetaObject;
Executed by:
  • tst_qqmlitemmodels
56
121 default:
executed 347708 times by 131 tests: default:
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
347708
122 if (t == qMetaTypeId<QItemSelectionRange>())
t == qMetaType...ectionRange>()Description
TRUEevaluated 42 times by 1 test
Evaluated by:
  • tst_qqmlitemmodels
FALSEevaluated 347666 times by 131 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
42-347666
123 return &QQmlItemSelectionRangeValueType::staticMetaObject;
executed 42 times by 1 test: return &QQmlItemSelectionRangeValueType::staticMetaObject;
Executed by:
  • tst_qqmlitemmodels
42
124-
125 if (const QMetaObject *mo = QQml_valueTypeProvider()->metaObjectForMetaType(t))
const QMetaObj...ForMetaType(t)Description
TRUEevaluated 12919 times by 36 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlmetaobject
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickdraghandler
  • tst_qquickdynamicpropertyanimation
  • tst_qquickflickable
  • tst_qquickflipable
  • tst_qquickfocusscope
  • tst_qquickfontloader_static
  • tst_qquickgridview
  • tst_qquickitem2
  • ...
FALSEevaluated 334747 times by 130 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
12919-334747
126 return mo;
executed 12919 times by 36 tests: return mo;
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlmetaobject
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickdraghandler
  • tst_qquickdynamicpropertyanimation
  • tst_qquickflickable
  • tst_qquickflipable
  • tst_qquickfocusscope
  • tst_qquickfontloader_static
  • tst_qquickgridview
  • tst_qquickitem2
  • ...
12919
127 break;
executed 334747 times by 130 tests: break;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
334747
128 }-
129-
130 QMetaType metaType(t);-
131 if (metaType.flags() & QMetaType::IsGadget)
metaType.flags...Type::IsGadgetDescription
TRUEevaluated 2084 times by 4 tests
Evaluated by:
  • tst_flickableinterop
  • tst_qqmlvaluetypes
  • tst_qquickdraghandler
  • tst_qquicktaphandler
FALSEevaluated 332663 times by 130 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
2084-332663
132 return metaType.metaObject();
executed 2084 times by 4 tests: return metaType.metaObject();
Executed by:
  • tst_flickableinterop
  • tst_qqmlvaluetypes
  • tst_qquickdraghandler
  • tst_qquicktaphandler
2084
133 return nullptr;
executed 332663 times by 130 tests: return nullptr;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
332663
134}-
135-
136QQmlValueType *QQmlValueTypeFactoryImpl::valueType(int idx)-
137{-
138 if (idx >= (int)QVariant::UserType) {
idx >= (int)QVariant::UserTypeDescription
TRUEevaluated 102201 times by 100 tests
Evaluated by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlprofilerservice
  • tst_qqmlproperty
  • tst_qqmlsettings
  • tst_qqmltimer
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • ...
FALSEevaluated 411498 times by 55 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
102201-411498
139 // Protect the hash with a mutex-
140 mutex.lock();-
141-
142 QHash<int, QQmlValueType *>::iterator it = userTypes.find(idx);-
143 if (it == userTypes.end()) {
it == userTypes.end()Description
TRUEevaluated 634 times by 100 tests
Evaluated by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlprofilerservice
  • tst_qqmlproperty
  • tst_qqmlsettings
  • tst_qqmltimer
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • ...
FALSEevaluated 101567 times by 93 tests
Evaluated by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlproperty
  • tst_qqmlsettings
  • tst_qqmltimer
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickage
  • tst_qquickanchors
  • tst_qquickangleddirection
  • tst_qquickanimatedimage
  • ...
634-101567
144 QQmlValueType *vt = nullptr;-
145 if (const QMetaObject *mo = metaObjectForMetaType(idx))
const QMetaObj...rMetaType(idx)Description
TRUEevaluated 22 times by 6 tests
Evaluated by:
  • tst_flickableinterop
  • tst_qqmlitemmodels
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdraghandler
  • tst_qquicktaphandler
FALSEevaluated 612 times by 99 tests
Evaluated by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlprofilerservice
  • tst_qqmlproperty
  • tst_qqmlsettings
  • tst_qqmltimer
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • ...
22-612
146 vt = new QQmlValueType(idx, mo);
executed 22 times by 6 tests: vt = new QQmlValueType(idx, mo);
Executed by:
  • tst_flickableinterop
  • tst_qqmlitemmodels
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdraghandler
  • tst_qquicktaphandler
22
147 it = userTypes.insert(idx, vt);-
148 }
executed 634 times by 100 tests: end of block
Executed by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlprofilerservice
  • tst_qqmlproperty
  • tst_qqmlsettings
  • tst_qqmltimer
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • ...
634
149-
150 mutex.unlock();-
151 return *it;
executed 102201 times by 100 tests: return *it;
Executed by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qmlcachegen
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlprofilerservice
  • tst_qqmlproperty
  • tst_qqmlsettings
  • tst_qqmltimer
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • ...
102201
152 }-
153-
154 QQmlValueType *rv = valueTypes[idx];-
155 if (!rv) {
!rvDescription
TRUEevaluated 506 times by 55 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
FALSEevaluated 410992 times by 48 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlitemmodels
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • tst_qquickdynamicpropertyanimation
  • tst_qquickflickable
  • tst_qquickflipable
  • ...
506-410992
156 // No need for mutex protection - the most we can lose is a valueType instance-
157-
158 // TODO: Investigate the performance/memory characteristics of-
159 // removing the preallocated array-
160 if (const QMetaObject *mo = metaObjectForMetaType(idx)) {
const QMetaObj...rMetaType(idx)Description
TRUEevaluated 288 times by 55 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
FALSEevaluated 218 times by 2 tests
Evaluated by:
  • tst_qqmlvaluetypes
  • tst_qquickdesignersupport
218-288
161 rv = new QQmlValueType(idx, mo);-
162 valueTypes[idx] = rv;-
163 }
executed 288 times by 55 tests: end of block
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
288
164 }
executed 506 times by 55 tests: end of block
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
506
165-
166 return rv;
executed 411498 times by 55 tests: return rv;
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
411498
167}-
168-
169}-
170-
171Q_GLOBAL_STATIC(QQmlValueTypeFactoryImpl, factoryImpl);
executed 290 times by 132 tests: end of block
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
executed 290 times by 132 tests: guard.store(QtGlobalStatic::Destroyed);
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
executed 1541005 times by 132 tests: return &holder.value;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
guard.load() =...c::InitializedDescription
TRUEevaluated 290 times by 132 tests
Evaluated by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
FALSEnever evaluated
0-1541005
172-
173bool QQmlValueTypeFactory::isValueType(int idx)-
174{-
175 return factoryImpl()->isValueType(idx);
executed 416941 times by 115 tests: return factoryImpl()->isValueType(idx);
Executed by:
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmllocale
  • ...
416941
176}-
177-
178QQmlValueType *QQmlValueTypeFactory::valueType(int idx)-
179{-
180 return factoryImpl()->valueType(idx);
executed 413752 times by 55 tests: return factoryImpl()->valueType(idx);
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
413752
181}-
182-
183const QMetaObject *QQmlValueTypeFactory::metaObjectForMetaType(int type)-
184{-
185 return factoryImpl()->metaObjectForMetaType(type);
executed 710312 times by 131 tests: return factoryImpl()->metaObjectForMetaType(type);
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • ...
710312
186}-
187-
188void QQmlValueTypeFactory::registerValueTypes(const char *uri, int versionMajor, int versionMinor)-
189{-
190 qmlRegisterValueTypeEnums<QQmlEasingValueType>(uri, versionMajor, versionMinor, "Easing");-
191}
executed 374 times by 132 tests: end of block
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugjs
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmlimport
  • tst_qqmlincubator
  • tst_qqmlinfo
  • tst_qqmlinstantiator
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • ...
374
192-
193QQmlValueType::QQmlValueType(int typeId, const QMetaObject *gadgetMetaObject)-
194 : gadgetPtr(QMetaType::create(typeId))-
195 , typeId(typeId)-
196 , metaType(typeId)-
197{-
198 QObjectPrivate *op = QObjectPrivate::get(this);-
199 Q_ASSERT(!op->metaObject);-
200 op->metaObject = this;-
201-
202 QMetaObjectBuilder builder(gadgetMetaObject);-
203 _metaObject = builder.toMetaObject();-
204-
205 *static_cast<QMetaObject*>(this) = *_metaObject;-
206}
executed 310 times by 55 tests: end of block
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
310
207-
208QQmlValueType::~QQmlValueType()-
209{-
210 QObjectPrivate *op = QObjectPrivate::get(this);-
211 Q_ASSERT(op->metaObject == this);-
212 op->metaObject = nullptr;-
213 ::free(const_cast<QMetaObject *>(_metaObject));-
214 metaType.destroy(gadgetPtr);-
215}
executed 310 times by 55 tests: end of block
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlitemmodels
  • tst_qqmllistmodel
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • tst_qquickbehaviors
  • tst_qquickborderimage
  • tst_qquickdesignersupport
  • tst_qquickdrag
  • tst_qquickdraghandler
  • ...
310
216-
217void QQmlValueType::read(QObject *obj, int idx)-
218{-
219 void *a[] = { gadgetPtr, nullptr };-
220 QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);-
221}
executed 44398 times by 26 tests: end of block
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdraghandler
  • tst_qquickflipable
  • tst_qquickfocusscope
  • tst_qquickfontloader_static
  • tst_qquickgridview
  • tst_qquickimage
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickrepeater
  • tst_qquickshadereffect
  • tst_qquickstates
  • tst_qquicktaphandler
  • tst_qquicktext
  • tst_qquicktextedit
  • ...
44398
222-
223void QQmlValueType::write(QObject *obj, int idx, QQmlPropertyData::WriteFlags flags)-
224{-
225 Q_ASSERT(gadgetPtr);-
226 int status = -1;-
227 void *a[] = { gadgetPtr, nullptr, &status, &flags };-
228 QMetaObject::metacall(obj, QMetaObject::WriteProperty, idx, a);-
229}
executed 44362 times by 26 tests: end of block
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdraghandler
  • tst_qquickflipable
  • tst_qquickfocusscope
  • tst_qquickfontloader_static
  • tst_qquickgridview
  • tst_qquickimage
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickrepeater
  • tst_qquickshadereffect
  • tst_qquickstates
  • tst_qquicktaphandler
  • tst_qquicktext
  • tst_qquicktextedit
  • ...
44362
230-
231QVariant QQmlValueType::value()-
232{-
233 Q_ASSERT(gadgetPtr);-
234 return QVariant(typeId, gadgetPtr);
never executed: return QVariant(typeId, gadgetPtr);
0
235}-
236-
237void QQmlValueType::setValue(const QVariant &value)-
238{-
239 Q_ASSERT(typeId == value.userType());-
240 metaType.destruct(gadgetPtr);-
241 metaType.construct(gadgetPtr, value.constData());-
242}
executed 28 times by 3 tests: end of block
Executed by:
  • tst_qqmlvaluetypes
  • tst_qquickbehaviors
  • tst_qquickdesignersupport
28
243-
244QAbstractDynamicMetaObject *QQmlValueType::toDynamicMetaObject(QObject *)-
245{-
246 return this;
executed 136 times by 7 tests: return this;
Executed by:
  • tst_qqmlproperty
  • tst_qqmlvaluetypes
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdesignersupport
  • tst_qquicklistview
  • tst_qquicktext
136
247}-
248-
249void QQmlValueType::objectDestroyed(QObject *)-
250{-
251}-
252-
253int QQmlValueType::metaCall(QObject *, QMetaObject::Call type, int _id, void **argv)-
254{-
255 const QMetaObject *mo = _metaObject;-
256 QQmlMetaObject::resolveGadgetMethodOrPropertyIndex(type, &mo, &_id);-
257 mo->d.static_metacall(reinterpret_cast<QObject*>(gadgetPtr), type, _id, argv);-
258 return _id;
executed 44374 times by 26 tests: return _id;
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickaccessible
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdraghandler
  • tst_qquickflipable
  • tst_qquickfocusscope
  • tst_qquickfontloader_static
  • tst_qquickgridview
  • tst_qquickimage
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickrepeater
  • tst_qquickshadereffect
  • tst_qquickstates
  • tst_qquicktaphandler
  • tst_qquicktext
  • tst_qquicktextedit
  • ...
44374
259}-
260-
261QString QQmlPointFValueType::toString() const-
262{-
263 return QString::asprintf("QPointF(%g, %g)", v.x(), v.y());
executed 4 times by 1 test: return QString::asprintf("QPointF(%g, %g)", v.x(), v.y());
Executed by:
  • tst_qqmlvaluetypes
4
264}-
265-
266qreal QQmlPointFValueType::x() const-
267{-
268 return v.x();
executed 2130 times by 10 tests: return v.x();
Executed by:
  • tst_flickableinterop
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdrag
  • tst_qquickdraghandler
  • tst_qquickgridview
  • tst_qquickitem2
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquicktaphandler
2130
269}-
270-
271qreal QQmlPointFValueType::y() const-
272{-
273 return v.y();
executed 2138 times by 11 tests: return v.y();
Executed by:
  • tst_flickableinterop
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdrag
  • tst_qquickdraghandler
  • tst_qquickflickable
  • tst_qquickgridview
  • tst_qquickitem2
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquicktaphandler
2138
274}-
275-
276void QQmlPointFValueType::setX(qreal x)-
277{-
278 v.setX(x);-
279}
executed 266 times by 4 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlvaluetypes
  • tst_qquickdrag
  • tst_qquicklistview
266
280-
281void QQmlPointFValueType::setY(qreal y)-
282{-
283 v.setY(y);-
284}
executed 266 times by 4 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlvaluetypes
  • tst_qquickdrag
  • tst_qquicklistview
266
285-
286-
287int QQmlPointValueType::x() const-
288{-
289 return v.x();
executed 36 times by 3 tests: return v.x();
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlproperty
  • tst_qqmlvaluetypes
36
290}-
291-
292int QQmlPointValueType::y() const-
293{-
294 return v.y();
executed 24 times by 2 tests: return v.y();
Executed by:
  • tst_qqmlvaluetypes
  • tst_qquickmousearea
24
295}-
296-
297void QQmlPointValueType::setX(int x)-
298{-
299 v.setX(x);-
300}
executed 16 times by 3 tests: end of block
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlproperty
  • tst_qqmlvaluetypes
16
301-
302void QQmlPointValueType::setY(int y)-
303{-
304 v.setY(y);-
305}
executed 2 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
2
306-
307-
308QString QQmlSizeFValueType::toString() const-
309{-
310 return QString::asprintf("QSizeF(%g, %g)", v.width(), v.height());
executed 4 times by 1 test: return QString::asprintf("QSizeF(%g, %g)", v.width(), v.height());
Executed by:
  • tst_qqmlvaluetypes
4
311}-
312-
313qreal QQmlSizeFValueType::width() const-
314{-
315 return v.width();
executed 10 times by 2 tests: return v.width();
Executed by:
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
10
316}-
317-
318qreal QQmlSizeFValueType::height() const-
319{-
320 return v.height();
executed 10 times by 2 tests: return v.height();
Executed by:
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
10
321}-
322-
323void QQmlSizeFValueType::setWidth(qreal w)-
324{-
325 v.setWidth(w);-
326}
executed 2 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
2
327-
328void QQmlSizeFValueType::setHeight(qreal h)-
329{-
330 v.setHeight(h);-
331}
executed 2 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
2
332-
333-
334int QQmlSizeValueType::width() const-
335{-
336 return v.width();
executed 50 times by 3 tests: return v.width();
Executed by:
  • tst_examples
  • tst_qqmlvaluetypes
  • tst_qquickanimatedimage
50
337}-
338-
339int QQmlSizeValueType::height() const-
340{-
341 return v.height();
executed 60 times by 2 tests: return v.height();
Executed by:
  • tst_examples
  • tst_qqmlvaluetypes
60
342}-
343-
344void QQmlSizeValueType::setWidth(int w)-
345{-
346 v.setWidth(w);-
347}
executed 10 times by 2 tests: end of block
Executed by:
  • tst_qqmlvaluetypes
  • tst_qquickimage
10
348-
349void QQmlSizeValueType::setHeight(int h)-
350{-
351 v.setHeight(h);-
352}
executed 20 times by 3 tests: end of block
Executed by:
  • tst_qqmlvaluetypes
  • tst_qquickimage
  • tst_qquickshadereffect
20
353-
354QString QQmlRectFValueType::toString() const-
355{-
356 return QString::asprintf("QRectF(%g, %g, %g, %g)", v.x(), v.y(), v.width(), v.height());
executed 4 times by 1 test: return QString::asprintf("QRectF(%g, %g, %g, %g)", v.x(), v.y(), v.width(), v.height());
Executed by:
  • tst_qqmlvaluetypes
4
357}-
358-
359qreal QQmlRectFValueType::x() const-
360{-
361 return v.x();
executed 126 times by 4 tests: return v.x();
Executed by:
  • tst_examples
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickitem2
126
362}-
363-
364qreal QQmlRectFValueType::y() const-
365{-
366 return v.y();
executed 126 times by 4 tests: return v.y();
Executed by:
  • tst_examples
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickitem2
126
367}-
368-
369void QQmlRectFValueType::setX(qreal x)-
370{-
371 v.moveLeft(x);-
372}
executed 4 times by 2 tests: end of block
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlvaluetypes
4
373-
374void QQmlRectFValueType::setY(qreal y)-
375{-
376 v.moveTop(y);-
377}
executed 2 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
2
378-
379qreal QQmlRectFValueType::width() const-
380{-
381 return v.width();
executed 234 times by 4 tests: return v.width();
Executed by:
  • tst_examples
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickitem2
234
382}-
383-
384qreal QQmlRectFValueType::height() const-
385{-
386 return v.height();
executed 262 times by 4 tests: return v.height();
Executed by:
  • tst_examples
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickitem2
262
387}-
388-
389void QQmlRectFValueType::setWidth(qreal w)-
390{-
391 v.setWidth(w);-
392}
executed 2 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
2
393-
394void QQmlRectFValueType::setHeight(qreal h)-
395{-
396 v.setHeight(h);-
397}
executed 2 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
2
398-
399qreal QQmlRectFValueType::left() const-
400{-
401 return v.left();
executed 2 times by 1 test: return v.left();
Executed by:
  • tst_qqmlvaluetypes
2
402}-
403-
404qreal QQmlRectFValueType::right() const-
405{-
406 return v.right();
executed 2 times by 1 test: return v.right();
Executed by:
  • tst_qqmlvaluetypes
2
407}-
408-
409qreal QQmlRectFValueType::top() const-
410{-
411 return v.top();
executed 2 times by 1 test: return v.top();
Executed by:
  • tst_qqmlvaluetypes
2
412}-
413-
414qreal QQmlRectFValueType::bottom() const-
415{-
416 return v.bottom();
executed 2 times by 1 test: return v.bottom();
Executed by:
  • tst_qqmlvaluetypes
2
417}-
418-
419int QQmlRectValueType::x() const-
420{-
421 return v.x();
executed 34 times by 2 tests: return v.x();
Executed by:
  • tst_qqmlproperty
  • tst_qqmlvaluetypes
34
422}-
423-
424int QQmlRectValueType::y() const-
425{-
426 return v.y();
executed 6 times by 1 test: return v.y();
Executed by:
  • tst_qqmlvaluetypes
6
427}-
428-
429void QQmlRectValueType::setX(int x)-
430{-
431 v.moveLeft(x);-
432}
executed 44 times by 2 tests: end of block
Executed by:
  • tst_qqmlproperty
  • tst_qqmlvaluetypes
44
433-
434void QQmlRectValueType::setY(int y)-
435{-
436 v.moveTop(y);-
437}
executed 10 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
10
438-
439int QQmlRectValueType::width() const-
440{-
441 return v.width();
executed 6 times by 1 test: return v.width();
Executed by:
  • tst_qqmlvaluetypes
6
442}-
443-
444int QQmlRectValueType::height() const-
445{-
446 return v.height();
executed 6 times by 1 test: return v.height();
Executed by:
  • tst_qqmlvaluetypes
6
447}-
448-
449void QQmlRectValueType::setWidth(int w)-
450{-
451 v.setWidth(w);-
452}
executed 6 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
6
453-
454void QQmlRectValueType::setHeight(int h)-
455{-
456 v.setHeight(h);-
457}
executed 6 times by 1 test: end of block
Executed by:
  • tst_qqmlvaluetypes
6
458-
459int QQmlRectValueType::left() const-
460{-
461 return v.left();
executed 2 times by 1 test: return v.left();
Executed by:
  • tst_qqmlvaluetypes
2
462}-
463-
464int QQmlRectValueType::right() const-
465{-
466 return v.right();
executed 2 times by 1 test: return v.right();
Executed by:
  • tst_qqmlvaluetypes
2
467}-
468-
469int QQmlRectValueType::top() const-
470{-
471 return v.top();
executed 2 times by 1 test: return v.top();
Executed by:
  • tst_qqmlvaluetypes
2
472}-
473-
474int QQmlRectValueType::bottom() const-
475{-
476 return v.bottom();
executed 2 times by 1 test: return v.bottom();
Executed by:
  • tst_qqmlvaluetypes
2
477}-
478-
479QQmlEasingValueType::Type QQmlEasingValueType::type() const-
480{-
481 return (QQmlEasingValueType::Type)v.type();
never executed: return (QQmlEasingValueType::Type)v.type();
0
482}-
483-
484qreal QQmlEasingValueType::amplitude() const-
485{-
486 return v.amplitude();
never executed: return v.amplitude();
0
487}-
488-
489qreal QQmlEasingValueType::overshoot() const-
490{-
491 return v.overshoot();
never executed: return v.overshoot();
0
492}-
493-
494qreal QQmlEasingValueType::period() const-
495{-
496 return v.period();
never executed: return v.period();
0
497}-
498-
499void QQmlEasingValueType::setType(QQmlEasingValueType::Type type)-
500{-
501 v.setType((QEasingCurve::Type)type);-
502}
executed 486 times by 4 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickanimations
  • tst_qquickgridview
  • tst_qquicklistview
486
503-
504void QQmlEasingValueType::setAmplitude(qreal amplitude)-
505{-
506 v.setAmplitude(amplitude);-
507}
executed 10 times by 4 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickanimations
  • tst_qquickgridview
  • tst_qquicklistview
10
508-
509void QQmlEasingValueType::setOvershoot(qreal overshoot)-
510{-
511 v.setOvershoot(overshoot);-
512}
executed 4 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickanimations
4
513-
514void QQmlEasingValueType::setPeriod(qreal period)-
515{-
516 v.setPeriod(period);-
517}
executed 4 times by 2 tests: end of block
Executed by:
  • tst_examples
  • tst_qquickanimations
4
518-
519void QQmlEasingValueType::setBezierCurve(const QVariantList &customCurveVariant)-
520{-
521 if (customCurveVariant.isEmpty())
customCurveVariant.isEmpty()Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_qquickanimations
0-2
522 return;
never executed: return;
0
523-
524 QVariantList variantList = customCurveVariant;-
525 if ((variantList.count() % 6) == 0) {
(variantList.count() % 6) == 0Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qquickanimations
FALSEnever evaluated
0-2
526 bool allRealsOk = true;-
527 QVector<qreal> reals;-
528 const int variantListCount = variantList.count();-
529 reals.reserve(variantListCount);-
530 for (int i = 0; i < variantListCount; i++) {
i < variantListCountDescription
TRUEevaluated 12 times by 1 test
Evaluated by:
  • tst_qquickanimations
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_qquickanimations
2-12
531 bool ok;-
532 const qreal real = variantList.at(i).toReal(&ok);-
533 reals.append(real);-
534 if (!ok)
!okDescription
TRUEnever evaluated
FALSEevaluated 12 times by 1 test
Evaluated by:
  • tst_qquickanimations
0-12
535 allRealsOk = false;
never executed: allRealsOk = false;
0
536 }
executed 12 times by 1 test: end of block
Executed by:
  • tst_qquickanimations
12
537 if (allRealsOk) {
allRealsOkDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qquickanimations
FALSEnever evaluated
0-2
538 QEasingCurve newEasingCurve(QEasingCurve::BezierSpline);-
539 for (int i = 0; i < reals.count() / 6; i++) {
i < reals.count() / 6Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qquickanimations
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_qquickanimations
2
540 const qreal c1x = reals.at(i * 6);-
541 const qreal c1y = reals.at(i * 6 + 1);-
542 const qreal c2x = reals.at(i * 6 + 2);-
543 const qreal c2y = reals.at(i * 6 + 3);-
544 const qreal c3x = reals.at(i * 6 + 4);-
545 const qreal c3y = reals.at(i * 6 + 5);-
546-
547 const QPointF c1(c1x, c1y);-
548 const QPointF c2(c2x, c2y);-
549 const QPointF c3(c3x, c3y);-
550-
551 newEasingCurve.addCubicBezierSegment(c1, c2, c3);-
552 v = newEasingCurve;-
553 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_qquickanimations
2
554 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_qquickanimations
2
555 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_qquickanimations
2
556}
executed 2 times by 1 test: end of block
Executed by:
  • tst_qquickanimations
2
557-
558QVariantList QQmlEasingValueType::bezierCurve() const-
559{-
560 QVariantList rv;-
561 const QVector<QPointF> points = v.toCubicSpline();-
562 rv.reserve(points.size() * 2);-
563 for (const auto &point : points)-
564 rv << QVariant(point.x()) << QVariant(point.y());
never executed: rv << QVariant(point.x()) << QVariant(point.y());
0
565 return rv;
never executed: return rv;
0
566}-
567-
568QT_END_NAMESPACE-
569-
570#include "moc_qqmlvaluetype_p.cpp"-
Source codeSwitch to Preprocessed file

Generated by Squish Coco 4.2.0