Bug 32301 2 Packages with similar names have a problem displaying in the Java browsing perspective.
Hello, Thanks for a wonderful IDE with all these rich features. I think we have a small bug in the Java Browsing Perspective. As an example: Please create a package called "test" in your project. Then create a parallel package called "test_a". After refreshing project, test_a will show up as a child of "test" and also as its parallel project. "test_a" is actually a parallel package, and should show up only alongside "test", not under it. Thanks, agam
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/PackagesViewHierarchicalContentProvider.java
processAffectedChildren(delta);
	}
	
	private Object findElementToRefresh(Object object) {
		Object toBeRefreshed= object;
		if (fViewer.testFindItem(object) == null) {
			 Object parent= getParent(object);
			 if(parent instanceof IPackageFragmentRoot && fInputIsProject)
			 	parent= ((IPackageFragmentRoot)parent).getJavaProject();
			 
			if(parent != null)
				toBeRefreshed= parent;
		}
		return toBeRefreshed;
	}
	private void processAffectedChildren(IJavaElementDelta delta) throws JavaModelException {
		IJavaElementDelta[] affectedChildren = delta.getAffectedChildren();
		for (int i = 0; i < affectedChildren.length; i++) {
			if (!(affectedChildren[i] instanceof ICompilationUnit)) {
				processDelta(affectedChildren[i]);
			}
		}
	}
	private void postAdd(final Object child, final Object parent) {
		postRunnable(new Runnable() {
			public void run() {
				Control ctrl = fViewer.getControl();
				if (ctrl != null && !ctrl.isDisposed()) {
					((TreeViewer)fViewer).add(parent, child);