zoukankan      html  css  js  c++  java
  • iOS10相机等崩溃

    当使用iOS10使用相机时会出现崩溃

        This app has crashed because it attempted to access privacy-sensitive data without a usage description. The app's Info.plist must contain an NSCameraUsageDescription key with a string value explaining to the user how the app uses this data.

    有如下常用字段
    • NSContactsUsageDescription -> 通讯录

    • NSMicrophoneUsageDescription -> 麦克风

    • NSPhotoLibraryUsageDescription -> 相册

    • NSCameraUsageDescription -> 相机

    • NSLocationAlwaysUsageDescription -> 地理位置

    • NSLocationWhenInUseUsageDescription -> 地理位置

    我们需要在info.plist中设置提醒,在iOS10之前默认就给设置了

    <key>NSCameraUsageDescription</key>    
    <string>cameraDesciption</string>
    <key>NSContactsUsageDescription</key>
    <string>contactsDesciption</string>
    <key>NSMicrophoneUsageDescription</key>
    <string>microphoneDesciption</string>
    <key>NSPhotoLibraryUsageDescription</key>
    <string>photoLibraryDesciption</string>
  • 相关阅读:
    Linq&Lumbda
    PS颜色模式
    WPF绑定方式
    明三杰刘健
    齐有鲍叔,郑有子皮
    朱厚照
    管子&小白
    时间
    人外有人之神箭手养繇基篇
    楚共王
  • 原文地址:https://www.cnblogs.com/qiutangfengmian/p/6069800.html
Copyright © 2011-2022 走看看