Skip to content

Commit 2e6428e

Browse files
rzeldentCopilot
andauthored
Update src/main.cpp
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 95b0eef commit 2e6428e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/main.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -593,7 +593,11 @@ void display_flights()
593593
lv_label_set_text(label_latlon, format_gps_location(iotWebParamLatitude.value(), iotWebParamLongitude.value()).c_str());
594594
lv_obj_align(label_latlon, LV_ALIGN_CENTER, 0, 0);
595595
auto label_latLonRange = lv_label_create(lv_scr_act());
596-
auto latLonRange = iotWebParamMetric.value() ? "lat: " + String(iotWebParamLatitudeRange.value() * DEGREES_TO_KM) + " / lon: " + String(iotWebParamLatitudeRange.value() * DEGREES_TO_KM) + " km" : "lat: " + String(iotWebParamLatitudeRange.value() * DEGREES_TO_MI) + " / lon: " + String(iotWebParamLatitudeRange.value() * DEGREES_TO_MI) + " mi";
596+
auto latLonRange = iotWebParamMetric.value()
597+
? "lat: " + String(iotWebParamLatitudeRange.value() * DEGREES_TO_KM) +
598+
" / lon: " + String(iotWebParamLongitudeRange.value() * DEGREES_TO_KM) + " km"
599+
: "lat: " + String(iotWebParamLatitudeRange.value() * DEGREES_TO_MI) +
600+
" / lon: " + String(iotWebParamLongitudeRange.value() * DEGREES_TO_MI) + " mi";
597601
lv_label_set_text(label_latLonRange, latLonRange.c_str());
598602
lv_obj_align(label_latLonRange, LV_ALIGN_CENTER, 0, 16);
599603
auto label_location = lv_label_create(lv_scr_act());

0 commit comments

Comments
 (0)