mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 06:26:18 +00:00
Improve typing status sending.
This commit is contained in:
@@ -152,7 +152,14 @@ bool SendProgressManager::skipRequest(const Key &key) const {
|
||||
return true;
|
||||
}
|
||||
const auto recently = base::unixtime::now() - kSendTypingsToOfflineFor;
|
||||
return !Data::OnlineTextActive(user->onlineTill, recently);
|
||||
const auto online = user->onlineTill;
|
||||
if (online == -2) { // last seen recently
|
||||
return false;
|
||||
} else if (online < 0) {
|
||||
return (-online < recently);
|
||||
} else {
|
||||
return (online < recently);
|
||||
}
|
||||
}
|
||||
|
||||
void SendProgressManager::done(
|
||||
|
Reference in New Issue
Block a user