Package org.eclipse.ui.internal.dialogs

Examples of org.eclipse.ui.internal.dialogs.ImportExportWizard


    public void run() {
        if (workbenchWindow == null) {
            // action has been disposed
            return;
        }
        ImportExportWizard wizard = new ImportExportWizard(ImportExportWizard.IMPORT);
        IStructuredSelection selectionToPass;
        // get the current workbench selection
        ISelection workbenchSelection = workbenchWindow.getSelectionService()
                .getSelection();
        if (workbenchSelection instanceof IStructuredSelection) {
            selectionToPass = (IStructuredSelection) workbenchSelection;
        } else {
            selectionToPass = StructuredSelection.EMPTY;
        }

        wizard.init(workbenchWindow.getWorkbench(), selectionToPass);
        IDialogSettings workbenchSettings = WorkbenchPlugin.getDefault()
                .getDialogSettings();
        IDialogSettings wizardSettings = workbenchSettings
                .getSection("ImportExportAction"); //$NON-NLS-1$
        if (wizardSettings == null) {
      wizardSettings = workbenchSettings
                    .addNewSection("ImportExportAction"); //$NON-NLS-1$
    }
        wizard.setDialogSettings(wizardSettings);
        wizard.setForcePreviousAndNextButtons(true);

        Shell parent = workbenchWindow.getShell();
        WizardDialog dialog = new WizardDialog(parent, wizard);
        dialog.create();
        dialog.getShell().setSize(
View Full Code Here


    public void run() {
        if (workbenchWindow == null) {
            // action has been disposed
            return;
        }
        ImportExportWizard wizard = new ImportExportWizard(ImportExportWizard.EXPORT);
        IStructuredSelection selectionToPass;
        // get the current workbench selection
        ISelection workbenchSelection = workbenchWindow.getSelectionService()
                .getSelection();
        if (workbenchSelection instanceof IStructuredSelection) {
            selectionToPass = (IStructuredSelection) workbenchSelection;
        } else {
            selectionToPass = StructuredSelection.EMPTY;
        }

        wizard.init(workbenchWindow.getWorkbench(), selectionToPass);
        IDialogSettings workbenchSettings = WorkbenchPlugin.getDefault()
                .getDialogSettings();
        IDialogSettings wizardSettings = workbenchSettings
                .getSection("ImportExportAction"); //$NON-NLS-1$
        if (wizardSettings == null) {
      wizardSettings = workbenchSettings
                    .addNewSection("ImportExportAction"); //$NON-NLS-1$
    }
        wizard.setDialogSettings(wizardSettings);
        wizard.setForcePreviousAndNextButtons(true);

        Shell parent = workbenchWindow.getShell();
        WizardDialog dialog = new WizardDialog(parent, wizard);
        dialog.create();
        dialog.getShell().setSize(
View Full Code Here

TOP

Related Classes of org.eclipse.ui.internal.dialogs.ImportExportWizard

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.