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

Unified Diff: content/renderer/media/media_stream_dispatcher.cc

Issue 11146008: remove VideoDeviceError and AudioDeviceError for media stream. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 2 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/renderer/media/media_stream_dispatcher.cc
===================================================================
--- content/renderer/media/media_stream_dispatcher.cc (revision 161798)
+++ content/renderer/media/media_stream_dispatcher.cc (working copy)
@@ -225,10 +225,6 @@
OnStreamGenerated)
IPC_MESSAGE_HANDLER(MediaStreamMsg_StreamGenerationFailed,
OnStreamGenerationFailed)
- IPC_MESSAGE_HANDLER(MediaStreamHostMsg_VideoDeviceFailed,
- OnVideoDeviceFailed)
- IPC_MESSAGE_HANDLER(MediaStreamHostMsg_AudioDeviceFailed,
- OnAudioDeviceFailed)
IPC_MESSAGE_HANDLER(MediaStreamMsg_DevicesEnumerated,
OnDevicesEnumerated)
IPC_MESSAGE_HANDLER(MediaStreamMsg_DevicesEnumerationFailed,
@@ -287,38 +283,6 @@
}
}
-void MediaStreamDispatcher::OnVideoDeviceFailed(const std::string& label,
- int index) {
- DCHECK(main_loop_->BelongsToCurrentThread());
- LabelStreamMap::iterator it = label_stream_map_.find(label);
- if (it == label_stream_map_.end())
- return;
-
- // index is the index in the video_array that has failed.
- DCHECK_GT(it->second.video_array.size(), static_cast<size_t>(index));
- media_stream::StreamDeviceInfoArray::iterator device_it =
- it->second.video_array.begin();
- it->second.video_array.erase(device_it + index);
- if (it->second.handler)
- it->second.handler->OnVideoDeviceFailed(label, index);
-}
-
-void MediaStreamDispatcher::OnAudioDeviceFailed(const std::string& label,
- int index) {
- DCHECK(main_loop_->BelongsToCurrentThread());
- LabelStreamMap::iterator it = label_stream_map_.find(label);
- if (it == label_stream_map_.end())
- return;
-
- // index is the index in the audio_array that has failed.
- DCHECK_GT(it->second.audio_array.size(), static_cast<size_t>(index));
- media_stream::StreamDeviceInfoArray::iterator device_it =
- it->second.audio_array.begin();
- it->second.audio_array.erase(device_it + index);
- if (it->second.handler)
- it->second.handler->OnAudioDeviceFailed(label, index);
-}
-
void MediaStreamDispatcher::OnDevicesEnumerated(
int request_id,
const std::string& label,
« no previous file with comments | « content/renderer/media/media_stream_dispatcher.h ('k') | content/renderer/media/media_stream_dispatcher_eventhandler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698