Bug 78733 ITypeHierarchyViewPart.setInputElement() does not select methods
If you pass an IMethod to the ITypeHierarchyViewPart.setInputElement (IJavaElement element) it does not select the method like the normal "F4" in the Java Editor does. My use case is as follows: Properties p = new Properties(); p.getProperty("foo"); Where Properties is java.util.Properties and you try to "F4" (an action implemented using ITypeHierarchyViewPart) the getProperty method. I'm using Eclipse 3.0.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
for (int i= 0; i < fAllViewers.length; i++) {
			addDragAdapters(fAllViewers[i], ops, transfers);
			addDropAdapters(fAllViewers[i], ops | DND.DROP_DEFAULT, transfers);
		}	
		addDragAdapters(fMethodsViewer, ops, transfers);
		
		DropTarget dropTarget = new DropTarget(fNoHierarchyShownLabel, ops | DND.DROP_DEFAULT);
		dropTarget.setTransfer(transfers);
		dropTarget.addDropListener(new TypeHierarchyTransferDropAdapter(this, fAllViewers[0]));
	}
	
	private void addDropAdapters(AbstractTreeViewer viewer, int ops, Transfer[] transfers){
		TransferDropTargetListener[] dropListeners= new TransferDropTargetListener[] {
			new TypeHierarchyTransferDropAdapter(this, viewer)
		};
		viewer.addDropSupport(ops, transfers, new DelegatingDropAdapter(dropListeners));
	}
	private void addDragAdapters(StructuredViewer viewer, int ops, Transfer[] transfers) {
		TransferDragSourceListener[] dragListeners= new TransferDragSourceListener[] {
			new SelectionTransferDragAdapter(viewer)
		};
		viewer.addDragSupport(ops, transfers, new JdtViewerDragAdapter(viewer, dragListeners));
	}	
			
	/**
	 * Returns the inner component in a workbench part.
	 * @see IWorkbenchPart#createPartControl(Composite)
	 */
	public void createPartControl(Composite container) {
		fParent= container;