Fixed display of online badge in pinned Saved Messages in touchbar.

- Fixed #6162.
This commit is contained in:
23rd 2019-06-22 10:42:02 +03:00 committed by John Preston
parent 7489f2297f
commit bebf58ea8d
1 changed files with 4 additions and 1 deletions

View File

@ -440,7 +440,7 @@ void AppendEmojiPacks(std::vector<PickerScrubberItem> &to) {
}
_peerChangedLifetime.destroy();
_peer = newPeer;
if (!_peer) {
if (!_peer || IsSelfPeer(_peer)) {
return;
}
Notify::PeerUpdateViewer(
@ -516,6 +516,9 @@ void AppendEmojiPacks(std::vector<PickerScrubberItem> &to) {
}
- (void) updateBadge {
if (IsSelfPeer(_peer)) {
return;
}
// Draw unread or online badge.
auto pixmap = App::pixmapFromImageInPlace(_userpic.toImage());
Painter p(&pixmap);