Name: clC74495 Date: 02/08/99 The read(), skip(), and reset() methods of ProgressMonitorInputStream update the ProgressMonitor associated to it outside of the event thread. For instance: public long skip(long n) throws IOException { long nr = in.skip(n); if (nr>0) monitor.setProgress(nread+=nr); return nr; } I realize that ProgressMonitor isn't itself a Swing component, however, I think its setProgress() method needs to be called from the event thread, as this accesses a JProgressBar. I could possibly see why it might be okay outside the event thread (it only does a set, no gets). However, it seems like if it is okay, then there should be a comment added. (Review ID: 53802) ======================================================================
|