mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
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>
This commit is contained in:
parent
6b4e830670
commit
c0bca3ad04
2 changed files with 19 additions and 14 deletions
|
@ -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
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue