IVTMyLiveCollectionViewCell.m
1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
//
// IVTMyLiveCollectionViewCell.m
// IVTMeLiveTwo
//
// Created by XRG on 16/8/25.
// Copyright © 2016年 QLQ. All rights reserved.
//
#import "IVTMyLiveCollectionViewCell.h"
@interface IVTMyLiveCollectionViewCell ()
{
UIImageView *userHeaderImageView;
}
@end
@implementation IVTMyLiveCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame{
self = [super initWithFrame:frame];
if (self) {
userHeaderImageView = [[UIImageView alloc]init];
userHeaderImageView.userInteractionEnabled = YES;
[self.contentView addSubview:userHeaderImageView];
[userHeaderImageView mas_makeConstraints:^(MASConstraintMaker *make) {
make.edges.equalTo(self.contentView);
}];
}
return self;
}
- (void)setUserHeaderImageUrl:(NSString *)userHeaderImageUrl{
_userHeaderImageUrl = userHeaderImageUrl;
[userHeaderImageView sd_setImageWithURL:[NSURL URLWithString:_userHeaderImageUrl] placeholderImage:[UIImage imageNamed:@"占位头像"]];
}
@end