diff options
author | Jarek Kobus <jaroslaw.kobus@qt.io> | 2020-06-22 14:52:01 +0200 |
---|---|---|
committer | Jarek Kobus <jaroslaw.kobus@qt.io> | 2020-07-02 21:57:06 +0200 |
commit | 2a6cdec718934ca2cc7f6f9c616ebe62f6912123 (patch) | |
tree | c8b9ed8db47912dccd2e8d125d23760936820c29 /src/widgets/kernel/qboxlayout.cpp | |
parent | d4c04acc65657d29df5b790281a8d1ba896dd868 (diff) |
Use QList instead of QVector in widgets
Task-number: QTBUG-84469
Change-Id: I3007734f8e4f164ece9dd8850ef007cbef9e12ef
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
Diffstat (limited to 'src/widgets/kernel/qboxlayout.cpp')
-rw-r--r-- | src/widgets/kernel/qboxlayout.cpp | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/widgets/kernel/qboxlayout.cpp b/src/widgets/kernel/qboxlayout.cpp index 7b09adfbf0..a23b89a8a5 100644 --- a/src/widgets/kernel/qboxlayout.cpp +++ b/src/widgets/kernel/qboxlayout.cpp @@ -37,15 +37,14 @@ ** ****************************************************************************/ -#include "qboxlayout.h" #include "qapplication.h" -#include "qwidget.h" +#include "qboxlayout.h" #include "qlist.h" #include "qsizepolicy.h" -#include "qvector.h" +#include "qwidget.h" -#include "qlayoutengine_p.h" #include "qlayout_p.h" +#include "qlayoutengine_p.h" QT_BEGIN_NAMESPACE @@ -104,7 +103,7 @@ public: } QList<QBoxLayoutItem *> list; - QVector<QLayoutStruct> geomArray; + QList<QLayoutStruct> geomArray; int hfwWidth; int hfwHeight; int hfwMinHeight; @@ -271,7 +270,7 @@ void QBoxLayoutPrivate::setupGeom() int n = list.count(); geomArray.clear(); - QVector<QLayoutStruct> a(n); + QList<QLayoutStruct> a(n); QSizePolicy::ControlTypes controlTypes1; QSizePolicy::ControlTypes controlTypes2; @@ -400,7 +399,7 @@ void QBoxLayoutPrivate::setupGeom() */ void QBoxLayoutPrivate::calcHfw(int w) { - QVector<QLayoutStruct> &a = geomArray; + QList<QLayoutStruct> &a = geomArray; int n = a.count(); int h = 0; int mh = 0; @@ -770,7 +769,7 @@ void QBoxLayout::setGeometry(const QRect &r) cr.width() - (left + right), cr.height() - (top + bottom)); - QVector<QLayoutStruct> a = d->geomArray; + QList<QLayoutStruct> a = d->geomArray; int pos = horz(d->dir) ? s.x() : s.y(); int space = horz(d->dir) ? s.width() : s.height(); int n = a.count(); |