Search code examples
localizationxcode4internationalizationstoryboard

Weird behavior of Xcode 4.6 base localization: Works on simulator but only PARTLY on device


I tried to use base localization for a project using Xcode 4.6. The weird thing is that it works completely on the simulator and on an ad-hoc testing device that loaded an archive by iTunes, but on the development iPhone connected to Xcode, with language setting to German, only the Localizable.strings are shown in German, but none of the MainStoryboard_iPhone.strings - they are all shown in English.
I have cleaned my product, deleted the app completely from the development iPhone, changed its language settings back to English and forth to German, restarted Xcode etc. The result is always the same: The development iPhone does not translate the storyboard files, although they are translated on the simulator and on an ad-hoc testing device.
My configuration: I have a base localization for the storyboard, and a localization of it in two languages (English and German), i.e. in my project folder there is a folder Base.lproj containing MainStoryboard_iPhone.storyboard, an en.lproj folder containing InfoPlist.strings, Localizable.strings, and MainStoryboard_iPhone.strings (apart from MainStoryboard_iPad.storyboard, which I don't use right now), and a de.lproj folder containing files with the same name.
My base localization is English. So the English MainStoryboard_iPhone.strings file contains content like

/* Class = "IBUIViewController"; title = "Help"; ObjectID = "1Yu-La-mu2"; */  
"1Yu-La-mu2.title" = "Help";

and the German version

/* Class = "IBUIViewController"; title = "Help"; ObjectID = "1Yu-La-mu2"; */  
"1Yu-La-mu2.title" = "Hilfe";  

The Localizable.strings files contain the usual like "STORE" = "Store"; in the English version, and "STORE" = "Speichern"; in the German version.
I run out of ideas, and could not find anything related on the web. I would be glad if anybody else had an advice what to do.
EDIT: Inserted "changed its language settings back to English and forth to German" above, and the iOS Version of the iPhone..


Solution

  • Sorry, after submitting the question I had one more idea (that I could have had before): It might be useful for others with the same problem:
    I completely switched off the development iPhone, restarted it, and now it shows the correct storyboard localization.
    Sorry for bothering you...