JDK-5067819 : JFileChooser - can't clear selection to select parent directory
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 5.0
  • Priority: P4
  • Status: Closed
  • Resolution: Won't Fix
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2004-06-24
  • Updated: 2019-12-17
  • Resolved: 2019-12-17
Related Reports
Relates :  
Description
JDK 1.5.0-beta3-b56

1) Invoke JFileChooser
2) Click to the are where are no any files in the list (out of the file list scope)
3) ERROR in Windows L&F
The selection is cleared only in the list, not in the "File Name" edit box -- it is only visualization change which doesn't affect file/directory choosen.

Notice:
It's really very annoying for the users (especially when they want to choose a directory) and for developers to provide non-standard file chooser behavior to their customers.

4) (minor) ERROR in Metal L&F
The mouse event is applied to the "nearest" file - could behave as Windows L&F.
###@###.### 2004-06-25

Comments
EVALUATION The behavior that the submitter describes has already been implemented for the Windows Look and Feel under bug number 4835633. The JFileChooser should behave exactly like Windows under the Windows Look and Feel. At the time, it was decided that Metal Look and Feel would be left as-is. Perhaps we can re-visit this decision. ###@###.### 2004-06-24 Name: sh120115 Date: 07/07/2004 My initial evaluation refers to the submitter's original description, which they have since changed. Previously, the complaint was that we don't clear the selection in JFileChooser when clicking in an area with no file. Now the complaint is that we only clear the selection in the list and not in the text field. I don't believe this is a bug. My testing of the native Windows file chooser shows that it has the same behavior. Therefore, the only issue to be addressed here is the question of whether or not Metal's JFileChooser should act more like the Windows file chooser. ###@###.### 2004-07-07 ======================================================================
07-07-2004