From 5fb8839023027b469f242987b6ab04e9ac333f14 Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Sun, 17 Aug 2014 20:41:58 +0200 Subject: QMdiArea: don't hold QPointers in QList MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit QPointer is larger than a void*, so holding them in a QList is needlessly inefficient. Worse, the code could come to depend on the fragile property of (inefficient) QLists that references to elements therein never are invalidated. Change-Id: I3cdd4914658b6fe025ad379007502b4223e126cd Reviewed-by: Sérgio Martins Reviewed-by: Olivier Goffart (Woboq GmbH) --- src/widgets/widgets/qmdiarea_p.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/widgets/widgets/qmdiarea_p.h') diff --git a/src/widgets/widgets/qmdiarea_p.h b/src/widgets/widgets/qmdiarea_p.h index 7f28879f8d..f6bdf61492 100644 --- a/src/widgets/widgets/qmdiarea_p.h +++ b/src/widgets/widgets/qmdiarea_p.h @@ -142,8 +142,8 @@ public: #endif QMdiAreaTabBar *tabBar; QList pendingRearrangements; - QList< QPointer > pendingPlacements; - QList< QPointer > childWindows; + QVector< QPointer > pendingPlacements; + QVector< QPointer > childWindows; QList indicesToActivatedChildren; QPointer active; QPointer aboutToBecomeActive; -- cgit v1.2.3