Mercurial > public > ostc4
comparison Discovery/Src/t3.c @ 541:6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
In previous version the ostc tried to applied the t7 default view selection to t3 view. As t3 has different views than t3, a new selection menu has been added to the custom view menu enabling the selection of the big font default view.
In parallel the auto return function has been adapted to use the new parameter.
author | Ideenmodellierer |
---|---|
date | Sat, 10 Oct 2020 18:34:10 +0200 |
parents | d784f281833a |
children | 6960df7ddb09 |
comparison
equal
deleted
inserted
replaced
540:ffd01ead2c80 | 541:6fbf7cd391cb |
---|---|
70 CVIEW_T3_TTS, | 70 CVIEW_T3_TTS, |
71 CVIEW_T3_ppO2andGas, | 71 CVIEW_T3_ppO2andGas, |
72 CVIEW_T3_GasList, | 72 CVIEW_T3_GasList, |
73 CVIEW_T3_Navigation, | 73 CVIEW_T3_Navigation, |
74 CVIEW_T3_DepthData, | 74 CVIEW_T3_DepthData, |
75 CVIEW_noneOrDebug, | |
75 CVIEW_T3_END | 76 CVIEW_T3_END |
76 }; | 77 }; |
77 | 78 |
78 /* Private function prototypes -----------------------------------------------*/ | 79 /* Private function prototypes -----------------------------------------------*/ |
79 void t3_refresh_divemode(void); | 80 void t3_refresh_divemode(void); |
177 } | 178 } |
178 | 179 |
179 if(status.base != BaseHome) | 180 if(status.base != BaseHome) |
180 return; | 181 return; |
181 | 182 |
182 if(last_mode != MODE_DIVE) /* Select customview */ | 183 if(last_mode != MODE_DIVE) /* Select custom view */ |
183 { | 184 { |
184 if((settingsGetPointer()->tX_customViewTimeout == 0) && (settingsGetPointer()->showDebugInfo)) | 185 if((settingsGetPointer()->tX_customViewTimeout == 0) && (settingsGetPointer()->showDebugInfo)) |
185 { | 186 { |
186 t3_selection_customview = CVIEW_noneOrDebug; | 187 t3_selection_customview = CVIEW_noneOrDebug; |
187 } | 188 } |
188 else | 189 else |
189 { | 190 { |
190 t3_selection_customview = settingsGetPointer()->tX_customViewPrimary; | 191 t3_selection_customview = settingsGetPointer()->tX_customViewPrimaryBF; |
191 } | 192 } |
192 t3_change_customview(ACTION_END); | 193 t3_change_customview(ACTION_END); |
193 } | 194 } |
194 t3screen.FBStartAdress = getFrame(24); | 195 t3screen.FBStartAdress = getFrame(24); |
195 t3_refresh_divemode(); | 196 t3_refresh_divemode(); |
196 GFX_SetFramesTopBottom(t3screen.FBStartAdress, 0,480); | 197 GFX_SetFramesTopBottom(t3screen.FBStartAdress, 0,480); |
197 releaseAllFramesExcept(24,t3screen.FBStartAdress); | 198 releaseAllFramesExcept(24,t3screen.FBStartAdress); |
198 last_mode = stateUsed->mode; | 199 last_mode = stateUsed->mode; |
199 } | 200 } |
200 | 201 |
202 void t3_set_customview_to_primary(void) | |
203 { | |
204 if(stateUsed->mode == MODE_DIVE) | |
205 { | |
206 t3_selection_customview = settingsGetPointer()->tX_customViewPrimaryBF; | |
207 } | |
208 } | |
201 | 209 |
202 /* Private functions ---------------------------------------------------------*/ | 210 /* Private functions ---------------------------------------------------------*/ |
203 | 211 |
204 float t3_basics_lines_depth_and_divetime(GFX_DrawCfgScreen *tXscreen, GFX_DrawCfgWindow* tXl1, GFX_DrawCfgWindow* tXr1, uint8_t mode) | 212 float t3_basics_lines_depth_and_divetime(GFX_DrawCfgScreen *tXscreen, GFX_DrawCfgWindow* tXl1, GFX_DrawCfgWindow* tXr1, uint8_t mode) |
205 { | 213 { |