summaryrefslogtreecommitdiffstats
path: root/qt-models/divepicturemodel.h
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2018-04-11 06:56:46 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-05-13 13:52:35 -0700
commitc0bca3ad04762a7178bda37be4c2ed87ae7e5f4e (patch)
tree916494e45f8818b4075043a61bd55e56596c2493 /qt-models/divepicturemodel.h
parent6b4e830670d2e49b258f30f7083372318a2bcf36 (diff)
downloadsubsurface-c0bca3ad04762a7178bda37be4c2ed87ae7e5f4e.tar.gz
Dive pictures: Scale thumbnails on demand
To potentially conserve memory, don't keep copies of scaled thumbnails. Scale the thumbnails on demand. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'qt-models/divepicturemodel.h')
-rw-r--r--qt-models/divepicturemodel.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/qt-models/divepicturemodel.h b/qt-models/divepicturemodel.h
index 74f92f449..443be4a0e 100644
--- a/qt-models/divepicturemodel.h
+++ b/qt-models/divepicturemodel.h
@@ -10,7 +10,6 @@ struct PictureEntry {
struct picture *picture;
QString filename;
QImage image;
- QImage imageProfile; // For the profile widget keep a copy of a constant sized image
int offsetSeconds;
};
@@ -31,7 +30,10 @@ private:
DivePictureModel();
QList<PictureEntry> pictures;
double zoomLevel; // -1.0: minimum, 0.0: standard, 1.0: maximum
+ int defaultSize;
+ int size;
void updateThumbnails();
+ void updateZoom();
};
#endif