Search in sources :

Example 1 with MoveRowsCommand

use of org.kie.workbench.common.dmn.client.commands.expressions.types.context.MoveRowsCommand in project kie-wb-common by kiegroup.

the class ContextGridData method moveRowsTo.

@Override
public void moveRowsTo(final int index, final List<GridRow> rows) {
    expression.ifPresent(context -> {
        final AbstractCanvasHandler handler = (AbstractCanvasHandler) sessionManager.getCurrentSession().getCanvasHandler();
        final MoveRowsCommand command = new MoveRowsCommand(context, delegate, index, rows, canvasOperation);
        if (isAllowed(sessionCommandManager.allow(handler, command))) {
            sessionCommandManager.execute(handler, command);
        }
    });
}
Also used : MoveRowsCommand(org.kie.workbench.common.dmn.client.commands.expressions.types.context.MoveRowsCommand) AbstractCanvasHandler(org.kie.workbench.common.stunner.core.client.canvas.AbstractCanvasHandler)

Aggregations

MoveRowsCommand (org.kie.workbench.common.dmn.client.commands.expressions.types.context.MoveRowsCommand)1 AbstractCanvasHandler (org.kie.workbench.common.stunner.core.client.canvas.AbstractCanvasHandler)1