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

Unified Diff: media/base/media_observer.h

Issue 2696663002: Media Remoting: Don't auto suspend the media pipeline. (Closed)
Patch Set: Addressed comments. Created 3 years, 10 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
Index: media/base/media_observer.h
diff --git a/media/base/media_observer.h b/media/base/media_observer.h
index 55558de179952a4e1b8326654285b5ffcc5c2d85..0320ef96d24bf452c4a139ccf7c4ae0d6aa0238c 100644
--- a/media/base/media_observer.h
+++ b/media/base/media_observer.h
@@ -11,6 +11,19 @@
namespace media {
+class MEDIA_EXPORT MediaObserverClient {
+ public:
+ virtual ~MediaObserverClient() {}
+
+ // Requests to restart the media pipeline and create a new renderer as soon as
+ // possible. |disable_pipeline_auto_suspend| indicates whether to disable
+ // the optimization that might suspend media pipeline.
miu 2017/02/15 02:00:43 nit: s/suspend media/suspend the media/
miu 2017/02/15 02:00:43 nit: s/the optimization/any optimizations/
xjz 2017/02/15 02:31:57 Done.
xjz 2017/02/15 02:31:57 Done.
+ virtual void SwitchRenderer(bool disable_pipeline_auto_suspend) = 0;
+
+ // Requests to activate monitoring changes on viewport intersection.
+ virtual void ActivateViewportIntersectionMonitoring(bool activate) = 0;
+};
+
// This class is an observer of media player events.
class MEDIA_EXPORT MediaObserver {
public:
@@ -45,6 +58,9 @@ class MEDIA_EXPORT MediaObserver {
// Called when a poster image URL is set, which happens when media is loaded
// or the poster attribute is changed.
virtual void OnSetPoster(const GURL& poster) = 0;
+
+ // Set the MediaObserverClient.
+ virtual void SetClient(MediaObserverClient* client) = 0;
};
} // namespace media

Powered by Google App Engine
This is Rietveld 408576698