void (@NotNull final AnActionEvent e) { Project project = e.getData(CommonDataKeys.PROJECT); ListSelection<Change> selection = e.getData(VcsDataKeys.CHANGES_SELECTION); boolean isInAir = CommittedChangesBrowserUseCase.IN_AIR.equals(e.getData(CommittedChangesBrowserUseCase.DATA_KEY)); e.getPresentation().setEnabled(project != null && selection != null && !isInAir && canShowDiff(selection.getList())); }