]> source.dussan.org Git - aspectj.git/commitdiff
Fix for 54238: Restore build cancelling to Swing-based IDEs
authormkersten <mkersten>
Tue, 27 Apr 2004 18:55:41 +0000 (18:55 +0000)
committermkersten <mkersten>
Tue, 27 Apr 2004 18:55:41 +0000 (18:55 +0000)
ajbrowser/src/org/aspectj/tools/ajbrowser/BasicEditor.java

index 95d5c9135faea6dba233b5a90abae4cabf087457..720ed65fd6e5155854f68f18500e8095fc2fac8f 100644 (file)
@@ -72,9 +72,13 @@ public class BasicEditor implements EditorAdapter {
     }
 
     public void showSourceLine(ISourceLocation sourceLocation, boolean highlight) {
-               showSourceLine(sourceLocation.getSourceFile().getAbsolutePath(), sourceLocation.getLine(), highlight);
-       }
-
+       try {
+               showSourceLine(sourceLocation.getSourceFile().getAbsolutePath(), sourceLocation.getLine(), highlight);
+       } catch (NullPointerException npe) {
+               Ajde.getDefault().getIdeUIAdapter().displayStatusInformation(" no corresponding source line to seek to");
+       }
+    }
+       
     public void showSourceLine(int lineNumber, boolean highlight) {
         showSourceLine(filePath, lineNumber, highlight);
     }