mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 11:08:06 +00:00
fix last update time chat room
This commit is contained in:
parent
74c0f46dfa
commit
2b9abae0cc
2 changed files with 5 additions and 7 deletions
|
|
@ -146,9 +146,9 @@ static int sorted_history_comparison(LinphoneChatRoom *to_insert, LinphoneChatRo
|
|||
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
|
||||
static NSString *kCellId = @"UIChatCell";
|
||||
UIChatCell *cell = [tableView dequeueReusableCellWithIdentifier:kCellId];
|
||||
if (cell == nil) {
|
||||
if (cell == nil)
|
||||
cell = [[UIChatCell alloc] initWithIdentifier:kCellId];
|
||||
}
|
||||
|
||||
|
||||
[cell setChatRoom:(LinphoneChatRoom *)bctbx_list_nth_data(_data, (int)[indexPath row])];
|
||||
[super accessoryForCell:cell atPath:indexPath];
|
||||
|
|
|
|||
|
|
@ -88,14 +88,12 @@
|
|||
NSString *text = [[FastAddressBook displayNameForAddress:linphone_chat_message_get_from_address(last_msg)]
|
||||
stringByAppendingFormat:@" : %@", [UIChatBubbleTextCell TextMessageForChat:last_msg]];
|
||||
// shorten long messages
|
||||
if ([text length] > 50) {
|
||||
if ([text length] > 50)
|
||||
text = [[text substringToIndex:50] stringByAppendingString:@"[...]"];
|
||||
}
|
||||
|
||||
_chatContentLabel.text = text;
|
||||
} else {
|
||||
} else
|
||||
_chatContentLabel.text = nil;
|
||||
_chatLatestTimeLabel.text = NSLocalizedString(@"Now", nil);
|
||||
}
|
||||
|
||||
[self updateUnreadBadge];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue