summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2014-06-14 14:36:49 -0700
committerKeith Packard <keithp@keithp.com>2014-06-14 14:36:49 -0700
commit242e968a6982f2ceaa79780cbeec8c4e21321b44 (patch)
treeb075deac26f2a27da48f80418a95daffd8874ed7
parentc7553c54765dcc9ac532fe52aae9594b2ad5e560 (diff)
altosuilib: In graph, show zero sats in view as 0 instead of MISSING
Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r--altosuilib/AltosGraphDataPoint.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/altosuilib/AltosGraphDataPoint.java b/altosuilib/AltosGraphDataPoint.java
index 446468d7..3aff1e82 100644
--- a/altosuilib/AltosGraphDataPoint.java
+++ b/altosuilib/AltosGraphDataPoint.java
@@ -101,8 +101,12 @@ public class AltosGraphDataPoint implements AltosUIDataPoint {
y = state.gps.nsat;
break;
case data_gps_nsat_view:
- if (state.gps != null && state.gps.cc_gps_sat != null)
- y = state.gps.cc_gps_sat.length;
+ if (state.gps != null) {
+ if (state.gps.cc_gps_sat != null)
+ y = state.gps.cc_gps_sat.length;
+ else
+ y = 0;
+ }
break;
case data_gps_altitude:
y = state.gps_altitude();