boolean (@NotNull FilePath filePath) { return ReadAction.compute(() -> { if (myProject.isDisposed() || myProject.isDefault()) return false; if (Registry.is("ide.hide.excluded.files")) { VirtualFile vf = VcsImplUtil.findValidParentAccurately(filePath); return vf != null && myExcludedIndex.isExcludedFile(vf); } else { // WARN: might differ from 'myExcludedIndex.isUnderIgnored' if whole content root is under folder with 'ignored' name. FileTypeManager fileTypeManager = FileTypeManager.getInstance(); for (String name : StringUtil.tokenize(filePath.getPath(), "/")) { if (fileTypeManager.isFileIgnored(name)) { return true; } } return false; } }); }