Xcode 有时会忘记资源
我正在经历这个巨大的问题。 我有一款 iOS 应用程序,我将其用作其他应用程序的基础。通常我将项目复制到不同的目录中,然后用 res 中具有相同名称和相同大小的其他资源覆盖图形资源。
问题是有时 Xcode(3 和 4)会忘记其中一些,即使它们存在并链接在资源组中。我还注意到它们存在于目标的“复制捆绑资源”中。该错误发生在设备和模拟器上。
它总是发生在图像上,尤其是具有不同后缀的图像,例如:~ipad,@2x
一些线索: -
删除了所有 .svn 隐藏文件夹
- 图像没有在任何 xib 中引用,而仅在代码中
引用 - 名称是正确的(我我知道模拟器不区分大小写,而设备则不然)
- 文件的目标在其本身以及“复制捆绑资源”中正确设置
- 更改文件的名称(以及代码)当然)不会改变这种奇怪的行为
-“触摸”文件不会改变
-清理所有目标不会有任何区别
-恢复模拟器不会有任何区别
-文件未本地化
-删除文件并添加它再次不会影响问题
- 在 .app 包内存在图像
是否存在隐藏目录或其他东西???或包含引用资源的 plist?
感谢您的帮助, 安德里亚
I'm experiencing this huge problem.
I've got one iOS app that I use as base-ground for others. Usually I copy the project in different directories and then overwrite the graphs resources with others with the same name and same sizes in res.
The problem is that sometimes Xcode (both 3 and 4) forget some of them, even if they are present and linked in the resources group. I've noticed also that they are present in the "Copy Bundle Resources" of target. The error happens on device and simulator.
It always happens with images especially the one with different suffix such as: ~ipad,@2x
Some clues:
-deleted all .svn hidden folders
-the image is not referenced in any xib, but only in code
-the name is correct ( I'm aware that simulator isn't case sensitive while the device is)
-the target of the file is set corrctly in itself and also in the "Copy Bundled Resources"
-changing the name of the file (and code, of course) doesn't change this weird behavior
-"touch" the file doesn't change
-clean all target doesn't make any difference
-restore simulator doesn't make any difference
-file isn't localized
-deleting the file and add it again doesn't affect the problem
-Inside the .app package the image is present
Is there a hidden directory or something????or a plist with the referenced resources?
Thanks for the help,
Andrea
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
解决了!!!
我已删除主项目文件夹中的所有 .svn 文件夹。打开项目,清理目标,恢复 iPhone 模拟器。一切似乎都很好。
如何显示 .svn 文件夹。在终端中写入:
恢复以前的配置:
希望这有帮助。
再见,
安德里亚
Solved!!!!
I've delete ALL .svn folders inside the main project folder. Open the project, clean targets, restored iphone simulator. Everything seems to be ok.
How to show .svn folders. In terminal write:
To restore the previous config:
Hope this helps.
Ciao,
Andrea