1
This commit is contained in:
@@ -79,19 +79,7 @@
|
||||
self.titleLabel.text = character.characterName ?: @"";
|
||||
self.subLabel.text = character.download ?: @"";
|
||||
|
||||
// 头像:圆形占位 + 网络图
|
||||
UIImage *placeholder = nil;
|
||||
if (!placeholder) {
|
||||
// 使用纯色圆形作为占位
|
||||
CGFloat side = 56.0;
|
||||
UIGraphicsBeginImageContextWithOptions(CGSizeMake(side, side), NO, 0);
|
||||
CGContextRef ctx = UIGraphicsGetCurrentContext();
|
||||
[[UIColor colorWithWhite:0.9 alpha:1.0] setFill];
|
||||
CGContextFillEllipseInRect(ctx, CGRectMake(0, 0, side, side));
|
||||
placeholder = UIGraphicsGetImageFromCurrentImageContext();
|
||||
UIGraphicsEndImageContext();
|
||||
}
|
||||
[self.avatarView kb_setAvatarURL:character.avatarUrl placeholder:placeholder];
|
||||
[self.avatarView kb_setAvatarURL:character.avatarUrl placeholder:KBPlaceholderImage];
|
||||
|
||||
// 加入状态
|
||||
BOOL joined = character.added;
|
||||
|
||||
Reference in New Issue
Block a user