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/QOpenGLShaderProgram>
|
||||||
#include <QtGui/private/qinputdevicemanager_p.h>
|
#include <QtGui/private/qinputdevicemanager_p.h>
|
||||||
|
|
||||||
|
#include <QtCore/qvector.h>
|
||||||
|
|
||||||
QT_BEGIN_NAMESPACE
|
QT_BEGIN_NAMESPACE
|
||||||
|
|
||||||
class QOpenGLShaderProgram;
|
class QOpenGLShaderProgram;
|
||||||
@ -143,7 +145,7 @@ private:
|
|||||||
int cursorsPerRow;
|
int cursorsPerRow;
|
||||||
int width, height; // width and height of the atlas
|
int width, height; // width and height of the atlas
|
||||||
int cursorWidth, cursorHeight; // width and height of cursors inside 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
|
QImage image; // valid until it's uploaded
|
||||||
} m_cursorAtlas;
|
} m_cursorAtlas;
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@
|
|||||||
#define QEGLFSKMSGBMCURSOR_H
|
#define QEGLFSKMSGBMCURSOR_H
|
||||||
|
|
||||||
#include <qpa/qplatformcursor.h>
|
#include <qpa/qplatformcursor.h>
|
||||||
#include <QtCore/QList>
|
#include <QtCore/QVector>
|
||||||
#include <QtGui/QImage>
|
#include <QtGui/QImage>
|
||||||
#include <QtGui/private/qinputdevicemanager_p.h>
|
#include <QtGui/private/qinputdevicemanager_p.h>
|
||||||
|
|
||||||
@ -110,7 +110,7 @@ private:
|
|||||||
int cursorsPerRow;
|
int cursorsPerRow;
|
||||||
int width, height; // width and height of the atlas
|
int width, height; // width and height of the atlas
|
||||||
int cursorWidth, cursorHeight; // width and height of cursors inside the atlas
|
int cursorWidth, cursorHeight; // width and height of cursors inside the atlas
|
||||||
QList<QPoint> hotSpots;
|
QVector<QPoint> hotSpots;
|
||||||
QImage image;
|
QImage image;
|
||||||
} m_cursorAtlas;
|
} m_cursorAtlas;
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user