MESSENGER-3310 use local personal note avatar and remove url of old rooms

This commit is contained in:
Frank Rotermund
2022-07-22 16:50:46 +02:00
parent 1c4d623de4
commit ecdd1e3a48
11 changed files with 80 additions and 25 deletions
+11 -4
View File
@@ -1862,11 +1862,18 @@ static CGSize kThreadListBarButtonItemImageSize;
MXKImageView *userPictureView = ((RoomTitleView*)self.titleView).pictureView;
// Set user picture in input toolbar
if (userPictureView)
{
[self.roomDataSource.room.summary setRoomAvatarImageIn:userPictureView];
// bwi: if the room is a personal notes room a local image is used as room avatar
if (userPictureView) {
if (BwiBuildSettings.bwiUseCustomPersonalNotesAvatar
&& [self.roomDataSource.room isPersonalNotesRoom]) {
PersonalNotesDefaultService *service = [PersonalNotesDefaultService service:self.mainSession];
userPictureView.image = [UIImage imageNamed:[service avatarImageUrl]];
} else {
[self.roomDataSource.room.summary setRoomAvatarImageIn:userPictureView];
}
}
[self refreshMissedDiscussionsCount:YES];
if (RiotSettings.shared.enableThreads)