2018-07-15

2018-07-15  本文已影响10人  Gradlyarn
+ (instancetype)view
{
    NSString *bundlePath = [[NSBundle mainBundle] pathForResource:@"Resource" ofType:@"bundle"];
    NSBundle *bundle = [NSBundle bundleWithPath:bundlePath];
    
    //xib加载
    PopView *pop = [bundle loadNibNamed:@"PopView" owner:self options:nil].lastObject;
    //图片加载
    UIImage *image = [UIImage imageNamed:@"2" inBundle:bundle compatibleWithTraitCollection:nil];
    pop.imageView.image = image;
    
    return pop;
}
上一篇 下一篇

猜你喜欢

热点阅读