7

JFileChooser, at least under OS X, produces a very half-baked open dialog that doesn't support things like typing in the start of a file name to select it or disclosure triangles.

Does anyone know of a 3rd-party alternative that has a more fully-featured behaviour? Ideally, I'd like one for each major platform. I'm aware of XFileDialog for windows, but what about Mac and Linux/Unix?

In comparison:

Java's file chooser

OS X's file chooser

Zarkonnen
  • 22,200
  • 14
  • 65
  • 81

2 Answers2

3

Does java.awt.FileDialog do what you want, you may need to specify

System.setProperty("apple.awt.fileDialogForDirectories", "true");

if you want to get a directory though

vickirk
  • 3,979
  • 2
  • 22
  • 37
  • Oh, it does what I want so very nearly, but it doesn't seem to support multiple selection! – Zarkonnen Mar 21 '11 at 11:59
  • Sorry, you are out of luck for multiple selection, not that it helps you now java 1.7 adds setMultipleMode to FileDialog :-( Of course that code is open sourced in open jdk, maybe you could repackage it and bundle it with your app as long as your license is compatible (and assuming it has been updated for MAC OS, probably not). – vickirk Mar 21 '11 at 13:27
1

I found the Quaqua Look & Feel, which upgrades JFileChooser a bit - it's still not perfect, but it's arguably better.

Zarkonnen
  • 22,200
  • 14
  • 65
  • 81