| Index: content/browser/renderer_host/media/media_stream_dispatcher_host.cc
|
| ===================================================================
|
| --- content/browser/renderer_host/media/media_stream_dispatcher_host.cc (revision 109546)
|
| +++ content/browser/renderer_host/media/media_stream_dispatcher_host.cc (working copy)
|
| @@ -12,6 +12,17 @@
|
|
|
| namespace media_stream {
|
|
|
| +struct MediaStreamDispatcherHost::StreamRequest {
|
| + StreamRequest() {}
|
| + StreamRequest(int render_view_id, int page_request_id)
|
| + : render_view_id(render_view_id),
|
| + page_request_id(page_request_id ) {
|
| + }
|
| + int render_view_id;
|
| + // Id of the request generated by MediaStreamDispatcher.
|
| + int page_request_id;
|
| +};
|
| +
|
| MediaStreamDispatcherHost::MediaStreamDispatcherHost(
|
| const content::ResourceContext* resource_context, int render_process_id)
|
| : resource_context_(resource_context),
|
| @@ -39,7 +50,7 @@
|
|
|
| void MediaStreamDispatcherHost::OnChannelClosing() {
|
| BrowserMessageFilter::OnChannelClosing();
|
| - VLOG(1) << "MediaStreamDispatcherHost::OnChannelClosing";
|
| + DVLOG(1) << "MediaStreamDispatcherHost::OnChannelClosing";
|
|
|
| // TODO(mflodman) Remove this temporary solution when shut-down issue is
|
| // resolved, i.e. uncomment the code below.
|
| @@ -59,18 +70,18 @@
|
| int page_request_id,
|
| const media_stream::StreamOptions& components,
|
| const std::string& security_origin) {
|
| - VLOG(1) << "MediaStreamDispatcherHost::OnGenerateStream("
|
| - << render_view_id << ", "
|
| - << page_request_id << ", [ "
|
| - << (components.audio ? "audio " : "")
|
| - << ((components.video_option &
|
| - StreamOptions::kFacingUser) ?
|
| - "video_facing_user " : "")
|
| - << ((components.video_option &
|
| - StreamOptions::kFacingEnvironment) ?
|
| - "video_facing_environment " : "")
|
| - << "], "
|
| - << security_origin << ")";
|
| + DVLOG(1) << "MediaStreamDispatcherHost::OnGenerateStream("
|
| + << render_view_id << ", "
|
| + << page_request_id << ", [ "
|
| + << (components.audio ? "audio " : "")
|
| + << ((components.video_option &
|
| + StreamOptions::kFacingUser) ?
|
| + "video_facing_user " : "")
|
| + << ((components.video_option &
|
| + StreamOptions::kFacingEnvironment) ?
|
| + "video_facing_environment " : "")
|
| + << "], "
|
| + << security_origin << ")";
|
|
|
| std::string label;
|
| manager()->GenerateStream(this, render_process_id_, render_view_id,
|
| @@ -81,8 +92,8 @@
|
|
|
| void MediaStreamDispatcherHost::OnStopGeneratedStream(
|
| int render_view_id, const std::string& label) {
|
| - VLOG(1) << "MediaStreamDispatcherHost::OnStopGeneratedStream("
|
| - << ", {label = " << label << "})";
|
| + DVLOG(1) << "MediaStreamDispatcherHost::OnStopGeneratedStream("
|
| + << ", {label = " << label << "})";
|
|
|
| StreamMap::iterator it = streams_.find(label);
|
| DCHECK(it != streams_.end());
|
| @@ -95,8 +106,8 @@
|
| const StreamDeviceInfoArray& audio_devices,
|
| const StreamDeviceInfoArray& video_devices) {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
|
| - VLOG(1) << "MediaStreamDispatcherHost::StreamGenerated("
|
| - << ", {label = " << label << "})";
|
| + DVLOG(1) << "MediaStreamDispatcherHost::StreamGenerated("
|
| + << ", {label = " << label << "})";
|
|
|
| StreamMap::iterator it = streams_.find(label);
|
| DCHECK(it != streams_.end());
|
| @@ -110,8 +121,8 @@
|
| void MediaStreamDispatcherHost::StreamGenerationFailed(
|
| const std::string& label) {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
|
| - VLOG(1) << "MediaStreamDispatcherHost::StreamGenerationFailed("
|
| - << ", {label = " << label << "})";
|
| + DVLOG(1) << "MediaStreamDispatcherHost::StreamGenerationFailed("
|
| + << ", {label = " << label << "})";
|
|
|
| StreamMap::iterator it = streams_.find(label);
|
| DCHECK(it != streams_.end());
|
| @@ -125,8 +136,8 @@
|
| void MediaStreamDispatcherHost::AudioDeviceFailed(const std::string& label,
|
| int index) {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
|
| - VLOG(1) << "MediaStreamDispatcherHost::AudioDeviceFailed("
|
| - << ", {label = " << label << "})";
|
| + DVLOG(1) << "MediaStreamDispatcherHost::AudioDeviceFailed("
|
| + << ", {label = " << label << "})";
|
|
|
| StreamMap::iterator it = streams_.find(label);
|
| DCHECK(it != streams_.end());
|
| @@ -139,8 +150,8 @@
|
| void MediaStreamDispatcherHost::VideoDeviceFailed(const std::string& label,
|
| int index) {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
|
| - VLOG(1) << "MediaStreamDispatcherHost::VideoDeviceFailed("
|
| - << ", {label = " << label << "})";
|
| + DVLOG(1) << "MediaStreamDispatcherHost::VideoDeviceFailed("
|
| + << ", {label = " << label << "})";
|
|
|
| StreamMap::iterator it = streams_.find(label);
|
| DCHECK(it != streams_.end());
|
|
|