现在的位置: 首页 > 综合 > 正文

从nib加载cell,创建cell为nib

2018年05月08日 ⁄ 综合 ⁄ 共 238字 ⁄ 字号 评论关闭

                NSArray *objects = [[NSBundle
mainBundle] loadNibNamed:@"MsgCell"
owner:self options:nil];

                for (NSObject *o
in objects) {

                    if ([o
isKindOfClass
:[MsgCell class]]) {

                        cell = (MsgCell *)o;

                        break;

                    }

                }

抱歉!评论已关闭.