removeAll();
// Progress panel
JPanel progressPanel = new JPanel(new BorderLayout());
progressPanel.setBorder(BorderFactory.createTitledBorder("Progress"));
final JProgressBar b = new JProgressBar(0, l.size());
b.setStringPainted(true);
progressPanel.add(b, BorderLayout.CENTER);
add(progressPanel, BorderLayout.NORTH);
// Console panel
JPanel consolePanel = new JPanel(new BorderLayout());
consolePanel.setBorder(BorderFactory.createTitledBorder("Output"));
console = new JTextPane();
JScrollPane scrollPane = new JScrollPane(console);
consolePanel.add(scrollPane, BorderLayout.CENTER);
add(consolePanel, BorderLayout.CENTER);
//
validate();
repaint();
//
Thread t = new Thread() {
public void run() {
try {
for(Iterator i = l.iterator(); i.hasNext(); ) {
AbstractDatabaseUpgrade upgrade = (AbstractDatabaseUpgrade)i.next();
b.setValue(b.getValue() + 1);
upgrade.upgrade(GUIUpgrader.this);
try {
Thread.sleep(750);
}
catch(InterruptedException ie) {