<Swing Dev> [9] Review request for 8041694: JFileChooser removes trailing spaces in the selected directory name

Anton Litvinov anton.litvinov at oracle.com
Wed May 11 12:14:24 UTC 2016


Hello,

Could you please review the following fix for the bug.

Bug: https://bugs.openjdk.java.net/browse/JDK-8041694
Webrev: http://cr.openjdk.java.net/~alitvinov/8041694/jdk9/webrev.00

The bug consists in the fact that the method 
"JFileChooser.getSelectedFile()" returns "java.io.File" object which 
does not contain trailing spaces in the directory name, in spite of the 
fact that the corresponding directory in the file system has trailing 
spaces in its name. The fix deletes the code in the method 
"javax.swing.plaf.basic.BasicFileChooserUI.ApproveSelectionAction.actionPerformed" 
which deliberately modifies the selected directory string name by 
removing trailing spaces from it.

All automatic regression tests from open and closed sets located in 
"javax/swing/JFileChooser" directories were run on MS Windows 7 OS 
during verification of the fix.

Thank you,
Anton



More information about the swing-dev mailing list