【发布时间】:2019-09-22 18:12:03
【问题描述】:
我已经在 NSCameraUsageDescription 和 NSPhotoLibraryUsageDescription 字段的 info.plist 文件中指定了我需要的文本,但没有任何改变。
始终使用相同的系统文本“此应用需要访问相机”和“此应用需要访问照片库”。我已经尝试在代码中找到它。没找到。我在文件 info.plist 中指定在我使用的所有库中添加我的 NSCameraUsageDescription 和 NSPhotoLibraryUsageDescription 键。同样没有任何变化。
info.plist 文件
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleDisplayName</key>
<string>Mona</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>NSCameraUsageDescription</key>
<string>The program wants to access the camera so you can use your photos and camera in this photo editor.</string>
<key>NSPhotoLibraryUsageDescription</key>
<string>The program wants to access the photo gallery so you can use your photos and camera in this photo editor.</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
</dict>
</plist>
请帮助我。告诉我如何更改这些查询的描述。
【问题讨论】:
-
请发布您的应用目标的 info.plist。
-
@shallowThought 完成
-
不能替换系统文本,只能添加。显示您的权限警报的屏幕截图。
-
@Gereon 完成外观
-
这绝对不是系统文本。字符串“此应用程序需要访问相机”必须在您的项目中,可能是本地化/字符串文件。
标签: ios