mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-09-05 09:05:14 +00:00
Display topic name in chats list.
This commit is contained in:
@@ -968,24 +968,9 @@ void Notification::updateNotifyDisplay() {
|
||||
|
||||
const auto topicWithChat = [&]() -> TextWithEntities {
|
||||
const auto name = _history->peer->name();
|
||||
const auto wrapIcon = [](DocumentId id) {
|
||||
return TextWithEntities{
|
||||
"@",
|
||||
{ EntityInText(
|
||||
EntityType::CustomEmoji,
|
||||
0,
|
||||
1,
|
||||
Data::SerializeCustomEmojiId({.id = id }))
|
||||
},
|
||||
};
|
||||
};
|
||||
if (!_topic) {
|
||||
return { name };
|
||||
}
|
||||
auto start = _topic->iconId()
|
||||
? wrapIcon(_topic->iconId())
|
||||
: TextWithEntities();
|
||||
return start.append(_topic->title() + u" ("_q + name + ')');
|
||||
return _topic
|
||||
? _topic->titleWithIcon().append(u" ("_q + name + ')')
|
||||
: TextWithEntities{ name };
|
||||
};
|
||||
auto title = options.hideNameAndPhoto
|
||||
? TextWithEntities{ u"Telegram Desktop"_q }
|
||||
|
Reference in New Issue
Block a user