|
|
|
@ -431,7 +431,7 @@ public class SmartInsertDBManipulationPane extends DBManipulationPane {
|
|
|
|
|
if (oriCellSelection != null && isSameStartPoint(cellselection, oriCellSelection)) { |
|
|
|
|
dealDragSelection(add, cellselection, newValue); |
|
|
|
|
} else if (cellselection.getSelectedType() == CellSelection.CHOOSE_ROW || cellselection.getSelectedType() == CellSelection.CHOOSE_COLUMN) { |
|
|
|
|
dealSelectColRow(add, cellselection); |
|
|
|
|
dealSelectColRow(add, cellselection, newValue); |
|
|
|
|
} else { |
|
|
|
|
ColumnRow columnRow = ColumnRow.valueOf(cellselection.getColumn(), cellselection.getRow()); |
|
|
|
|
String allColumnRow = newValue.toString(); |
|
|
|
@ -503,12 +503,15 @@ public class SmartInsertDBManipulationPane extends DBManipulationPane {
|
|
|
|
|
return cs1.getColumn() == cs2.getColumn() && cs1.getRow() == cs2.getRow(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void dealSelectColRow(ColumnRowGroup add, CellSelection se) { |
|
|
|
|
private void dealSelectColRow(ColumnRowGroup add, CellSelection se, ColumnRowGroup newValue) { |
|
|
|
|
int c = se.getColumn(), cs = se.getColumnSpan(), |
|
|
|
|
r = se.getRow(), rs = se.getRowSpan(); |
|
|
|
|
for (int i = 0; i < cs; i++) { |
|
|
|
|
for (int j = 0; j < rs; j++) { |
|
|
|
|
add.addColumnRow(ColumnRow.valueOf(c + i, r + j)); |
|
|
|
|
ColumnRow columnRow = ColumnRow.valueOf(c + i, r + j); |
|
|
|
|
if (!newValue.contains(columnRow)) { |
|
|
|
|
add.addColumnRow(columnRow); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|