chore: 地图消息Cell圆角优化及IM登录日志

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
jiayangyang
2026-08-04 16:31:49 +08:00
co-authored by Claude Opus 4.7
parent ee47bba29a
commit 5b719599ba
2 changed files with 9 additions and 3 deletions
@@ -32,6 +32,7 @@
// KPostNotification(KNotificationLoginIMResult, @YES);
HQUserInfo *user = [HQCommonUtils keyedUnarchiverWithKey:LoginUserInfo];
[[TUICallKit createInstance] setSelfInfo:user.realname avatar:user.avatar succ:nil fail:nil];
DLog(@"IM登录成功");
} fail:^(int code, NSString *msg) {
@@ -30,8 +30,11 @@
- (void)createMapUI {
// 隐藏默认气泡图片,改用白色圆角
// 隐藏默认气泡图片,改用白色圆角背景
self.bubbleView.image = nil;
self.container.backgroundColor = KWhiteColor;
self.container.layer.cornerRadius = 8;
self.container.layer.masksToBounds = YES;
self.myTextLabel = [[UILabel alloc] init];
self.myTextLabel.font = SYSTEMFONT(15);
@@ -69,12 +72,14 @@
#pragma mark - TUIChat 实时聊天回调
- (void)fillWithData:(CustomMapMessageCellData *)data {
// 不显示名字标签,让白色卡片紧贴顶部(父类 layoutSubviews 用 frame 布局,需在 data 层面关闭)
data.showName = NO;
[super fillWithData:data];
// 清掉父类设回来的气泡图,让 container 白底露出来
self.bubbleView.image = nil;
self.myTextLabel.text = data.text.length > 0 ? data.text : @"我的位置";
[self.mapImage sd_setImageWithURL:[NSURL URLWithString:data.MapPictureImg] placeholderImage:nil];
self.nameLabel.hidden = YES;
}
#pragma mark - 历史记录回调