Mercurial > public > ostc4
comparison Discovery/Src/t7.c @ 1055:de56b8d75504 Icon_Integration
LLC data: improve switching:
In the previous version an inactive view could be shown in case two inactive views are located after each other. To avoid this scenario the views are now switched until an active view is available.
The scrubber time is now only shown in rebreather mode.
| author | Ideenmodellierer |
|---|---|
| date | Sat, 03 Jan 2026 20:40:11 +0100 |
| parents | 88b6ab90c55a |
| children |
comparison
equal
deleted
inserted
replaced
| 1054:8fe6676f28c9 | 1055:de56b8d75504 |
|---|---|
| 3199 selection_custom_field = settingsGetPointer()->tX_userselectedLeftLowerCornerPrimary; | 3199 selection_custom_field = settingsGetPointer()->tX_userselectedLeftLowerCornerPrimary; |
| 3200 } | 3200 } |
| 3201 | 3201 |
| 3202 void t7_change_field(void) | 3202 void t7_change_field(void) |
| 3203 { | 3203 { |
| 3204 SSettings *settings = settingsGetPointer(); | |
| 3204 selection_custom_field++; | 3205 selection_custom_field++; |
| 3205 | 3206 |
| 3206 if((stateUsed->diveSettings.deco_type.ub.standard == VPM_MODE) && ((selection_custom_field == LLC_GF) || (selection_custom_field == LCC_GF_SURF))) /* no GF if in VPM mode */ | 3207 uint8_t checkAgain = 0; |
| 3207 { | 3208 |
| 3208 selection_custom_field++; | 3209 do |
| 3209 } | 3210 { |
| 3210 SSettings *settings = settingsGetPointer(); | 3211 checkAgain = 0; |
| 3211 if (selection_custom_field == LLC_ScrubberTime && !isScrubberTimerEnabled(settings)) { | 3212 if((stateUsed->diveSettings.deco_type.ub.standard == VPM_MODE) && ((selection_custom_field == LLC_GF) || (selection_custom_field == LCC_GF_SURF))) /* no GF if in VPM mode */ |
| 3212 selection_custom_field++; | 3213 { |
| 3213 } | 3214 selection_custom_field++; |
| 3215 checkAgain = 1; | |
| 3216 } | |
| 3217 | |
| 3218 if ((selection_custom_field == LLC_ScrubberTime) && ((!isScrubberTimerEnabled(settings)) || (!isLoopMode(stateUsed->diveSettings.diveMode)))) | |
| 3219 { | |
| 3220 selection_custom_field++; | |
| 3221 checkAgain = 1; | |
| 3222 } | |
| 3214 #ifdef ENABLE_PSCR_MODE | 3223 #ifdef ENABLE_PSCR_MODE |
| 3215 if((selection_custom_field == LCC_SimPpo2) && (settings->dive_mode != DIVEMODE_PSCR)) | 3224 if((selection_custom_field == LCC_SimPpo2) && (settings->dive_mode != DIVEMODE_PSCR)) |
| 3216 { | 3225 { |
| 3217 selection_custom_field++; | 3226 selection_custom_field++; |
| 3218 } | 3227 checkAgain = 1; |
| 3228 } | |
| 3219 #endif | 3229 #endif |
| 3220 #ifdef ENABLE_CO2_SUPPORT | 3230 #ifdef ENABLE_CO2_SUPPORT |
| 3221 if((selection_custom_field == LCC_CO2) && (settings->co2_sensor_active == 0)) | 3231 if((selection_custom_field == LCC_CO2) && (settings->co2_sensor_active == 0)) |
| 3222 { | 3232 { |
| 3223 selection_custom_field++; | 3233 selection_custom_field++; |
| 3224 } | 3234 checkAgain = 1; |
| 3225 | 3235 } |
| 3226 #endif | 3236 #endif |
| 3227 | 3237 if(selection_custom_field >= LLC_END) |
| 3228 if(selection_custom_field >= LLC_END) | 3238 { |
| 3229 { | 3239 selection_custom_field = LLC_Empty; |
| 3230 selection_custom_field = LLC_Empty; | 3240 } |
| 3231 } | 3241 } while (checkAgain); |
| 3232 } | 3242 } |
| 3233 | 3243 |
| 3234 | 3244 |
| 3235 void t7_refresh_divemode_userselected_left_lower_corner(void) | 3245 void t7_refresh_divemode_userselected_left_lower_corner(void) |
| 3236 { | 3246 { |
