Mercurial > public > ostc4
diff Discovery/Src/t7.c @ 318:bc31d078fb90
Merged in Ideenmodellierer/ostc4/Bugfix_Flip_FirmwareUpdate (pull request #26)
Bugfix Flip FirmwareUpdate
author | heinrichsweikamp <bitbucket@heinrichsweikamp.com> |
---|---|
date | Wed, 19 Jun 2019 13:12:01 +0000 |
parents | 7420ed6c3508 |
children | 449e9e9632e4 e309f78f89a5 |
line wrap: on
line diff
--- a/Discovery/Src/t7.c Sat Jun 01 10:12:15 2019 +0200 +++ b/Discovery/Src/t7.c Wed Jun 19 13:12:01 2019 +0000 @@ -1834,7 +1834,15 @@ t7cC.WindowLineSpacing = 95; t7cC.WindowNumberOfTextLines = 3; text[textpointer] = 0; + if(pSettings->FlipDisplay) + { + t7cC.WindowY1 -= 40; + } GFX_write_string(&FontT105,&t7cC,text,1); + if(pSettings->FlipDisplay) + { + t7cC.WindowY1 += 40; + } break; case CVIEW_sensors_mV: @@ -1864,7 +1872,15 @@ t7cC.WindowLineSpacing = 95; t7cC.WindowNumberOfTextLines = 3; text[textpointer] = 0; + if(pSettings->FlipDisplay) + { + t7cC.WindowY1 -= 40; + } GFX_write_string(&FontT48,&t7cC,text,1); + if(pSettings->FlipDisplay) + { + t7cC.WindowY1 += 40; + } break; case CVIEW_Compass: @@ -3055,6 +3071,11 @@ fCNS = 999; t7cY0free.WindowY0 = t7cC.WindowY0 - 10; + if(settingsGetPointer()->FlipDisplay) + { + t7cY0free.WindowY1 = 400; + } + t7cY0free.WindowLineSpacing = 48; t7cY0free.WindowNumberOfTextLines = 6; t7cY0free.WindowTab = 420; @@ -3079,12 +3100,23 @@ text[textpointer++] = TXT_FutureTTS; text[textpointer++] = '\017'; text[textpointer++] = 0; - t7cY0free.WindowX0 += 10; - t7cY0free.WindowY0 += 10; - GFX_write_string(&FontT24, &t7cY0free, text, 1); - t7cY0free.WindowX0 -= 10; - t7cY0free.WindowY0 -= 10; - + + if(!settingsGetPointer()->FlipDisplay) + { + t7cY0free.WindowX0 += 10; + t7cY0free.WindowY0 += 10; + GFX_write_string(&FontT24, &t7cY0free, text, 1); + t7cY0free.WindowX0 -= 10; + t7cY0free.WindowY0 -= 10; + } + else + { + t7cY0free.WindowY1 -= 10; + t7cY0free.WindowX1 -= 10; + GFX_write_string(&FontT24, &t7cY0free, text, 1); + t7cY0free.WindowY1 += 10; + t7cY0free.WindowX1 += 10; + } textpointer = 0; text[textpointer++] = '\t'; textpointer += snprintf(&text[textpointer],10,"\020%01.2f", stateUsed->lifeData.ppO2);