JDK-6937234 : [filechooser] tooltip for desktop button is in English on non-English windows
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 6u10
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows
  • CPU: generic
  • Submitted: 2010-03-23
  • Updated: 2011-01-19
  • Resolved: 2010-05-20
Related Reports
Duplicate :  
Duplicate :  
Description
When open standard file chooser, all the tooltips of the buttons are in English, except one.

The tooltip of the home directory button is in English as "Desktop" on windows, when the home directory is the root.

There is no message in the resource file corresponding to it.

In the file /src/share/classes/com/sun/java/swing/plaf/windows/WindowsFileChooserUI.java, there is code section

if (OS_VERSION.startsWith("4.1")) {		// Windows 98 (4.10)
	    // Desktop Button
	    File homeDir = fsv.getHomeDirectory();
	    String toolTipText = homeFolderToolTipText;
	    if (fsv.isRoot(homeDir)) {
		toolTipText = getFileView(fc).getName(homeDir); // Probably "Desktop".
	    }
  .................

The tooltip is "Desktop", which makes user feel strange on non-English windows, because all the other buttons have localized tooltips.

Attached is the snapshot.
The snapshot can not be attached.

Please see it at http://java-g11n.sfbay.sun.com/j2se/6u10/tooltip.png
The snapshot is attached.

Comments
PUBLIC COMMENTS Because we don't support windows 98 that code was removed in the fix of CR 6589634. So I close the bug as a duplicate.
20-05-2010