Hi all,
i have tested etienne's SortedTableModel from the code
community.
During testing this model i "think" i found a bug which already
has been reported and should have been solved.
I have created a class extending UneditableDefaultTableModel and
have implemented all necessary methods inside (getvalueAt,
getRowCount...).
After that i have adapted the UneditableDefaultTableModel to the
SortedTableModel :
private MagazineModelUneditable
getMagazineModelUneditable() {
if (magazineModelUneditable == null) {
magazineModelUneditable = new
MagazineModelUneditable();
}
return magazineModelUneditable;
}
private SortedTableModel getSortedTableModel() {
if (sortedTableModel == null) {
sortedTableModel = new
SortedTableModel(getMagazineModelUneditable());
ULCListSelectionModel selectionModel =
ulcTable.getSelectionModel();
ulcTable.getTableHeader().addActionListener(new
SortTableColumnHandler(sortedTableModel, selectionModel));
}
return sortedTableModel;
}
Now i have set the SortedTableModel as model for my table:
ulcTable.setModel(getSortedTableModel());
If i run now my application, the headericons will not be
repainted.
If i use the workaround:
http://lists.canoo.com/mailman/private/ulc-developer/2005/002922.html
it works!!
Does anybody know why?? Is this still a bug or have i made an
error including the sorted-table-model?
thx a lot
marco
_______________________________________________
ULC-developer mailing list
[email protected]
http://lists.canoo.com/mailman/listinfo/ulc-developer