Merge pull request #92 from syund/Show-fixed-GPS-coordinates-on-screen

Fix coordinates not displaying when fixed
1.2-legacy
Jm Casler 2021-12-19 15:16:33 -05:00 zatwierdzone przez GitHub
commit 836113ef8b
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 2 dodań i 2 usunięć

Wyświetl plik

@ -460,9 +460,9 @@ static void drawGPScoordinates(OLEDDisplay *display, int16_t x, int16_t y, const
// If fixed position, display text "Fixed GPS" alternating with the coordinates.
if (radioConfig.preferences.fixed_position) {
if ((millis() / 10000) % 2) {
display->drawString(x + (SCREEN_WIDTH - (display->getStringWidth(displayLine))) / 2, y, displayLine);
display->drawString(x + (SCREEN_WIDTH - (display->getStringWidth(coordinateLine))) / 2, y, coordinateLine);
} else {
displayLine = "Fixed GPS";
display->drawString(x + (SCREEN_WIDTH - (display->getStringWidth("Fixed GPS"))) / 2, y, "Fixed GPS");
}
} else {
display->drawString(x + (SCREEN_WIDTH - (display->getStringWidth(coordinateLine))) / 2, y, coordinateLine);