Bug 169591 [Common Navigator] Show In fails for editor inputs
The show(ShowInContext) method for CommonNavigator only considers the selection of the context. When Show In Project Explorer is performed from an editor, the selection is empty and the input is provided. Unfortunately, this is problematic, as the show-in target needs to adapt the input to an IFile so this will probably need to have some sort of extension so that the Project Explorer can plug-in the proper support.
bundles/org.eclipse.ui.navigator/src/org/eclipse/ui/navigator/CommonNavigator.java
import org.eclipse.ui.IMemento;
import org.eclipse.ui.ISaveablePart;
import org.eclipse.ui.ISaveablesLifecycleListener;
import org.eclipse.ui.ISaveablesSource;
import org.eclipse.ui.IViewSite;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.Saveable;
import org.eclipse.ui.SaveablesLifecycleEvent;
import org.eclipse.ui.actions.ActionGroup;
import org.eclipse.ui.internal.navigator.CommonNavigatorActionGroup;
import org.eclipse.ui.internal.navigator.CommonNavigatorManager;
import org.eclipse.ui.part.ISetSelectionTarget;
import org.eclipse.ui.part.IShowInTarget;
import org.eclipse.ui.part.ShowInContext;
import org.eclipse.ui.part.ViewPart;
/**
 * <p>
 * This class provides the IViewPart for the Common Navigator framework in the
 * Eclipse workbench. This class also serves as the backbone for navigational
 * viewers. The following types are used by this class to render the Common
 * Navigator:
 * <ul>
 * <li>
 * <p>
 * {@link org.eclipse.ui.navigator.CommonViewer}: The viewer that renders the
 * extensible tree. Creates and manages the lifecylce of the Navigator Content
 * Service (described below).
 * </p>
 * </li>
 * <li>