diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2020-04-11 18:50:53 +0200 |
---|---|---|
committer | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2020-04-11 18:50:53 +0200 |
commit | abf9650280819a5e1f5b15f6d21fa297f986f42e (patch) | |
tree | 947bac6c813ea6aec4688085fc97cd08812407db /qt-models/divepicturemodel.cpp | |
parent | 1c420dc64a800fc2ebf0b675fc7edabed6a30d31 (diff) | |
download | subsurface-abf9650280819a5e1f5b15f6d21fa297f986f42e.tar.gz |
cleanup: don't keep pointer-to-picture in PictureEntry
The DivePictureModel kept a pointer to picture for each entry.
Firstly, this is dangerous from a data-consistency point of view.
Secondly, the entry wasn't even used anywhere. Remove it.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'qt-models/divepicturemodel.cpp')
-rw-r--r-- | qt-models/divepicturemodel.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/qt-models/divepicturemodel.cpp b/qt-models/divepicturemodel.cpp index ab54c2dc1..705f23592 100644 --- a/qt-models/divepicturemodel.cpp +++ b/qt-models/divepicturemodel.cpp @@ -59,7 +59,7 @@ void DivePictureModel::updateDivePictures() if (dive->selected) { int first = pictures.count(); FOR_EACH_PICTURE(dive) - pictures.push_back({ dive->id, picture, picture->filename, {}, picture->offset.seconds, {.seconds = 0}}); + pictures.push_back({ dive->id, picture->filename, {}, picture->offset.seconds, {.seconds = 0}}); // Sort pictures of this dive by offset. // Thus, the list will be sorted by (diveId, offset). |