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
41
42
43
44
45
46
47
48
//
// GXFNoticeFunctionTableViewCell.m
// XFFruit
//
// Created by freecui on 15/8/27.
// Copyright (c) 2015年 Xummer. All rights reserved.
//
#import "GXFNoticeFunctionTableViewCell.h"
@implementation GXFNoticeFunctionTableViewCell
- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
_functionImg = [[UIImageView alloc]initWithFrame:CGRectMake(20.f, 10.f, 45.f, 45.f)];
_functionImg.image = [UIImage imageNamed:@""];
[self.contentView addSubview:_functionImg];
_unReadLabel = [[UILabel alloc]initWithFrame:CGRectMake(self.width - 60.f,(self.height - 20.0f)/2.0 , 25.0f, 20.0f)];
_unReadLabel.backgroundColor = [UIColor redColor];
_unReadLabel.textColor = [UIColor whiteColor];
_unReadLabel.font = [UIFont systemFontOfSize:13];
_unReadLabel.layer.cornerRadius =10;
_unReadLabel.layer.masksToBounds = YES;
[self.contentView addSubview:_unReadLabel];
_noticeLabel = [[UILabel alloc] initWithFrame:CGRectMake(_functionImg.right ,_functionImg.x,self.width - _functionImg.right - 40,self.height)];
_noticeLabel.font = [UIFont systemFontOfSize:13.0f];
[_noticeLabel setTextAlignment:NSTextAlignmentRight];
_noticeLabel.textColor = [UIColor blackColor];
[self.contentView addSubview:_noticeLabel];
}
return self;
}
- (void)awakeFromNib {
// Initialization code
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
[super setSelected:selected animated:animated];
// Configure the view for the selected state
}
@end