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

Unified Diff: content/public/browser/media_session.h

Issue 2623953002: [Chromecast] Fix media session blocking tests. (Closed)
Patch Set: [Chromecast] Fix media session blocking tests. Created 3 years, 11 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: content/public/browser/media_session.h
diff --git a/content/public/browser/media_session.h b/content/public/browser/media_session.h
index 509629f894ad72b8111d6e5a418046463e6d8c5b..72221ac9ed613f47e0db407e4138b17c5833337e 100644
--- a/content/public/browser/media_session.h
+++ b/content/public/browser/media_session.h
@@ -16,6 +16,7 @@ enum class MediaSessionAction;
namespace content {
+class MediaSessionObserver;
class WebContents;
// MediaSession manages the media session and audio focus for a given
@@ -23,7 +24,7 @@ class WebContents;
//
// MediaSession allows clients to observe its changes via MediaSessionObserver,
// and allows clients to resume/suspend/stop the managed players.
-class MediaSession {
+class CONTENT_EXPORT MediaSession {
public:
enum class SuspendType {
// Suspended by the system because a transient sound needs to be played.
@@ -65,6 +66,12 @@ class MediaSession {
protected:
MediaSession() = default;
+
+ private:
+ friend class MediaSessionObserver;
+
+ virtual void AddObserver(MediaSessionObserver* observer) = 0;
+ virtual void RemoveObserver(MediaSessionObserver* observer) = 0;
};
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698