Author: pkluegl
Date: Tue Mar 26 08:34:31 2013
New Revision: 1461013

URL: http://svn.apache.org/r1461013
Log:
no jira -  added check on null for editor

Modified:
    
uima/sandbox/textmarker/trunk/textmarker-ep-ide/src/main/java/org/apache/uima/textmarker/ide/TextMarkerIdePlugin.java

Modified: 
uima/sandbox/textmarker/trunk/textmarker-ep-ide/src/main/java/org/apache/uima/textmarker/ide/TextMarkerIdePlugin.java
URL: 
http://svn.apache.org/viewvc/uima/sandbox/textmarker/trunk/textmarker-ep-ide/src/main/java/org/apache/uima/textmarker/ide/TextMarkerIdePlugin.java?rev=1461013&r1=1461012&r2=1461013&view=diff
==============================================================================
--- 
uima/sandbox/textmarker/trunk/textmarker-ep-ide/src/main/java/org/apache/uima/textmarker/ide/TextMarkerIdePlugin.java
 (original)
+++ 
uima/sandbox/textmarker/trunk/textmarker-ep-ide/src/main/java/org/apache/uima/textmarker/ide/TextMarkerIdePlugin.java
 Tue Mar 26 08:34:31 2013
@@ -72,7 +72,9 @@ public class TextMarkerIdePlugin extends
         // close all CAS Editors if on is focused when exiting Eclipse
         final IWorkbenchPage activePage = 
workbench.getActiveWorkbenchWindow().getActivePage();
         IEditorPart activeEditor = activePage.getActiveEditor();
-        if 
(activeEditor.getClass().getName().equals("org.apache.uima.caseditor.editor.AnnotationEditor"))
 {
+        if (activeEditor != null
+                && activeEditor.getClass().getName()
+                        
.equals("org.apache.uima.caseditor.editor.AnnotationEditor")) {
           IEditorReference[] editorReferences = 
activePage.getEditorReferences();
           List<IEditorReference> toClose = new ArrayList<IEditorReference>();
           for (IEditorReference each : editorReferences) {
@@ -88,7 +90,7 @@ public class TextMarkerIdePlugin extends
       public void postShutdown(IWorkbench workbench) {
 
       }
-    });  
+    });
   }
 
   /*


Reply via email to