mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
platform project view: excluded files from project root were shown as top level elements
This commit is contained in:
+4
-3
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2009 JetBrains s.r.o.
|
||||
* Copyright 2000-2016 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -23,6 +23,7 @@ import com.intellij.openapi.module.Module;
|
||||
import com.intellij.openapi.module.ModuleUtil;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.openapi.roots.ModuleRootManager;
|
||||
import com.intellij.openapi.roots.ProjectFileIndex;
|
||||
import com.intellij.openapi.util.Comparing;
|
||||
import com.intellij.openapi.util.io.FileUtil;
|
||||
import com.intellij.openapi.vfs.VfsUtilCore;
|
||||
@@ -73,8 +74,8 @@ public class ProjectViewProjectNode extends AbstractProjectNode {
|
||||
|
||||
final VirtualFile[] files = baseDir.getChildren();
|
||||
for (VirtualFile file : files) {
|
||||
if (ModuleUtil.findModuleForFile(file, getProject()) == null) {
|
||||
if (!file.isDirectory()) {
|
||||
if (!file.isDirectory()) {
|
||||
if (ProjectFileIndex.SERVICE.getInstance(getProject()).getModuleForFile(file, false) == null) {
|
||||
nodes.add(new PsiFileNode(getProject(), psiManager.findFile(file), getSettings()));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user