diff options
| author | Keith Packard <keithp@keithp.com> | 2015-06-25 18:33:46 -0700 | 
|---|---|---|
| committer | Keith Packard <keithp@keithp.com> | 2015-06-25 18:43:13 -0700 | 
| commit | f76d5e4fc2ed1e0d79c096cc89793d671ecb78c3 (patch) | |
| tree | 413c4a4e5a2c85790eaa54336b7036f44c7753cb | |
| parent | 7c0f66bf64f410415afaff1b5c8e1443512b7a57 (diff) | |
altosuilib: Receiver battery voltage lives in listener_state
The code to detect whether to show or hide this entry was using
functions that weren't given the listener_state and hence returned
MISSING all of the time.
Signed-off-by: Keith Packard <keithp@keithp.com>
| -rw-r--r-- | altosuilib/AltosUIUnitsIndicator.java | 6 | 
1 files changed, 5 insertions, 1 deletions
diff --git a/altosuilib/AltosUIUnitsIndicator.java b/altosuilib/AltosUIUnitsIndicator.java index 6f398808..8e0a9e07 100644 --- a/altosuilib/AltosUIUnitsIndicator.java +++ b/altosuilib/AltosUIUnitsIndicator.java @@ -36,6 +36,10 @@ public abstract class AltosUIUnitsIndicator extends AltosUIIndicator {  		return hide(value(state, i));  	} +	public boolean hide(AltosState state, AltosListenerState listener_state, int i) { +		return hide(state, i); +	} +  	public double value (AltosState state, AltosListenerState listener_state, int i) {  		return value(state, i);  	} @@ -77,7 +81,7 @@ public abstract class AltosUIUnitsIndicator extends AltosUIIndicator {  				v[i] = value(state, listener_state, i);  			else  				v[i] = AltosLib.MISSING; -			if (hide(state, i)) +			if (hide(state, listener_state, i))  				hide = true;  		}  | 
