void (@NotNull FileSystemTree fileSystemTree, @NotNull AnActionEvent e) { Presentation presentation = e.getPresentation(); if (presentation.isEnabled()) { VirtualFile userHomeDir = VfsUtil.getUserHomeDir(); presentation.setEnabled(userHomeDir != null && fileSystemTree.isUnderRoots(userHomeDir)); } }