Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(140)

Unified Diff: media/blink/buffered_resource_loader.h

Issue 1029763002: Introduce CancelUponDeferral() to buffered media loaders. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Comments Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/blink/buffered_data_source_unittest.cc ('k') | media/blink/buffered_resource_loader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/buffered_resource_loader.h
diff --git a/media/blink/buffered_resource_loader.h b/media/blink/buffered_resource_loader.h
index 4f380eae15753ab55b546c2df5cd9e5becec2a94..2b9cf5791555561599a4d590754926cdff6667a0 100644
--- a/media/blink/buffered_resource_loader.h
+++ b/media/blink/buffered_resource_loader.h
@@ -198,6 +198,13 @@ class MEDIA_EXPORT BufferedResourceLoader
const std::string& content_range_str, int64* first_byte_position,
int64* last_byte_position, int64* instance_size);
+ // Cancels and closes any outstanding deferred ActiveLoader instances. Does
+ // not report a failed state, so subsequent read calls to cache may still
+ // complete okay. If the ActiveLoader is not deferred it will be canceled once
+ // it is unless playback starts before then (as determined by the reported
+ // playback rate).
+ void CancelUponDeferral();
+
private:
friend class BufferedDataSourceTest;
friend class BufferedResourceLoaderTest;
@@ -311,6 +318,8 @@ class MEDIA_EXPORT BufferedResourceLoader
scoped_refptr<MediaLog> media_log_;
+ bool cancel_upon_deferral_;
+
DISALLOW_COPY_AND_ASSIGN(BufferedResourceLoader);
};
« no previous file with comments | « media/blink/buffered_data_source_unittest.cc ('k') | media/blink/buffered_resource_loader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698