public static void moveCell(final RadContainer container, final boolean isRow, final int sourceCell, int targetCell) {
    if (targetCell == sourceCell || targetCell == sourceCell+1) return;
    // if column moved to left - components inbetween move to right, and vice versa
    int delta = (sourceCell > targetCell) ? 1 : -1;
    int startCell = Math.min(sourceCell, targetCell);
    int endCell = Math.max(sourceCell, targetCell);
    if (sourceCell < targetCell) targetCell--;
    for(RadComponent c: container.getComponents()) {
      GridConstraints constraints = c.getConstraints();
      GridConstraints oldConstraints = (GridConstraints) constraints.clone();
      final int aCell = constraints.getCell(isRow);
      if (aCell == sourceCell) {
        constraints.setCell(isRow, targetCell);
      }
      else if (aCell >= startCell && aCell < endCell) {
        constraints.setCell(isRow, aCell + delta);
      }
      c.fireConstraintsChanged(oldConstraints);
    }
  }
public static void moveCell(final RadContainer container, final boolean isRow, final int sourceCell, int targetCell)