use of com.intellij.openapi.roots.SourceFolder in project android by JetBrains.
the class NonAndroidSourceTypeNode method getSourceFolders.
private List<VirtualFile> getSourceFolders() {
ModuleRootManager rootManager = ModuleRootManager.getInstance(getValue());
List<VirtualFile> folders = Lists.newArrayList();
ContentEntry[] contentEntries = rootManager.getContentEntries();
for (ContentEntry entry : contentEntries) {
List<SourceFolder> sources = entry.getSourceFolders(mySourceType.rootType);
for (SourceFolder folder : sources) {
VirtualFile file = folder.getFile();
if (file != null) {
folders.add(file);
}
}
}
return folders;
}
Aggregations