//
|
// SearchHotCell.m
|
// BuWanVideo2.0
|
//
|
// Created by Aeline on 2021/5/30.
|
// Copyright © 2021 com.yeshi.buwansheque.ios. All rights reserved.
|
//
|
|
#import "SearchHotCell.h"
|
|
@interface SearchHotCell ()
|
|
@property (nonatomic, nullable, strong) UIImageView *imaegViewIcon;
|
@property (nonatomic, nullable, strong) UILabel *labelTitle;
|
@end
|
|
@implementation SearchHotCell
|
|
- (instancetype)initWithFrame:(CGRect)frame
|
{
|
self = [super initWithFrame:frame];
|
if (self) {
|
|
[self setupViewConfig];
|
}
|
return self;
|
}
|
|
- (void)setupViewConfig {
|
[self.contentView addSubview:self.imaegViewIcon];
|
[self.contentView addSubview:self.labelTitle];
|
|
self.imaegViewIcon.sd_layout.leftSpaceToView(self.contentView, 12).topSpaceToView(self.contentView, 17).widthIs(14).heightIs(18);
|
|
self.labelTitle.sd_layout.leftSpaceToView(self.imaegViewIcon, 10).centerYEqualToView(self.imaegViewIcon).rightSpaceToView(self.contentView, 0).heightIs(14);
|
}
|
|
- (UIImageView *)imaegViewIcon {
|
if (!_imaegViewIcon) {
|
_imaegViewIcon = [[UIImageView alloc] init];
|
[_imaegViewIcon setContentScaleFactor:[[UIScreen mainScreen] scale]];
|
_imaegViewIcon.contentMode = UIViewContentModeScaleAspectFill;
|
_imaegViewIcon.clipsToBounds = YES;
|
_imaegViewIcon.image = [UIImage imageNamed:@"search_hot"];
|
}
|
return _imaegViewIcon;
|
}
|
|
- (UILabel *)labelTitle {
|
if (!_labelTitle) {
|
_labelTitle = [[UILabel alloc] init];
|
_labelTitle.text = @"新·福音战士剧场版:│▌ / Evangelion: 3.0+1.0";
|
_labelTitle.textColor = UICOLOR_FROM_RGB(0x000000, 1);
|
_labelTitle.font = [UIFont systemFontOfSize:14];
|
_labelTitle.textAlignment = NSTextAlignmentLeft;
|
}
|
return _labelTitle;
|
}
|
|
@end
|