Search in sources :

Example 1 with WizardActionGroup

use of org.eclipse.ui.navigator.WizardActionGroup in project translationstudio8 by heartsome.

the class PortingActionProvider method init.

public void init(ICommonActionExtensionSite anExtensionSite) {
    Assert.isTrue(!disposed);
    if (anExtensionSite.getViewSite() instanceof ICommonViewerWorkbenchSite) {
        IWorkbenchWindow window = ((ICommonViewerWorkbenchSite) anExtensionSite.getViewSite()).getWorkbenchWindow();
        importAction = new ImportResourcesAction(window);
        importAction.setText(WorkbenchNavigatorMessages.PortingActionProvider_ImportResourcesMenu_label);
        exportAction = new ExportResourcesAction(window);
        exportAction.setText(WorkbenchNavigatorMessages.PortingActionProvider_ExportResourcesMenu_label);
        importWizardActionGroup = new WizardActionGroup(window, PlatformUI.getWorkbench().getImportWizardRegistry(), WizardActionGroup.TYPE_IMPORT, anExtensionSite.getContentService());
        exportWizardActionGroup = new WizardActionGroup(window, PlatformUI.getWorkbench().getExportWizardRegistry(), WizardActionGroup.TYPE_EXPORT, anExtensionSite.getContentService());
        contribute = true;
    }
}
Also used : IWorkbenchWindow(org.eclipse.ui.IWorkbenchWindow) ExportResourcesAction(org.eclipse.ui.actions.ExportResourcesAction) ImportResourcesAction(org.eclipse.ui.actions.ImportResourcesAction) WizardActionGroup(org.eclipse.ui.navigator.WizardActionGroup) ICommonViewerWorkbenchSite(org.eclipse.ui.navigator.ICommonViewerWorkbenchSite)

Aggregations

IWorkbenchWindow (org.eclipse.ui.IWorkbenchWindow)1 ExportResourcesAction (org.eclipse.ui.actions.ExportResourcesAction)1 ImportResourcesAction (org.eclipse.ui.actions.ImportResourcesAction)1 ICommonViewerWorkbenchSite (org.eclipse.ui.navigator.ICommonViewerWorkbenchSite)1 WizardActionGroup (org.eclipse.ui.navigator.WizardActionGroup)1