ios - UIDocumentMenuViewController 更多按钮

标签 ios objective-c uidocumentmenuvc

我的应用程序中有以下代码,当我点击“更多”按钮时,保管箱选项显示并迅速消失,不允许启用。

UIDocumentMenuViewController *picker = [[UIDocumentMenuViewController alloc]
                                            initWithDocumentTypes:@[(NSString *)kUTTypeImage]
                                            inMode:UIDocumentPickerModeImport];
    [picker addOptionWithTitle:@"Rolo de Câmera" image:[UIImage imageNamed:@"ic_photo_library"] order:0 handler:^{

    }];
    [picker addOptionWithTitle:@"Tirar Foto" image:[UIImage imageNamed:@"ic_photo_camera"] order:0 handler:^{

    }];
    picker.delegate = self;
    [self presentViewController:picker animated:YES completion:nil];

结果:

DocumentPicker Bug

有什么建议吗?

最佳答案

问题出在 UINavigationBarisTranslucent 属性上。我遇到了同样的问题,我通过在我的 didFinishLaunchingWithOptions 方法中删除这一行来解决

UINavigationBar.appearance().isTranslucent = false

关于ios - UIDocumentMenuViewController 更多按钮,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44052046/

相关文章:

iOS 7 UISearchBar 定制当它是第一响应者

ios - UIDocumentMenuViewController 的自定义图像仅显示蓝色框

ios - 如何在 iTunes Connect 地区选择孟加拉国国家?

ios - 本地保存后如何在 IOS 中加载 CSV

iOS 7 : Delete application with grey background

ios - 这是 iOS 中的 Controller

ios - 我如何让我的 View 在 ios 6 中的状态栏下启动,就像在 ios 7 中一样

iphone - 优化 A* Pathfinding iPhone - NSDictionary 能解决问题吗?

带有静态 TableView 单元格的 IOS 8 动态类型 - 基本和副标题