Class BookmarkNavigator

    • Constructor Detail

      • BookmarkNavigator

        public BookmarkNavigator()
        Creates the bookmarks view.
    • Method Detail

      • createPartControl

        public void createPartControl​(Composite parent)
        Description copied from interface: IWorkbenchPart
        Creates the SWT controls for this workbench part.

        Clients should not call this method (the workbench calls this method when it needs to, which may be never).

        For implementors this is a multi-step process:

        1. Create one or more controls within the parent.
        2. Set the parent layout as needed.
        3. Register any global actions with the site's IActionBars.
        4. Register any context menus with the site.
        5. Register a selection provider with the site, to make it available to the workbench's ISelectionService (optional).
        Specified by:
        createPartControl in interface IWorkbenchPart
        Specified by:
        createPartControl in class WorkbenchPart
        parent - the parent control
      • dispose

        public void dispose()
        Description copied from class: WorkbenchPart
        The WorkbenchPart implementation of this IWorkbenchPart method disposes the title image loaded by setInitializationData. Subclasses may extend.
        Specified by:
        dispose in interface IWorkbenchPart
        dispose in class WorkbenchPart
      • getAdapter

        public <T> T getAdapter​(Class<T> adapterClass)
        Description copied from class: WorkbenchPart
        Returns an object which is an instance of the given class associated with this object. Returns null if no such object can be found.

        Clients may implement this method but should generally call Adapters.adapt(Object, Class, boolean) rather than invoking it directly. Subclasses may override this method (however, if they do so, they should invoke the method on their superclass to ensure that the Platform's adapter manager is consulted).

        Specified by:
        getAdapter in interface IAdaptable
        getAdapter in class WorkbenchPart
        Type Parameters:
        T - the class type
        adapterClass - the adapter class to look up
        a object of the given class, or null if this object does not have an adapter for the given class
      • init

        public void init​(IViewSite site,
                         IMemento memento)
                  throws PartInitException
        Description copied from interface: IViewPart
        Initializes this view with the given view site. A memento is passed to the view which contains a snapshot of the views state from a previous session. Where possible, the view should try to recreate that state within the part controls.

        This method is automatically called by the workbench shortly after the part is instantiated. It marks the start of the views's lifecycle. Clients must not call this method.

        Specified by:
        init in interface IViewPart
        init in class ViewPart
        site - the view site
        memento - the IViewPart state or null if there is no previous saved state
        PartInitException - if this view was not initialized successfully
      • initDragAndDrop

        protected void initDragAndDrop()
        Adds drag and drop support to the bookmark navigator.
      • setFocus

        public void setFocus()
        Description copied from interface: IWorkbenchPart
        Asks this part to take focus within the workbench. Parts must assign focus to one of the controls contained in the part's parent composite.

        Clients should not call this method (the workbench calls this method at appropriate times). To have the workbench activate a part, use IWorkbenchPage.activate(IWorkbenchPart) instead.

        Specified by:
        setFocus in interface IWorkbenchPart
        Specified by:
        setFocus in class WorkbenchPart