summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/preferences
diff options
context:
space:
mode:
authorGravatar Rick Walsh <rickmwalsh@gmail.com>2016-09-24 18:02:08 +1000
committerGravatar Dirk Hohndel <dirk@hohndel.org>2016-09-24 08:30:11 -0700
commit7e09a6c7bcb135d65b3e48f2aee44791dd080443 (patch)
treed1a3620e9084cf335f711fdf0b4ca397914117a3 /desktop-widgets/preferences
parent7b891904e77364719471098a7bdf4eacc589807c (diff)
downloadsubsurface-7e09a6c7bcb135d65b3e48f2aee44791dd080443.tar.gz
Separate VPM-B conservatism preference for planner and profile
Separate the VPM-B conservatism preference into diveplan.vpmb_conservatism for planning dives and prefs.vpmb_conservatism for profile ceiling display of saved dives. Signed-off-by: Rick Walsh <rickmwalsh@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'desktop-widgets/preferences')
-rw-r--r--desktop-widgets/preferences/preferences_graph.cpp2
-rw-r--r--desktop-widgets/preferences/preferences_graph.ui36
2 files changed, 30 insertions, 8 deletions
diff --git a/desktop-widgets/preferences/preferences_graph.cpp b/desktop-widgets/preferences/preferences_graph.cpp
index 36951ef22..c13915e37 100644
--- a/desktop-widgets/preferences/preferences_graph.cpp
+++ b/desktop-widgets/preferences/preferences_graph.cpp
@@ -27,6 +27,7 @@ void PreferencesGraph::refreshSettings()
ui->gflow->setValue(prefs.gflow);
ui->gfhigh->setValue(prefs.gfhigh);
+ ui->vpmb_conservatism->setValue(prefs.vpmb_conservatism);
ui->gf_low_at_maxdepth->setChecked(prefs.gf_low_at_maxdepth);
ui->show_ccr_setpoint->setChecked(prefs.show_ccr_setpoint);
ui->show_ccr_sensors->setChecked(prefs.show_ccr_sensors);
@@ -55,6 +56,7 @@ void PreferencesGraph::syncSettings()
tech->setRedceiling(ui->red_ceiling->isChecked());
tech->setGflow(ui->gflow->value());
tech->setGfhigh(ui->gfhigh->value());
+ tech->setVpmbConservatism(ui->vpmb_conservatism->value());
tech->setGfLowAtMaxDepth(ui->gf_low_at_maxdepth->isChecked());
tech->setShowCCRSetpoint(ui->show_ccr_setpoint->isChecked());
tech->setShowCCRSensors(ui->show_ccr_sensors->isChecked());
diff --git a/desktop-widgets/preferences/preferences_graph.ui b/desktop-widgets/preferences/preferences_graph.ui
index e0d0cda54..b8d6a4656 100644
--- a/desktop-widgets/preferences/preferences_graph.ui
+++ b/desktop-widgets/preferences/preferences_graph.ui
@@ -168,13 +168,33 @@
</widget>
</item>
<item row="2" column="0">
+ <widget class="QLabel" name="label_21">
+ <property name="text">
+ <string>VPM-B Conservatism</string>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="1">
+ <widget class="QSpinBox" name="vpmb_conservatism">
+ <property name="prefix">
+ <string>+</string>
+ </property>
+ <property name="minimum">
+ <number>0</number>
+ </property>
+ <property name="maximum">
+ <number>4</number>
+ </property>
+ </widget>
+ </item>
+ <item row="3" column="0">
<widget class="QLabel" name="label_26">
<property name="text">
<string>Default CCR set-point for dive planning</string>
</property>
</widget>
</item>
- <item row="2" column="1">
+ <item row="3" column="1">
<widget class="QDoubleSpinBox" name="defaultSetpoint">
<property name="suffix">
<string>bar</string>
@@ -190,14 +210,14 @@
</property>
</widget>
</item>
- <item row="3" column="0">
+ <item row="4" column="0">
<widget class="QLabel" name="pSCR">
<property name="text">
<string>pSCR O₂ metabolism rate</string>
</property>
</widget>
</item>
- <item row="3" column="1">
+ <item row="4" column="1">
<widget class="QDoubleSpinBox" name="psro2rate">
<property name="suffix">
<string>ℓ/min</string>
@@ -207,14 +227,14 @@
</property>
</widget>
</item>
- <item row="4" column="0">
+ <item row="5" column="0">
<widget class="QLabel" name="label_28">
<property name="text">
<string>pSCR ratio</string>
</property>
</widget>
</item>
- <item row="4" column="1">
+ <item row="5" column="1">
<widget class="QSpinBox" name="pscrfactor">
<property name="suffix">
<string/>
@@ -224,21 +244,21 @@
</property>
</widget>
</item>
- <item row="5" column="0" colspan="2">
+ <item row="6" column="0" colspan="2">
<widget class="QCheckBox" name="gf_low_at_maxdepth">
<property name="text">
<string>GFLow at max depth</string>
</property>
</widget>
</item>
- <item row="6" column="0" colspan="2">
+ <item row="7" column="0" colspan="2">
<widget class="QCheckBox" name="show_ccr_setpoint">
<property name="text">
<string>CCR: show setpoints when viewing pO₂</string>
</property>
</widget>
</item>
- <item row="7" column="0" colspan="2">
+ <item row="8" column="0" colspan="2">
<widget class="QCheckBox" name="show_ccr_sensors">
<property name="text">
<string>CCR: show individual O₂ sensor values when viewing pO₂</string>