From 1e25b81e0d6c1da4643c9cc48680f5cc4399d068 Mon Sep 17 00:00:00 2001 From: Jarek Kobus Date: Mon, 6 Jul 2020 12:34:58 +0200 Subject: [PATCH] Use QList instead of QVector in plugins Task-number: QTBUG-84469 Change-Id: Ic86f4a3000592a1c9ae62e4a83f4fe39832a6b24 Reviewed-by: Friedemann Kleint --- .../generic/bsdkeyboard/qbsdkeyboard.h | 4 +- src/plugins/generic/tuiotouch/qoscmessage_p.h | 4 +- .../generic/tuiotouch/qtuiohandler.cpp | 2 +- .../generic/tuiotouch/qtuiohandler_p.h | 6 +-- src/plugins/imageformats/gif/qgifhandler.cpp | 6 +-- src/plugins/imageformats/gif/qgifhandler_p.h | 2 +- src/plugins/imageformats/ico/qicohandler.cpp | 12 ++--- .../imageformats/jpeg/qjpeghandler.cpp | 10 ++--- .../platforminputcontexts/ibus/qibustypes.h | 4 +- .../qandroidassetsfileenginehandler.cpp | 4 +- .../android/qandroideventdispatcher.h | 2 +- .../platforms/android/qandroidplatformmenu.h | 4 +- .../android/qandroidplatformmenubar.h | 6 +-- .../direct2d/qwindowsdirect2dpaintengine.cpp | 12 ++--- .../platforms/eglfs/api/qeglfscursor_p.h | 4 +- .../eglfs_kms/qeglfskmsgbmcursor.h | 4 +- .../eglfs_kms/qeglfskmsgbmdevice.cpp | 2 +- .../eglfs_kms/qeglfskmsgbmdevice.h | 2 +- .../eglfs_kms/qeglfskmsgbmscreen.cpp | 2 +- .../eglfs_kms/qeglfskmsgbmscreen.h | 4 +- .../qeglfskmsegldeviceintegration.cpp | 2 +- .../eglfs_kms_support/qeglfskmsscreen.cpp | 4 +- .../eglfs_kms_support/qeglfskmsscreen.h | 2 +- .../eglfs_kms_vsp2/qeglfskmsvsp2device.cpp | 2 +- .../eglfs_kms_vsp2/qeglfskmsvsp2device.h | 2 +- .../eglfs_kms_vsp2/qeglfskmsvsp2screen.h | 2 +- .../eglfs_kms_vsp2/qvsp2blendingdevice.h | 4 +- .../platforms/linuxfb/qlinuxfbdrmscreen.cpp | 2 +- src/plugins/platforms/vnc/qvnc_p.h | 4 +- .../platforms/wasm/qwasmcompositor.cpp | 2 +- .../platforms/wasm/qwasmeventdispatcher.h | 2 +- src/plugins/platforms/wasm/qwasmintegration.h | 2 +- .../platforms/windows/qwindowsmenu.cpp | 14 +++--- src/plugins/platforms/windows/qwindowsmenu.h | 6 +-- .../platforms/windows/qwindowsmime.cpp | 44 +++++++++---------- src/plugins/platforms/windows/qwindowsmime.h | 8 ++-- src/plugins/platforms/windows/qwindowsole.cpp | 6 +-- src/plugins/platforms/windows/qwindowsole.h | 8 ++-- .../windows/qwindowsopengltester.cpp | 6 +-- .../platforms/windows/qwindowsopengltester.h | 4 +- .../platforms/windows/qwindowsscreen.cpp | 2 +- .../platforms/windows/qwindowsscreen.h | 3 +- .../windows/qwindowssystemtrayicon.cpp | 4 +- .../windows/qwindowstabletsupport.cpp | 2 +- .../platforms/windows/qwindowstabletsupport.h | 6 +-- .../qwindowsuiaselectionprovider.cpp | 3 +- .../xcb_glx/qglxintegration.cpp | 6 +-- .../xcb/nativepainting/qbackingstore_x11.cpp | 4 +- .../xcb/nativepainting/qcolormap_x11.cpp | 6 +-- .../xcb/nativepainting/qcolormap_x11_p.h | 4 +- .../xcb/nativepainting/qpaintengine_x11.cpp | 8 ++-- .../xcb/nativepainting/qpixmap_x11.cpp | 8 ++-- .../xcb/nativepainting/qxcbnativepainting.cpp | 4 +- .../xcb/nativepainting/qxcbnativepainting.h | 2 +- src/plugins/platforms/xcb/qxcbclipboard.cpp | 6 +-- src/plugins/platforms/xcb/qxcbconnection.h | 7 ++- .../platforms/xcb/qxcbconnection_xi2.cpp | 4 +- src/plugins/platforms/xcb/qxcbdrag.cpp | 8 ++-- src/plugins/platforms/xcb/qxcbdrag.h | 24 +++++----- src/plugins/platforms/xcb/qxcbeventqueue.h | 4 +- src/plugins/platforms/xcb/qxcbkeyboard.cpp | 2 +- src/plugins/platforms/xcb/qxcbmime.cpp | 6 +-- src/plugins/platforms/xcb/qxcbmime.h | 4 +- src/plugins/platforms/xcb/qxcbwindow.cpp | 12 ++--- src/plugins/platforms/xcb/qxcbwindow.h | 2 +- src/plugins/platforms/xcb/qxcbwmsupport.h | 8 ++-- src/plugins/platformthemes/gtk3/qgtk3menu.h | 2 +- .../qxdgdesktopportalfiledialog_p.h | 6 +-- .../printsupport/cups/qcupsprintengine.cpp | 2 +- .../windows/qwindowsprintdevice.cpp | 2 +- .../windows/qwindowsprintdevice.h | 8 ++-- src/plugins/sqldrivers/db2/qsql_db2.cpp | 8 ++-- src/plugins/sqldrivers/ibase/qsql_ibase.cpp | 11 +++-- src/plugins/sqldrivers/mysql/qsql_mysql.cpp | 16 +++---- src/plugins/sqldrivers/oci/qsql_oci.cpp | 42 +++++++++--------- src/plugins/sqldrivers/odbc/qsql_odbc.cpp | 12 ++--- src/plugins/sqldrivers/psql/qsql_psql.cpp | 2 +- src/plugins/sqldrivers/sqlite/qsql_sqlite.cpp | 28 ++++++------ src/plugins/styles/android/qandroidstyle.cpp | 2 +- src/plugins/styles/android/qandroidstyle_p.h | 8 ++-- src/plugins/styles/mac/qmacstyle_mac_p_p.h | 4 +- 81 files changed, 260 insertions(+), 264 deletions(-) diff --git a/src/plugins/generic/bsdkeyboard/qbsdkeyboard.h b/src/plugins/generic/bsdkeyboard/qbsdkeyboard.h index 46d8988d3a..b74a02bf21 100644 --- a/src/plugins/generic/bsdkeyboard/qbsdkeyboard.h +++ b/src/plugins/generic/bsdkeyboard/qbsdkeyboard.h @@ -42,7 +42,7 @@ #include #include -#include +#include QT_BEGIN_NAMESPACE @@ -137,7 +137,7 @@ private: bool m_numLock = false; bool m_scrollLock = false; - QVector m_keymap; + QList m_keymap; }; QT_END_NAMESPACE diff --git a/src/plugins/generic/tuiotouch/qoscmessage_p.h b/src/plugins/generic/tuiotouch/qoscmessage_p.h index 46c6ca3918..f8738c4242 100644 --- a/src/plugins/generic/tuiotouch/qoscmessage_p.h +++ b/src/plugins/generic/tuiotouch/qoscmessage_p.h @@ -58,12 +58,12 @@ public: bool isValid() const { return m_isValid; } QByteArray addressPattern() const { return m_addressPattern; } - QList arguments() const { return m_arguments; } + QVariantList arguments() const { return m_arguments; } private: bool m_isValid; QByteArray m_addressPattern; - QList m_arguments; + QVariantList m_arguments; }; Q_DECLARE_TYPEINFO(QOscMessage, Q_MOVABLE_TYPE); diff --git a/src/plugins/generic/tuiotouch/qtuiohandler.cpp b/src/plugins/generic/tuiotouch/qtuiohandler.cpp index 1ef50915d8..260dc883af 100644 --- a/src/plugins/generic/tuiotouch/qtuiohandler.cpp +++ b/src/plugins/generic/tuiotouch/qtuiohandler.cpp @@ -158,7 +158,7 @@ void QTuioHandler::processPackets() // messages. The FSEQ frame ID is incremented for each delivered bundle, // while redundant bundles can be marked using the frame sequence ID // -1." - QVector messages; + QList messages; QOscBundle bundle(datagram); if (bundle.isValid()) { diff --git a/src/plugins/generic/tuiotouch/qtuiohandler_p.h b/src/plugins/generic/tuiotouch/qtuiohandler_p.h index 09de1d8536..4145c1eae6 100644 --- a/src/plugins/generic/tuiotouch/qtuiohandler_p.h +++ b/src/plugins/generic/tuiotouch/qtuiohandler_p.h @@ -41,10 +41,10 @@ #ifndef QTUIOHANDLER_P_H #define QTUIOHANDLER_P_H +#include #include #include #include -#include #include #include @@ -83,9 +83,9 @@ private: QPointingDevice *m_device = nullptr; QUdpSocket m_socket; QMap m_activeCursors; - QVector m_deadCursors; + QList m_deadCursors; QMap m_activeTokens; - QVector m_deadTokens; + QList m_deadTokens; QTransform m_transform; }; diff --git a/src/plugins/imageformats/gif/qgifhandler.cpp b/src/plugins/imageformats/gif/qgifhandler.cpp index e895e4f91b..b6322f0f4d 100644 --- a/src/plugins/imageformats/gif/qgifhandler.cpp +++ b/src/plugins/imageformats/gif/qgifhandler.cpp @@ -69,7 +69,7 @@ public: int decode(QImage *image, const uchar* buffer, int length, int *nextFrameDelay, int *loopCount); - static void scan(QIODevice *device, QVector *imageSizes, int *loopCount); + static void scan(QIODevice *device, QList *imageSizes, int *loopCount); bool newFrame; bool partialNewFrame; @@ -688,9 +688,9 @@ int QGIFFormat::decode(QImage *image, const uchar *buffer, int length, /*! Scans through the data stream defined by \a device and returns the image - sizes found in the stream in the \a imageSizes vector. + sizes found in the stream in the \a imageSizes list. */ -void QGIFFormat::scan(QIODevice *device, QVector *imageSizes, int *loopCount) +void QGIFFormat::scan(QIODevice *device, QList *imageSizes, int *loopCount) { if (!device) return; diff --git a/src/plugins/imageformats/gif/qgifhandler_p.h b/src/plugins/imageformats/gif/qgifhandler_p.h index f19777fa18..9508e9ac92 100644 --- a/src/plugins/imageformats/gif/qgifhandler_p.h +++ b/src/plugins/imageformats/gif/qgifhandler_p.h @@ -94,7 +94,7 @@ private: mutable int nextDelay; mutable int loopCnt; int frameNumber; - mutable QVector imageSizes; + mutable QList imageSizes; mutable bool scanIsCached; }; diff --git a/src/plugins/imageformats/ico/qicohandler.cpp b/src/plugins/imageformats/ico/qicohandler.cpp index 631d7e8d0f..52e231e5a7 100644 --- a/src/plugins/imageformats/ico/qicohandler.cpp +++ b/src/plugins/imageformats/ico/qicohandler.cpp @@ -103,9 +103,9 @@ public: QImage iconAt(int index); static bool canRead(QIODevice *iodev); - static QVector read(QIODevice *device); + static QList read(QIODevice *device); - static bool write(QIODevice *device, const QVector &images); + static bool write(QIODevice *device, const QList &images); bool readIconEntry(int index, ICONDIRENTRY * iconEntry); @@ -564,9 +564,9 @@ QImage ICOReader::iconAt(int index) \sa write() */ -QVector ICOReader::read(QIODevice *device) +QList ICOReader::read(QIODevice *device) { - QVector images; + QList images; ICOReader reader(device); const int N = reader.count(); @@ -590,7 +590,7 @@ QVector ICOReader::read(QIODevice *device) \sa read() */ -bool ICOReader::write(QIODevice *device, const QVector &images) +bool ICOReader::write(QIODevice *device, const QList &images) { bool retValue = false; @@ -809,7 +809,7 @@ bool QtIcoHandler::read(QImage *image) bool QtIcoHandler::write(const QImage &image) { QIODevice *device = QImageIOHandler::device(); - QVector imgs; + QList imgs; imgs.append(image); return ICOReader::write(device, imgs); } diff --git a/src/plugins/imageformats/jpeg/qjpeghandler.cpp b/src/plugins/imageformats/jpeg/qjpeghandler.cpp index 1b48e8fc90..7574d1ca00 100644 --- a/src/plugins/imageformats/jpeg/qjpeghandler.cpp +++ b/src/plugins/imageformats/jpeg/qjpeghandler.cpp @@ -39,14 +39,14 @@ #include "qjpeghandler_p.h" -#include +#include #include #include #include -#include -#include -#include +#include +#include #include +#include #include #include #include // for qt_getImageText @@ -535,7 +535,7 @@ static bool do_write_jpeg_image(struct jpeg_compress_struct &cinfo, bool progressive) { bool success = false; - const QVector cmap = image.colorTable(); + const QList cmap = image.colorTable(); if (image.format() == QImage::Format_Invalid || image.format() == QImage::Format_Alpha8) return false; diff --git a/src/plugins/platforminputcontexts/ibus/qibustypes.h b/src/plugins/platforminputcontexts/ibus/qibustypes.h index 217cd836fc..e6bff1ef81 100644 --- a/src/plugins/platforminputcontexts/ibus/qibustypes.h +++ b/src/plugins/platforminputcontexts/ibus/qibustypes.h @@ -39,7 +39,7 @@ #ifndef QIBUSTYPES_H #define QIBUSTYPES_H -#include +#include #include #include #include @@ -104,7 +104,7 @@ public: void serializeTo(QDBusArgument &argument) const; void deserializeFrom(const QDBusArgument &argument); - QVector attributes; + QList attributes; }; Q_DECLARE_TYPEINFO(QIBusAttributeList, Q_MOVABLE_TYPE); diff --git a/src/plugins/platforms/android/qandroidassetsfileenginehandler.cpp b/src/plugins/platforms/android/qandroidassetsfileenginehandler.cpp index 07776a4a76..6edddf4a66 100644 --- a/src/plugins/platforms/android/qandroidassetsfileenginehandler.cpp +++ b/src/plugins/platforms/android/qandroidassetsfileenginehandler.cpp @@ -42,7 +42,7 @@ #include #include -#include +#include #include QT_BEGIN_NAMESPACE @@ -88,7 +88,7 @@ struct AssetItem { QString name; }; -using AssetItemList = QVector; +using AssetItemList = QList; class FolderIterator : public AssetItemList { diff --git a/src/plugins/platforms/android/qandroideventdispatcher.h b/src/plugins/platforms/android/qandroideventdispatcher.h index 82d414d49a..85d4cee6cb 100644 --- a/src/plugins/platforms/android/qandroideventdispatcher.h +++ b/src/plugins/platforms/android/qandroideventdispatcher.h @@ -78,7 +78,7 @@ public: private: QMutex m_mutex; QAtomicInt m_started = 1; - QVector m_dispatchers; + QList m_dispatchers; }; diff --git a/src/plugins/platforms/android/qandroidplatformmenu.h b/src/plugins/platforms/android/qandroidplatformmenu.h index b1d6a88787..b8334ff970 100644 --- a/src/plugins/platforms/android/qandroidplatformmenu.h +++ b/src/plugins/platforms/android/qandroidplatformmenu.h @@ -41,7 +41,7 @@ #define QANDROIDPLATFORMMENU_H #include -#include +#include #include QT_BEGIN_NAMESPACE @@ -50,7 +50,7 @@ class QAndroidPlatformMenuItem; class QAndroidPlatformMenu: public QPlatformMenu { public: - typedef QVector PlatformMenuItemsType; + typedef QList PlatformMenuItemsType; public: QAndroidPlatformMenu(); diff --git a/src/plugins/platforms/android/qandroidplatformmenubar.h b/src/plugins/platforms/android/qandroidplatformmenubar.h index 81a26c72f4..449c39ca52 100644 --- a/src/plugins/platforms/android/qandroidplatformmenubar.h +++ b/src/plugins/platforms/android/qandroidplatformmenubar.h @@ -41,9 +41,9 @@ #define QANDROIDPLATFORMMENUBAR_H #include -#include -#include #include +#include +#include QT_BEGIN_NAMESPACE @@ -51,7 +51,7 @@ class QAndroidPlatformMenu; class QAndroidPlatformMenuBar: public QPlatformMenuBar { public: - typedef QVector PlatformMenusType; + typedef QList PlatformMenusType; public: QAndroidPlatformMenuBar(); ~QAndroidPlatformMenuBar(); diff --git a/src/plugins/platforms/direct2d/qwindowsdirect2dpaintengine.cpp b/src/plugins/platforms/direct2d/qwindowsdirect2dpaintengine.cpp index 4ce5825f95..028344a37d 100644 --- a/src/plugins/platforms/direct2d/qwindowsdirect2dpaintengine.cpp +++ b/src/plugins/platforms/direct2d/qwindowsdirect2dpaintengine.cpp @@ -124,9 +124,9 @@ static inline D2D1_MATRIX_3X2_F transformFromLine(const QLineF &line, qreal penW static void adjustLine(QPointF *p1, QPointF *p2); static bool isLinePositivelySloped(const QPointF &p1, const QPointF &p2); -static QVector qGradientStopsToD2DStops(const QGradientStops &qstops) +static QList qGradientStopsToD2DStops(const QGradientStops &qstops) { - QVector stops(qstops.count()); + QList stops(qstops.count()); for (int i = 0, count = stops.size(); i < count; ++i) { stops[i].position = FLOAT(qstops.at(i).first); stops[i].color = to_d2d_color_f(qstops.at(i).second); @@ -572,8 +572,8 @@ public: HRESULT hr; if (props.dashStyle == D2D1_DASH_STYLE_CUSTOM) { - QVector dashes = newPen.dashPattern(); - QVector converted(dashes.size()); + QList dashes = newPen.dashPattern(); + QList converted(dashes.size()); qreal penWidth = pen.qpen.widthF(); qreal brushWidth = 0; for (int i = 0; i < dashes.size(); i++) { @@ -696,7 +696,7 @@ public: linearGradientBrushProperties.startPoint = to_d2d_point_2f(qlinear->start()); linearGradientBrushProperties.endPoint = to_d2d_point_2f(qlinear->finalStop()); - const QVector stops = qGradientStopsToD2DStops(qlinear->stops()); + const QList stops = qGradientStopsToD2DStops(qlinear->stops()); hr = dc()->CreateGradientStopCollection(stops.constData(), UINT32(stops.size()), @@ -736,7 +736,7 @@ public: radialGradientBrushProperties.radiusX = FLOAT(qradial->radius()); radialGradientBrushProperties.radiusY = FLOAT(qradial->radius()); - const QVector stops = qGradientStopsToD2DStops(qradial->stops()); + const QList stops = qGradientStopsToD2DStops(qradial->stops()); hr = dc()->CreateGradientStopCollection(stops.constData(), stops.size(), &gradientStopCollection); if (FAILED(hr)) { diff --git a/src/plugins/platforms/eglfs/api/qeglfscursor_p.h b/src/plugins/platforms/eglfs/api/qeglfscursor_p.h index 7a6044aca0..ea1212ace8 100644 --- a/src/plugins/platforms/eglfs/api/qeglfscursor_p.h +++ b/src/plugins/platforms/eglfs/api/qeglfscursor_p.h @@ -59,7 +59,7 @@ #include #include -#include +#include QT_BEGIN_NAMESPACE @@ -145,7 +145,7 @@ private: int cursorsPerRow; int width, height; // width and height of the atlas int cursorWidth, cursorHeight; // width and height of cursors inside the atlas - QVector hotSpots; + QList hotSpots; QImage image; // valid until it's uploaded } m_cursorAtlas; diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmcursor.h b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmcursor.h index 5d2dfedba2..55420cef62 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmcursor.h +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmcursor.h @@ -41,7 +41,7 @@ #define QEGLFSKMSGBMCURSOR_H #include -#include +#include #include #include @@ -112,7 +112,7 @@ private: int cursorsPerRow; int width, height; // width and height of the atlas int cursorWidth, cursorHeight; // width and height of cursors inside the atlas - QVector hotSpots; + QList hotSpots; QImage image; } m_cursorAtlas; }; diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmdevice.cpp b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmdevice.cpp index 503419cf91..d32e36b04d 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmdevice.cpp +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmdevice.cpp @@ -150,7 +150,7 @@ QPlatformScreen *QEglFSKmsGbmDevice::createHeadlessScreen() void QEglFSKmsGbmDevice::registerScreenCloning(QPlatformScreen *screen, QPlatformScreen *screenThisScreenClones, - const QVector &screensCloningThisScreen) + const QList &screensCloningThisScreen) { if (!screenThisScreenClones && screensCloningThisScreen.isEmpty()) return; diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmdevice.h b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmdevice.h index f1476f8ffa..1964b30c5e 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmdevice.h +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmdevice.h @@ -69,7 +69,7 @@ public: QPlatformScreen *createHeadlessScreen() override; void registerScreenCloning(QPlatformScreen *screen, QPlatformScreen *screenThisScreenClones, - const QVector &screensCloningThisScreen) override; + const QList &screensCloningThisScreen) override; void registerScreen(QPlatformScreen *screen, bool isPrimary, const QPoint &virtualPos, diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.cpp b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.cpp index 6f5c3b6953..efb0b1b060 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.cpp +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.cpp @@ -198,7 +198,7 @@ void QEglFSKmsGbmScreen::resetSurface() } void QEglFSKmsGbmScreen::initCloning(QPlatformScreen *screenThisScreenClones, - const QVector &screensCloningThisScreen) + const QList &screensCloningThisScreen) { // clone destinations need to know the clone source const bool clonesAnother = screenThisScreenClones != nullptr; diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.h b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.h index 69feeee703..2be1630e19 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.h +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.h @@ -64,7 +64,7 @@ public: void resetSurface(); void initCloning(QPlatformScreen *screenThisScreenClones, - const QVector &screensCloningThisScreen); + const QList &screensCloningThisScreen); void waitForFlip() override; @@ -98,7 +98,7 @@ private: QEglFSKmsGbmScreen *screen = nullptr; bool cloneFlipPending = false; }; - QVector m_cloneDests; + QList m_cloneDests; }; QT_END_NAMESPACE diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp index 3e78196227..a480a390d1 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp @@ -171,7 +171,7 @@ void QEglFSKmsEglDeviceWindow::resetSurface() qCDebug(qLcEglfsKmsDebug, "Output has %d layers", count); - QVector layers; + QList layers; layers.resize(count); EGLint actualCount; if (!m_integration->m_funcs->get_output_layers(display, nullptr, layers.data(), count, &actualCount)) { diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.cpp b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.cpp index 959f17eba3..59d7ec104c 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.cpp +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.cpp @@ -218,9 +218,9 @@ qreal QEglFSKmsScreen::refreshRate() const return refresh > 0 ? refresh : 60; } -QVector QEglFSKmsScreen::modes() const +QList QEglFSKmsScreen::modes() const { - QVector list; + QList list; list.reserve(m_output.modes.size()); for (const drmModeModeInfo &info : qAsConst(m_output.modes)) diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.h b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.h index 0f0b10a980..103476bc54 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.h +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/qeglfskmsscreen.h @@ -83,7 +83,7 @@ public: QList virtualSiblings() const override { return m_siblings; } void setVirtualSiblings(QList sl) { m_siblings = sl; } - QVector modes() const override; + QList modes() const override; int currentMode() const override; int preferredMode() const override; diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2device.cpp b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2device.cpp index 44f855910c..62ad58c3f5 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2device.cpp +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2device.cpp @@ -122,7 +122,7 @@ QPlatformScreen *QEglFSKmsVsp2Device::createHeadlessScreen() void QEglFSKmsVsp2Device::registerScreenCloning(QPlatformScreen *screen, QPlatformScreen *screenThisScreenClones, - const QVector &screensCloningThisScreen) + const QList &screensCloningThisScreen) { Q_UNUSED(screen); qWarning() << Q_FUNC_INFO << "Not implemented yet"; diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2device.h b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2device.h index c795fa4005..3926f809c4 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2device.h +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2device.h @@ -65,7 +65,7 @@ public: QPlatformScreen *createHeadlessScreen() override; void registerScreenCloning(QPlatformScreen *screen, QPlatformScreen *screenThisScreenClones, - const QVector &screensCloningThisScreen) override; + const QList &screensCloningThisScreen) override; private: Q_DISABLE_COPY(QEglFSKmsVsp2Device) diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2screen.h b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2screen.h index 378786643d..9aa23d90a6 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2screen.h +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qeglfskmsvsp2screen.h @@ -97,7 +97,7 @@ private: std::array m_frameBuffers; uint m_backFb = 0; void initDumbFrameBuffer(FrameBuffer &fb); - QVector m_blendFinishedCallbacks; + QList m_blendFinishedCallbacks; struct DmaBuffer { //these are for qt buffers before blending with additional layers (gbm buffer data) int dmabufFd = -1; diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qvsp2blendingdevice.h b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qvsp2blendingdevice.h index ee34ae654a..ae157129df 100644 --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qvsp2blendingdevice.h +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_vsp2/qvsp2blendingdevice.h @@ -40,8 +40,8 @@ #ifndef QVSP2BLENDINGDEVICE_H #define QVSP2BLENDINGDEVICE_H +#include #include -#include #include #include "qlinuxmediadevice.h" @@ -86,7 +86,7 @@ private: struct media_pad *bruInputFormatPad = nullptr; // bru:x QLinuxMediaDevice::OutputSubDevice *rpfInput = nullptr; // rpf.x input }; - QVector m_inputs; + QList m_inputs; const QSize m_screenSize; bool m_dirty = true; }; diff --git a/src/plugins/platforms/linuxfb/qlinuxfbdrmscreen.cpp b/src/plugins/platforms/linuxfb/qlinuxfbdrmscreen.cpp index dcc1ef2790..1c99ac8cb1 100644 --- a/src/plugins/platforms/linuxfb/qlinuxfbdrmscreen.cpp +++ b/src/plugins/platforms/linuxfb/qlinuxfbdrmscreen.cpp @@ -115,7 +115,7 @@ private: static void pageFlipHandler(int fd, unsigned int sequence, unsigned int tv_sec, unsigned int tv_usec, void *user_data); - QVector m_outputs; + QList m_outputs; }; QLinuxFbDevice::QLinuxFbDevice(QKmsScreenConfig *screenConfig) diff --git a/src/plugins/platforms/vnc/qvnc_p.h b/src/plugins/platforms/vnc/qvnc_p.h index f7f2f74ddb..9c71cd8f94 100644 --- a/src/plugins/platforms/vnc/qvnc_p.h +++ b/src/plugins/platforms/vnc/qvnc_p.h @@ -380,7 +380,7 @@ public: QImage cursor; QPoint hotspot; - QVector clients; + QList clients; }; #endif // QT_CONFIG(cursor) @@ -408,7 +408,7 @@ private slots: private: QTcpServer *serverSocket; - QVector clients; + QList clients; QVncScreen *qvnc_screen; quint16 m_port; }; diff --git a/src/plugins/platforms/wasm/qwasmcompositor.cpp b/src/plugins/platforms/wasm/qwasmcompositor.cpp index 2eb04a501b..4ea69a3e78 100644 --- a/src/plugins/platforms/wasm/qwasmcompositor.cpp +++ b/src/plugins/platforms/wasm/qwasmcompositor.cpp @@ -621,7 +621,7 @@ void QWasmCompositor::drawShadePanel(QWasmTitleBarOptions options, QPainter *pai light = palette.midlight().color(); } QPen oldPen = painter->pen(); - QVector lines; + QList lines; lines.reserve(2*lineWidth); painter->setPen(light); diff --git a/src/plugins/platforms/wasm/qwasmeventdispatcher.h b/src/plugins/platforms/wasm/qwasmeventdispatcher.h index 3f51722c2a..8420f2cf1a 100644 --- a/src/plugins/platforms/wasm/qwasmeventdispatcher.h +++ b/src/plugins/platforms/wasm/qwasmeventdispatcher.h @@ -58,7 +58,7 @@ private: bool m_hasMainLoop = false; bool m_hasZeroTimer = false; uint64_t m_currentTargetTime = std::numeric_limits::max(); - QVector> m_requestUpdateCallbacks; + QList> m_requestUpdateCallbacks; }; QT_END_NAMESPACE diff --git a/src/plugins/platforms/wasm/qwasmintegration.h b/src/plugins/platforms/wasm/qwasmintegration.h index cb8639086a..f527053489 100644 --- a/src/plugins/platforms/wasm/qwasmintegration.h +++ b/src/plugins/platforms/wasm/qwasmintegration.h @@ -95,7 +95,7 @@ private: mutable QWasmFontDatabase *m_fontDb; mutable QWasmServices *m_desktopServices; mutable QHash m_backingStores; - QVector> m_screens; + QList> m_screens; mutable QWasmClipboard *m_clipboard; qreal m_fontDpi = -1; mutable QScopedPointer m_inputContext; diff --git a/src/plugins/platforms/windows/qwindowsmenu.cpp b/src/plugins/platforms/windows/qwindowsmenu.cpp index 5f21bdfa33..31d9d3e09b 100644 --- a/src/plugins/platforms/windows/qwindowsmenu.cpp +++ b/src/plugins/platforms/windows/qwindowsmenu.cpp @@ -69,10 +69,10 @@ QT_BEGIN_NAMESPACE static uint nextId = 1; -// Find a QPlatformMenu[Item]* in a vector of QWindowsMenu[Item], where -// QVector::indexOf() cannot be used since it wants a QWindowsMenu[Item]* +// Find a QPlatformMenu[Item]* in a list of QWindowsMenu[Item], where +// QList::indexOf() cannot be used since it wants a QWindowsMenu[Item]* template -static int indexOf(const QVector &v, const Needle *needle) +static int indexOf(const QList &v, const Needle *needle) { for (int i = 0, size = v.size(); i < size; ++i) { if (v.at(i) == needle) @@ -81,9 +81,9 @@ static int indexOf(const QVector &v, const Needle *needle) return -1; } -// Helper for inserting a QPlatformMenu[Item]* into a vector of QWindowsMenu[Item]. +// Helper for inserting a QPlatformMenu[Item]* into a list of QWindowsMenu[Item]. template -static int insertBefore(QVector *v, Base *newItemIn, const Base *before = nullptr) +static int insertBefore(QList *v, Base *newItemIn, const Base *before = nullptr) { int index = before ? indexOf(*v, before) : -1; if (index != -1) { @@ -175,7 +175,7 @@ static QWindowsMenu *findMenuByHandle(const Menu *menu, HMENU hMenu) } template -static int findNextVisibleEntry(const QVector &entries, int pos) +static int findNextVisibleEntry(const QList &entries, int pos) { for (int i = pos, size = entries.size(); i < size; ++i) { if (entries.at(i)->isVisible()) @@ -862,7 +862,7 @@ void QWindowsMenuBar::redraw() const #ifndef QT_NO_DEBUG_STREAM template /* Menu[Item] */ -static void formatTextSequence(QDebug &d, const QVector &v) +static void formatTextSequence(QDebug &d, const QList &v) { if (const int size = v.size()) { d << '[' << size << "]("; diff --git a/src/plugins/platforms/windows/qwindowsmenu.h b/src/plugins/platforms/windows/qwindowsmenu.h index aa36846ec0..b94efbe713 100644 --- a/src/plugins/platforms/windows/qwindowsmenu.h +++ b/src/plugins/platforms/windows/qwindowsmenu.h @@ -44,7 +44,7 @@ #include -#include +#include #include QT_BEGIN_NAMESPACE @@ -120,7 +120,7 @@ class QWindowsMenu : public QPlatformMenu { Q_OBJECT public: - using MenuItems = QVector; + using MenuItems = QList; QWindowsMenu(); ~QWindowsMenu(); @@ -196,7 +196,7 @@ class QWindowsMenuBar : public QPlatformMenuBar { Q_OBJECT public: - using Menus = QVector; + using Menus = QList; QWindowsMenuBar(); ~QWindowsMenuBar() override; diff --git a/src/plugins/platforms/windows/qwindowsmime.cpp b/src/plugins/platforms/windows/qwindowsmime.cpp index 3867311243..e4a7777c4e 100644 --- a/src/plugins/platforms/windows/qwindowsmime.cpp +++ b/src/plugins/platforms/windows/qwindowsmime.cpp @@ -539,9 +539,9 @@ int QWindowsMime::registerMimeType(const QString &mime) */ /*! -\fn QVector QWindowsMime::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const +\fn QList QWindowsMime::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const - Returns a QVector of FORMATETC structures representing the different windows clipboard + Returns a QList of FORMATETC structures representing the different windows clipboard formats that can be provided for the \a mimeType from the \a mimeData. All subclasses must reimplement this pure virtual function. @@ -576,7 +576,7 @@ public: QString mimeForFormat(const FORMATETC &formatetc) const override; bool canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const override; bool convertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData, STGMEDIUM *pmedium) const override; - QVector formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; + QList formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; }; bool QWindowsMimeText::canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const @@ -678,9 +678,9 @@ QString QWindowsMimeText::mimeForFormat(const FORMATETC &formatetc) const } -QVector QWindowsMimeText::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const +QList QWindowsMimeText::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const { - QVector formatics; + QList formatics; if (mimeType.startsWith(u"text/plain") && mimeData->hasText()) { formatics += setCf(CF_UNICODETEXT); formatics += setCf(CF_TEXT); @@ -733,7 +733,7 @@ public: QString mimeForFormat(const FORMATETC &formatetc) const override; bool canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const override; bool convertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData, STGMEDIUM *pmedium) const override; - QVector formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; + QList formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; private: int CF_INETURL_W; // wide char version int CF_INETURL; @@ -829,9 +829,9 @@ QString QWindowsMimeURI::mimeForFormat(const FORMATETC &formatetc) const return format; } -QVector QWindowsMimeURI::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const +QList QWindowsMimeURI::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const { - QVector formatics; + QList formatics; if (mimeType == u"text/uri-list") { if (canConvertFromMime(setCf(CF_HDROP), mimeData)) formatics += setCf(CF_HDROP); @@ -898,7 +898,7 @@ public: // for converting from Qt bool canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const override; bool convertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData, STGMEDIUM * pmedium) const override; - QVector formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; + QList formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; // for converting to Qt bool canConvertToMime(const QString &mimeType, IDataObject *pDataObj) const override; @@ -914,9 +914,9 @@ QWindowsMimeHtml::QWindowsMimeHtml() CF_HTML = QWindowsMime::registerMimeType(QStringLiteral("HTML Format")); } -QVector QWindowsMimeHtml::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const +QList QWindowsMimeHtml::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const { - QVector formatetcs; + QList formatetcs; if (mimeType == u"text/html" && (!mimeData->html().isEmpty())) formatetcs += setCf(CF_HTML); return formatetcs; @@ -1035,7 +1035,7 @@ public: // for converting from Qt bool canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const override; bool convertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData, STGMEDIUM * pmedium) const override; - QVector formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; + QList formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; // for converting to Qt bool canConvertToMime(const QString &mimeType, IDataObject *pDataObj) const override; @@ -1051,9 +1051,9 @@ QWindowsMimeImage::QWindowsMimeImage() CF_PNG = RegisterClipboardFormat(L"PNG"); } -QVector QWindowsMimeImage::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const +QList QWindowsMimeImage::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const { - QVector formatetcs; + QList formatetcs; if (mimeData->hasImage() && mimeType == u"application/x-qt-image") { //add DIBV5 if image has alpha channel. Do not add CF_PNG here as it will confuse MS Office (QTBUG47656). auto image = qvariant_cast(mimeData->imageData()); @@ -1190,7 +1190,7 @@ public: // for converting from Qt bool canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const override; bool convertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData, STGMEDIUM * pmedium) const override; - QVector formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; + QList formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; // for converting to Qt bool canConvertToMime(const QString &mimeType, IDataObject *pDataObj) const override; @@ -1264,9 +1264,9 @@ bool QBuiltInMimes::convertFromMime(const FORMATETC &formatetc, const QMimeData return false; } -QVector QBuiltInMimes::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const +QList QBuiltInMimes::formatsForMime(const QString &mimeType, const QMimeData *mimeData) const { - QVector formatetcs; + QList formatetcs; const auto mit = std::find(outFormats.cbegin(), outFormats.cend(), mimeType); if (mit != outFormats.cend() && mimeData->formats().contains(mimeType)) formatetcs += setCf(mit.key()); @@ -1311,7 +1311,7 @@ public: // for converting from Qt bool canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const override; bool convertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData, STGMEDIUM * pmedium) const override; - QVector formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; + QList formatsForMime(const QString &mimeType, const QMimeData *mimeData) const override; // for converting to Qt bool canConvertToMime(const QString &mimeType, IDataObject *pDataObj) const override; @@ -1381,9 +1381,9 @@ bool QLastResortMimes::convertFromMime(const FORMATETC &formatetc, const QMimeDa #endif // QT_CONFIG(draganddrop) } -QVector QLastResortMimes::formatsForMime(const QString &mimeType, const QMimeData * /*mimeData*/) const +QList QLastResortMimes::formatsForMime(const QString &mimeType, const QMimeData * /*mimeData*/) const { - QVector formatetcs; + QList formatetcs; auto mit = std::find(formats.begin(), formats.end(), mimeType); // register any other available formats if (mit == formats.end() && !excludeList.contains(mimeType, Qt::CaseInsensitive)) @@ -1556,10 +1556,10 @@ QWindowsMime * QWindowsMimeConverter::converterFromMime(const FORMATETC &formate return nullptr; } -QVector QWindowsMimeConverter::allFormatsForMime(const QMimeData *mimeData) const +QList QWindowsMimeConverter::allFormatsForMime(const QMimeData *mimeData) const { ensureInitialized(); - QVector formatics; + QList formatics; #if !QT_CONFIG(draganddrop) Q_UNUSED(mimeData); #else diff --git a/src/plugins/platforms/windows/qwindowsmime.h b/src/plugins/platforms/windows/qwindowsmime.h index f8708f1259..af2a35457f 100644 --- a/src/plugins/platforms/windows/qwindowsmime.h +++ b/src/plugins/platforms/windows/qwindowsmime.h @@ -42,7 +42,7 @@ #include -#include +#include #include QT_BEGIN_NAMESPACE @@ -60,7 +60,7 @@ public: // for converting from Qt virtual bool canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const = 0; virtual bool convertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData, STGMEDIUM * pmedium) const = 0; - virtual QVector formatsForMime(const QString &mimeType, const QMimeData *mimeData) const = 0; + virtual QList formatsForMime(const QString &mimeType, const QMimeData *mimeData) const = 0; // for converting to Qt virtual bool canConvertToMime(const QString &mimeType, IDataObject *pDataObj) const = 0; @@ -80,7 +80,7 @@ public: QWindowsMime *converterToMime(const QString &mimeType, IDataObject *pDataObj) const; QStringList allMimesForFormats(IDataObject *pDataObj) const; QWindowsMime *converterFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const; - QVector allFormatsForMime(const QMimeData *mimeData) const; + QList allFormatsForMime(const QMimeData *mimeData) const; // Convenience. QVariant convertToMime(const QStringList &mimeTypes, IDataObject *pDataObj, QVariant::Type preferredType, @@ -94,7 +94,7 @@ public: private: void ensureInitialized() const; - mutable QVector m_mimes; + mutable QList m_mimes; mutable int m_internalMimeCount = 0; }; diff --git a/src/plugins/platforms/windows/qwindowsole.cpp b/src/plugins/platforms/windows/qwindowsole.cpp index 0a7fef6c30..4427133882 100644 --- a/src/plugins/platforms/windows/qwindowsole.cpp +++ b/src/plugins/platforms/windows/qwindowsole.cpp @@ -178,7 +178,7 @@ QWindowsOleDataObject::EnumFormatEtc(DWORD dwDirection, LPENUMFORMATETC FAR* ppe SCODE sc = S_OK; - QVector fmtetcs; + QList fmtetcs; if (dwDirection == DATADIR_GET) { QWindowsMimeConverter &mc = QWindowsContext::instance()->mimeConverter(); fmtetcs = mc.allFormatsForMime(data); @@ -229,7 +229,7 @@ QWindowsOleDataObject::EnumDAdvise(LPENUMSTATDATA FAR*) \internal */ -QWindowsOleEnumFmtEtc::QWindowsOleEnumFmtEtc(const QVector &fmtetcs) +QWindowsOleEnumFmtEtc::QWindowsOleEnumFmtEtc(const QList &fmtetcs) { if (QWindowsContext::verbose > 1) qCDebug(lcQpaMime) << __FUNCTION__ << fmtetcs; @@ -246,7 +246,7 @@ QWindowsOleEnumFmtEtc::QWindowsOleEnumFmtEtc(const QVector &fmtetcs) } } -QWindowsOleEnumFmtEtc::QWindowsOleEnumFmtEtc(const QVector &lpfmtetcs) +QWindowsOleEnumFmtEtc::QWindowsOleEnumFmtEtc(const QList &lpfmtetcs) { if (QWindowsContext::verbose > 1) qCDebug(lcQpaMime) << __FUNCTION__; diff --git a/src/plugins/platforms/windows/qwindowsole.h b/src/plugins/platforms/windows/qwindowsole.h index 6940657e88..759779c6c3 100644 --- a/src/plugins/platforms/windows/qwindowsole.h +++ b/src/plugins/platforms/windows/qwindowsole.h @@ -43,9 +43,9 @@ #include "qwindowscombase.h" #include +#include #include #include -#include #include @@ -86,8 +86,8 @@ private: class QWindowsOleEnumFmtEtc : public QWindowsComBase { public: - explicit QWindowsOleEnumFmtEtc(const QVector &fmtetcs); - explicit QWindowsOleEnumFmtEtc(const QVector &lpfmtetcs); + explicit QWindowsOleEnumFmtEtc(const QList &fmtetcs); + explicit QWindowsOleEnumFmtEtc(const QList &lpfmtetcs); ~QWindowsOleEnumFmtEtc() override; bool isNull() const; @@ -102,7 +102,7 @@ private: bool copyFormatEtc(LPFORMATETC dest, const FORMATETC *src) const; ULONG m_nIndex = 0; - QVector m_lpfmtetcs; + QList m_lpfmtetcs; bool m_isNull = false; }; diff --git a/src/plugins/platforms/windows/qwindowsopengltester.cpp b/src/plugins/platforms/windows/qwindowsopengltester.cpp index 2d8e51eb3b..bf86727838 100644 --- a/src/plugins/platforms/windows/qwindowsopengltester.cpp +++ b/src/plugins/platforms/windows/qwindowsopengltester.cpp @@ -69,7 +69,7 @@ static GpuDescription adapterIdentifierToGpuDescription(const D3DADAPTER_IDENTIF result.deviceId = adapterIdentifier.DeviceId; result.revision = adapterIdentifier.Revision; result.subSysId = adapterIdentifier.SubSysId; - QVector version(4, 0); + QList version(4, 0); version[0] = HIWORD(adapterIdentifier.DriverVersion.HighPart); // Product version[1] = LOWORD(adapterIdentifier.DriverVersion.HighPart); // Version version[2] = HIWORD(adapterIdentifier.DriverVersion.LowPart); // Sub version @@ -169,9 +169,9 @@ GpuDescription GpuDescription::detect() return result; } -QVector GpuDescription::detectAll() +QList GpuDescription::detectAll() { - QVector result; + QList result; QDirect3D9Handle direct3D9; if (const UINT adapterCount = direct3D9.adapterCount()) { for (UINT adp = 0; adp < adapterCount; ++adp) { diff --git a/src/plugins/platforms/windows/qwindowsopengltester.h b/src/plugins/platforms/windows/qwindowsopengltester.h index b9db2afd4b..9091949699 100644 --- a/src/plugins/platforms/windows/qwindowsopengltester.h +++ b/src/plugins/platforms/windows/qwindowsopengltester.h @@ -42,7 +42,7 @@ #include #include -#include +#include #include QT_BEGIN_NAMESPACE @@ -53,7 +53,7 @@ class QVariant; struct GpuDescription { static GpuDescription detect(); - static QVector detectAll(); + static QList detectAll(); QString toString() const; QVariant toVariant() const; diff --git a/src/plugins/platforms/windows/qwindowsscreen.cpp b/src/plugins/platforms/windows/qwindowsscreen.cpp index 0ccadfa343..34e9e8fe31 100644 --- a/src/plugins/platforms/windows/qwindowsscreen.cpp +++ b/src/plugins/platforms/windows/qwindowsscreen.cpp @@ -74,7 +74,7 @@ static inline QDpi monitorDPI(HMONITOR hMonitor) return {0, 0}; } -using WindowsScreenDataList = QVector; +using WindowsScreenDataList = QList; static bool monitorData(HMONITOR hMonitor, QWindowsScreenData *data) { diff --git a/src/plugins/platforms/windows/qwindowsscreen.h b/src/plugins/platforms/windows/qwindowsscreen.h index 9b1e61743e..1989934ad4 100644 --- a/src/plugins/platforms/windows/qwindowsscreen.h +++ b/src/plugins/platforms/windows/qwindowsscreen.h @@ -43,7 +43,6 @@ #include "qtwindowsglobal.h" #include -#include #include #include #include @@ -127,7 +126,7 @@ private: class QWindowsScreenManager { public: - using WindowsScreenList = QVector; + using WindowsScreenList = QList; QWindowsScreenManager(); diff --git a/src/plugins/platforms/windows/qwindowssystemtrayicon.cpp b/src/plugins/platforms/windows/qwindowssystemtrayicon.cpp index def011e4bd..7c473e66b6 100644 --- a/src/plugins/platforms/windows/qwindowssystemtrayicon.cpp +++ b/src/plugins/platforms/windows/qwindowssystemtrayicon.cpp @@ -60,8 +60,8 @@ #include #include #include +#include #include -#include #include #include @@ -119,7 +119,7 @@ struct QWindowsHwndSystemTrayIconEntry QWindowsSystemTrayIcon *trayIcon; }; -using HwndTrayIconEntries = QVector; +using HwndTrayIconEntries = QList; Q_GLOBAL_STATIC(HwndTrayIconEntries, hwndTrayIconEntries) diff --git a/src/plugins/platforms/windows/qwindowstabletsupport.cpp b/src/plugins/platforms/windows/qwindowstabletsupport.cpp index f2c82f3247..7b8ba35065 100644 --- a/src/plugins/platforms/windows/qwindowstabletsupport.cpp +++ b/src/plugins/platforms/windows/qwindowstabletsupport.cpp @@ -318,7 +318,7 @@ void QWindowsTabletSupport::notifyActivate() qCDebug(lcQpaTablet) << __FUNCTION__ << result; } -static inline int indexOfDevice(const QVector &devices, qint64 uniqueId) +static inline int indexOfDevice(const QList &devices, qint64 uniqueId) { for (int i = 0; i < devices.size(); ++i) if (devices.at(i).uniqueId == uniqueId) diff --git a/src/plugins/platforms/windows/qwindowstabletsupport.h b/src/plugins/platforms/windows/qwindowstabletsupport.h index b50b1875dc..a47d7fb2f5 100644 --- a/src/plugins/platforms/windows/qwindowstabletsupport.h +++ b/src/plugins/platforms/windows/qwindowstabletsupport.h @@ -44,9 +44,9 @@ #include #include -#include -#include #include +#include +#include #include @@ -152,7 +152,7 @@ private: const HCTX m_context; int m_absoluteRange = 20; bool m_tiltSupport = false; - QVector m_devices; + QList m_devices; int m_currentDevice = -1; Mode m_mode = PenMode; State m_state = PenUp; diff --git a/src/plugins/platforms/windows/uiautomation/qwindowsuiaselectionprovider.cpp b/src/plugins/platforms/windows/uiautomation/qwindowsuiaselectionprovider.cpp index fb41012cf4..3305e9c5c4 100644 --- a/src/plugins/platforms/windows/uiautomation/qwindowsuiaselectionprovider.cpp +++ b/src/plugins/platforms/windows/uiautomation/qwindowsuiaselectionprovider.cpp @@ -49,7 +49,6 @@ #include #include #include -#include QT_BEGIN_NAMESPACE @@ -79,7 +78,7 @@ HRESULT STDMETHODCALLTYPE QWindowsUiaSelectionProvider::GetSelection(SAFEARRAY * return UIA_E_ELEMENTNOTAVAILABLE; // First put selected items in a list, then build a safe array with the right size. - QVector selectedList; + QList selectedList; for (int i = 0; i < accessible->childCount(); ++i) { if (QAccessibleInterface *child = accessible->child(i)) { if (child->state().selected) { diff --git a/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp b/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp index feae5fa13c..6318501662 100644 --- a/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp +++ b/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp @@ -261,7 +261,7 @@ QGLXContext::QGLXContext(Display *display, QXcbScreen *screen, const QSurfaceFor // order from the requested version. const int requestedVersion = m_format.majorVersion() * 10 + qMin(m_format.minorVersion(), 9); - QVector glVersions; + QList glVersions; if (m_format.renderableType() == QSurfaceFormat::OpenGL) { if (requestedVersion > 46) glVersions << requestedVersion; @@ -290,7 +290,7 @@ QGLXContext::QGLXContext(Display *display, QXcbScreen *screen, const QSurfaceFor const int majorVersion = version / 10; const int minorVersion = version % 10; - QVector contextAttributes; + QList contextAttributes; contextAttributes << GLX_CONTEXT_MAJOR_VERSION_ARB << majorVersion << GLX_CONTEXT_MINOR_VERSION_ARB << minorVersion; @@ -323,7 +323,7 @@ QGLXContext::QGLXContext(Display *display, QXcbScreen *screen, const QSurfaceFor } if (supportsRobustness && m_format.testOption(QSurfaceFormat::ResetNotification)) { - QVector contextAttributesWithRobustness = contextAttributes; + QList contextAttributesWithRobustness = contextAttributes; contextAttributesWithRobustness << GLX_CONTEXT_RESET_NOTIFICATION_STRATEGY_ARB << GLX_LOSE_CONTEXT_ON_RESET_ARB; if (supportsVideoMemoryPurge) contextAttributesWithRobustness << GLX_GENERATE_RESET_ON_VIDEO_MEMORY_PURGE_NV << GL_TRUE; diff --git a/src/plugins/platforms/xcb/nativepainting/qbackingstore_x11.cpp b/src/plugins/platforms/xcb/nativepainting/qbackingstore_x11.cpp index bbc156fc53..5193461273 100644 --- a/src/plugins/platforms/xcb/nativepainting/qbackingstore_x11.cpp +++ b/src/plugins/platforms/xcb/nativepainting/qbackingstore_x11.cpp @@ -100,7 +100,7 @@ void QXcbNativeBackingStore::flush(QWindow *window, const QRegion ®ion, const Window wid = platformWindow->xcb_window(); Pixmap pid = qt_x11PixmapHandle(m_pixmap); - QVector clipRects = qt_region_to_xrectangles(clipped); + QList clipRects = qt_region_to_xrectangles(clipped); #if QT_CONFIG(xrender) if (m_translucentBackground) @@ -198,7 +198,7 @@ void QXcbNativeBackingStore::beginPaint(const QRegion ®ion) #if QT_CONFIG(xrender) if (m_translucentBackground) { - const QVector xrects = qt_region_to_xrectangles(region); + const QList xrects = qt_region_to_xrectangles(region); const XRenderColor color = { 0, 0, 0, 0 }; XRenderFillRectangles(display(), PictOpSrc, qt_x11PictureHandle(m_pixmap), &color, diff --git a/src/plugins/platforms/xcb/nativepainting/qcolormap_x11.cpp b/src/plugins/platforms/xcb/nativepainting/qcolormap_x11.cpp index fe9d1fcde9..b4a9d64eb8 100644 --- a/src/plugins/platforms/xcb/nativepainting/qcolormap_x11.cpp +++ b/src/plugins/platforms/xcb/nativepainting/qcolormap_x11.cpp @@ -77,8 +77,8 @@ public: uint g_shift; uint b_shift; - QVector colors; - QVector pixels; + QList colors; + QList pixels; }; static uint right_align(uint v) @@ -638,7 +638,7 @@ const QColor QXcbColormap::colorAt(uint pixel) const return QColor(r, g, b); } -const QVector QXcbColormap::colormap() const +const QList QXcbColormap::colormap() const { return d->colors; } QXcbColormap &QXcbColormap::operator=(const QXcbColormap &colormap) diff --git a/src/plugins/platforms/xcb/nativepainting/qcolormap_x11_p.h b/src/plugins/platforms/xcb/nativepainting/qcolormap_x11_p.h index 573a0f28ea..c4070321de 100644 --- a/src/plugins/platforms/xcb/nativepainting/qcolormap_x11_p.h +++ b/src/plugins/platforms/xcb/nativepainting/qcolormap_x11_p.h @@ -41,7 +41,7 @@ #define QCOLORMAP_X11_H #include -#include +#include QT_BEGIN_NAMESPACE @@ -69,7 +69,7 @@ public: uint pixel(const QColor &color) const; const QColor colorAt(uint pixel) const; - const QVector colormap() const; + const QList colormap() const; private: QXcbColormap(); diff --git a/src/plugins/platforms/xcb/nativepainting/qpaintengine_x11.cpp b/src/plugins/platforms/xcb/nativepainting/qpaintengine_x11.cpp index 77d0caf649..ab0f537926 100644 --- a/src/plugins/platforms/xcb/nativepainting/qpaintengine_x11.cpp +++ b/src/plugins/platforms/xcb/nativepainting/qpaintengine_x11.cpp @@ -392,7 +392,7 @@ static inline void x11SetClipRegion(Display *dpy, GC gc, GC gc2, { // int num; // XRectangle *rects = (XRectangle *)qt_getClipRects(r, num); - QVector rects = qt_region_to_xrectangles(r); + QList rects = qt_region_to_xrectangles(r); int num = rects.size(); if (gc) @@ -2129,7 +2129,7 @@ void QX11PaintEngine::drawPixmap(const QRectF &r, const QPixmap &px, const QRect XSetBackground(d->dpy, cgc, 0); XSetForeground(d->dpy, cgc, 1); if (!d->crgn.isEmpty()) { - QVector rects = qt_region_to_xrectangles(d->crgn); + QList rects = qt_region_to_xrectangles(d->crgn); XSetClipRectangles(d->dpy, cgc, -x, -y, rects.data(), rects.size(), Unsorted); } else if (d->has_clipping) { XSetClipRectangles(d->dpy, cgc, 0, 0, 0, 0, Unsorted); @@ -2152,7 +2152,7 @@ void QX11PaintEngine::drawPixmap(const QRectF &r, const QPixmap &px, const QRect GC cgc = XCreateGC(d->dpy, comb, 0, 0); XSetForeground(d->dpy, cgc, 0); XFillRectangle(d->dpy, comb, cgc, 0, 0, sw, sh); - QVector rects = qt_region_to_xrectangles(d->crgn); + QList rects = qt_region_to_xrectangles(d->crgn); XSetClipRectangles(d->dpy, cgc, -x, -y, rects.data(), rects.size(), Unsorted); XCopyArea(d->dpy, qt_x11PixmapHandle(pixmap), comb, cgc, sx, sy, sw, sh, 0, 0); XFreeGC(d->dpy, cgc); @@ -2201,7 +2201,7 @@ void QX11PaintEngine::drawPixmap(const QRectF &r, const QPixmap &px, const QRect if (restore_clip) { XSetClipOrigin(d->dpy, d->gc, 0, 0); - QVector rects = qt_region_to_xrectangles(d->crgn); + QList rects = qt_region_to_xrectangles(d->crgn); if (rects.isEmpty()) XSetClipMask(d->dpy, d->gc, XNone); else diff --git a/src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp b/src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp index 467e93e64f..d55a49768c 100644 --- a/src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp +++ b/src/plugins/platforms/xcb/nativepainting/qpixmap_x11.cpp @@ -573,7 +573,7 @@ void QX11PlatformPixmap::fromImage(const QImage &img, Qt::ImageConversionFlags f switch (cimage.format()) { case QImage::Format_Indexed8: { - QVector colorTable = cimage.colorTable(); + QList colorTable = cimage.colorTable(); uint *xidata = (uint *)xi->data; for (int y = 0; y < h; ++y) { const uchar *p = cimage.scanLine(y); @@ -676,7 +676,7 @@ void QX11PlatformPixmap::fromImage(const QImage &img, Qt::ImageConversionFlags f const uint bbits = highest_bit(blue_mask) - lowest_bit(blue_mask) + 1; if (d8) { // setup pixel translation - QVector ctable = cimage.colorTable(); + QList ctable = cimage.colorTable(); for (int i=0; i < cimage.colorCount(); i++) { int r = qRed (ctable[i]); int g = qGreen(ctable[i]); @@ -1061,7 +1061,7 @@ void QX11PlatformPixmap::fromImage(const QImage &img, Qt::ImageConversionFlags f int maxpop = 0; int maxpix = 0; uint j = 0; - QVector ctable = cimage.colorTable(); + QList ctable = cimage.colorTable(); for (int i = 0; i < 256; i++) { // init pixel array if (pop[i] > 0) { px->r = qRed (ctable[i]); @@ -2114,7 +2114,7 @@ QImage QX11PlatformPixmap::toImage(const QXImageWrapper &xiWrapper, const QRect } else { image.setColorCount(ncols); // create color table } - QVector colors = QXcbColormap::instance(xinfo.screen()).colormap(); + QList colors = QXcbColormap::instance(xinfo.screen()).colormap(); int j = 0; for (int i=0; i qt_region_to_xrectangles(const QRegion &r) +QList qt_region_to_xrectangles(const QRegion &r) { const int numRects = r.rectCount(); const auto input = r.begin(); - QVector output(numRects); + QList output(numRects); for (int i = 0; i < numRects; ++i) { const QRect &in = input[i]; XRectangle &out = output[i]; diff --git a/src/plugins/platforms/xcb/nativepainting/qxcbnativepainting.h b/src/plugins/platforms/xcb/nativepainting/qxcbnativepainting.h index b00ccfcdff..7682be8b4a 100644 --- a/src/plugins/platforms/xcb/nativepainting/qxcbnativepainting.h +++ b/src/plugins/platforms/xcb/nativepainting/qxcbnativepainting.h @@ -55,7 +55,7 @@ class QXcbConnection; class QPixmap; void qt_xcb_native_x11_info_init(QXcbConnection *conn); -QVector qt_region_to_xrectangles(const QRegion &r); +QList qt_region_to_xrectangles(const QRegion &r); class QXcbX11InfoData; class QXcbX11Info diff --git a/src/plugins/platforms/xcb/qxcbclipboard.cpp b/src/plugins/platforms/xcb/qxcbclipboard.cpp index e04f2c6665..6d023035f2 100644 --- a/src/plugins/platforms/xcb/qxcbclipboard.cpp +++ b/src/plugins/platforms/xcb/qxcbclipboard.cpp @@ -131,7 +131,7 @@ protected: (void)formats(); // trigger update of format list - QVector atoms; + QList atoms; const xcb_atom_t *targets = (const xcb_atom_t *) format_atoms.data(); int size = format_atoms.size() / sizeof(xcb_atom_t); atoms.reserve(size); @@ -445,10 +445,10 @@ xcb_window_t QXcbClipboard::owner() const xcb_atom_t QXcbClipboard::sendTargetsSelection(QMimeData *d, xcb_window_t window, xcb_atom_t property) { - QVector types; + QList types; QStringList formats = QInternalMimeData::formatsHelper(d); for (int i = 0; i < formats.size(); ++i) { - QVector atoms = QXcbMime::mimeAtomsForFormat(connection(), formats.at(i)); + QList atoms = QXcbMime::mimeAtomsForFormat(connection(), formats.at(i)); for (int j = 0; j < atoms.size(); ++j) { if (!types.contains(atoms.at(j))) types.append(atoms.at(j)); diff --git a/src/plugins/platforms/xcb/qxcbconnection.h b/src/plugins/platforms/xcb/qxcbconnection.h index e6feabf79e..a097604643 100644 --- a/src/plugins/platforms/xcb/qxcbconnection.h +++ b/src/plugins/platforms/xcb/qxcbconnection.h @@ -49,7 +49,6 @@ #include "qxcbexport.h" #include #include -#include #include #include #include @@ -277,7 +276,7 @@ private: int number = -1; QXcbAtom::Atom label; }; - QVector valuatorInfo; + QList valuatorInfo; // Stuff that is relevant only for touchpads QPointF firstPressedPosition; // in screen coordinates where the first point was pressed @@ -313,7 +312,7 @@ private: friend class QTypeInfo; bool xi2HandleTabletEvent(const void *event, TabletData *tabletData); void xi2ReportTabletEvent(const void *event, TabletData *tabletData); - QVector m_tabletData; + QList m_tabletData; TabletData *tabletDataForDevice(int id); #endif // QT_CONFIG(tabletevent) // TODO get rid of this: store a smaller struct in QPointingDevicePrivate::extra @@ -378,7 +377,7 @@ private: mutable QXcbGlIntegration *m_glIntegration = nullptr; mutable bool m_glIntegrationInitialized = false; bool m_xiGrab = false; - QVector m_xiMasterPointerIds; + QList m_xiMasterPointerIds; xcb_window_t m_qtSelectionOwner = 0; diff --git a/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp b/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp index d93cbc2822..d50c3c6e8c 100644 --- a/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp +++ b/src/plugins/platforms/xcb/qxcbconnection_xi2.cpp @@ -572,7 +572,7 @@ void QXcbConnection::xi2SelectDeviceEventsCompatibility(xcb_window_t window) QSet tabletDevices; if (!m_tabletData.isEmpty()) { const int nrTablets = m_tabletData.count(); - QVector xiEventMask(nrTablets); + QList xiEventMask(nrTablets); for (int i = 0; i < nrTablets; ++i) { int deviceId = m_tabletData.at(i).deviceId; tabletDevices.insert(deviceId); @@ -585,7 +585,7 @@ void QXcbConnection::xi2SelectDeviceEventsCompatibility(xcb_window_t window) #endif if (!m_scrollingDevices.isEmpty()) { - QVector xiEventMask(m_scrollingDevices.size()); + QList xiEventMask(m_scrollingDevices.size()); int i = 0; for (const ScrollingDevice& scrollingDevice : qAsConst(m_scrollingDevices)) { #if QT_CONFIG(tabletevent) diff --git a/src/plugins/platforms/xcb/qxcbdrag.cpp b/src/plugins/platforms/xcb/qxcbdrag.cpp index ab4acbe727..3e24027e51 100644 --- a/src/plugins/platforms/xcb/qxcbdrag.cpp +++ b/src/plugins/platforms/xcb/qxcbdrag.cpp @@ -182,7 +182,7 @@ void QXcbDrag::startDrag() QStringList fmts = QXcbMime::formatsHelper(drag()->mimeData()); for (int i = 0; i < fmts.size(); ++i) { - QVector atoms = QXcbMime::mimeAtomsForFormat(connection(), fmts.at(i)); + QList atoms = QXcbMime::mimeAtomsForFormat(connection(), fmts.at(i)); for (int j = 0; j < atoms.size(); ++j) { if (!drag_types.contains(atoms.at(j))) drag_types.append(atoms.at(j)); @@ -580,7 +580,7 @@ Qt::DropAction QXcbDrag::toDropAction(xcb_atom_t a) const return Qt::CopyAction; } -Qt::DropActions QXcbDrag::toDropActions(const QVector &atoms) const +Qt::DropActions QXcbDrag::toDropActions(const QList &atoms) const { Qt::DropActions actions; for (const auto actionAtom : atoms) { @@ -625,7 +625,7 @@ void QXcbDrag::readActionList() void QXcbDrag::setActionList(Qt::DropAction requestedAction, Qt::DropActions supportedActions) { #ifndef QT_NO_CLIPBOARD - QVector actions; + QList actions; if (requestedAction != Qt::IgnoreAction) actions.append(toXdndAction(requestedAction)); @@ -1361,7 +1361,7 @@ QVariant QXcbDropData::xdndObtainData(const QByteArray &format, QMetaType::Type return result; } - QVector atoms = drag->xdnd_types; + QList atoms = drag->xdnd_types; bool hasUtf8 = false; xcb_atom_t a = mimeAtomForFormat(c, QLatin1String(format), requestedType, atoms, &hasUtf8); if (a == XCB_NONE) diff --git a/src/plugins/platforms/xcb/qxcbdrag.h b/src/plugins/platforms/xcb/qxcbdrag.h index 0d16afc47e..257e82f049 100644 --- a/src/plugins/platforms/xcb/qxcbdrag.h +++ b/src/plugins/platforms/xcb/qxcbdrag.h @@ -42,16 +42,16 @@ #include #include -#include #include +#include +#include +#include +#include #include +#include #include #include -#include -#include -#include -#include -#include +#include #include @@ -118,7 +118,7 @@ private: void send_leave(); Qt::DropAction toDropAction(xcb_atom_t atom) const; - Qt::DropActions toDropActions(const QVector &atoms) const; + Qt::DropActions toDropActions(const QList &atoms) const; xcb_atom_t toXdndAction(Qt::DropAction a) const; void readActionList(); @@ -139,7 +139,7 @@ private: // the types in this drop. 100 is no good, but at least it's big. enum { xdnd_max_type = 100 }; - QVector xdnd_types; + QList xdnd_types; // timestamp from XdndPosition and XdndDroptime for retrieving the data xcb_timestamp_t target_time; @@ -167,10 +167,10 @@ private: enum { XdndDropTransactionTimeout = 600000 }; int cleanup_timer; - QVector drag_types; + QList drag_types; - QVector current_actions; - QVector drop_actions; + QList current_actions; + QList drop_actions; struct Transaction { @@ -183,7 +183,7 @@ private: QTime time; }; friend class QTypeInfo; - QVector transactions; + QList transactions; int transaction_expiry_timer; void restartDropExpiryTimer(); diff --git a/src/plugins/platforms/xcb/qxcbeventqueue.h b/src/plugins/platforms/xcb/qxcbeventqueue.h index e7327b3fd6..4763b57ecb 100644 --- a/src/plugins/platforms/xcb/qxcbeventqueue.h +++ b/src/plugins/platforms/xcb/qxcbeventqueue.h @@ -42,7 +42,7 @@ #include #include #include -#include +#include #include #include @@ -132,7 +132,7 @@ private: bool m_peekerIndexCacheDirty = false; QHash m_peekerToNode; - QVector m_inputEvents; + QList m_inputEvents; // debug stats quint64 m_nodesOnHeap = 0; diff --git a/src/plugins/platforms/xcb/qxcbkeyboard.cpp b/src/plugins/platforms/xcb/qxcbkeyboard.cpp index e8286381a2..9ab804ca1b 100644 --- a/src/plugins/platforms/xcb/qxcbkeyboard.cpp +++ b/src/plugins/platforms/xcb/qxcbkeyboard.cpp @@ -223,7 +223,7 @@ struct xkb_keymap *QXcbKeyboard::keymapFromCore(const KeysymModifierMap &keysymM // Generate mapping between symbolic names and keysyms { - QVector xkeymap; + QList xkeymap; int keysymsPerKeycode = 0; { int keycodeCount = maxKeycode - minKeycode + 1; diff --git a/src/plugins/platforms/xcb/qxcbmime.cpp b/src/plugins/platforms/xcb/qxcbmime.cpp index e761b066ad..bb168b9b00 100644 --- a/src/plugins/platforms/xcb/qxcbmime.cpp +++ b/src/plugins/platforms/xcb/qxcbmime.cpp @@ -129,9 +129,9 @@ bool QXcbMime::mimeDataForAtom(QXcbConnection *connection, xcb_atom_t a, QMimeDa return ret; } -QVector QXcbMime::mimeAtomsForFormat(QXcbConnection *connection, const QString &format) +QList QXcbMime::mimeAtomsForFormat(QXcbConnection *connection, const QString &format) { - QVector atoms; + QList atoms; atoms.reserve(7); atoms.append(connection->internAtom(format.toLatin1())); @@ -256,7 +256,7 @@ QVariant QXcbMime::mimeConvertToFormat(QXcbConnection *connection, xcb_atom_t a, } xcb_atom_t QXcbMime::mimeAtomForFormat(QXcbConnection *connection, const QString &format, QMetaType::Type requestedType, - const QVector &atoms, bool *hasUtf8) + const QList &atoms, bool *hasUtf8) { *hasUtf8 = false; diff --git a/src/plugins/platforms/xcb/qxcbmime.h b/src/plugins/platforms/xcb/qxcbmime.h index cd6161a08b..d348bae77e 100644 --- a/src/plugins/platforms/xcb/qxcbmime.h +++ b/src/plugins/platforms/xcb/qxcbmime.h @@ -55,14 +55,14 @@ public: QXcbMime(); ~QXcbMime(); - static QVector mimeAtomsForFormat(QXcbConnection *connection, const QString &format); + static QList mimeAtomsForFormat(QXcbConnection *connection, const QString &format); static QString mimeAtomToString(QXcbConnection *connection, xcb_atom_t a); static bool mimeDataForAtom(QXcbConnection *connection, xcb_atom_t a, QMimeData *mimeData, QByteArray *data, xcb_atom_t *atomFormat, int *dataFormat); static QVariant mimeConvertToFormat(QXcbConnection *connection, xcb_atom_t a, const QByteArray &data, const QString &format, QMetaType::Type requestedType, bool hasUtf8); static xcb_atom_t mimeAtomForFormat(QXcbConnection *connection, const QString &format, QMetaType::Type requestedType, - const QVector &atoms, bool *hasUtf8); + const QList &atoms, bool *hasUtf8); }; QT_END_NAMESPACE diff --git a/src/plugins/platforms/xcb/qxcbwindow.cpp b/src/plugins/platforms/xcb/qxcbwindow.cpp index af12f20104..c29e18529c 100644 --- a/src/plugins/platforms/xcb/qxcbwindow.cpp +++ b/src/plugins/platforms/xcb/qxcbwindow.cpp @@ -632,7 +632,7 @@ QMargins QXcbWindow::frameMargins() const bool foundRoot = false; - const QVector &virtualRoots = + const QList &virtualRoots = connection()->wmSupport()->virtualRoots(); while (!foundRoot) { @@ -1086,7 +1086,7 @@ void QXcbWindow::setNetWmStateOnUnmappedWindow() // we first read it and then merge our hints with the existing values, allowing a user // to set custom hints. - QVector atoms; + QList atoms; auto reply = Q_XCB_REPLY_UNCHECKED(xcb_get_property, xcb_connection(), 0, m_window, atom(QXcbAtom::_NET_WM_STATE), XCB_ATOM_ATOM, 0, 1024); @@ -1293,7 +1293,7 @@ void QXcbWindow::setWindowIconText(const QString &title) void QXcbWindow::setWindowIcon(const QIcon &icon) { - QVector icon_data; + QList icon_data; if (!icon.isNull()) { QList availableSizes = icon.availableSizes(); if (availableSizes.isEmpty()) { @@ -1542,7 +1542,7 @@ QXcbWindowFunctions::WmWindowTypes QXcbWindow::wmWindowTypes() const void QXcbWindow::setWmWindowType(QXcbWindowFunctions::WmWindowTypes types, Qt::WindowFlags flags) { - QVector atoms; + QList atoms; // manual selection 1 (these are never set by Qt and take precedence) if (types & QXcbWindowFunctions::Normal) @@ -2526,9 +2526,9 @@ void QXcbWindow::setOpacity(qreal level) (uchar *)&value); } -QVector qRegionToXcbRectangleList(const QRegion ®ion) +QList qRegionToXcbRectangleList(const QRegion ®ion) { - QVector rects; + QList rects; rects.reserve(region.rectCount()); for (const QRect &r : region) rects.push_back(qRectToXCBRectangle(r)); diff --git a/src/plugins/platforms/xcb/qxcbwindow.h b/src/plugins/platforms/xcb/qxcbwindow.h index a5803939fb..258ee3fe95 100644 --- a/src/plugins/platforms/xcb/qxcbwindow.h +++ b/src/plugins/platforms/xcb/qxcbwindow.h @@ -296,7 +296,7 @@ protected: void create() override {} // No-op }; -QVector qRegionToXcbRectangleList(const QRegion ®ion); +QList qRegionToXcbRectangleList(const QRegion ®ion); QT_END_NAMESPACE diff --git a/src/plugins/platforms/xcb/qxcbwmsupport.h b/src/plugins/platforms/xcb/qxcbwmsupport.h index b5de5b7e5b..24b3fde16a 100644 --- a/src/plugins/platforms/xcb/qxcbwmsupport.h +++ b/src/plugins/platforms/xcb/qxcbwmsupport.h @@ -41,7 +41,7 @@ #include "qxcbobject.h" #include "qxcbconnection.h" -#include +#include QT_BEGIN_NAMESPACE @@ -52,15 +52,15 @@ public: bool isSupportedByWM(xcb_atom_t atom) const; - const QVector &virtualRoots() const { return net_virtual_roots; } + const QList &virtualRoots() const { return net_virtual_roots; } private: friend class QXcbConnection; void updateNetWMAtoms(); void updateVirtualRoots(); - QVector net_wm_atoms; - QVector net_virtual_roots; + QList net_wm_atoms; + QList net_virtual_roots; }; QT_END_NAMESPACE diff --git a/src/plugins/platformthemes/gtk3/qgtk3menu.h b/src/plugins/platformthemes/gtk3/qgtk3menu.h index cce800fbd8..8e3f951649 100644 --- a/src/plugins/platformthemes/gtk3/qgtk3menu.h +++ b/src/plugins/platformthemes/gtk3/qgtk3menu.h @@ -156,7 +156,7 @@ protected: private: GtkWidget *m_menu; QPoint m_targetPos; - QVector m_items; + QList m_items; }; QT_END_NAMESPACE diff --git a/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog_p.h b/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog_p.h index c1f1a2c005..b21a9f7d84 100644 --- a/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog_p.h +++ b/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog_p.h @@ -40,7 +40,7 @@ #define QXDGDESKTOPPORTALFILEDIALOG_P_H #include -#include +#include QT_BEGIN_NAMESPACE @@ -61,13 +61,13 @@ public: ConditionType type; QString pattern; // E.g. '*ico' or 'image/png' }; - typedef QVector FilterConditionList; + typedef QList FilterConditionList; struct Filter { QString name; // E.g. 'Images' or 'Text FilterConditionList filterConditions;; // E.g. [(0, '*.ico'), (1, 'image/png')] or [(0, '*.txt')] }; - typedef QVector FilterList; + typedef QList FilterList; QXdgDesktopPortalFileDialog(QPlatformFileDialogHelper *nativeFileDialog = nullptr); ~QXdgDesktopPortalFileDialog(); diff --git a/src/plugins/printsupport/cups/qcupsprintengine.cpp b/src/plugins/printsupport/cups/qcupsprintengine.cpp index d09b2b5a69..f0893df8b5 100644 --- a/src/plugins/printsupport/cups/qcupsprintengine.cpp +++ b/src/plugins/printsupport/cups/qcupsprintengine.cpp @@ -201,7 +201,7 @@ void QCupsPrintEnginePrivate::closePrintDevice() // Set up print options. QList > options; - QVector cupsOptStruct; + QList cupsOptStruct; options.append(QPair("media", m_pageLayout.pageSize().key().toLocal8Bit())); diff --git a/src/plugins/printsupport/windows/qwindowsprintdevice.cpp b/src/plugins/printsupport/windows/qwindowsprintdevice.cpp index f01e93d611..bfd7a9a946 100644 --- a/src/plugins/printsupport/windows/qwindowsprintdevice.cpp +++ b/src/plugins/printsupport/windows/qwindowsprintdevice.cpp @@ -49,7 +49,7 @@ QT_BEGIN_NAMESPACE QT_WARNING_DISABLE_GCC("-Wsign-compare") -typedef QVector WindowsPrinterLookup; +typedef QList WindowsPrinterLookup; Q_GLOBAL_STATIC(WindowsPrinterLookup, windowsDeviceLookup); extern qreal qt_pointMultiplier(QPageLayout::Unit unit); diff --git a/src/plugins/printsupport/windows/qwindowsprintdevice.h b/src/plugins/printsupport/windows/qwindowsprintdevice.h index 166f0f65b2..8b63998181 100644 --- a/src/plugins/printsupport/windows/qwindowsprintdevice.h +++ b/src/plugins/printsupport/windows/qwindowsprintdevice.h @@ -75,10 +75,10 @@ public: QString m_makeAndModel; QList m_pageSizes; QList m_resolutions; - QVector m_inputSlots; - QVector m_outputBins; - QVector m_duplexModes; - QVector m_colorModes; + QList m_inputSlots; + QList m_outputBins; + QList m_duplexModes; + QList m_colorModes; QSize m_minimumPhysicalPageSize; QSize m_maximumPhysicalPageSize; bool m_isRemote = false; diff --git a/src/plugins/sqldrivers/db2/qsql_db2.cpp b/src/plugins/sqldrivers/db2/qsql_db2.cpp index ddf54666e7..da5ff95179 100644 --- a/src/plugins/sqldrivers/db2/qsql_db2.cpp +++ b/src/plugins/sqldrivers/db2/qsql_db2.cpp @@ -40,13 +40,13 @@ #include "qsql_db2_p.h" #include #include -#include +#include #include +#include #include #include #include #include -#include #include #include #include @@ -141,7 +141,7 @@ public: SQLHANDLE hStmt; QSqlRecord recInf; - QVector valueCache; + QList valueCache; }; static QString qFromTChar(SQLTCHAR* str) @@ -692,7 +692,7 @@ bool QDB2Result::exec() return false; - QVector &values = boundValues(); + QList &values = boundValues(); int i; for (i = 0; i < values.count(); ++i) { // bind parameters - only positional binding allowed diff --git a/src/plugins/sqldrivers/ibase/qsql_ibase.cpp b/src/plugins/sqldrivers/ibase/qsql_ibase.cpp index ba79cdad9b..eae72fff4f 100644 --- a/src/plugins/sqldrivers/ibase/qsql_ibase.cpp +++ b/src/plugins/sqldrivers/ibase/qsql_ibase.cpp @@ -41,20 +41,19 @@ #include #include #include -#include +#include +#include +#include #include #include #include #include +#include #include #include -#include -#include -#include #include #include #include -#include #include QT_BEGIN_NAMESPACE @@ -968,7 +967,7 @@ bool QIBaseResult::exec() setAt(QSql::BeforeFirstRow); if (d->inda) { - QVector& values = boundValues(); + QList& values = boundValues(); int i; if (values.count() > d->inda->sqld) { qWarning("QIBaseResult::exec: Parameter mismatch, expected %d, got %d parameters", diff --git a/src/plugins/sqldrivers/mysql/qsql_mysql.cpp b/src/plugins/sqldrivers/mysql/qsql_mysql.cpp index 10c3e11bf2..2629233098 100644 --- a/src/plugins/sqldrivers/mysql/qsql_mysql.cpp +++ b/src/plugins/sqldrivers/mysql/qsql_mysql.cpp @@ -42,15 +42,15 @@ #include #include #include +#include +#include +#include #include #include #include #include #include #include -#include -#include -#include #include #include @@ -178,7 +178,7 @@ public: ulong bufLength = 0ul; }; - QVector fields; + QList fields; MYSQL_STMT *stmt = nullptr; MYSQL_RES *meta = nullptr; @@ -882,11 +882,11 @@ bool QMYSQLResult::exec() int r = 0; MYSQL_BIND* currBind; - QVector timeVector; - QVector stringVector; - QVector nullVector; + QList timeVector; + QList stringVector; + QList nullVector; - const QVector values = boundValues(); + const QList values = boundValues(); r = mysql_stmt_reset(d->stmt); if (r != 0) { diff --git a/src/plugins/sqldrivers/oci/qsql_oci.cpp b/src/plugins/sqldrivers/oci/qsql_oci.cpp index cf50942c69..48295f58e5 100644 --- a/src/plugins/sqldrivers/oci/qsql_oci.cpp +++ b/src/plugins/sqldrivers/oci/qsql_oci.cpp @@ -40,8 +40,9 @@ #include "qsql_oci_p.h" #include -#include #include +#include +#include #include #if QT_CONFIG(regularexpression) #include @@ -54,10 +55,9 @@ #include #include #include -#include -#include -#include #include +#include +#include // This is needed for oracle oci when compiling with mingw-w64 headers #if defined(__MINGW64_VERSION_MAJOR) && defined(_WIN64) @@ -283,9 +283,9 @@ public: void setStatementAttributes(); int bindValue(OCIStmt *sql, OCIBind **hbnd, OCIError *err, int pos, const QVariant &val, dvoid *indPtr, ub2 *tmpSize, TempStorage &tmpStorage); - int bindValues(QVector &values, IndicatorArray &indicators, SizeArray &tmpSizes, + int bindValues(QVariantList &values, IndicatorArray &indicators, SizeArray &tmpSizes, TempStorage &tmpStorage); - void outValues(QVector &values, IndicatorArray &indicators, + void outValues(QVariantList &values, IndicatorArray &indicators, TempStorage &tmpStorage); inline bool isOutValue(int i) const { Q_Q(const QOCIResult); return q->bindValueType(i) & QSql::Out; } @@ -502,7 +502,7 @@ int QOCIResultPrivate::bindValue(OCIStmt *sql, OCIBind **hbnd, OCIError *err, in return r; } -int QOCIResultPrivate::bindValues(QVector &values, IndicatorArray &indicators, +int QOCIResultPrivate::bindValues(QVariantList &values, IndicatorArray &indicators, SizeArray &tmpSizes, TempStorage &tmpStorage) { int r = OCI_SUCCESS; @@ -551,7 +551,7 @@ static void qOraOutValue(QVariant &value, TempStorage &tmpStorage, OCIEnv *env, } } -void QOCIResultPrivate::outValues(QVector &values, IndicatorArray &indicators, +void QOCIResultPrivate::outValues(QVariantList &values, IndicatorArray &indicators, TempStorage &tmpStorage) { for (int i = 0; i < values.count(); ++i) { @@ -835,12 +835,12 @@ class QOCICols public: QOCICols(int size, QOCIResultPrivate* dp); ~QOCICols(); - int readPiecewise(QVector &values, int index = 0); - int readLOBs(QVector &values, int index = 0); + int readPiecewise(QVariantList &values, int index = 0); + int readLOBs(QVariantList &values, int index = 0); int fieldFromDefine(OCIDefine* d); - void getValues(QVector &v, int index); + void getValues(QVariantList &v, int index); inline int size() { return fieldInf.size(); } - static bool execBatch(QOCIResultPrivate *d, QVector &boundValues, bool arrayBind); + static bool execBatch(QOCIResultPrivate *d, QVariantList &boundValues, bool arrayBind); QSqlRecord rec; @@ -865,7 +865,7 @@ private: void *dataPtr; }; - QVector fieldInf; + QList fieldInf; const QOCIResultPrivate *const d; }; @@ -1116,7 +1116,7 @@ OCILobLocator **QOCICols::createLobLocator(int position, OCIEnv* env) return &lob; } -int QOCICols::readPiecewise(QVector &values, int index) +int QOCICols::readPiecewise(QVariantList &values, int index) { OCIDefine* dfn; ub4 typep; @@ -1328,7 +1328,7 @@ struct QOCIBatchColumn struct QOCIBatchCleanupHandler { - inline QOCIBatchCleanupHandler(QVector &columns) + inline QOCIBatchCleanupHandler(QList &columns) : col(columns) {} ~QOCIBatchCleanupHandler() @@ -1341,10 +1341,10 @@ struct QOCIBatchCleanupHandler } } - QVector &col; + QList &col; }; -bool QOCICols::execBatch(QOCIResultPrivate *d, QVector &boundValues, bool arrayBind) +bool QOCICols::execBatch(QOCIResultPrivate *d, QVariantList &boundValues, bool arrayBind) { int columnCount = boundValues.count(); if (boundValues.isEmpty() || columnCount == 0) @@ -1364,7 +1364,7 @@ bool QOCICols::execBatch(QOCIResultPrivate *d, QVector &boundValues, b : tp); } SizeArray tmpSizes(columnCount); - QVector columns(columnCount); + QList columns(columnCount); QOCIBatchCleanupHandler cleaner(columns); TempStorage tmpStorage; @@ -1612,7 +1612,7 @@ bool QOCICols::execBatch(QOCIResultPrivate *d, QVector &boundValues, b return false; } - // for out parameters we copy data back to value vector + // for out parameters we copy data back to value list for (i = 0; i < columnCount; ++i) { if (!d->isOutValue(i)) @@ -1739,7 +1739,7 @@ int qReadLob(T &buf, const QOCIResultPrivate *d, OCILobLocator *lob) return r; } -int QOCICols::readLOBs(QVector &values, int index) +int QOCICols::readLOBs(QVariantList &values, int index) { OCILobLocator *lob; int r = OCI_SUCCESS; @@ -1778,7 +1778,7 @@ int QOCICols::fieldFromDefine(OCIDefine* d) return -1; } -void QOCICols::getValues(QVector &v, int index) +void QOCICols::getValues(QVariantList &v, int index) { for (int i = 0; i < fieldInf.size(); ++i) { const OraFieldInf &fld = fieldInf.at(i); diff --git a/src/plugins/sqldrivers/odbc/qsql_odbc.cpp b/src/plugins/sqldrivers/odbc/qsql_odbc.cpp index 4081cd1122..03c197053a 100644 --- a/src/plugins/sqldrivers/odbc/qsql_odbc.cpp +++ b/src/plugins/sqldrivers/odbc/qsql_odbc.cpp @@ -44,15 +44,15 @@ #include #endif #include -#include #include +#include +#include #include #include #include #include +#include #include -#include -#include #include #include #include @@ -206,7 +206,7 @@ public: SQLHANDLE hStmt = nullptr; QSqlRecord rInf; - QVector fieldCache; + QVariantList fieldCache; int fieldCacheIdx = 0; int disconnectCount = 0; bool hasSQLFetchScroll = true; @@ -1399,8 +1399,8 @@ bool QODBCResult::exec() if (isSelect()) SQLCloseCursor(d->hStmt); - QVector& values = boundValues(); - QVector tmpStorage(values.count(), QByteArray()); // holds temporary buffers + QVariantList &values = boundValues(); + QByteArrayList tmpStorage(values.count(), QByteArray()); // holds temporary buffers QVarLengthArray indicators(values.count()); memset(indicators.data(), 0, indicators.size() * sizeof(SQLLEN)); diff --git a/src/plugins/sqldrivers/psql/qsql_psql.cpp b/src/plugins/sqldrivers/psql/qsql_psql.cpp index 3424400cc1..b477f701e2 100644 --- a/src/plugins/sqldrivers/psql/qsql_psql.cpp +++ b/src/plugins/sqldrivers/psql/qsql_psql.cpp @@ -848,7 +848,7 @@ void QPSQLResult::virtual_hook(int id, void *data) QSqlResult::virtual_hook(id, data); } -static QString qCreateParamString(const QVector &boundValues, const QSqlDriver *driver) +static QString qCreateParamString(const QList &boundValues, const QSqlDriver *driver) { if (boundValues.isEmpty()) return QString(); diff --git a/src/plugins/sqldrivers/sqlite/qsql_sqlite.cpp b/src/plugins/sqldrivers/sqlite/qsql_sqlite.cpp index e900ccf5ec..f507e44d32 100644 --- a/src/plugins/sqldrivers/sqlite/qsql_sqlite.cpp +++ b/src/plugins/sqldrivers/sqlite/qsql_sqlite.cpp @@ -41,7 +41,8 @@ #include #include -#include +#include +#include #include #include #include @@ -49,8 +50,7 @@ #include #include #include -#include -#include +#include #if QT_CONFIG(regularexpression) #include #include @@ -146,7 +146,7 @@ class QSQLiteDriverPrivate : public QSqlDriverPrivate public: inline QSQLiteDriverPrivate() : QSqlDriverPrivate(QSqlDriver::SQLite) {} sqlite3 *access = nullptr; - QVector results; + QList results; QStringList notificationid; }; @@ -166,7 +166,7 @@ public: sqlite3_stmt *stmt = nullptr; QSqlRecord rInf; - QVector firstRow; + QList firstRow; bool skippedStatus = false; // the status of the fetchNext() that's skipped bool skipRow = false; // skip the next fetchNext()? }; @@ -413,15 +413,15 @@ bool QSQLiteResult::execBatch(bool arrayBind) { Q_UNUSED(arrayBind); Q_D(QSqlResult); - QScopedValueRollback> valuesScope(d->values); - QVector values = d->values; + QScopedValueRollback> valuesScope(d->values); + QList values = d->values; if (values.count() == 0) return false; for (int i = 0; i < values.at(0).toList().count(); ++i) { d->values.clear(); - QScopedValueRollback>> indexesScope(d->indexes); - QHash>::const_iterator it = d->indexes.constBegin(); + QScopedValueRollback>> indexesScope(d->indexes); + auto it = d->indexes.constBegin(); while (it != d->indexes.constEnd()) { bindValue(it.key(), values.at(it.value().first()).toList().at(i), QSql::In); ++it; @@ -435,7 +435,7 @@ bool QSQLiteResult::execBatch(bool arrayBind) bool QSQLiteResult::exec() { Q_D(QSQLiteResult); - QVector values = boundValues(); + QList values = boundValues(); d->skippedStatus = false; d->skipRow = false; @@ -460,7 +460,7 @@ bool QSQLiteResult::exec() // can end up in a case where for virtual tables it returns 0 even though it // has parameters if (paramCount >= 1 && paramCount < values.count()) { - const auto countIndexes = [](int counter, const QVector &indexList) { + const auto countIndexes = [](int counter, const QList &indexList) { return counter + indexList.length(); }; @@ -471,10 +471,10 @@ bool QSQLiteResult::exec() paramCountIsValid = bindParamCount == values.count(); // When using named placeholders, it will reuse the index for duplicated - // placeholders. So we need to ensure the QVector has only one instance of + // placeholders. So we need to ensure the QList has only one instance of // each value as SQLite will do the rest for us. - QVector prunedValues; - QVector handledIndexes; + QList prunedValues; + QList handledIndexes; for (int i = 0, currentIndex = 0; i < values.size(); ++i) { if (handledIndexes.contains(i)) continue; diff --git a/src/plugins/styles/android/qandroidstyle.cpp b/src/plugins/styles/android/qandroidstyle.cpp index 1d0838daec..0a4e4286e0 100644 --- a/src/plugins/styles/android/qandroidstyle.cpp +++ b/src/plugins/styles/android/qandroidstyle.cpp @@ -845,7 +845,7 @@ int QAndroidStyle::Android9PatchDrawable::calculateStretch(int boundsLimit, } void QAndroidStyle::Android9PatchDrawable::extractIntArray(const QVariantList &values, - QVector & array) + QList & array) { for (const QVariant &value : values) array << value.toInt(); diff --git a/src/plugins/styles/android/qandroidstyle_p.h b/src/plugins/styles/android/qandroidstyle_p.h index 6cb30a2f79..5730bdfe2c 100644 --- a/src/plugins/styles/android/qandroidstyle_p.h +++ b/src/plugins/styles/android/qandroidstyle_p.h @@ -89,9 +89,9 @@ public: struct Android9PatchChunk { - QVector xDivs; - QVector yDivs; - QVector colors; + QList xDivs; + QList yDivs; + QList colors; }; struct AndroidItemStateInfo @@ -169,7 +169,7 @@ public: static int calculateStretch(int boundsLimit, int startingPoint, int srcSpace, int numStrechyPixelsRemaining, int numFixedPixelsRemaining); - void extractIntArray(const QVariantList &values, QVector &array); + void extractIntArray(const QVariantList &values, QList &array); private: Android9PatchChunk m_chunkData; }; diff --git a/src/plugins/styles/mac/qmacstyle_mac_p_p.h b/src/plugins/styles/mac/qmacstyle_mac_p_p.h index 274936bd79..6305a0ea1f 100644 --- a/src/plugins/styles/mac/qmacstyle_mac_p_p.h +++ b/src/plugins/styles/mac/qmacstyle_mac_p_p.h @@ -45,12 +45,12 @@ #include #include +#include #include #include #include #include #include -#include #include @@ -291,7 +291,7 @@ public: public: mutable QPointer autoDefaultButton; - static QVector > scrollBars; + static QList > scrollBars; mutable QPointer focusWidget; mutable NSView *backingStoreNSView;