mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Don't use QList if sizeof(item) > void*.
QList is optimized for storing pointer-sized items, thus a QVector is the better choice for everything else. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
5e446fd258
commit
1a933e7e19
4 changed files with 10 additions and 9 deletions
|
|
@ -43,7 +43,7 @@ public:
|
|||
int size();
|
||||
struct diveplan getDiveplan();
|
||||
QStringList &getGasList();
|
||||
QList<QPair<int, int> > collectGases(dive *d);
|
||||
QVector<QPair<int, int> > collectGases(dive *d);
|
||||
|
||||
public slots:
|
||||
int addStop(int millimeters = 0, int seconds = 0, int o2 = 0, int he = 0, int ccpoint = 0 );
|
||||
|
|
@ -76,7 +76,7 @@ private:
|
|||
void deleteTemporaryPlan(struct divedatapoint *dp);
|
||||
QVector<sample> backupSamples; // For editing added dives.
|
||||
struct dive *stagingDive;
|
||||
QList<QPair<int, int> > oldGases;
|
||||
QVector<QPair<int, int> > oldGases;
|
||||
};
|
||||
|
||||
class Button : public QObject, public QGraphicsRectItem {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue