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

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

Issue 11232014: Move a bunch of code in content\renderer to the content namespace. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix mac 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 163045)
+++ content/renderer/media/media_stream_dispatcher.cc (working copy)
@@ -10,6 +10,8 @@
#include "content/renderer/render_view_impl.h"
#include "googleurl/src/gurl.h"
+namespace content {
+
struct MediaStreamDispatcher::Request {
Request(const base::WeakPtr<MediaStreamDispatcherEventHandler>& handler,
int request_id,
@@ -59,7 +61,7 @@
};
MediaStreamDispatcher::MediaStreamDispatcher(RenderViewImpl* render_view)
- : content::RenderViewObserver(render_view),
+ : RenderViewObserver(render_view),
main_loop_(base::MessageLoopProxy::current()),
next_ipc_id_(0) {
}
@@ -117,13 +119,13 @@
media_stream::MediaStreamType type,
const GURL& security_origin) {
DCHECK(main_loop_->BelongsToCurrentThread());
- DCHECK(type == content::MEDIA_DEVICE_AUDIO_CAPTURE ||
- type == content::MEDIA_DEVICE_VIDEO_CAPTURE);
+ DCHECK(type == MEDIA_DEVICE_AUDIO_CAPTURE ||
+ type == MEDIA_DEVICE_VIDEO_CAPTURE);
DVLOG(1) << "MediaStreamDispatcher::EnumerateDevices("
<< request_id << ")";
EnumerationState* state =
- (type == content::MEDIA_DEVICE_AUDIO_CAPTURE ?
+ (type == MEDIA_DEVICE_AUDIO_CAPTURE ?
&audio_enumeration_state_ : &video_enumeration_state_);
state->requests.push_back(EnumerationRequest(event_handler, request_id));
@@ -328,9 +330,9 @@
if (request.ipc_request == request_id) {
Stream new_stream;
new_stream.handler = request.handler;
- if (content::IsAudioMediaType(device_info.stream_type)) {
+ if (IsAudioMediaType(device_info.stream_type)) {
new_stream.audio_array.push_back(device_info);
- } else if (content::IsVideoMediaType(device_info.stream_type)) {
+ } else if (IsVideoMediaType(device_info.stream_type)) {
new_stream.video_array.push_back(device_info);
} else {
NOTREACHED();
@@ -388,3 +390,5 @@
DCHECK_GT(it->second.video_array.size(), static_cast<size_t>(index));
return it->second.video_array[index].session_id;
}
+
+} // namespace content
« no previous file with comments | « content/renderer/media/media_stream_dispatcher.h ('k') | content/renderer/media/media_stream_dispatcher_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698