Messages screen: Update recents display.

Apply Ribot  design on recents cell
This commit is contained in:
giomfo
2015-12-16 17:08:53 +01:00
parent 7f464f928e
commit ba57dc1653
5 changed files with 75 additions and 90 deletions
+11 -7
View File
@@ -33,6 +33,8 @@
// Round image view
[_roomAvatar.layer setCornerRadius:_roomAvatar.frame.size.width / 2];
_roomAvatar.clipsToBounds = YES;
self.roomTitle.textColor = VECTOR_TEXT_BLACK_COLOR;
}
- (void)render:(MXKCellData *)cellData
@@ -54,23 +56,25 @@
self.lastEventDescription.text = roomCellData.lastEventTextMessage;
}
self.lastEventDate.textColor = VECTOR_TEXT_GRAY_COLOR;
// Notify unreads and bing
self.bingIndicator.hidden = YES;
if (roomCellData.unreadCount)
{
self.bingIndicator.hidden = NO;
if (0 < roomCellData.unreadBingCount)
{
self.bingIndicator.hidden = NO;
self.bingIndicator.backgroundColor = roomCellData.recentsDataSource.eventFormatter.bingTextColor;
self.lastEventDate.textColor = self.bingIndicator.backgroundColor;
}
else
{
self.bingIndicator.backgroundColor = VECTOR_SILVER_COLOR;
self.lastEventDate.textColor = VECTOR_TEXT_GRAY_COLOR;
}
self.roomTitle.font = [UIFont boldSystemFontOfSize:17];
}
else
{
self.roomTitle.font = [UIFont systemFontOfSize:17];
self.bingIndicator.hidden = YES;
self.lastEventDate.textColor = VECTOR_TEXT_GRAY_COLOR;
}
self.roomAvatar.backgroundColor = [UIColor clearColor];