Fix appear animation when sending a reaction in a group.

This commit is contained in:
John Preston 2022-01-18 13:09:42 +03:00
parent 72a093ec77
commit e121487170
2 changed files with 3 additions and 2 deletions

View File

@ -500,7 +500,8 @@ void MessageReactions::add(const QString &reaction) {
_chosen = reaction;
if (!reaction.isEmpty()) {
if (_item->canViewReactions()) {
_recent[reaction].push_back(self);
auto &list = _recent[reaction];
list.insert(begin(list), self);
}
++_list[reaction];
}

View File

@ -128,7 +128,7 @@ void InlineList::setButtonUserpics(
if (!button.userpics) {
button.userpics = std::make_unique<Userpics>();
}
const auto count = int(users.size());
const auto count = button.count = int(users.size());
auto &list = button.userpics->list;
const auto regenerate = [&] {
if (list.size() != count) {