if (columnGroupMoved) {
// If the next entry is a column group - move past it.
if (columnGroupModel != null
&& columnGroupModel
.isPartOfAGroup(nextColumnEntryIndex)) {
ColumnGroup nextColumnGroup = columnGroupModel
.getColumnGroupByIndex(nextColumnEntryIndex);
toPositions.add(lastPositionInGroup
+ nextColumnGroup.getSize());
} else {
toPositions.add(lastPositionInGroup + 1);
}
} else {
// If is last member of the unbreakable group, can't
// move down i.e. out of the group
if (columnGroupModel != null
&& columnGroupModel
.isPartOfAnUnbreakableGroup(columnEntryIndex)
&& !ColumnGroupUtils.isInTheSameGroup(
columnEntryIndex, nextColumnEntryIndex,
columnGroupModel)) {
return;
}
// If next entry is an unbreakable column group - move
// past it
if (columnGroupModel != null
&& columnGroupModel
.isPartOfAnUnbreakableGroup(nextColumnEntryIndex)
&& !ColumnGroupUtils.isInTheSameGroup(
columnEntryIndex, nextColumnEntryIndex,
columnGroupModel)) {
ColumnGroup nextColumnGroup = columnGroupModel
.getColumnGroupByIndex(nextColumnEntryIndex);
toPositions.add(lastPositionInGroup
+ nextColumnGroup.getSize());
} else {
toPositions.add(lastPositionInGroup + 1);
}
}
}