Bug 30291 SearchUsagesInFileAction should show dialog in case of failures
Build I20030122 SearchUsagesInFileAction should show a dialog in failure/error cases (e.g. code resolve fails).
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/search/SearchUsagesInFileAction.java
public void searchFinished(final ISearchResultView view) {
		if (view != null) 
			view.searchFinished();
	}
	public IRunnableWithProgress getNullOperation() {
		return new IRunnableWithProgress() {
			public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
			}
		};
	}
	
	private String getName(Name name) {
		IDocument document= getDocument();
		String result= ""; 
		try {
			result= document.get(name.getStartPosition(), name.getLength());
		} catch (BadLocationException e) {
		}
		return result;
	}
		
	private IResource getResource(IJavaElement element) throws JavaModelException {
		if (element instanceof ICompilationUnit) {
			ICompilationUnit cu= (ICompilationUnit)element;
			if (cu.isWorkingCopy()) {
				IJavaElement original= cu.getOriginalElement();
				return original.getUnderlyingResource();
			}
			return cu.getUnderlyingResource();
		}