Bug 3733 'close project' not available in the package view (1GEHFLT)
AK (5/29/01 12:05:55 PM) should the 'close project' action be available also in the package view? NOTES: EG (5/29/01 5:31:26 PM) not for June EG (7/12/01 2:23:28 PM) this requires JavaModel support so that closed projects show up in the UI. Otherwise closing a project makes it disappear.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
*/
	protected static IJavaElement getWorkingCopy(IJavaElement input) {
		try {
			if (input instanceof ICompilationUnit)
				return ((ICompilationUnit)input).findSharedWorkingCopy(JavaUI.getBufferFactory());
			else
				return EditorUtility.getWorkingCopy(input, false);
		} catch (JavaModelException ex) {
		}
		return null;
	}
	/**
	 * Returns the original element from which the specified working copy
	 * element was created from. This is a handle only method, the
	 * returned element may or may not exist.
	 * 
	 * @param	workingCopy the element for which to get the original
	 * @return the original Java element or <code>null</code> if this is not a working copy element
	 */
	protected static IJavaElement getOriginal(IJavaElement workingCopy) {
		ICompilationUnit cu= getCompilationUnit(workingCopy);
		if (cu != null)
			return ((IWorkingCopy)cu).getOriginal(workingCopy);
		return null;
	}
	/**
	 * Returns the compilation unit for the given java element.
	 * 
	 * @param	element the java element whose compilation unit is searched for
	 * @return	the compilation unit of the given java element