Reputation: 3011
I have an app in development using Xcode Swift 1.1 and am testing it using iOS 7.1 and iOS 8.1 simulators.
The app allows users to access their photos library, but before they can, iOS displays the Privacy alert message title asking for the user's permission in English language - “App Name” Would Like to Access Your Photos. (Side note: the alert is triggered when calling PHAsset and/or ALAssetsLibrary.)
My app will be available in a few different languages, for example, Chinese. However whenever I try to localize or test for different languages settings, the above privacy alert message always shows in English. I want the system privacy alert message to display in the language as set on the user's device.
I’ve tried a number of different location settings and localization languages in Xcode with no difference in the simulator.
Should I expect (or rest easy) that setting a different location on a real device will have iOS automatically show the correct language for all system generated privacy alert messages?
What am I missing in localizing the system privacy alert messages?
(Note: I am unable to test on a real device yet and that setting the "Privacy - Photo Library Usage Description” key in Info.plist does not change the Privacy alert message title, but sets an optional description for the alert instead.)
Upvotes: 4
Views: 2486
Reputation: 40028
The ... would like to access your photos
permission alert is shown by the system and not by your app. Therefore its localisation is done by the system and not your app's code. You don't have to provide translation strings.
What you are experiencing is a simulator bug. It works on the device. I encourage you to test your app on a real hardware.
Upvotes: 5