Skip to content

Commit

Permalink
TableView do not reliably delete rows apache#3712, apache#3767
Browse files Browse the repository at this point in the history
  • Loading branch information
nadment committed Apr 7, 2024
1 parent cc0669d commit d89db9c
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions ui/src/main/java/org/apache/hop/ui/core/widget/TableView.java
Original file line number Diff line number Diff line change
Expand Up @@ -574,7 +574,7 @@ public void mouseDown(MouseEvent event) {
applyTextChange(activeTableItem, activeTableRow, activeTableColumn);
break;
case ColumnInfo.COLUMN_TYPE_CCOMBO:
applyComboChange(activeTableItem, activeTableRow, activeTableColumn);
applyComboChange(activeTableItem, activeTableRow, activeTableColumn);
break;
}
}
Expand Down Expand Up @@ -1753,6 +1753,9 @@ private void fireContentChangedListener(int rowNr, int colNr, String textData) {
}

private void applyComboChange(TableItem row, int rowNr, int colNr) {

System.out.println("Apply combo change "+activeTableRow);

String textData;
boolean usingVariables = columns[colNr - 1].isUsingVariables();
if (usingVariables) {
Expand All @@ -1768,9 +1771,9 @@ private void applyComboChange(TableItem row, int rowNr, int colNr) {
}
row.setText(colNr, textData);
if (usingVariables) {
comboVar.setVisible(false);
} else {
combo.setVisible(false);
safelyDisposeControl(comboVar);
} else {
safelyDisposeControl(combo);
}

String[] afterEdit = getItemText(row);
Expand Down Expand Up @@ -3431,6 +3434,7 @@ public void closeActiveButton() {
}

public void unEdit() {
System.out.println("unedit");
if (text != null && !text.isDisposed()) {
text.dispose();
text = null;
Expand Down

0 comments on commit d89db9c

Please sign in to comment.