//
|
// SearchRecordCell.m
|
// BuWanVideo2.0
|
//
|
// Created by Aeline on 2021/5/30.
|
// Copyright © 2021 com.yeshi.buwansheque.ios. All rights reserved.
|
//
|
|
#import "SearchRecordCell.h"
|
|
@interface SearchRecordCell ()
|
|
@property (nonatomic, nullable, strong) UILabel *labelTitle;
|
|
@end
|
|
@implementation SearchRecordCell
|
|
- (instancetype)initWithFrame:(CGRect)frame {
|
self = [super initWithFrame:frame];
|
if (self) {
|
[self setupViewConfig];
|
}
|
return self;
|
}
|
|
- (void)setupViewConfig {
|
[self.contentView addSubview:self.labelTitle];
|
self.labelTitle.sd_layout.leftSpaceToView(self.contentView, 0).topSpaceToView(self.contentView, 0).rightSpaceToView(self.contentView, 0).bottomSpaceToView(self.contentView, 0);
|
self.labelTitle.sd_cornerRadius = @14.5;
|
}
|
|
- (void)setName:(NSString *)name {
|
self.labelTitle.text = name;
|
}
|
|
- (UILabel *)labelTitle {
|
if (!_labelTitle) {
|
_labelTitle = [[UILabel alloc] init];
|
_labelTitle.textAlignment = NSTextAlignmentCenter;
|
_labelTitle.textColor = [UIColor blackColor];
|
_labelTitle.font = [UIFont systemFontOfSize:13];
|
_labelTitle.backgroundColor = UICOLOR_FROM_RGB(0xF7F7F7, 1);
|
}
|
return _labelTitle;
|
}
|
|
@end
|