Keep sending typings up to 30s after offline.
This commit is contained in:
parent
1de144a48d
commit
9de4c42555
|
@ -20,6 +20,7 @@ namespace {
|
||||||
|
|
||||||
constexpr auto kCancelTypingActionTimeout = crl::time(5000);
|
constexpr auto kCancelTypingActionTimeout = crl::time(5000);
|
||||||
constexpr auto kSetMyActionForMs = 10 * crl::time(1000);
|
constexpr auto kSetMyActionForMs = 10 * crl::time(1000);
|
||||||
|
constexpr auto kSendTypingsToOfflineFor = TimeId(30);
|
||||||
|
|
||||||
} // namespace
|
} // namespace
|
||||||
|
|
||||||
|
@ -150,7 +151,8 @@ bool SendProgressManager::skipRequest(const Key &key) const {
|
||||||
} else if (user->isBot() && !user->isSupport()) {
|
} else if (user->isBot() && !user->isSupport()) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return !Data::OnlineTextActive(user->onlineTill, base::unixtime::now());
|
const auto recently = base::unixtime::now() - kSendTypingsToOfflineFor;
|
||||||
|
return !Data::OnlineTextActive(user->onlineTill, recently);
|
||||||
}
|
}
|
||||||
|
|
||||||
void SendProgressManager::done(
|
void SendProgressManager::done(
|
||||||
|
|
2
cmake
2
cmake
|
@ -1 +1 @@
|
||||||
Subproject commit b485d43a45eec75b8cbc0ab966ab3c06b5e8bac8
|
Subproject commit cfc6051fb65da4c67ccbc2a1d9e753758f995fe3
|
Loading…
Reference in New Issue