开发者

Resource problem - Localization and iPhone/iPad XIBs all broken

I had a localized universal application. I copied a bunch of resources (XIB) files from an old project into the appropriate locations (English.lprog) directories for both iPhone (Filename~iPhone.xib) and iPad (Filename~iPad.xib). I added them to the project, and they all appear correctly in Xcode, as localizations, etc. I can open the localized files for each device in XCode/IB, and everything appears correct.

Now, when I run the project - everything is completely haywi开发者_Python百科re. In short, when I run in English on the iPad simulator, I get the Chinese version of the iPhone XIBs!!!

I can't figure out what the problem is - any idea how to dig deeper?!


Few things fixed this:

  1. Total clean build of project

  2. Erase old application from device and/or simulator before reinstall.

  3. Just because the icon in XCode looks like an IB icon, and double-clicking opens in IB, it still MUST have an ".xib" extension visible on the file.

  4. Simulator is NOT case sensitive, but iPhone IS. This includes differences like MyClass~iphone.xib (works) vs. MyClass~iPhone.xib (doesn't work).


These steps have worked for me: In Xcode,

  • Check the location of folders for every language
  • Build > Clean all targets
  • Build > Compile
  • alt-R
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜