-
Notifications
You must be signed in to change notification settings - Fork 0
/
adminCell.m
40 lines (35 loc) · 1.05 KB
/
adminCell.m
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
39
40
//
// adminCell.m
// HymnLens
//
// Created by 邹应天 on 16/2/20.
// Copyright © 2016年 陈志浩. All rights reserved.
//
#import "adminCell.h"
@interface adminCell()
@property UIImageView *faviconV;
@end
@implementation adminCell
-(id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
return self;
}
-(void)createWithImage:(UIImage*)image
{
self.faviconV = [UIImageView new];
self.faviconV.image = image;
self.faviconV.contentMode = UIViewContentModeScaleAspectFit;
[self.contentView addSubview:self.faviconV];
[self.faviconV mas_makeConstraints:^(MASConstraintMaker *make) {
make.right.equalTo(self.contentView).offset(-20);
make.centerY.equalTo(self.contentView);
make.width.mas_equalTo(50);
make.height.mas_equalTo(50);
}];
}
-(void)createWithDetailLabel:(NSString *)string
{
self.detailTextLabel.textColor = [UIColor grayColor];
self.detailTextLabel.text = string;
}
@end