public static @NotNull List<VirtualFile> getChosenFiles(@NotNull FileChooserDescriptor descriptor, @NotNull List<VirtualFile> selectedFiles) {
    return ContainerUtil.mapNotNull(selectedFiles, file -> file != null && file.isValid() ? descriptor.getFileToSelect(file) : null);
  }
public static @NotNull List<VirtualFile> getChosenFiles(@NotNull FileChooserDescriptor descriptor, @NotNull List<VirtualFile> selectedFiles)