2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-30 22:25:12 +00:00

Show send action animations in Replies thread.

This commit is contained in:
John Preston
2020-09-29 11:36:30 +03:00
parent 433c147dd0
commit e8df47c926
20 changed files with 597 additions and 332 deletions

View File

@@ -1535,7 +1535,12 @@ void Updates::feedUpdate(const MTPUpdate &update) {
const auto user = session().data().userLoaded(d.vuser_id().v);
if (history && user) {
const auto when = requestingDifference() ? 0 : base::unixtime::now();
session().data().registerSendAction(history, user, d.vaction(), when);
session().data().registerSendAction(
history,
MsgId(),
user,
d.vaction(),
when);
}
} break;
@@ -1548,7 +1553,12 @@ void Updates::feedUpdate(const MTPUpdate &update) {
: session().data().userLoaded(d.vuser_id().v);
if (history && user) {
const auto when = requestingDifference() ? 0 : base::unixtime::now();
session().data().registerSendAction(history, user, d.vaction(), when);
session().data().registerSendAction(
history,
MsgId(),
user,
d.vaction(),
when);
}
} break;
@@ -1559,9 +1569,17 @@ void Updates::feedUpdate(const MTPUpdate &update) {
const auto user = (d.vuser_id().v == session().userId())
? nullptr
: session().data().userLoaded(d.vuser_id().v);
if (history && user && !d.vtop_msg_id().value_or_empty()) {
const auto when = requestingDifference() ? 0 : base::unixtime::now();
session().data().registerSendAction(history, user, d.vaction(), when);
if (history && user) {
const auto when = requestingDifference()
? 0
: base::unixtime::now();
const auto rootId = d.vtop_msg_id().value_or_empty();
session().data().registerSendAction(
history,
rootId,
user,
d.vaction(),
when);
}
} break;