Search in sources :

Example 1 with ReconfigureMetaNodeWizard

use of org.knime.workbench.editor2.meta.ReconfigureMetaNodeWizard in project knime-core by knime.

the class MetaNodeReconfigureAction method runOnNodes.

/**
 * {@inheritDoc}
 */
@Override
public void runOnNodes(final NodeContainerEditPart[] nodeParts) {
    if (nodeParts.length < 1) {
        return;
    }
    NodeContainerEditPart ep = nodeParts[0];
    WorkflowManager metanode = Wrapper.unwrapWFM(ep.getNodeContainer());
    if (!metanode.unlock(new GUIWorkflowCipherPrompt())) {
        return;
    }
    ReconfigureMetaNodeWizard wizard = new ReconfigureMetaNodeWizard(ep.getViewer(), metanode);
    WizardDialog dlg = new WizardDialog(Display.getCurrent().getActiveShell(), wizard);
    dlg.create();
    dlg.open();
}
Also used : NodeContainerEditPart(org.knime.workbench.editor2.editparts.NodeContainerEditPart) WorkflowManager(org.knime.core.node.workflow.WorkflowManager) ReconfigureMetaNodeWizard(org.knime.workbench.editor2.meta.ReconfigureMetaNodeWizard) GUIWorkflowCipherPrompt(org.knime.workbench.editor2.editparts.GUIWorkflowCipherPrompt) WizardDialog(org.eclipse.jface.wizard.WizardDialog)

Aggregations

WizardDialog (org.eclipse.jface.wizard.WizardDialog)1 WorkflowManager (org.knime.core.node.workflow.WorkflowManager)1 GUIWorkflowCipherPrompt (org.knime.workbench.editor2.editparts.GUIWorkflowCipherPrompt)1 NodeContainerEditPart (org.knime.workbench.editor2.editparts.NodeContainerEditPart)1 ReconfigureMetaNodeWizard (org.knime.workbench.editor2.meta.ReconfigureMetaNodeWizard)1