# HG changeset patch # User Ideenmodellierer # Date 1598290993 -7200 # Node ID cf06c12c06d1ff285ab515bcee7e2a5b5386b99a # Parent 2ffee0811ad9fbab4f36856e36e2a24c77272cdd Bugfix display of disabled screen. It is possible to select a screen as default which is in parallel disabled in the selection view. To avoid this the enable / disable state is not also checked when entering dive mode. The check function was depending on an ACTION. The functionality has been changed to allow the function call without ACTION. diff -r 2ffee0811ad9 -r cf06c12c06d1 Discovery/Src/t7.c --- a/Discovery/Src/t7.c Mon Aug 24 19:39:28 2020 +0200 +++ b/Discovery/Src/t7.c Mon Aug 24 19:43:13 2020 +0200 @@ -575,6 +575,7 @@ else selection_customview = settingsGetPointer()->tX_customViewPrimary; + t7_change_customview(ACTION_END); InitMotionDetection(); } @@ -1582,53 +1583,38 @@ pLastView = pViews; pViews = pCurView; - if((action == ACTION_BUTTON_ENTER) || (action == ACTION_PITCH_POS)) - { - if(*pViews < CVIEW_END) - pViews++; - - if(*pViews == CVIEW_END) - { - pViews = pStartView; - } - } - else - { - if(pViews == pStartView) - { - pViews = pLastView - 1; - } - else - { - pViews--; - } - } - do { - cv_disabled = t7_customview_disabled(*pViews); - if(cv_disabled) /* view is disabled => jump to next view */ - { - if((action == ACTION_BUTTON_ENTER) || (action == ACTION_PITCH_POS)) - { - pViews++; - if(*pViews == CVIEW_END) + switch(action) + { + case ACTION_BUTTON_ENTER: + case ACTION_PITCH_POS: + if(*pViews != CVIEW_T3_END) + pViews++; + if(*pViews == CVIEW_T3_END) { pViews = pStartView; } - } - else - { - if(pViews == pStartView) - { - pViews = pLastView - 1; - } - else - { - pViews--; - } - } - } + break; + case ACTION_PITCH_NEG: + if(pViews == pStartView) + { + pViews = pLastView - 1; + } + else + { + pViews--; + } + break; + default: + break; + } + + cv_disabled = t7_customview_disabled(*pViews); + if((cv_disabled) && (action == ACTION_END)) + { + action = ACTION_BUTTON_ENTER; + } } while(cv_disabled); selection_customview = *pViews;