Lines 485-500
Link Here
|
485 |
updatedRoots = this.roots; |
485 |
updatedRoots = this.roots; |
486 |
otherUpdatedRoots = this.otherRoots; |
486 |
otherUpdatedRoots = this.otherRoots; |
487 |
} |
487 |
} |
|
|
488 |
int containerSegmentCount = containerPath.segmentCount(); |
489 |
boolean containerIsProject = containerSegmentCount == 1; |
488 |
Iterator iterator = updatedRoots.entrySet().iterator(); |
490 |
Iterator iterator = updatedRoots.entrySet().iterator(); |
489 |
while (iterator.hasNext()) { |
491 |
while (iterator.hasNext()) { |
490 |
Map.Entry entry = (Map.Entry) iterator.next(); |
492 |
Map.Entry entry = (Map.Entry) iterator.next(); |
491 |
IPath path = (IPath) entry.getKey(); |
493 |
IPath path = (IPath) entry.getKey(); |
492 |
if (containerPath.isPrefixOf(path) && !containerPath.equals(path)) { |
494 |
if (containerPath.isPrefixOf(path) && !containerPath.equals(path)) { |
493 |
IResourceDelta rootDelta = containerDelta.findMember(path.removeFirstSegments(1)); |
495 |
IResourceDelta rootDelta = containerDelta.findMember(path.removeFirstSegments(containerSegmentCount)); |
494 |
if (rootDelta == null) continue; |
496 |
if (rootDelta == null) continue; |
495 |
DeltaProcessor.RootInfo rootInfo = (DeltaProcessor.RootInfo) entry.getValue(); |
497 |
DeltaProcessor.RootInfo rootInfo = (DeltaProcessor.RootInfo) entry.getValue(); |
496 |
|
498 |
|
497 |
if (!rootInfo.project.getPath().isPrefixOf(path)) { // only consider roots that are not included in the container |
499 |
if (!containerIsProject |
|
|
500 |
|| !rootInfo.project.getPath().isPrefixOf(path)) { // only consider folder roots that are not included in the container |
498 |
deltaProcessor.updateCurrentDeltaAndIndex(rootDelta, IJavaElement.PACKAGE_FRAGMENT_ROOT, rootInfo); |
501 |
deltaProcessor.updateCurrentDeltaAndIndex(rootDelta, IJavaElement.PACKAGE_FRAGMENT_ROOT, rootInfo); |
499 |
} |
502 |
} |
500 |
|
503 |
|
Lines 503-509
Link Here
|
503 |
Iterator otherProjects = rootList.iterator(); |
506 |
Iterator otherProjects = rootList.iterator(); |
504 |
while (otherProjects.hasNext()) { |
507 |
while (otherProjects.hasNext()) { |
505 |
rootInfo = (DeltaProcessor.RootInfo)otherProjects.next(); |
508 |
rootInfo = (DeltaProcessor.RootInfo)otherProjects.next(); |
506 |
if (!rootInfo.project.getPath().isPrefixOf(path)) { // only consider roots that are not included in the container |
509 |
if (!containerIsProject |
|
|
510 |
|| !rootInfo.project.getPath().isPrefixOf(path)) { // only consider folder roots that are not included in the container |
507 |
deltaProcessor.updateCurrentDeltaAndIndex(rootDelta, IJavaElement.PACKAGE_FRAGMENT_ROOT, rootInfo); |
511 |
deltaProcessor.updateCurrentDeltaAndIndex(rootDelta, IJavaElement.PACKAGE_FRAGMENT_ROOT, rootInfo); |
508 |
} |
512 |
} |
509 |
} |
513 |
} |