From 91a75279b6d306ba9d068a28c64917d5312122e8 Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Sun, 27 Mar 2011 00:12:01 -0700 Subject: [PATCH] altosui: Off-by-one error in telemetry format configuration UI The telemetry format menu uses 0 for full and 1 for tiny, but the telemetry configuration uses 1 for full and 2 for tiny. One direction (config to UI) was right, the other (UI to config) was wrong. Signed-off-by: Keith Packard --- altosui/AltosFlightUI.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/altosui/AltosFlightUI.java b/altosui/AltosFlightUI.java index 286b2a4e..66dcdad5 100644 --- a/altosui/AltosFlightUI.java +++ b/altosui/AltosFlightUI.java @@ -162,7 +162,7 @@ public class AltosFlightUI extends JFrame implements AltosFlightDisplay { telemetries.setMaximumRowCount(2); telemetries.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { - int telemetry = telemetries.getSelectedIndex(); + int telemetry = telemetries.getSelectedIndex() + 1; reader.set_telemetry(telemetry); } }); -- 2.30.2