project not initialized: brute force fix
authorAlexey Kudravtsev <cdr@intellij.com>
Thu, 19 Aug 2010 13:21:01 +0000 (17:21 +0400)
committerAlexey Kudravtsev <cdr@intellij.com>
Fri, 20 Aug 2010 07:57:03 +0000 (11:57 +0400)
platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/DaemonCodeAnalyzerImpl.java

index ee6d27286d4874d389b055a99955f755da57461a..b174dc02cad75db3c523d2bea0dfaef494c27207 100644 (file)
@@ -179,7 +179,7 @@ public class DaemonCodeAnalyzerImpl extends DaemonCodeAnalyzer implements JDOMEx
   }
 
   void repaintErrorStripeRenderer(Editor editor) {
-    if (myProject.isDisposed()) return;
+    if (!myProject.isInitialized()) return;
     final Document document = editor.getDocument();
     final PsiFile psiFile = PsiDocumentManager.getInstance(myProject).getPsiFile(document);
     final EditorMarkupModel markup = (EditorMarkupModel)editor.getMarkupModel();
@@ -588,7 +588,7 @@ public class DaemonCodeAnalyzerImpl extends DaemonCodeAnalyzer implements JDOMEx
       public void run() {
         if (!myUpdateByTimerEnabled) return;
         if (PowerSaveMode.isEnabled()) return;
-        if (myDisposed || myProject.isDisposed()) return;
+        if (myDisposed || !myProject.isInitialized()) return;
         final Collection<FileEditor> activeEditors = myDaemonListeners.getSelectedEditors();
         if (activeEditors.isEmpty()) return;
         Map<FileEditor, HighlightingPass[]> passes = new THashMap<FileEditor, HighlightingPass[]>(activeEditors.size());