摘要: 首先粘上iOS开发文档对File's Owner的解释:One of the most important objects in a nib file is the File’s Owner object. Unlike interface objects, the File’s Owner object is a placeholder object that is not created when the nib file is loaded. Instead, you create this object in your code and pass it to the nib-l 阅读全文
posted @ 2014-01-02 18:28 CoderZHY 阅读(830) 评论(0) 推荐(0) 编辑
摘要: iOS官方文档极力推荐大家使用Nib开发程序的UI,也就是Interface Builder方式开发,这种开发模式相对代码实现的好处就是所见即所得,便于及时的调整。 这里主要谈两点:Nib文件的load过程和load方法。Nib文件的load过程根据iOS开发文档Resource Programming Guide的描述,Nib文件的load包含以下过程: 1.将Nib文件从磁盘载入内存,有两种技术可以加载Nib文件:NSBundle和UINib,具体细节会在第二节中描述。 2.执行unarchive和initialize操作,该过程主要由NSCoding Protocol中的initWit. 阅读全文
posted @ 2014-01-02 11:35 CoderZHY 阅读(2257) 评论(0) 推荐(0) 编辑