changeset 211:85bd5fea5e08 cv-persistent

New feature: do not show sensor customviews when no sensors attached There are mCCR divers, that use a DC just for deco and time purposes and not for O2 tracking and logging. These divers typically use the existing Fixed SP mode, and have 0 active 02 sensors. This commit simply suppresses display of the 2 customviews in case there are no active sensors defined. Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
author Jan Mulder <jlmulder@xs4all.nl>
date Tue, 26 Mar 2019 16:02:22 +0100
parents b2a9e9b02df0
children c878a08dcf86
files Discovery/Src/t7.c
diffstat 1 files changed, 7 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/Discovery/Src/t7.c	Tue Mar 26 13:00:15 2019 +0100
+++ b/Discovery/Src/t7.c	Tue Mar 26 16:02:22 2019 +0100
@@ -1523,6 +1523,13 @@
                     break;
                 }
             }
+
+            if ((*pViews == CVIEW_sensors || *pViews == CVIEW_sensors_mV) &&
+            	stateUsed->diveSettings.ppo2sensors_deactivated)
+            {
+            	cv_disabled = 1;
+            }
+
             if(cv_disabled)
             {
                 if(*pViews < CVIEW_END)