Bug 9112 goto type presents items not visible
stable 20020125 In the packages view Choose Go To > Type from the popup The resulting dialog displays things you cannot go to - it shows classes in referenced libraries even if you are not currenrtly showing referenced libraries - it shows classes not in your working set As a result if you pick that class nothing actually happens and you don't know why. Some options (food for thought): - filter the dialog (classes in current view vs. all classes) - let the user pick it then warn him its not in his current view and offer to change the view
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/packageview/GotoTypeAction.java
private PackageExplorerPart fPackageExplorer;
	
	GotoTypeAction(PackageExplorerPart part) {
		super();
		setText(PackagesMessages.getString("GotoType.action.label")); 
		setDescription(PackagesMessages.getString("GotoType.action.description")); 
		fPackageExplorer= part;
	}
	public void run() {
		Shell shell= JavaPlugin.getActiveWorkbenchShell();
		SelectionDialog dialog= null;
		try {
			dialog= JavaUI.createTypeDialog(shell, new ProgressMonitorDialog(shell),
				SearchEngine.createWorkspaceScope(), IJavaElementSearchConstants.CONSIDER_TYPES, false);
		} catch (JavaModelException e) {
			String title= PackagesMessages.getString("GotoType.dialog.title"); 
			String message= PackagesMessages.getString("GotoType.error.message"); 
			ExceptionHandler.handle(e, title, message);
			return;
		}
	
		dialog.setTitle(PackagesMessages.getString("GotoType.dialog.title")); 
		dialog.setMessage(PackagesMessages.getString("GotoType.dialog.message"));