diff options
author | Jarek Kobus <jaroslaw.kobus@qt.io> | 2020-07-07 14:02:36 +0200 |
---|---|---|
committer | Jarek Kobus <jaroslaw.kobus@qt.io> | 2020-07-07 19:32:07 +0200 |
commit | 8a59b2ebf081af5bb9698281420d0ce59405712d (patch) | |
tree | 354f5ca9f897667c8ee9b0765c32a1f2daabcd92 /tests | |
parent | 858e0ce0ef39e3094e09c19fa27a896be4abfe74 (diff) |
Use QList instead of QVector
Task-number: QTBUG-84469
Change-Id: Ic726ce85e01190dbc64426388fd454c54ae3c3e3
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/animation/bezierevaluator/tst_bezierevaluator.cpp | 2 | ||||
-rw-r--r-- | tests/auto/core/common/testarbiter.h | 4 | ||||
-rw-r--r-- | tests/auto/input/commons/testdevice.h | 8 | ||||
-rw-r--r-- | tests/auto/quick3d/quick3dnodeinstantiator/stringmodel.h | 2 | ||||
-rw-r--r-- | tests/auto/render/commons/testaspect.cpp | 6 | ||||
-rw-r--r-- | tests/auto/render/commons/testaspect.h | 4 | ||||
-rw-r--r-- | tests/manual/deferred-renderer-cpp/pointlightblock.cpp | 2 | ||||
-rw-r--r-- | tests/manual/deferred-renderer-cpp/pointlightblock.h | 6 | ||||
-rw-r--r-- | tests/manual/dynamicscene-cpp/examplescene.h | 2 |
9 files changed, 18 insertions, 18 deletions
diff --git a/tests/auto/animation/bezierevaluator/tst_bezierevaluator.cpp b/tests/auto/animation/bezierevaluator/tst_bezierevaluator.cpp index 06389bd36..27daaea48 100644 --- a/tests/auto/animation/bezierevaluator/tst_bezierevaluator.cpp +++ b/tests/auto/animation/bezierevaluator/tst_bezierevaluator.cpp @@ -29,7 +29,7 @@ #include <QtTest/QTest> #include <Qt3DAnimation/private/bezierevaluator_p.h> #include <Qt3DAnimation/private/keyframe_p.h> -#include <QtCore/qvector.h> +#include <QtCore/qlist.h> #include <cmath> diff --git a/tests/auto/core/common/testarbiter.h b/tests/auto/core/common/testarbiter.h index 1c1723fc1..92518bd07 100644 --- a/tests/auto/core/common/testarbiter.h +++ b/tests/auto/core/common/testarbiter.h @@ -51,8 +51,8 @@ public: setArbiterOnNode(n); } - QVector<Qt3DCore::QNode *> dirtyNodes() const { return m_dirtyFrontEndNodes; } - QVector<Qt3DCore::ComponentRelationshipChange> dirtyComponents() const { return m_dirtyEntityComponentNodeChanges; } + QList<Qt3DCore::QNode *> dirtyNodes() const { return m_dirtyFrontEndNodes; } + QList<Qt3DCore::ComponentRelationshipChange> dirtyComponents() const { return m_dirtyEntityComponentNodeChanges; } void clear() { diff --git a/tests/auto/input/commons/testdevice.h b/tests/auto/input/commons/testdevice.h index 37d115166..d7012ac70 100644 --- a/tests/auto/input/commons/testdevice.h +++ b/tests/auto/input/commons/testdevice.h @@ -119,9 +119,9 @@ public: return device; } - QVector<Qt3DCore::QNodeId> physicalDevices() const final + QList<Qt3DCore::QNodeId> physicalDevices() const final { - QVector<Qt3DCore::QNodeId> ids; + QList<Qt3DCore::QNodeId> ids; std::transform(m_devices.constBegin(), m_devices.constEnd(), std::back_inserter(ids), [] (TestDevice *device) { return device->id(); }); @@ -151,8 +151,8 @@ private: void onInitialize() final {} QScopedPointer<Qt3DCore::QNode> m_devicesParent; - QVector<TestDevice*> m_devices; - QVector<TestDeviceBackendNode*> m_deviceBackendNodes; + QList<TestDevice *> m_devices; + QList<TestDeviceBackendNode *> m_deviceBackendNodes; }; #endif // TESTDEVICE_H diff --git a/tests/auto/quick3d/quick3dnodeinstantiator/stringmodel.h b/tests/auto/quick3d/quick3dnodeinstantiator/stringmodel.h index 62d71b224..b928b2ab8 100644 --- a/tests/auto/quick3d/quick3dnodeinstantiator/stringmodel.h +++ b/tests/auto/quick3d/quick3dnodeinstantiator/stringmodel.h @@ -36,7 +36,7 @@ class StringModel : public QAbstractItemModel { Q_OBJECT - QVector<QString> items; + QList<QString> items; QHash<int, QByteArray> roles; QString name; diff --git a/tests/auto/render/commons/testaspect.cpp b/tests/auto/render/commons/testaspect.cpp index a2d6a8950..9176492e9 100644 --- a/tests/auto/render/commons/testaspect.cpp +++ b/tests/auto/render/commons/testaspect.cpp @@ -43,11 +43,11 @@ QT_BEGIN_NAMESPACE namespace Qt3DRender { -QVector<Qt3DCore::QNode *> getNodesForCreation(Qt3DCore::QNode *root) +QList<Qt3DCore::QNode *> getNodesForCreation(Qt3DCore::QNode *root) { using namespace Qt3DCore; - QVector<QNode *> nodes; + QList<QNode *> nodes; Qt3DCore::QNodeVisitor visitor; visitor.traverse(root, [&nodes](QNode *node) { nodes.append(node); @@ -74,7 +74,7 @@ TestAspect::TestAspect(Qt3DCore::QNode *root) Qt3DCore::QAbstractAspectPrivate::get(this)->m_jobManager = m_jobManager.data(); QRenderAspect::onRegistered(); - const QVector<Qt3DCore::QNode *> nodes = getNodesForCreation(root); + const QList<Qt3DCore::QNode *> nodes = getNodesForCreation(root); for (Qt3DCore::QNode *node : nodes) d_func()->createBackendNode({ diff --git a/tests/auto/render/commons/testaspect.h b/tests/auto/render/commons/testaspect.h index 35cf6534a..6f7043725 100644 --- a/tests/auto/render/commons/testaspect.h +++ b/tests/auto/render/commons/testaspect.h @@ -74,8 +74,8 @@ public: }); } Qt3DCore::QNode *lookupNode(Qt3DCore::QNodeId id) const override { return m_frontEndNodes.value(id, nullptr); } - QVector<Qt3DCore::QNode *> lookupNodes(const QVector<Qt3DCore::QNodeId> &ids) const override { - QVector<Qt3DCore::QNode *> res; + QList<Qt3DCore::QNode *> lookupNodes(const QList<Qt3DCore::QNodeId> &ids) const override { + QList<Qt3DCore::QNode *> res; for (const auto &id: ids) { auto node = m_frontEndNodes.value(id, nullptr); if (node) diff --git a/tests/manual/deferred-renderer-cpp/pointlightblock.cpp b/tests/manual/deferred-renderer-cpp/pointlightblock.cpp index 36bab9966..aceb13dad 100644 --- a/tests/manual/deferred-renderer-cpp/pointlightblock.cpp +++ b/tests/manual/deferred-renderer-cpp/pointlightblock.cpp @@ -60,7 +60,7 @@ PointLightBlock::~PointLightBlock() { } -QVector<Qt3DRender::QAbstractLight *> PointLightBlock::lights() const +QList<Qt3DRender::QAbstractLight *> PointLightBlock::lights() const { return m_lights; } diff --git a/tests/manual/deferred-renderer-cpp/pointlightblock.h b/tests/manual/deferred-renderer-cpp/pointlightblock.h index 9c93528c8..e2f1063df 100644 --- a/tests/manual/deferred-renderer-cpp/pointlightblock.h +++ b/tests/manual/deferred-renderer-cpp/pointlightblock.h @@ -57,19 +57,19 @@ class PointLightBlock : public Qt3DRender::QShaderData { Q_OBJECT - Q_PROPERTY(QVector<Qt3DRender::QAbstractLight *> lights READ lights NOTIFY lightsChanged) + Q_PROPERTY(QList<Qt3DRender::QAbstractLight *> lights READ lights NOTIFY lightsChanged) public: explicit PointLightBlock(Qt3DCore::QNode *parent = 0); ~PointLightBlock(); - QVector<Qt3DRender::QAbstractLight *> lights() const; + QList<Qt3DRender::QAbstractLight *> lights() const; void addLight(Qt3DRender::QAbstractLight *light); Q_SIGNALS: void lightsChanged(); private: - QVector<Qt3DRender::QAbstractLight *> m_lights; + QList<Qt3DRender::QAbstractLight *> m_lights; }; #endif // POINTLIGHTBLOCK_H diff --git a/tests/manual/dynamicscene-cpp/examplescene.h b/tests/manual/dynamicscene-cpp/examplescene.h index cac6330f3..fb141e355 100644 --- a/tests/manual/dynamicscene-cpp/examplescene.h +++ b/tests/manual/dynamicscene-cpp/examplescene.h @@ -72,7 +72,7 @@ private Q_SLOTS: void buildScene(); private: - QVector<BoxEntity *> m_entities; + QList<BoxEntity *> m_entities; QTimer *m_timer; bool m_even; }; |