Package org.eclipse.ui

Examples of org.eclipse.ui.IPartListener


        update(CoolBarItem.ATTACHMENTS, selection, part, false);
      }
    };

    /* Part Listener across the Workbench */
    final IPartListener partListener = new IPartListener() {
      public void partOpened(IWorkbenchPart part) {
        if (part instanceof IEditorPart) {
          update(CoolBarItem.CLOSE, null, part, false);
          update(CoolBarItem.CLOSE_OTHERS, null, part, false);
          update(CoolBarItem.CLOSE_ALL, null, part, false);
View Full Code Here


     
      // get user preference
      IPreferenceStore store = EclipseEmmetPlugin.getDefault().getPreferenceStore();
      setEnabled(store.getBoolean(PreferenceConstants.P_TAB_EXPAND));
     
      page.addPartListener(new IPartListener() {
       
        @Override
        public void partOpened(IWorkbenchPart part) {
          if (isEnabled())
            install(part);
View Full Code Here

        final IHandlerService handlerService = (IHandlerService) site
                .getService(IHandlerService.class);
        handlerService.activateHandler(
                IWorkbenchCommandConstants.NAVIGATE_TOGGLE_LINK_WITH_EDITOR,
                new ActionHandler(fToggleLinkingAction));
        fPartListener = new IPartListener() {

            @Override
            public void partOpened(final IWorkbenchPart part) {
                addFilters(); // JC borde filter-metoden ovan r�cka?
            }
View Full Code Here

            }
        };
    }

    private void initMapEditorListener() {
        listenerMapEditor = new  IPartListener() {
            private IWorkbenchPart currentPart;

            public void partActivated(IWorkbenchPart part) {
                if (part == currentPart)
                    return;
View Full Code Here

     * Notifies the listener that a part has been activated.
     */
    public void firePartActivated(final IWorkbenchPart part) {
        Object[] array = getListeners();
        for (int i = 0; i < array.length; i++) {
            final IPartListener l = (IPartListener) array[i];
            fireEvent(new SafeRunnable() {
                public void run() {
                    l.partActivated(part);
                }
            }, l, part, "activated::"); //$NON-NLS-1$
        }
    }
View Full Code Here

     * Notifies the listener that a part has been brought to top.
     */
    public void firePartBroughtToTop(final IWorkbenchPart part) {
        Object[] array = getListeners();
        for (int i = 0; i < array.length; i++) {
            final IPartListener l = (IPartListener) array[i];
            fireEvent(new SafeRunnable() {
                public void run() {
                    l.partBroughtToTop(part);
                }
            }, l, part, "broughtToTop::"); //$NON-NLS-1$
        }
    }
View Full Code Here

     * Notifies the listener that a part has been closed
     */
    public void firePartClosed(final IWorkbenchPart part) {
        Object[] array = getListeners();
        for (int i = 0; i < array.length; i++) {
            final IPartListener l = (IPartListener) array[i];
            fireEvent(new SafeRunnable() {
                public void run() {
                    l.partClosed(part);
                }
            }, l, part, "closed::"); //$NON-NLS-1$
        }
    }
View Full Code Here

     * Notifies the listener that a part has been deactivated.
     */
    public void firePartDeactivated(final IWorkbenchPart part) {
        Object[] array = getListeners();
        for (int i = 0; i < array.length; i++) {
            final IPartListener l = (IPartListener) array[i];
            fireEvent(new SafeRunnable() {
                public void run() {
                    l.partDeactivated(part);
                }
            }, l, part, "deactivated::"); //$NON-NLS-1$
        }
    }
View Full Code Here

     * Notifies the listener that a part has been opened.
     */
    public void firePartOpened(final IWorkbenchPart part) {
        Object[] array = getListeners();
        for (int i = 0; i < array.length; i++) {
            final IPartListener l = (IPartListener) array[i];
            fireEvent(new SafeRunnable() {
                public void run() {
                    l.partOpened(part);
                }
            }, l, part, "opened::"); //$NON-NLS-1$
        }
    }
View Full Code Here

        currentPart = ((MultiPageEditorSite) site).getMultiPageEditor();
      } else {
        currentPart = site.getPart();
      }

      partListener = new IPartListener() {
        public void partActivated(IWorkbenchPart part) {
        }

        public void partBroughtToTop(IWorkbenchPart part) {
        }
View Full Code Here

TOP

Related Classes of org.eclipse.ui.IPartListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.