navigate from tree in a write-safe context (EA-97654 - assert: PsiModificationTrackerImpl.fireEvent)

This commit is contained in:
peter
2017-08-14 09:58:14 +02:00
parent 4bffdff777
commit bc471d3a26
@@ -22,6 +22,7 @@ import com.intellij.ide.errorTreeView.impl.ErrorTreeViewConfiguration;
import com.intellij.ide.errorTreeView.impl.ErrorViewTextExporter;
import com.intellij.openapi.actionSystem.*;
import com.intellij.openapi.application.ModalityState;
import com.intellij.openapi.application.TransactionGuard;
import com.intellij.openapi.diagnostic.Logger;
import com.intellij.openapi.fileEditor.OpenFileDescriptor;
import com.intellij.openapi.ide.CopyPasteManager;
@@ -252,7 +253,7 @@ public class NewErrorTreeViewPanel extends JPanel implements DataProvider, Occur
if (firstError != null) {
selectElement(firstError, () -> {
if (shouldShowFirstErrorInEditor()) {
navigateToSource(false);
TransactionGuard.submitTransaction(myBuilder, () -> navigateToSource(false));
}
});
}