<Swing Dev> [11] JDK-8191957: JFileChooser shows empty name for external drives shown under Desktop

Krishna Addepalli krishna.addepalli at oracle.com
Fri Mar 16 11:17:33 UTC 2018


Hi Pankaj,

The changes look fine to me.

Thanks,
Krishna

-----Original Message-----
From: Pankaj Bansal 
Sent: Friday, March 16, 2018 4:42 PM
To: Krishna Addepalli <krishna.addepalli at oracle.com>; swing-dev at openjdk.java.net
Subject: RE: <Swing Dev> [11] JDK-8191957: JFileChooser shows empty name

Hi Krishna,

Thanks for the review.

I have incorporated the review comments. Please have a look.
Webrev: http://cr.openjdk.java.net/~pbansal/8191957/webrev.01/

Regards,
Pankaj Bansal

-----Original Message-----
From: Krishna Addepalli 
Sent: Friday, March 16, 2018 4:03 PM
To: swing-dev at openjdk.java.net
Subject: Re: <Swing Dev> [11] JDK-8191957: JFileChooser shows empty name

Hi Pankaj,

The fix looks fine to me. However I have couple points:

1. Please put a comment at the line of fix, about how Windows 10 treats the Desktop folder.
2. The test case can be a headless one, since you are not creating any gui components.

Thanks,
Krishna


-----Original Message-----
From: swing-dev-request at openjdk.java.net <swing-dev-request at openjdk.java.net> 
Sent: Monday, March 12, 2018 5:30 PM
To: swing-dev at openjdk.java.net
Subject: swing-dev Digest, Vol 131, Issue 25

Send swing-dev mailing list submissions to
	swing-dev at openjdk.java.net

To subscribe or unsubscribe via the World Wide Web, visit
	http://mail.openjdk.java.net/mailman/listinfo/swing-dev
or, via email, send a message with subject or body 'help' to
	swing-dev-request at openjdk.java.net

You can reach the person managing the list at
	swing-dev-owner at openjdk.java.net

When replying, please edit your Subject line so it is more specific than "Re: Contents of swing-dev digest..."


Today's Topics:

   1.  [11] JDK-8191957: JFileChooser shows empty name for external
      drives shown under Desktop (Pankaj Bansal)


----------------------------------------------------------------------

Message: 1
Date: Mon, 12 Mar 2018 01:52:35 -0700 (PDT)
From: Pankaj Bansal <pankaj.b.bansal at oracle.com>
To: swing-dev at openjdk.java.net
Subject: <Swing Dev> [11] JDK-8191957: JFileChooser shows empty name
	for external drives shown under Desktop
Message-ID: <065d066f-810c-4284-9de6-059f4235e61b at default>
Content-Type: text/plain; charset="us-ascii"

Hi All,

 

Please review the test only fix for JDK 11.

 

Bug:

https://bugs.openjdk.java.net/browse/JDK-8191957

 	

webrev:

http://cr.openjdk.java.net/~pbansal/8191957/webrev.00/

 

Issue:

In windows 10, the "External Drives" or "Removable drives" names are empty when root directory "Desktop" is selected in JFileChooser. Only the icon is shown and name is empty.

Fix:

The system folder names are found by calling FileSystemView.getSystemDisplayName, which in turn calls  Win32ShellFolderManager2.isFileSystemRoot. Here it was wrongly assumed that a drive will always be child of "DRIVES" or "MY PC". But in windows 10, the external drives are also shown as children of root directory "Desktop". Made changes to consider drives names which are children of "Desktop".

 

Note:

This is a windows 10 specific issues. 

You will need an removable drive attached to you system to test this.

 

Regards,

Pankaj Bansal

 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/swing-dev/attachments/20180312/784cc456/attachment-0001.html>

End of swing-dev Digest, Vol 131, Issue 25
******************************************



More information about the swing-dev mailing list