diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2013-11-19 05:32:24 -0800 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2013-11-19 05:32:24 -0800 |
commit | 1a876a85b903cf5fb3196779a7d00a1b32daac87 (patch) | |
tree | 6919a1d64b0c6b964dde3dd7d962186f087c8f15 /qt-ui/preferences.cpp | |
parent | 1a5e94006c5bcdf648ca791d1d9d1d44f1ec1a03 (diff) | |
download | subsurface-1a876a85b903cf5fb3196779a7d00a1b32daac87.tar.gz |
Hook up MOD in the preferences dialog
For some reason this was never connected. Oops.
Fixes #267
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/preferences.cpp')
-rw-r--r-- | qt-ui/preferences.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/qt-ui/preferences.cpp b/qt-ui/preferences.cpp index 5973db65d..8c3982eb5 100644 --- a/qt-ui/preferences.cpp +++ b/qt-ui/preferences.cpp @@ -38,6 +38,9 @@ void PreferencesDialog::setUiFromPrefs() ui.po2Threshold->setValue(prefs.pp_graphs.po2_threshold); ui.pn2Threshold->setValue(prefs.pp_graphs.pn2_threshold); ui.ead_end_eadd->setChecked(prefs.ead); + ui.mod->setChecked(prefs.mod); + ui.maxppo2->setEnabled(ui.mod->isChecked()); + ui.maxppo2->setValue(prefs.mod_ppO2); ui.dc_reported_ceiling->setChecked(prefs.profile_dc_ceiling); ui.red_ceiling->setEnabled(ui.dc_reported_ceiling->isChecked()); ui.red_ceiling->setChecked(prefs.profile_red_ceiling); @@ -101,6 +104,8 @@ void PreferencesDialog::setPrefsFromUi() prefs.pp_graphs.po2_threshold = ui.po2Threshold->value(); prefs.pp_graphs.pn2_threshold = ui.pn2Threshold->value(); SP(ead, ui.ead_end_eadd); + SP(mod, ui.mod); + prefs.mod_ppO2 = ui.maxppo2->value(); SP(profile_dc_ceiling, ui.dc_reported_ceiling); SP(profile_red_ceiling, ui.red_ceiling); SP(profile_calc_ceiling, ui.calculated_ceiling); @@ -139,6 +144,8 @@ void PreferencesDialog::syncSettings() s.setValue("po2threshold", ui.po2Threshold->value()); s.setValue("pn2threshold", ui.pn2Threshold->value()); SB("ead", ui.ead_end_eadd); + SB("mod", ui.mod); + s.setValue("modppo2", ui.maxppo2->value()); SB("dcceiling", ui.dc_reported_ceiling); SB("redceiling", ui.red_ceiling); SB("calcceiling", ui.calculated_ceiling); |