subsurface/qt-models
Berthold Stoeger d061a54e3d planner: fix gas selection
The lambda that created the list of gases took a copy not a
reference of the planned dive. Of course, that never had its
gases updated. Ultimately this would crash, because this sent
an index of "-1" on change.

Fix by
1) Using a reference to the dive, not the copy
2) Catch an invalid "-1" index (by Michael Keller <github@ike.ch>)

Fixes #4188

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2024-05-12 13:23:21 +02:00
..
cleanertablemodel.cpp
cleanertablemodel.h
CMakeLists.txt
completionmodels.cpp core: use C++-primitives for g_tag_list 2024-04-23 07:47:11 +07:00
completionmodels.h
cylindermodel.cpp planner: fix gas selection 2024-05-12 13:23:21 +02:00
cylindermodel.h Equipment: Include Unused Tanks in Merge if Preference is Enabled. 2023-07-25 11:19:03 +12:00
divecomputerextradatamodel.cpp
divecomputerextradatamodel.h
diveimportedmodel.cpp
diveimportedmodel.h
divelocationmodel.cpp core: replace SSRF_INFO macro by report_info() 2024-03-12 10:31:07 -04:00
divelocationmodel.h
divepicturemodel.cpp cleanup: more Coverity silencing 2024-01-17 14:23:19 -08:00
divepicturemodel.h
diveplannermodel.cpp planner: fix gas selection 2024-05-12 13:23:21 +02:00
diveplannermodel.h Mobile: Fix Gradient Factor Preference Setting. 2024-01-27 20:55:32 -08:00
divesiteimportmodel.cpp Desktop: Fix build for Qt6 2023-04-26 07:14:07 +02:00
divesiteimportmodel.h
divesummarymodel.cpp
divesummarymodel.h
divetripmodel.cpp core: use C++-primitives for g_tag_list 2024-04-23 07:47:11 +07:00
divetripmodel.h Add dive mode as possible column 2023-10-13 08:32:27 +13:00
filterconstraintmodel.cpp
filterconstraintmodel.h
filtermodels.cpp
filtermodels.h selection: move current dc logic to profile widget 2023-04-16 20:23:59 +02:00
filterpresetmodel.cpp core: port filterpreset.cpp to std::string 2024-03-10 11:01:42 +13:00
filterpresetmodel.h
maplocationmodel.cpp cleanup: replace Q_FOREACH and foreach by range base for 2024-03-24 17:53:19 +01:00
maplocationmodel.h
messagehandlermodel.cpp core: replace SSRF_INFO macro by report_info() 2024-03-12 10:31:07 -04:00
messagehandlermodel.h
mobilelistmodel.cpp
mobilelistmodel.h
models.cpp desktop: unglobalize ComboBox-models 2024-04-16 08:56:49 +12:00
models.h desktop: unglobalize ComboBox-models 2024-04-16 08:56:49 +12:00
tankinfomodel.cpp desktop: unglobalize ComboBox-models 2024-04-16 08:56:49 +12:00
tankinfomodel.h desktop: unglobalize ComboBox-models 2024-04-16 08:56:49 +12:00
treemodel.cpp
treemodel.h
weightmodel.cpp desktop: unglobalize ComboBox-models 2024-04-16 08:56:49 +12:00
weightmodel.h
weightsysteminfomodel.cpp desktop: unglobalize ComboBox-models 2024-04-16 08:56:49 +12:00
weightsysteminfomodel.h desktop: unglobalize ComboBox-models 2024-04-16 08:56:49 +12:00
yearlystatisticsmodel.cpp Desktop: Fix build for Qt6 2023-04-26 07:14:07 +02:00
yearlystatisticsmodel.h