// 我是自定义的Cell
//首先在自定义Cell重写ImageV的getter方法
-(UIImageView *)icon{
_icon.layer.cornerRadius =_icon.frame.size.width/2;
return _icon;
}
//然后
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
static NSString *cellNum = @"friend";
CircleFriendCell *cell = [tableView dequeueReusableCellWithIdentifier:cellNum];
cell.selectionStyle = UITableViewCellSelectionStyleNone;
CALayer *cellImage = cell.icon.layer;
[cellImage setMasksToBounds:YES];
cell.name.text = @"科技";
cell.icon.image = [UIImage imageNamed:@"girl_3.jpg"];
return cell;
}