summaryrefslogtreecommitdiffstats
path: root/qt-ui/profile/profilewidget2.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qt-ui/profile/profilewidget2.cpp')
-rw-r--r--qt-ui/profile/profilewidget2.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/qt-ui/profile/profilewidget2.cpp b/qt-ui/profile/profilewidget2.cpp
index 66ef84ac4..36b9c6468 100644
--- a/qt-ui/profile/profilewidget2.cpp
+++ b/qt-ui/profile/profilewidget2.cpp
@@ -1391,6 +1391,9 @@ void ProfileWidget2::changeGas()
struct gasmix gasmix;
int seconds = timeAxis->valueAt(scenePos);
+ // no gas changes before the dive starts
+ seconds = seconds > 0 ?: 0;
+
if (seconds == 0) {
bool eventRemoved = false;
struct event *gasChangeEvent = current_dc->events;