Fix working with webpage preview GIFs.

Fixes #4533.
This commit is contained in:
John Preston 2018-03-25 23:55:04 +04:00
parent 63098d3c7d
commit efdd3df129
2 changed files with 10 additions and 0 deletions

View File

@ -908,6 +908,14 @@ std::unique_ptr<Media> MediaWebPage::clone(not_null<HistoryItem*> parent) {
return std::make_unique<MediaWebPage>(parent, _page);
}
DocumentData *MediaWebPage::document() const {
return _page->document;
}
PhotoData *MediaWebPage::photo() const {
return _page->photo;
}
WebPageData *MediaWebPage::webpage() const {
return _page;
}

View File

@ -292,6 +292,8 @@ public:
std::unique_ptr<Media> clone(not_null<HistoryItem*> parent) override;
DocumentData *document() const override;
PhotoData *photo() const override;
WebPageData *webpage() const override;
bool hasReplyPreview() const override;