fix chat cell size

This commit is contained in:
Danmei Chen 2019-01-04 14:21:14 +01:00
parent 6e1ee5b516
commit 4180a8ed9c
2 changed files with 2 additions and 2 deletions

View file

@ -299,7 +299,7 @@ static const CGFloat MESSAGE_SPACING_PERCENTAGE = 1.f;
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
// pre-download data
if (preLoad)
return 0;
return 60;
LinphoneEventLog *event = [[eventList objectAtIndex:indexPath.row] pointerValue];
if (linphone_event_log_get_type(event) == LinphoneEventLogTypeConferenceChatMessage) {
LinphoneChatMessage *chat = linphone_event_log_get_chat_message(event);

View file

@ -444,7 +444,7 @@ static const CGFloat CELL_IMAGE_X_MARGIN = 100;
size:CGSizeMake(width - 4, CGFLOAT_MAX)
font:messageFont];
size.width = MAX(size.width + CELL_MESSAGE_X_MARGIN, CELL_MIN_WIDTH);
size.height = MAX(size.height + CELL_MESSAGE_Y_MARGIN + 40, CELL_MIN_HEIGHT);
size.height = MAX(size.height + CELL_MESSAGE_Y_MARGIN + 50, CELL_MIN_HEIGHT);
return size;
}