boolean (@NotNull ActionContext context, @NotNull ModUpdateInspectionOptions options) { VirtualFile vFile = context.file().getVirtualFile(); Project project = context.project(); setOption(project, vFile, options, true); UndoManager.getInstance(project).undoableActionPerformed(new BasicUndoableAction(vFile) { @Override public void undo() { setOption(project, vFile, options, false); } @Override public void redo() { setOption(project, vFile, options, true); } }); return true; }