【发布时间】:2023-12-07 04:30:02
【问题描述】:
我的应用程序包含一个用于共享的选项菜单,当长按UITableViewCell 时会显示该菜单。如果屏幕上的UITableViewCell 太高,则选项菜单中的箭头位于UITableViewCell 下方。有没有办法手动设置箭头方向?
我用来显示选项菜单的代码是:
self.documentInteractionController = UIDocumentInteractionController(URL: fileShareURL)
self.documentInteractionController.delegate = self
self.documentInteractionController.UTI = "public.xml"
self.documentInteractionController.presentOptionsMenuFromRect(self.view.frame, inView: self.view, animated: true)
其中documentInteractionController 定义为带有var documentInteractionController: UIDocumentInteractionController! 的类变量,fileShareURL 是指向我要共享的文件的NSURL。
【问题讨论】:
标签: ios swift uipopovercontroller uidocumentinteraction options-menu