RFR: 4834298: JFileChooser.getSelectedFiles() failed with multi-selection and double-click [v4]

Tejesh R tr at openjdk.org
Fri Sep 9 08:12:45 UTC 2022


> JFileChooser.getSelectedFiles() failed to retrieve files with multi-selection and double-click. This occurs when a single file is selected then enable multi-selection then select the same file through mouse double-click(Two file chooser dialogs used before and after multi-selection enabled). SelectedFiles are updated when a change in files/directory selection is done or when selection is made through keyboard selection. In this case since a single file is selected before multi-selection is enabled and same file is selected again without changing the selection index/directory, leaving selected Files un-updated. 
> **Proposed Fix** : Whenever Multi-Selection is enabled check if any files are selected, if yes update the selected Files of JFileChoooser.

Tejesh R has updated the pull request incrementally with one additional commit since the last revision:

  Updated based on review comments

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/9996/files
  - new: https://git.openjdk.org/jdk/pull/9996/files/1d7f271b..c437cdfc

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=9996&range=03
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=9996&range=02-03

  Stats: 27 lines in 2 files changed: 2 ins; 15 del; 10 mod
  Patch: https://git.openjdk.org/jdk/pull/9996.diff
  Fetch: git fetch https://git.openjdk.org/jdk pull/9996/head:pull/9996

PR: https://git.openjdk.org/jdk/pull/9996



More information about the client-libs-dev mailing list