summaryrefslogtreecommitdiffstats
path: root/src/core/nodes
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/nodes')
-rw-r--r--src/core/nodes/qcomponent.cpp4
-rw-r--r--src/core/nodes/qcomponent.h2
-rw-r--r--src/core/nodes/qentity.cpp2
-rw-r--r--src/core/nodes/qentity.h6
-rw-r--r--src/core/nodes/qnode.cpp4
-rw-r--r--src/core/nodes/qnode.h4
-rw-r--r--src/core/nodes/qnodeid.h2
7 files changed, 12 insertions, 12 deletions
diff --git a/src/core/nodes/qcomponent.cpp b/src/core/nodes/qcomponent.cpp
index 79bba229d..5e41e2f67 100644
--- a/src/core/nodes/qcomponent.cpp
+++ b/src/core/nodes/qcomponent.cpp
@@ -158,9 +158,9 @@ void QComponent::setShareable(bool shareable)
}
/*!
- Returns a QVector containing all the entities that reference this component.
+ Returns a QList containing all the entities that reference this component.
*/
-QVector<QEntity *> QComponent::entities() const
+QList<QEntity *> QComponent::entities() const
{
Q_D(const QComponent);
return d->m_entities;
diff --git a/src/core/nodes/qcomponent.h b/src/core/nodes/qcomponent.h
index f07b34c9f..3de755710 100644
--- a/src/core/nodes/qcomponent.h
+++ b/src/core/nodes/qcomponent.h
@@ -61,7 +61,7 @@ public:
bool isShareable() const;
- QVector<QEntity *> entities() const;
+ QList<QEntity *> entities() const;
public Q_SLOTS:
void setShareable(bool isShareable);
diff --git a/src/core/nodes/qentity.cpp b/src/core/nodes/qentity.cpp
index 02f84b924..25ec4434c 100644
--- a/src/core/nodes/qentity.cpp
+++ b/src/core/nodes/qentity.cpp
@@ -119,7 +119,7 @@ namespace Qt3DCore {
*/
/*!
- \fn template<typename T> QVector<T *> Qt3DCore::QEntity::componentsOfType() const
+ \fn template<typename T> QList<T *> Qt3DCore::QEntity::componentsOfType() const
Returns all the components added to this entity that can be cast to
type T or an empty vector if there are no such components.
diff --git a/src/core/nodes/qentity.h b/src/core/nodes/qentity.h
index ab87da4eb..6c9bec118 100644
--- a/src/core/nodes/qentity.h
+++ b/src/core/nodes/qentity.h
@@ -51,7 +51,7 @@ namespace Qt3DCore {
class QComponent;
class QEntityPrivate;
-typedef QVector<QComponent*> QComponentVector;
+using QComponentVector = QList<QComponent*>;
class Q_3DCORESHARED_EXPORT QEntity : public QNode
{
@@ -63,9 +63,9 @@ public:
QComponentVector components() const;
template<class T>
- QVector<T *> componentsOfType() const
+ QList<T *> componentsOfType() const
{
- QVector<T*> matchComponents;
+ QList<T*> matchComponents;
const QComponentVector comps = this->components();
for (QComponent *component : comps) {
T *typedComponent = qobject_cast<T*>(component);
diff --git a/src/core/nodes/qnode.cpp b/src/core/nodes/qnode.cpp
index e9665874d..15a2f5978 100644
--- a/src/core/nodes/qnode.cpp
+++ b/src/core/nodes/qnode.cpp
@@ -383,7 +383,7 @@ void QNodePrivate::setSceneHelper(QNode *root)
// We also need to handle QEntity <-> QComponent relationships
if (QComponent *c = qobject_cast<QComponent *>(root)) {
- const QVector<QEntity *> entities = c->entities();
+ const QList<QEntity *> entities = c->entities();
for (QEntity *entity : entities) {
if (!m_scene->hasEntityForComponent(c->id(), entity->id())) {
if (!c->isShareable() && !m_scene->entitiesForComponent(c->id()).isEmpty())
@@ -406,7 +406,7 @@ void QNodePrivate::unsetSceneHelper(QNode *node)
// We also need to handle QEntity <-> QComponent relationships removal
if (QComponent *c = qobject_cast<QComponent *>(node)) {
- const QVector<QEntity *> entities = c->entities();
+ const QList<QEntity *> entities = c->entities();
for (QEntity *entity : entities) {
if (nodePrivate->m_scene)
nodePrivate->m_scene->removeEntityForComponent(c->id(), entity->id());
diff --git a/src/core/nodes/qnode.h b/src/core/nodes/qnode.h
index 2fe0b0f9e..4c7f11d56 100644
--- a/src/core/nodes/qnode.h
+++ b/src/core/nodes/qnode.h
@@ -58,8 +58,8 @@ class QAspectEngine;
class QBackendNodeTester;
#endif
-typedef QVector<QNode *> QNodeVector;
-typedef QSharedPointer<QNode> QNodePtr;
+using QNodeVector = QList<QNode *>;
+using QNodePtr = QSharedPointer<QNode>;
class Q_3DCORESHARED_EXPORT QNode : public QObject
{
diff --git a/src/core/nodes/qnodeid.h b/src/core/nodes/qnodeid.h
index 18fb954ef..704fc6c76 100644
--- a/src/core/nodes/qnodeid.h
+++ b/src/core/nodes/qnodeid.h
@@ -100,7 +100,7 @@ private:
};
QT3D_DECLARE_TYPEINFO(Qt3DCore, QNodeId, Q_PRIMITIVE_TYPE)
-typedef QVector<QNodeId> QNodeIdVector;
+using QNodeIdVector = QList<QNodeId>;
#ifndef QT_NO_DEBUG_STREAM
Q_3DCORESHARED_EXPORT QDebug operator<<(QDebug d, QNodeId id);