{
JList4j list = (JList4j) event.getSource();
// Get index of item clicked
int index = list.locationToIndex(event.getPoint());
JCheckListItem item = (JCheckListItem) list.getModel().getElementAt(index);
// Toggle selected state
item.setSelected(!item.isSelected());