void (@NotNull AnActionEvent event) { final Project project = event.getProject(); assert project != null; final VcsSelection selection = VcsSelectionUtil.getSelection(this, event); assert selection != null; final VirtualFile file = FileDocumentManager.getInstance().getFile(selection.getDocument()); assert file != null; final AbstractVcs activeVcs = ProjectLevelVcsManager.getInstance(project).getVcsFor(file); assert activeVcs != null; final VcsHistoryProvider provider = activeVcs.getVcsBlockHistoryProvider(); assert provider != null; final int selectionStart = selection.getSelectionStartLineNumber(); final int selectionEnd = selection.getSelectionEndLineNumber(); VcsSelectionHistoryDialog dialog = new VcsSelectionHistoryDialog(project, file, selection.getDocument(), provider, activeVcs, Math.min(selectionStart, selectionEnd), Math.max(selectionStart, selectionEnd), selection.getDialogTitle()); dialog.show(); }