Fix bug - manufacturers cannot be ordered with AlphanumComparator because they are not Strings. Instead just use the default sorting provided.

This commit is contained in:
Kevin Ruland 2012-09-18 01:35:28 +00:00
parent ffdedd2b95
commit fc8c771548

View File

@ -114,7 +114,7 @@ public class ComponentPresetTable extends JTable {
columns[index] = new ComponentPresetTableColumn.Parameter(key,index);
}
tableColumnModel.addColumn(columns[index]);
if ( key == ComponentPreset.MANUFACTURER || key == ComponentPreset.PARTNO ) {
if ( key == ComponentPreset.PARTNO ) {
sorter.setComparator(index, new AlphanumComparator());
} else if ( key.getType() == Double.class ) {
sorter.setComparator(index, new Comparator<Value>() {