altosui: Only call swing display functions from main thread.
authorKeith Packard <keithp@keithp.com>
Thu, 25 Nov 2010 23:56:42 +0000 (15:56 -0800)
committerKeith Packard <keithp@keithp.com>
Fri, 26 Nov 2010 00:30:19 +0000 (16:30 -0800)
commit12fb7f0e70cd244475d84469f93283112478d1e1
treeeaada3e2ea3534f3c8d7eae1dc77f1c83651cb36
parentb74cec6cd0bc043f53e9e28472765aa343136813
altosui: Only call swing display functions from main thread.

Swing insists that all display functions be called from a single
thread, and the flight window wasn't following this for display
updates. Use SwingUtilities.invokeLater to make sure the flight UI
updates happen in the right context.

Fixes a UI freeze on Mac OS.

Signed-off-by: Keith Packard <keithp@keithp.com>
altosui/AltosDisplayThread.java