void (@NotNull AnActionEvent e) { final Project project = e.getProject(); final VirtualFile file = VcsContextUtil.selectedFile(e.getDataContext()); if (project == null || file == null) return; final AbstractVcs vcs = ProjectLevelVcsManager.getInstance(project).getVcsFor(file); if (vcs == null) return; RevisionSelector selector = vcs.getRevisionSelector(); DiffProvider diffProvider = vcs.getDiffProvider(); if (selector == null || diffProvider == null) return; VcsRevisionNumber vcsRevisionNumber = selector.selectNumber(file); if (vcsRevisionNumber != null) { DiffActionExecutor.showDiff(diffProvider, vcsRevisionNumber, file, project); } }