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

Unified Diff: content/renderer/render_thread_impl.cc

Issue 9648007: Adding a skeleton MediaStreamCenter. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Don't create MediaStreamCenter if WebRTC is disabled. Created 8 years, 9 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
« no previous file with comments | « content/renderer/render_thread_impl.h ('k') | content/renderer/renderer_webkitplatformsupport_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_thread_impl.cc
diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc
index f4a9d66d96ebb70b1ac18dd5c17d5f92515f0981..45f3c78ba4e5d2b26ae8a84d6127cc850f6ef118 100644
--- a/content/renderer/render_thread_impl.cc
+++ b/content/renderer/render_thread_impl.cc
@@ -48,6 +48,7 @@
#include "content/renderer/gpu/compositor_thread.h"
#include "content/renderer/media/audio_input_message_filter.h"
#include "content/renderer/media/audio_message_filter.h"
+#include "content/renderer/media/media_stream_center.h"
#include "content/renderer/media/video_capture_impl_manager.h"
#include "content/renderer/media/video_capture_message_filter.h"
#include "content/renderer/plugin_channel_host.h"
@@ -209,6 +210,8 @@ void RenderThreadImpl::Init() {
main_thread_indexed_db_dispatcher_.reset(
IndexedDBDispatcher::ThreadSpecificInstance());
+ media_stream_center_ = NULL;
+
db_message_filter_ = new DBMessageFilter();
AddFilter(db_message_filter_.get());
@@ -924,6 +927,19 @@ GpuChannelHost* RenderThreadImpl::EstablishGpuChannelSync(
return GetGpuChannel();
}
+WebKit::WebMediaStreamCenter* RenderThreadImpl::CreateMediaStreamCenter(
+ WebKit::WebMediaStreamCenterClient* client) {
+#if defined(ENABLE_WEBRTC)
+ if (!CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kEnableMediaStream)) {
+ return NULL;
+ }
+ if (!media_stream_center_)
+ media_stream_center_ = new content::MediaStreamCenter(client);
+#endif
+ return media_stream_center_;
+}
+
GpuChannelHost* RenderThreadImpl::GetGpuChannel() {
if (!gpu_channel_.get())
return NULL;
« no previous file with comments | « content/renderer/render_thread_impl.h ('k') | content/renderer/renderer_webkitplatformsupport_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698