Chromium Code Reviews| Index: content/browser/renderer_host/media/audio_renderer_host.h |
| diff --git a/content/browser/renderer_host/media/audio_renderer_host.h b/content/browser/renderer_host/media/audio_renderer_host.h |
| index 38317ef8094fbe59d6200f16115d59fcda5e51fe..f2fcdef21907c8971f5a80cbf8cdf7f0fe3ef935 100644 |
| --- a/content/browser/renderer_host/media/audio_renderer_host.h |
| +++ b/content/browser/renderer_host/media/audio_renderer_host.h |
| @@ -89,6 +89,10 @@ class CONTENT_EXPORT AudioRendererHost : public BrowserMessageFilter { |
| // be called from any thread. |
| bool HasActiveAudio(); |
| + // Returns true if any streams managed by the RenderView identified by |
| + // |render_view_id| are actively playing. Can be called from any thread. |
| + bool RenderViewHasActiveAudio(int render_view_id); |
|
DaleCurtis
2014/09/30 17:15:15
const
aiolos (Not reviewing)
2014/09/30 18:15:13
Done.
|
| + |
| private: |
| friend class AudioRendererHostTest; |
| friend class BrowserThread; |
| @@ -157,6 +161,10 @@ class CONTENT_EXPORT AudioRendererHost : public BrowserMessageFilter { |
| // Returns NULL if not found. |
| AudioEntry* LookupById(int stream_id); |
| + // A helper method to update the number of playing streams and alert the |
| + // ResourceScheduler when the renderer starts or stops playing an audiostream. |
| + void UpdateNumPlayingStreams(AudioEntry* entry, bool is_playing); |
| + |
| // ID of the RenderProcessHost that owns this instance. |
| const int render_process_id_; |