last bits for thursday night

This commit is contained in:
benfry
2003-11-06 05:32:27 +00:00
parent 1c9a72ca79
commit f03ec873c9
3 changed files with 103 additions and 70 deletions

View File

@@ -1049,6 +1049,34 @@ public class PdeBase extends Frame
}
}
//
// could also do showMessage with JOptionPane.INFORMATION_MESSAGE
//
static public void showWarning(String title, String message,
Exception e) {
if (title == null) title = "Warning";
JOptionPane.showMessageDialog(this, message, title,
JOptionPane.WARNING_MESSAGE);
//System.err.println(e.toString());
if (e != null) e.printStackTrace();
}
//
static public void showError(String title, String message,
Exception e) {
if (title == null) title = "Error";
JOptionPane.showMessageDialog(this, message, title,
JOptionPane.ERROR_MESSAGE);
if (e != null) e.printStackTrace();
}
//
// used by PdeEditorButtons, but probably more later
static public Image getImage(String name, Component who) {