JFileChooser Question
I have a JFileChooser that allows the user to select multiple image files to create a slideshow. I want to show the files in the order that the user selected them with the JFileChooser. The problem is that the JFileChooser returns the files via the getSelectedFiles() in sorted order, sorted by file name, and I need to know the order that the user selcted the files in. Is there any way to gather this information? Any help is appreciated, thanks for your time.
[469 byte] By [
Malcolm_Fa] at [2007-11-27 5:08:58]

That would be a neat trick. At the very least I would think that you would have to extend JFileChooser and intercept the events firing when the user selects a file to keep up with which one was added to the selected collection when. I'm not even sure it's possible to get hold of the things you would need to to make it work.
It's a very neat idea though.
PS.
Typically file choosers don't provide this information, so you would be making a user interface innovation. This is often a bad idea as users know how file choosers work and don't care to be surprised by innovations.
Besides, your question is not completely well-defined. It's possible to select a group of files all at once using shift-click (or some similar keystroke). And then it's possible to unselect something in the middle of that group using control-click (or similar).
That's a good idea. If you're going to process the files in a certain order, presumably because it makes a difference which order you process them in, then it would help to give the user visual feedback about that order.