UIActivityViewController iOS8 iPad Crash处理
2015-02-09 10:01
239 查看
在iPhone 上程序一切正常,但独在iPad iOS8的系统上,UIActivityViewController会崩溃,经查阅资料:
On iPad the activity view controller will be displayed as a popover using the newUIPopoverPresentationController,
it requires that you specify an anchor point for the presentation of the popover using one of the three following properties:
barButtonItem
sourceView
sourceRect
In order to specify the anchor point you will need to obtain a reference to the UIActivityController's UIPopoverPresentationController and set one of the properties as follows:activityViewController.popoverPresentationController.sourceView = parentView;
// 或者
activityViewController.popoverPresentationController.barButtonItem = _actionButton;
// 或者SourceRect(不再举例)
资料地址: http://stackoverflow.com/questions/25644054/uiactivityviewcontroller-crashing-on-ios8-ipads
On iPad the activity view controller will be displayed as a popover using the newUIPopoverPresentationController,
it requires that you specify an anchor point for the presentation of the popover using one of the three following properties:
barButtonItem
sourceView
sourceRect
In order to specify the anchor point you will need to obtain a reference to the UIActivityController's UIPopoverPresentationController and set one of the properties as follows:activityViewController.popoverPresentationController.sourceView = parentView;
// 或者
activityViewController.popoverPresentationController.barButtonItem = _actionButton;
// 或者SourceRect(不再举例)
资料地址: http://stackoverflow.com/questions/25644054/uiactivityviewcontroller-crashing-on-ios8-ipads
相关文章推荐
- iOS项目开发中遇到CRASH:重写Setter对服务器获取的数据做空值的过滤处理
- crash处理core文件
- Android Crash异常处理方法
- iOS 数组越界 Crash处理经验
- 【iOS开发】 常遇到的Crash和Bug处理
- 英国首相卡梅隆特制iPad应用,处理政务
- 视网膜New iPad与普通分辨率iPad页面的兼容处理
- 一个fread失败时处理不当引发的crash
- Android 重写系统Crash处理类,保存Crash信息到SD卡 和 完美退出程序的方法
- 关于debug版本OK,release版本crash的问题处理可能原因
- 在iOS设备(iPhone/iPad)中调用摄像头进行全屏拍摄时的处理方案
- crash处理case范例说明
- 重写系统Crash处理类,保存Crash信息到SD卡 和 完美退出程序的方法
- 重写系统Crash处理类,保存Crash信息到SD卡 和 完美退出程序的方法
- Google Breakpad 之一,跨平台crash 处理上报系统简介
- CRASH: -[NSNull length]: unrecognized selector sent to instance错误的处理办法
- ipad default图片 横屏处理办法
- Android 重写系统Crash处理类,保存Crash信息到SD卡 和 完美退出程序的方法
- Android--应用Crash处理
- 一些Windows API导致的Crash以及使用问题总结(API的AV失败,可以用try catch捕捉后处理)