/** * <p> * Constructs and returns an instance of {@link CommonViewer}. The ID of * the Eclipse view part will be used to create the viewer. The ID is * important as some extensions indicate they should only be used with a * particular viewer ID. * <p> * * @param aParent * A composite parent to contain the Common Viewer * @return An initialized instance of CommonViewer */ protected CommonViewer createCommonViewer(Composite aParent) { CommonViewer aViewer = new CommonViewer(getViewSite().getId(), aParent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL); initListeners(aViewer); aViewer.getNavigatorContentService().restoreState(memento); return aViewer; }
commonViewer.getNavigatorContentService().restoreState(memento);