在手动显示PHPickerViewController
时是否可以显示用户当前的照片选择?例如,使用以下代码时,选择器不会显示用户当前选择的任何照片。
var pickerConfig = PHPickerConfiguration()
pickerConfig.selectionLimit = 0
pickerConfig.filter = .any(of: [.images])
let imagePicker = PHPickerViewController(configuration: pickerConfig)
imagePicker.delegate = self
// When presented, the user's current selected photos are empty, nothing is selected
viewController.present(imagePicker, animated: true)
但是,如果我使用Apple内置的presentLimitedLibraryPicker
功能,它会显示用户当前的照片选择:
// This does show the user's current selections
PHPhotoLibrary.shared().presentLimitedLibraryPicker(from controller: self)
是否有一种无需使用presentLimitedLibraryPicker
即可获得此行为的方法?