comparison Discovery/Src/tMenuEditCustom.c @ 640:f735f1123526

Development bugfix Viewport settings: Settings of the viewport have been reset after every update. Root cause: plausibility check value has not been adapted to latest implementation. In addition settings for frame have been overwritten while focus was changed because of an invalid and combination. Both issues have been solved
author Ideenmodellierer
date Thu, 11 Mar 2021 21:43:43 +0100
parents b9d4baa4f6fa
children 3ccf13af4651
comparison
equal deleted inserted replaced
639:13ded99ecd56 640:f735f1123526
707 return UPDATE_DIVESETTINGS; 707 return UPDATE_DIVESETTINGS;
708 } 708 }
709 uint8_t OnAction_CViewPortLayout(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) 709 uint8_t OnAction_CViewPortLayout(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action)
710 { 710 {
711 SSettings* pSettings = settingsGetPointer(); 711 SSettings* pSettings = settingsGetPointer();
712 if(pSettings->viewPortMode >> 4 != 0) 712 if((pSettings->viewPortMode >> 4) & 0x10 != 0)
713 { 713 {
714 pSettings->viewPortMode &= 0x0F; 714 pSettings->viewPortMode &= 0xEF; /* 1110 1111 */
715 } 715 }
716 else 716 else
717 { 717 {
718 pSettings->viewPortMode |= 0x10; 718 pSettings->viewPortMode |= 0x10;
719 } 719 }
770 newValue = ((pSettings->viewPortMode >> 5) + 1) & 0x03; 770 newValue = ((pSettings->viewPortMode >> 5) + 1) & 0x03;
771 if(newValue > MAX_FOCUS_LIMITER) 771 if(newValue > MAX_FOCUS_LIMITER)
772 { 772 {
773 newValue = 0; 773 newValue = 0;
774 } 774 }
775 pSettings->viewPortMode &= 0x9F; 775 pSettings->viewPortMode &= 0x9F; /* 1001 1111 */
776 pSettings->viewPortMode |= (newValue << 5); 776 pSettings->viewPortMode |= (newValue << 5);
777 return UPDATE_DIVESETTINGS; 777 return UPDATE_DIVESETTINGS;
778 } 778 }
779 779
780 void openEdit_CustomviewDivemode(const uint8_t* pcv_changelist) 780 void openEdit_CustomviewDivemode(const uint8_t* pcv_changelist)