我正在尝试以模态方式显示 UIDocumentPickerViewController。它显示,但 UIDocumentPickerViewController 内的滚动视图没有从顶部显示某些部分,我必须向下滚动才能看到内容,一旦发布,再次回到顶部。(见图)。
这就是我正在尝试的方式!
let documentPicker: UIDocumentPickerViewController = UIDocumentPickerViewController(documentTypes: ["public.image", "public.audio", "public.movie", "public.text", "public.item", "public.content", "public.source-code"],
in: .import)
if #available(iOS 11.0, *) {
documentPicker.allowsMultipleSelection = true
} else {
// Fallback on earlier versions
}
self.present(documentPicker, animated: true,
completion: nil)