Eliminate the last QList<QPoint> in QtBase production code
QList<QPoint> is horribly inefficient™ (on 32-bit platforms). Fix by using a QVector instead. Change-Id: Id85cb71404f329049c3e9997e51113035569e1b4 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
This commit is contained in:
parent
319c478603
commit
6eaa1d07e1
@ -59,6 +59,8 @@
|
||||
#include <QtGui/QOpenGLShaderProgram>
|
||||
#include <QtGui/private/qinputdevicemanager_p.h>
|
||||
|
||||
#include <QtCore/qvector.h>
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QOpenGLShaderProgram;
|
||||
@ -143,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
|
||||
QList<QPoint> hotSpots;
|
||||
QVector<QPoint> hotSpots;
|
||||
QImage image; // valid until it's uploaded
|
||||
} m_cursorAtlas;
|
||||
|
||||
|
@ -41,7 +41,7 @@
|
||||
#define QEGLFSKMSGBMCURSOR_H
|
||||
|
||||
#include <qpa/qplatformcursor.h>
|
||||
#include <QtCore/QList>
|
||||
#include <QtCore/QVector>
|
||||
#include <QtGui/QImage>
|
||||
#include <QtGui/private/qinputdevicemanager_p.h>
|
||||
|
||||
@ -110,7 +110,7 @@ private:
|
||||
int cursorsPerRow;
|
||||
int width, height; // width and height of the atlas
|
||||
int cursorWidth, cursorHeight; // width and height of cursors inside the atlas
|
||||
QList<QPoint> hotSpots;
|
||||
QVector<QPoint> hotSpots;
|
||||
QImage image;
|
||||
} m_cursorAtlas;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user