Search in sources :

Example 1 with NewBendpointDeleteCommand

use of org.knime.workbench.editor2.commands.NewBendpointDeleteCommand in project knime-core by knime.

the class ConnectionBendpointEditPolicy method getDeleteBendpointCommand.

/**
 * {@inheritDoc}
 */
protected Command getDeleteBendpointCommand(final BendpointRequest req) {
    // get the index of the bendpoint to delete
    int index = req.getIndex();
    ConnectionContainerEditPart editPart = (ConnectionContainerEditPart) getHost();
    WorkflowManager wfm = getWorkflowManager();
    return new NewBendpointDeleteCommand(editPart, wfm, index);
}
Also used : ConnectionContainerEditPart(org.knime.workbench.editor2.editparts.ConnectionContainerEditPart) WorkflowManager(org.knime.core.node.workflow.WorkflowManager) NewBendpointDeleteCommand(org.knime.workbench.editor2.commands.NewBendpointDeleteCommand) AbsoluteBendpoint(org.eclipse.draw2d.AbsoluteBendpoint) Point(org.eclipse.draw2d.geometry.Point) Bendpoint(org.eclipse.draw2d.Bendpoint)

Aggregations

AbsoluteBendpoint (org.eclipse.draw2d.AbsoluteBendpoint)1 Bendpoint (org.eclipse.draw2d.Bendpoint)1 Point (org.eclipse.draw2d.geometry.Point)1 WorkflowManager (org.knime.core.node.workflow.WorkflowManager)1 NewBendpointDeleteCommand (org.knime.workbench.editor2.commands.NewBendpointDeleteCommand)1 ConnectionContainerEditPart (org.knime.workbench.editor2.editparts.ConnectionContainerEditPart)1