Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled
I have the same problem with 0.9.2. The following code works when filters are disabled but throws an ArrayBlablabaException when enabled and one of the list items are selected.
[code]
public class ListMess {
public static void main(String[] args) {
final DefaultListModel model = new DefaultListModel();
model.addElement("What");
model.addElement("the");
model.addElement("bleep");
model.addElement("is");
model.addElement("wrong");
final JXList list = new JXList(model);
list.setFilterEnabled(true);
list.setFilters( new FilterPipeline(new ShuttleSorter()));
list.addListSelectionListener( new ListSelectionListener() {
public void valueChanged(ListSelectionEvent e) {
Object item = list.getSelectedValue();
model.removeElement( item );
}
});
JPanel panel = new JPanel( new BorderLayout() );
panel.add( list );
JFrame frame = new JFrame();
frame.setContentPane( panel );
frame.pack();
frame.setVisible( true );
}
}
[/code]
Is this bug related to issue #2? Didn't want to create an extra entry in the issue tracker.
Fondest regards,
Erik
[Message sent by forum member 'clandestino057' (clandestino057)]
http://forums.java.net/jive/thread.jspa?messageID=272957
---------------------------------------------------------------------
To unsubscribe, e-mail: [jdnc-unsubscribe@masked-domain]
For additional commands, e-mail: [jdnc-help@masked-domain]
Other messages in this topic
| Sender | Date sent | Subject |
| [jdnc-interest@masked-domain] | Tue, 27 May 2008 10:55:31 PDT | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| Kleopatra [fastegal@masked-domain] | Thu, 15 May 2008 18:22:05 +0200 | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| [jdnc-interest@masked-domain] | Thu, 15 May 2008 09:03:53 PDT | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| Kleopatra [fastegal@masked-domain] | Fri, 09 May 2008 12:39:45 +0200 | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| Kleopatra [fastegal@masked-domain] | Fri, 09 May 2008 09:58:46 +0200 | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| Kleopatra [fastegal@masked-domain] | Fri, 09 May 2008 09:47:49 +0200 | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| [jdnc-interest@masked-domain] | Thu, 08 May 2008 11:29:03 PDT | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| [jdnc-interest@masked-domain] | Thu, 08 May 2008 10:56:14 PDT | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| Kleopatra [fastegal@masked-domain] | Tue, 06 May 2008 17:23:46 +0200 | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| [jdnc-interest@masked-domain] | Tue, 06 May 2008 05:52:09 PDT | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| Kleopatra [fastegal@masked-domain] | Tue, 06 May 2008 09:51:39 +0200 | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| [jdnc-interest@masked-domain] | Mon, 05 May 2008 20:10:24 PDT | Re: ArrayIndexOutOfBoundsException in JXList when FilterEnabled |
| [jdnc-interest@masked-domain] | Mon, 05 May 2008 20:08:52 PDT | ArrayIndexOutOfBoundsException in JXList when FilterEnabled |