优化长按聊天记录 如果是自己 不要显示举报

This commit is contained in:
2026-02-04 18:39:25 +08:00
parent 3ed120106e
commit db9f07d199
3 changed files with 47 additions and 2 deletions

View File

@@ -970,10 +970,13 @@ static NSString * const KBChatSessionDidResetNotification = @"KBChatSessionDidRe
self.selectedActionMessage = message;
CGFloat width = 240;
CGFloat height = 156;
BOOL isUserMessage = (message.type == KBAiChatMessageTypeUser);
BOOL showsReport = !isUserMessage;
CGFloat height = [KBChatMessageActionPopView preferredHeightWithShowsReportAction:showsReport];
KBChatMessageActionPopView *content = [[KBChatMessageActionPopView alloc]
initWithFrame:CGRectMake(0, 0, width, height)];
content.delegate = self;
content.showsReportAction = showsReport;
UIWindow *window = [UIApplication sharedApplication].keyWindow;
if (!window) {
@@ -988,7 +991,6 @@ static NSString * const KBChatSessionDidResetNotification = @"KBChatSessionDidRe
[window addSubview:mask];
self.messageActionMaskView = mask;
BOOL isUserMessage = (message.type == KBAiChatMessageTypeUser);
CGFloat margin = 12.0;
CGFloat spacing = 8.0;
CGFloat topSafe = 0.0;