Package org.eclipse.ui.commands

Examples of org.eclipse.ui.commands.IWorkbenchCommandSupport


        if (enabled) {
            fViewer.updateViewerColors();
            fViewer.getTextWidget().setFocus();

            IWorkbench workbench = PlatformUI.getWorkbench();
            IWorkbenchCommandSupport commandSupport = workbench.getCommandSupport();
            commandSupport.addHandlerSubmission(submission);
        } else {
            Color color = fViewer.getControl().getDisplay().getSystemColor(SWT.COLOR_WIDGET_BACKGROUND);
            fViewer.getTextWidget().setBackground(color);
            IWorkbench workbench = PlatformUI.getWorkbench();
            IWorkbenchCommandSupport commandSupport = workbench.getCommandSupport();
            commandSupport.removeHandlerSubmission(submission);
        }
        valueChanged();
    }
View Full Code Here


    }

    public void dispose() {
        if (fViewer.isEditable()) {
            IWorkbench workbench = PlatformUI.getWorkbench();
            IWorkbenchCommandSupport commandSupport = workbench.getCommandSupport();
            commandSupport.removeHandlerSubmission(submission);
        }
        fViewer.getDocument().removeDocumentListener(fDocumentListener);
        fViewer.dispose();
    }
View Full Code Here

TOP

Related Classes of org.eclipse.ui.commands.IWorkbenchCommandSupport

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.