Search in sources :

Example 1 with HasRowDragRestrictions

use of org.kie.workbench.common.dmn.client.widgets.grid.model.HasRowDragRestrictions in project kie-wb-common by kiegroup.

the class DelegatingGridWidgetDndMouseMoveHandler method findMovableRows.

@Override
protected void findMovableRows(final GridWidget view, final double cx, final double cy) {
    super.findMovableRows(view, cx, cy);
    if (view instanceof HasRowDragRestrictions) {
        final HasRowDragRestrictions hasRowDragRestrictions = (HasRowDragRestrictions) view;
        if (!hasRowDragRestrictions.isRowDragPermitted(state)) {
            state.reset();
            layer.getViewport().getElement().getStyle().setCursor(state.getCursor());
        }
    }
}
Also used : HasRowDragRestrictions(org.kie.workbench.common.dmn.client.widgets.grid.model.HasRowDragRestrictions)

Aggregations

HasRowDragRestrictions (org.kie.workbench.common.dmn.client.widgets.grid.model.HasRowDragRestrictions)1