diff options
author | Keith Packard <keithp@keithp.com> | 2011-04-25 21:17:07 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2011-04-25 21:17:07 -0700 |
commit | 2e7b7b80432bb251ac39efa1fa05d32b5f250e14 (patch) | |
tree | 602b6834664e4a5d80a13334fcc4b59ca4958160 /altosui/AltosRomconfigUI.java | |
parent | 214cd69c0e4a1617ed5cde8fc2f46a4cee6ecced (diff) |
altosui: Separate out flash debug code to separate thread
This avoids blocking the Swing thread while waiting for the serial
device.
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'altosui/AltosRomconfigUI.java')
-rw-r--r-- | altosui/AltosRomconfigUI.java | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/altosui/AltosRomconfigUI.java b/altosui/AltosRomconfigUI.java index e1dc974e..7e21735c 100644 --- a/altosui/AltosRomconfigUI.java +++ b/altosui/AltosRomconfigUI.java @@ -126,6 +126,11 @@ public class AltosRomconfigUI setLocationRelativeTo(owner); } + public AltosRomconfigUI(JFrame frame, AltosRomconfig config) { + this(frame); + set(config); + } + boolean selected; /* Listen for events from our buttons */ @@ -183,4 +188,9 @@ public class AltosRomconfigUI return romconfig(); return null; } + + public static AltosRomconfig show(JFrame frame, AltosRomconfig config) { + AltosRomconfigUI ui = new AltosRomconfigUI(frame, config); + return ui.showDialog(); + } } |