X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=telegps%2FTeleGPSState.java;h=e01ef47e46e64d12bb32e14051adba8b91908d6e;hb=7d21ff641a7bc35318f0f637589eabb5bb6c5152;hp=a0ff572761ad4c023e1b3c2cf8f0d3e6b27b9f76;hpb=97adfff4cfb67c17a96f3ff46606b4e439422b01;p=fw%2Faltos diff --git a/telegps/TeleGPSState.java b/telegps/TeleGPSState.java index a0ff5727..e01ef47e 100644 --- a/telegps/TeleGPSState.java +++ b/telegps/TeleGPSState.java @@ -136,10 +136,13 @@ public class TeleGPSState extends AltosUIFlightTab { class FlightLogMax extends AltosUIIndicator { public void show(AltosState state, AltosListenerState listener_state) { - if (state.flight_log_max == AltosLib.MISSING) + int storage = state.flight_log_max; + if (storage == AltosLib.MISSING) + storage = state.log_space >> 10; + if (storage == AltosLib.MISSING) show("Missing"); else - show(String.format("%dkB", state.flight_log_max)); + show(String.format("%dkB", storage)); } public FlightLogMax(Container container, int y) {