Bug 64897 packages view: not updated when project source folders change [browsing]
RC1 - browsing perspective - smoke test scenario... - import junit.zip into the previously not existing folder 'src' -> packages view shows a number of packages src.junit.framework... with errors - go to the project properties, source page - add 'src' as source folder, accept when asked to remove the project root as source folder - press OK -> the error marks in the packages view are removed -> the packages src... are still visible in the packages view -> they are only removed upon a selection change in the "projects" view
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/PackagesViewFlatContentProvider.java
import org.eclipse.jface.viewers.TableViewer;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IJavaElementDelta;
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.core.IPackageFragment;
import org.eclipse.jdt.core.IPackageFragmentRoot;
import org.eclipse.jdt.core.JavaModelException;
/**
 * Table content provider for the hierarchical layout in the packages view.
 * <p> 
 * XXX: The standard Java browsing part content provider needs and calls
 * the browsing part/view. This class currently doesn't need to do so
 * but might be required to later.
 * </p>
 */
class PackagesViewFlatContentProvider extends LogicalPackagesProvider implements IStructuredContentProvider {
	PackagesViewFlatContentProvider(StructuredViewer viewer) {
		super(viewer);
	}
	
	/*
	 * @see org.eclipse.jface.viewers.ITreeContentProvider#getChildren(java.lang.Object)
	 */
	public Object[] getChildren(Object parentElement) {
		
		if(parentElement instanceof IJavaElement){
			IJavaElement element= (IJavaElement) parentElement;
			int type= element.getElementType();
			
			try {