面试资料iOS DeveloperiOS 开发成长中心

iOS的plist文件适配那点事儿

2016-11-17  本文已影响89人  爱吃鱼的小灰

关于AFNetworking的网络请求失败看这里

<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>

iOS10也有一些需要适配的plist文件内容

This app attempts to access privacy-sensitive data without a usage description. The app's Info.plist must contain an NSPhotoLibraryUsageDescription key with a string value explaining to the user how the app uses this data.

 This app attempts to access privacy-sensitive data without a usage description. The app's Info.plist must contain an NSMicrophoneUsageDescription key with a string value explaining to the user how the app uses this data.

  This app attempts 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.
// 这个是相机的
 <key>NSCameraUsageDescription</key> 
<string>cameraDesciption</string>
// 通讯录
 <key>NSContactsUsageDescription</key>    
  <string>contactsDesciption</string>    
// 相册
<key>NSMicrophoneUsageDescription</key>   
 <string>microphoneDesciption</string>
  <key>NSPhotoLibraryUsageDescription</key>    
<string>此 App 需要您的同意才能读取媒体资料库</string>
上一篇下一篇

猜你喜欢

热点阅读