JDK-6493523 : JFileChooser: Problems with "My Documents" folder
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 6,6u2
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2006-11-14
  • Updated: 2011-03-09
  • Resolved: 2011-03-08
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
6u10Fixed 7 b15Fixed
Related Reports
Duplicate :  
On XP:

- Launch JFileChooser with Windows L&F
- In the dropdown, select C:
- In the file list, double click "Documents and Settings"
- In the file list, double click your username

Problem 1) Notice that the "My Documents" folder has a distinguishable icon (different than a regular folder). With the native JFileChooser, it doesn't in this view.

- Double click "My Documents"

Problem 2) Look in the dropdown. It shows the wrong location for "My Documents". It should show that you're in "C:\Documents and Settings\<user>\My Documents". Instead, it shows's that you're in "My Documents", the child of the desktop.

On Vista:

Similar problems appear on Vista with the "user" folder, and the "My Documents" folder. Care needs to be taken to correctly handle these folders on Vista.

EVALUATION Method "equals" in Win32ShellFolder2 is improved: now the same folder with different paths are not equal, but before was. E.g. "Desktop\My Documents" and "C:\Documents and Settings\<user>\My Documents" are not equal after fix.

EVALUATION Special folders handling in ShellFolder2.cpp should be refined.