EA-60956 - assert: DocumentImpl.doRemoveDocumentListener
authorDmitry Batrak <Dmitry.Batrak@jetbrains.com>
Tue, 23 Dec 2014 18:10:13 +0000 (21:10 +0300)
committerDmitry Batrak <Dmitry.Batrak@jetbrains.com>
Tue, 23 Dec 2014 18:11:04 +0000 (21:11 +0300)
platform/platform-impl/src/com/intellij/openapi/fileEditor/impl/text/TextEditorComponent.java

index de11bd5b9a12fa753fb5f8da972fdfd8668dd0e9..a476264b8285181f698cda15cdda7ec9a2848d68 100644 (file)
@@ -245,7 +245,7 @@ class TextEditorComponent extends JBLoadingPanel implements DataProvider {
    * changes its file type.
    */
   private void updateHighlighters(){
-    if (!myProject.isDisposed()) {
+    if (!myProject.isDisposed() && !myEditor.isDisposed()) {
       final EditorHighlighter highlighter = EditorHighlighterFactory.getInstance().createEditorHighlighter(myProject, myFile);
       ((EditorEx)myEditor).setHighlighter(highlighter);
     }