summaryrefslogtreecommitdiff
path: root/altosui
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2017-05-26 00:20:17 -0700
committerKeith Packard <keithp@keithp.com>2017-05-26 00:20:17 -0700
commit2e82051a6aaaccf1e8a242f9c8141e4167e652d2 (patch)
treec0f9642d04f28850c9d60a07266f36c685452fef /altosui
parent222158581887b5f9e8b9843d14321c313fa023fa (diff)
altoslib,altosuilib,altosui: Get stats and replay working again.
Stats are really easy with all of the data in memory. Replay takes a special thread to run the data and dump it into a single state. Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'altosui')
-rw-r--r--altosui/AltosFlightUI.java2
-rw-r--r--altosui/AltosUI.java3
2 files changed, 3 insertions, 2 deletions
diff --git a/altosui/AltosFlightUI.java b/altosui/AltosFlightUI.java
index eaf19256..23a62e95 100644
--- a/altosui/AltosFlightUI.java
+++ b/altosui/AltosFlightUI.java
@@ -115,7 +115,9 @@ public class AltosFlightUI extends AltosUIFrame implements AltosFlightDisplay {
JComponent tab = which_tab(state);
if (tab != cur_tab) {
+ System.out.printf("checking tab for state %s\n", AltosLib.state_name(state.state()));
if (cur_tab == pane.getSelectedComponent()) {
+ System.out.printf("switch tabs\n");
pane.setSelectedComponent(tab);
}
cur_tab = tab;
diff --git a/altosui/AltosUI.java b/altosui/AltosUI.java
index b0cff381..a6b967f8 100644
--- a/altosui/AltosUI.java
+++ b/altosui/AltosUI.java
@@ -481,8 +481,7 @@ public class AltosUI extends AltosUIFrame {
AltosRecordSet set = record_set(file);
if (set == null)
return null;
-// return new AltosReplayReader(states.iterator(), file);
- return null;
+ return new AltosReplayReader(set, file);
}
static boolean process_replay(File file) {