forked from LupusNobilis/java-org.hwo.ui
WIP161202
parent
8e56f66659
commit
dff6b32213
|
@ -438,10 +438,7 @@ public class TableMapper extends AbstractTableModel
|
|||
for (ColumnInfo ci: p_columns){
|
||||
minwidth += ci.getWidth();
|
||||
}
|
||||
|
||||
//jTable.setMinSize(new Dimension(minwidth, 24));
|
||||
jTable.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
|
||||
|
||||
|
||||
}
|
||||
|
||||
public boolean isSortingEnabled() {
|
||||
|
@ -754,7 +751,12 @@ public class TableMapper extends AbstractTableModel
|
|||
} else {
|
||||
this.p_rows.add(row);
|
||||
fireTableRowsInserted(this.p_rows.indexOf(row),this.p_rows.indexOf(row));
|
||||
};
|
||||
};
|
||||
|
||||
if (TableMapperValue.class.isInstance(row)){
|
||||
TableMapperValue tmv = (TableMapperValue)row;
|
||||
tmv.assignTableMapper(this);
|
||||
}
|
||||
}
|
||||
|
||||
public void addRows(Object[] rows,Object before){
|
||||
|
@ -788,7 +790,7 @@ public class TableMapper extends AbstractTableModel
|
|||
{
|
||||
if (TableMapperValue.class.isInstance(row)){
|
||||
TableMapperValue tmv = (TableMapperValue)row;
|
||||
tmv.assignTableMapper(this);
|
||||
tmv.unassignTableMapper(this);
|
||||
}
|
||||
this.p_rows.remove(index);
|
||||
fireTableRowsDeleted(index, index);
|
||||
|
@ -964,9 +966,12 @@ public class TableMapper extends AbstractTableModel
|
|||
|
||||
public void signalRowChanged(Object row){
|
||||
if (p_rows.contains(row)){
|
||||
fireTableRowsUpdated(p_rows.indexOf(row), p_rows.indexOf(row));
|
||||
}
|
||||
log(DEBUGDETAIL,"TableMapper: signalRowChanged(): received signal for existing row");
|
||||
|
||||
fireTableRowsUpdated(p_rows.indexOf(row), p_rows.indexOf(row));
|
||||
} else {
|
||||
log(ERROR,"TableMapper: signalRowChanged(): received signal for non-existing row");
|
||||
}
|
||||
}
|
||||
|
||||
class TableCellRenderer extends DefaultTableCellRenderer {
|
||||
|
|
Loading…
Reference in New Issue