Bug 157495 [Viewers] public subclasses of ViewerSorter should be changed to ViewerComparator
The following 3 classes in the ui should be changed to be subclasses of ViewerComparator: ResourceSorter WorkbenchViewerSorter FileViewerSorter This will involve deprecating old classes and methods, and adding new classes and methods for each of these classes and to classes that reference these sorter classes in their API.
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/navigator/ResourceNavigator.java
* @since 2.0
     */
    protected void editorActivated(IEditorPart editor) {
        if (!isLinkingEnabled()) {
            return;
        }
        IFile file = ResourceUtil.getFile(editor.getEditorInput());
        if (file != null) {
            ISelection newSelection = new StructuredSelection(file);
            if (getTreeViewer().getSelection().equals(newSelection)) {
                getTreeViewer().getTree().showSelection();
            } else {
                getTreeViewer().setSelection(newSelection, true);
            }
        }
    }
    /**
     * Called when the context menu is about to open.
     * Delegates to the action group using the viewer's selection as the action context.
     * @since 2.0
     */
    protected void fillContextMenu(IMenuManager menu) {
        IStructuredSelection selection = (IStructuredSelection) getViewer()
                .getSelection();
        getActionGroup().setContext(new ActionContext(selection));
        getActionGroup().fillContextMenu(menu);
    }
    /*
     * @see IResourceNavigatorPart
     * @since 2.0