Memory management in iOS Localization with .strings file

做~自己de王妃 提交于 2019-12-13 05:49:36

问题


Earlier i had posted this: What should be the better way for localizing iOS project?

Now I have done projects for both the ways and I am satisfied with the answers given over there.

In .strings file localization, if there is a username UILabel then instead of assign values in .nib itself, we do create an IBOutlet for that and in .m file we are assigning values. So is there any extra memory consumed by that IBOutlet?


回答1:


It's perfectly fine to have IBOutlet for accessing it .m file for the purpose of modifying the appearance. It will not give you any extra memory overheard, Even if you declare it with retain it will just increase the retainCount BUT don't forget to release it in dealloc if you retain the UILabel.



来源:https://stackoverflow.com/questions/9338713/memory-management-in-ios-localization-with-strings-file

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!