aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/scenegraph/qsgdefaultglyphnode_p.h
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@kdab.com>2019-06-06 18:19:14 +0200
committerMarc Mutz <marc.mutz@kdab.com>2019-06-06 18:19:16 +0200
commit7d98307788dfe12d56a660df29c4451534e20f3c (patch)
tree3e6b98a871e61212ab8c42d3d6bb33e4f3d34b8c /src/quick/scenegraph/qsgdefaultglyphnode_p.h
parent8de93acc2b3a0abafaad3aec0c95f22d36bc2f62 (diff)
Replace remaining QLinkedLists with QVector
In both cases, the container holds pointers, so stability of references can be ruled out as a cause for using linked lists. Both containers are also only ever appended to and then consumed, so there are no insertions in the middle that a linked list may speed up. Last, it also cannot be the sheer size of the container, as QLinkedList has 3x the memory consumption of a vector. We conclude that none of the things that make QLinkedList a container of choice apply here, so we can use a QVector instead. In QSGAbstractSoftwareRenderer, there was an accessor for the linked list member, but it appears unused, so was removed. Change-Id: I273f89c0d1267444019088371a5eb0b3b32a763c Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/quick/scenegraph/qsgdefaultglyphnode_p.h')
-rw-r--r--src/quick/scenegraph/qsgdefaultglyphnode_p.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/quick/scenegraph/qsgdefaultglyphnode_p.h b/src/quick/scenegraph/qsgdefaultglyphnode_p.h
index cfa1c1dad2..cf8746228f 100644
--- a/src/quick/scenegraph/qsgdefaultglyphnode_p.h
+++ b/src/quick/scenegraph/qsgdefaultglyphnode_p.h
@@ -77,7 +77,7 @@ private:
void setGlyphNodeType(DefaultGlyphNodeType type) { m_glyphNodeType = type; }
DefaultGlyphNodeType m_glyphNodeType;
- QLinkedList<QSGNode *> m_nodesToDelete;
+ QVector<QSGNode *> m_nodesToDelete;
struct GlyphInfo {
QVector<quint32> indexes;