Skip to content

Commit c211a45

Browse files
committed
Fix override-only violation: AnAction.actionPerformed(AnActionEvent)
See #178
1 parent 460605e commit c211a45

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/main/java/software/xdev/saveactions/processors/BuildProcessor.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@
2121
import com.intellij.openapi.actionSystem.AnAction;
2222
import com.intellij.openapi.actionSystem.AnActionEvent;
2323
import com.intellij.openapi.actionSystem.DataContext;
24+
import com.intellij.openapi.actionSystem.ex.ActionUtil;
2425
import com.intellij.openapi.actionSystem.impl.SimpleDataContext;
26+
import com.intellij.openapi.application.ApplicationManager;
2527
import com.intellij.openapi.compiler.CompilerManager;
2628
import com.intellij.openapi.fileEditor.FileEditorManager;
2729
import com.intellij.openapi.project.Project;
@@ -91,7 +93,9 @@ public enum BuildProcessor implements Processor
9193
ActionUiKind.NONE,
9294
null);
9395

94-
anAction.actionPerformed(event);
96+
// Run Action on EDT thread
97+
ApplicationManager.getApplication().invokeLater(() ->
98+
ActionUtil.performActionDumbAwareWithCallbacks(anAction, event));
9599
}
96100
})
97101
{

0 commit comments

Comments
 (0)