From 474a8850b3ca63e8763597c2010ae87d961ade65 Mon Sep 17 00:00:00 2001 From: Ilya Kirillov Date: Thu, 1 Aug 2019 11:45:58 +0300 Subject: [PATCH] Do not show error message in decompiler in write action #EA-209667 fixed --- .../jetbrains/kotlin/idea/internal/KotlinDecompilerAdapter.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/idea/src/org/jetbrains/kotlin/idea/internal/KotlinDecompilerAdapter.kt b/idea/src/org/jetbrains/kotlin/idea/internal/KotlinDecompilerAdapter.kt index 5311a42ab2b..f6ddb601393 100644 --- a/idea/src/org/jetbrains/kotlin/idea/internal/KotlinDecompilerAdapter.kt +++ b/idea/src/org/jetbrains/kotlin/idea/internal/KotlinDecompilerAdapter.kt @@ -42,7 +42,9 @@ class KotlinBytecodeDecompilerTask(val file: KtFile) : Task.Backgroundable(file. if (!file.isValid || file.project.isDisposed) return@runWriteAction if (decompiledText == null) { - Messages.showErrorDialog("Cannot decompile ${file.name}", "Decompiler error") + ApplicationManager.getApplication().invokeLater { + Messages.showErrorDialog("Cannot decompile ${file.name}", "Decompiler error") + } return@runWriteAction }