subsurface/qt-models
Berthold Stoeger 687f65bf77 planner: avoid out-of-bound access when initializing the planner
For dives with many samples (i.e. logged dives), samples are merged.

I'm not exactly sure how this code works, but it does an
out-of-bound access in some cases. Avoid that by a simple
check.

That said, I wonder if this downsampling is a good idea. A user
reports that they have logged dives marked as manually added dives.
We now load them into edit mode, which means a significant loss
of information.

Perhaps we should consider dives with more than 100 samples as
non-manual dives?

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2023-01-19 14:26:00 +01:00
..
cleanertablemodel.cpp Cleanup: return directly from data() methods 2019-06-19 13:11:10 -07:00
cleanertablemodel.h CylindersModel: fold CHANGED() macro into setData() 2020-04-07 00:13:35 +02:00
CMakeLists.txt build-system: make map support its own thing 2022-04-18 07:24:38 +02:00
completionmodels.cpp core: replace dive master by dive guide 2022-02-15 09:35:43 -08:00
completionmodels.h core: replace dive master by dive guide 2022-02-15 09:35:43 -08:00
cylindermodel.cpp Use combo box for moving sensor data 2022-09-03 13:38:34 -07:00
cylindermodel.h Allow editing sensors through equipment tab 2022-03-12 11:24:50 -08:00
divecomputerextradatamodel.cpp cleanup: split out divecomputer functions from dive.c 2020-10-25 13:59:52 -07:00
divecomputerextradatamodel.h cleanup: generalize ExtraDataModel to display data of any dc 2020-05-07 08:46:15 -07:00
diveimportedmodel.cpp downloader: save downloaded dives 2020-12-03 13:26:55 -08:00
diveimportedmodel.h downloader: wait for download thread 2020-12-03 13:26:55 -08:00
divelocationmodel.cpp desktop: fix saving of column-widths of device and site tables 2020-11-07 11:37:51 -08:00
divelocationmodel.h desktop: fix saving of column-widths of device and site tables 2020-11-07 11:37:51 -08:00
divepicturemodel.cpp cleanup: implement index_of() and index_of_if() generics 2022-10-31 19:35:15 +01:00
divepicturemodel.h undo: make picture (media) deletion undoable 2020-05-06 13:58:09 -07:00
diveplannermodel.cpp planner: avoid out-of-bound access when initializing the planner 2023-01-19 14:26:00 +01:00
diveplannermodel.h undo: more fine-grained undo of profile editing 2022-03-12 18:32:22 +01:00
divesiteimportmodel.cpp Create DivesiteImportDialog to select sites to import 2019-05-06 10:48:44 +02:00
divesiteimportmodel.h Create DivesiteImportDialog to select sites to import 2019-05-06 10:48:44 +02:00
divesummarymodel.cpp Ignore invalid dives in subsurface-mobile dive summary 2021-10-11 20:20:20 +03:00
divesummarymodel.h mobile/summary: add section headers 2020-02-08 10:29:36 -08:00
divetripmodel.cpp cleanup: implement index_of() and index_of_if() generics 2022-10-31 19:35:15 +01:00
divetripmodel.h model: unify tooltip formating in DiveTripModel 2022-02-15 09:37:16 -08:00
filterconstraintmodel.cpp filter: add filter constraint model 2020-09-29 16:13:03 -07:00
filterconstraintmodel.h filter: add filter constraint model 2020-09-29 16:13:03 -07:00
filtermodels.cpp core: fold display.h into profile.h 2022-03-13 15:07:33 -07:00
filtermodels.h cleanup: invert control-flow when resetting the core structures 2020-05-07 08:43:27 -07:00
filterpresetmodel.cpp filter: connect DiveListNotifier signals to filter preset model 2020-09-29 16:13:03 -07:00
filterpresetmodel.h filter: connect DiveListNotifier signals to filter preset model 2020-09-29 16:13:03 -07:00
maplocationmodel.cpp cleanup: fix compiler warnings in recently edited files. 2022-08-21 18:53:35 -07:00
maplocationmodel.h Cleanup: lower-case filenames in core/subsurface-qt/ 2020-02-04 02:16:46 +01:00
messagehandlermodel.cpp cleanup: replace QRegExp with QRegularExpression 2021-10-27 12:36:49 -07:00
messagehandlermodel.h Cleanup: reinstate override modifiers 2018-09-29 15:23:25 -07:00
mobilelistmodel.cpp core: replace dive master by dive guide 2022-02-15 09:35:43 -08:00
mobilelistmodel.h core: replace dive master by dive guide 2022-02-15 09:35:43 -08:00
models.cpp profile: pass dive to DiveHandler 2021-01-10 15:57:39 -08:00
models.h Cleanup: remove includes from qt-models/models.h 2019-07-18 05:42:55 -07:00
tankinfomodel.cpp core: keep tank infos in a dynamic table 2020-12-13 11:49:59 -08:00
tankinfomodel.h core: keep tank infos in a dynamic table 2020-12-13 11:49:59 -08:00
treemodel.cpp
treemodel.h Cleanup: reinstate override modifiers 2018-09-29 15:23:25 -07:00
weightmodel.cpp desktop: refine auto-fill of weights 2020-09-12 10:36:36 -07:00
weightmodel.h cleanup: replace to "dive.h" includes by more specific includes 2020-05-15 14:19:21 -07:00
weightsysteminfomodel.cpp cleanup: invert control-flow when resetting the core structures 2020-05-07 08:43:27 -07:00
weightsysteminfomodel.h Cleanup: implement proper Qt-model semantics in WeightInfoModel 2019-04-29 13:06:39 -07:00
yearlystatisticsmodel.cpp cleanup: move minute formating to format-string.cpp 2022-09-03 13:49:02 -07:00
yearlystatisticsmodel.h Show average max depth in yearly statistics 2018-12-17 12:18:26 +01:00