The question is: how to detect the old and new indeces in the ListSelectionEvent event handler? The answer is:
log("valueChanged from "
+ (instruments.getSelectedIndex() == e.getLastIndex()
? e.getFirstIndex()
: e.getLastIndex())
+ " to " + instruments.getSelectedIndex());
No comments:
Post a Comment