summaryrefslogtreecommitdiff
path: root/ao-tools/altosui/AltosFlightUI.java
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2010-11-09 14:40:58 -0800
committerKeith Packard <keithp@keithp.com>2010-11-09 14:40:58 -0800
commit22d00785188a880700cd372528189a7a15278da9 (patch)
tree3b0a1f0e265876d6f701b9dbd576011f42bf9e1d /ao-tools/altosui/AltosFlightUI.java
parenteb77e806ded99532dc7eaa39c1893f075b028af6 (diff)
altosui: Add tab UI with 'pad' mode.
This creates a multi-tab interface for flight monitoring and includes a special tab for 'pad' mode. Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'ao-tools/altosui/AltosFlightUI.java')
-rw-r--r--ao-tools/altosui/AltosFlightUI.java16
1 files changed, 15 insertions, 1 deletions
diff --git a/ao-tools/altosui/AltosFlightUI.java b/ao-tools/altosui/AltosFlightUI.java
index 11fc2442..a7caf7e9 100644
--- a/ao-tools/altosui/AltosFlightUI.java
+++ b/ao-tools/altosui/AltosFlightUI.java
@@ -37,6 +37,11 @@ public class AltosFlightUI extends JFrame implements AltosFlightDisplay {
AltosDisplayThread thread;
private Box vbox;
+
+ JTabbedPane pane;
+
+ AltosPad pad;
+
private AltosStatusTable flightStatus;
private AltosInfoTable flightInfo;
@@ -63,10 +68,12 @@ public class AltosFlightUI extends JFrame implements AltosFlightDisplay {
}
public void reset() {
+ pad.reset();
flightInfo.clear();
}
public void show(AltosState state, int crc_errors) {
+ pad.show(state, crc_errors);
flightStatus.set(state);
flightInfo.show(state, crc_errors);
}
@@ -86,8 +93,15 @@ public class AltosFlightUI extends JFrame implements AltosFlightDisplay {
vbox = new Box (BoxLayout.Y_AXIS);
vbox.add(flightStatus);
+ pane = new JTabbedPane();
+
+ pad = new AltosPad();
+ pane.add("Launch Pad", pad);
+
flightInfo = new AltosInfoTable();
- vbox.add(flightInfo.box());
+ pane.add("Table", flightInfo.box());
+
+ vbox.add(pane);
this.add(vbox);