iphone - UIDocumentInteractionController dismissPreviewAnimated 崩溃

标签 iphone ios uidocumentinteraction

我可以像这样打开一个文档交互 Controller :

UIDocumentInteractionController *documentController = [UIDocumentInteractionController interactionControllerWithURL:URL];
documentController.delegate = self;
[documentController presentPreviewAnimated:FALSE];

但是如果我尝试像这样以编程方式关闭它:

[documentController dismissPreviewAnimated:FALSE];

应用程序在 dismissPreviewAnimated 行崩溃并显示消息“[QLPreviewController exitFullScreenToRect:inView:]:无法识别的选择器发送到实例 0x197500。”

我的目标是在应用程序接受传入文件时关闭应用程序委托(delegate)的预览(我将 documentController 变量传递给应用程序委托(delegate)以便它可以找到 Controller ),但即使我立即放置关闭命令在执行当前命令后,我遇到了同样的崩溃。

错误消息中对 QLPreviewController 的引用告诉我 dismissPreviewAnimated 正在调用崩溃的基础方法。尽管我没有直接使用它,但我尝试将 QuickLook 框架添加到我的项目中,但这没有帮助。

我在文档中没有看到任何关于此的内容,并且当我在网络或开发者论坛中搜索“UIDocumentInteractionController dismissPreviewAnimated”时,我没有找到任何示例或信息。任何人都可以阐明这一点吗?

最佳答案

好的,Apple 确认这是 iOS 4.3 中的错误。

编辑:我已确认此问题已在 iOS 5.0 中修复。

关于iphone - UIDocumentInteractionController dismissPreviewAnimated 崩溃,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7015147/

相关文章:

objective-c - 我可以隐藏 UIDocumentInteractionController View 上的操作按钮吗?

iphone - iOS - 如何对从 CoreData 获取的托管对象进行排序?

ios - 如何为 UIToolbar 添加标题?

ios - 如何在恢复期间检测登录取消事件?

ios - 通过 UIDocumentInteractionController 允许 PDF 的预览选项

ios - UIDocumentInteractionController 需要很长时间才能显示选项

objective-c - 如何在 FileProviderUI 中创建自定义操作

ios - 在更改其嵌套的 UILabel 的同时移动 UIView 会导致 View 跳回到初始位置

php - 如何从iphone post请求中获取json数据

ios - 使用AVFoundation扫描PDF417条码