diff options
Diffstat (limited to 'qt-ui')
-rw-r--r-- | qt-ui/diveplanner.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp index 65a358489..6bc67ada0 100644 --- a/qt-ui/diveplanner.cpp +++ b/qt-ui/diveplanner.cpp @@ -1303,6 +1303,11 @@ void DivePlannerPointsModel::tanksUpdated() // either nothing relevant changed, or exactly ONE gasmix changed for (int i = 0; i < gases.length(); i++) { if (gases.at(i) != oldGases.at(i)) { + if (oldGases.count(oldGases.at(i)) > 1) { + // we had this gas more than once, so don't + // change segments that used this gas as it still exists + break; + } for (int j = 0; j < rowCount(); j++) { divedatapoint& p = divepoints[j]; int o2 = oldGases.at(i).first; |