2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 06:35:14 +00:00

Show option to download on streaming error.

This commit is contained in:
John Preston
2019-03-04 15:28:52 +04:00
parent 003d01206f
commit dafa286b18
17 changed files with 262 additions and 169 deletions

View File

@@ -228,6 +228,9 @@ public:
[[nodiscard]] auto createStreamingLoader(Data::FileOrigin origin) const
-> std::unique_ptr<Media::Streaming::Loader>;
void setInappPlaybackFailed();
[[nodiscard]] bool inappPlaybackFailed() const;
~DocumentData();
DocumentId id = 0;
@@ -272,6 +275,7 @@ private:
int32 _duration = -1;
bool _isImage = false;
bool _supportsStreaming = false;
bool _inappPlaybackFailed = false;
ActionOnLoad _actionOnLoad = ActionOnLoadNone;
FullMsgId _actionOnLoadMsgId;
@@ -393,4 +397,8 @@ base::binary_guard ReadImageAsync(
FnMut<QImage(QImage)> postprocess,
FnMut<void(QImage&&)> done);
void HandleUnsupportedMedia(
not_null<DocumentData*> document,
FullMsgId contextId);
} // namespace Data