From 64d65e096bd762bfa54c362a83edd8dcd5ba2e53 Mon Sep 17 00:00:00 2001 From: wolfbeast Date: Mon, 21 Jan 2019 13:58:20 +0100 Subject: Make resuming of decoding work for anonymous decoders. --- image/IDecodingTask.h | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'image/IDecodingTask.h') diff --git a/image/IDecodingTask.h b/image/IDecodingTask.h index 196ce5fdc..3cbab5006 100644 --- a/image/IDecodingTask.h +++ b/image/IDecodingTask.h @@ -102,22 +102,20 @@ class AnonymousDecodingTask final : public IDecodingTask public: NS_INLINE_DECL_THREADSAFE_REFCOUNTING(AnonymousDecodingTask, override) - explicit AnonymousDecodingTask(NotNull aDecoder); + explicit AnonymousDecodingTask(NotNull aDecoder, bool aResumable); void Run() override; bool ShouldPreferSyncRun() const override { return true; } TaskPriority Priority() const override { return TaskPriority::eLow; } - // Anonymous decoders normally get all their data at once. We have tests where - // they don't; in these situations, the test re-runs them manually. So no - // matter what, we don't want to resume by posting a task to the DecodePool. - void Resume() override { } + void Resume() override; private: virtual ~AnonymousDecodingTask() { } NotNull> mDecoder; + bool mResumable; }; } // namespace image -- cgit v1.2.3