ios - UIImagePickerController 在 iOS 9 上不请求权限

标签 ios objective-c permissions uiimagepickercontroller ios-permissions

我有一个 iOS 应用程序,我在其中显示了一个图像选择器

self.picker = [[UIImagePickerController alloc] init];
self.picker.delegate = self;
self.picker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;

self.popover = [[UIPopoverController alloc] initWithContentViewController:self.picker];
[self.popover presentPopoverFromRect:CGRectMake(100, 100, 1, 1) inView:self.view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];

然而,该应用根本不请求权限,它只是显示错误消息“此应用无权访问您的照片或视频”。

关于可能导致此问题的任何想法?

提前致谢!

最佳答案

问题是 Bundle Display Name 没有在 Info.plist 中设置

关于ios - UIImagePickerController 在 iOS 9 上不请求权限,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33009290/

相关文章:

ios - NS_UNAVAILABLE 的 Swift 等价物是什么?

objective-c - 是什么导致 SIGSEGV 使用 block ?

android - 如何注册具有权限的动态BroadcastReceiver?

kubernetes - 由于 `error while creating mount source path`而使Google Kubernetes Engine(GKE)集群 `read-only file system`

bash - 无法将目录更改为符号链接(symbolic link)目录

objective-c - CGaffine 在 UIView 上进行变换而不变换 subview

ios - 通过发送 "ID"作为参数,将数据从一个 collectionView 单元格传递到 swift 4 中的其他 Collection View Controller

iphone - MKMapView 中的 zoomLevel 和 mapCenter

objective-c - 是否保证在创建对象的同一线程上调用 dealloc?

ios - 如何从表格 View 行单元格中删除单独的行?