this.fif.getEditor().setItem(value.toString());
return this.fif;
}
for (int i = 0; i < this.fif.getModel().getSize(); i++)
{
ListElement element = (ListElement) this.fif.getModel().getElementAt(i);
if (value instanceof Number || value instanceof IntegerData) {
int num;
if (value instanceof Number) {
num = ((Number)value).intValue();
}
else {
num = ((IntegerData)value).intValue();
}
if (num == element.getIntegerValue()) {
this.fif.getModel().setSelectedItem(element);
return this.fif;
}
}
else {
if (value != null) {
String aString = value.toString();
if (aString.equals(element.getTextValue().toString())) {
this.fif.getModel().setSelectedItem(element);
return this.fif;
}
}
}
}
// TF:3/11/07: During the creation of the table editor we should not fire after value change
// events, yet setting the text value or the selected item will have this side effect. We
// must disable this first.
try {
EventManager.disableEventPosting();
if (this.fif.getModel().getSize() > 0 && !this.fif.isEditable()) {
ListElement element = (ListElement)this.fif.getModel().getElementAt(0);
table.getModel().setValueAt(this.getListElementValue(element),row, column);
this.fif.setSelectedIndex(0);
} else if (value != null){
String aString = value.toString();
this.fif.getModel().setSelectedItem(aString);