mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-09-02 07:25:46 +00:00
Add short-polling of stories.
This commit is contained in:
@@ -371,7 +371,12 @@ void Story::applyViewsSlice(
|
||||
}
|
||||
}
|
||||
|
||||
bool Story::applyChanges(StoryMedia media, const MTPDstoryItem &data) {
|
||||
bool Story::applyChanges(
|
||||
StoryMedia media,
|
||||
const MTPDstoryItem &data,
|
||||
TimeId now) {
|
||||
_lastUpdateTime = now;
|
||||
|
||||
const auto pinned = data.is_pinned();
|
||||
const auto edited = data.is_edited();
|
||||
const auto isPublic = data.is_public();
|
||||
@@ -424,6 +429,10 @@ bool Story::applyChanges(StoryMedia media, const MTPDstoryItem &data) {
|
||||
return true;
|
||||
}
|
||||
|
||||
TimeId Story::lastUpdateTime() const {
|
||||
return _lastUpdateTime;
|
||||
}
|
||||
|
||||
StoryPreload::StoryPreload(not_null<Story*> story, Fn<void()> done)
|
||||
: _story(story)
|
||||
, _done(std::move(done)) {
|
||||
|
Reference in New Issue
Block a user