From 461bf788adbc4e7740202ea4c1866268f312d4b1 Mon Sep 17 00:00:00 2001 From: mkersten Date: Wed, 9 Jul 2003 07:48:09 +0000 Subject: [PATCH] Added safeguard for missing 1.3 setLocationRelativeTo method. --- .../ajde/ui/swing/DefaultBuildProgressMonitor.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ajde/src/org/aspectj/ajde/ui/swing/DefaultBuildProgressMonitor.java b/ajde/src/org/aspectj/ajde/ui/swing/DefaultBuildProgressMonitor.java index 5caa9cbec..ad70c4d33 100644 --- a/ajde/src/org/aspectj/ajde/ui/swing/DefaultBuildProgressMonitor.java +++ b/ajde/src/org/aspectj/ajde/ui/swing/DefaultBuildProgressMonitor.java @@ -19,7 +19,7 @@ import java.awt.Frame; import javax.swing.JDialog; import org.aspectj.ajde.BuildProgressMonitor; - + /** * This dialog box is open while ajc is compiling the system and displays * a corresponding progress bar. @@ -36,7 +36,11 @@ public class DefaultBuildProgressMonitor extends Thread implements BuildProgress progressDialog = new BuildProgressPanel(); dialog.setContentPane(progressDialog); dialog.setSize(550, 120); - dialog.setLocationRelativeTo(parent); + try { + dialog.setLocationRelativeTo(parent); + } catch (NoSuchMethodError nsme) { + // running on 1.3 + } } /** -- 2.39.5