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

Unified Diff: content/renderer/renderer_webkitplatformsupport_impl.cc

Issue 9309078: Adding a skeleton MediaStreamCenter. (Closed)
Patch Set: Review comments fixed Created 8 years, 10 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/renderer_webkitplatformsupport_impl.cc
diff --git a/content/renderer/renderer_webkitplatformsupport_impl.cc b/content/renderer/renderer_webkitplatformsupport_impl.cc
index ce8e3d7019696b4f90342d98021a30f55c83779c..1ebdbf3b1b232621b115015ae99a742493604d20 100644
--- a/content/renderer/renderer_webkitplatformsupport_impl.cc
+++ b/content/renderer/renderer_webkitplatformsupport_impl.cc
@@ -651,14 +651,31 @@ void RendererWebKitPlatformSupportImpl::GetPlugins(
//------------------------------------------------------------------------------
-WebKit::WebPeerConnectionHandler*
-RendererWebKitPlatformSupportImpl::createPeerConnectionHandler(
- WebKit::WebPeerConnectionHandlerClient* client) {
+namespace {
+
+RenderViewImpl* findRenderView() {
WebFrame* web_frame = WebFrame::frameForCurrentContext();
if (!web_frame)
return NULL;
- RenderViewImpl* render_view = RenderViewImpl::FromWebView(web_frame->view());
+ return RenderViewImpl::FromWebView(web_frame->view());
+}
+
+}
+
+WebKit::WebPeerConnectionHandler*
+RendererWebKitPlatformSupportImpl::createPeerConnectionHandler(
+ WebKit::WebPeerConnectionHandlerClient* client) {
+ RenderViewImpl* render_view = findRenderView();
if (!render_view)
return NULL;
return render_view->CreatePeerConnectionHandler(client);
}
+
+WebKit::WebMediaStreamCenter*
darin (slow to review) 2012/02/13 16:27:01 nit: in this file, please add using directives to
tommyw 2012/02/13 17:30:07 Done.
+RendererWebKitPlatformSupportImpl::createMediaStreamCenter(
+ WebKit::WebMediaStreamCenterClient* client) {
+ RenderViewImpl* render_view = findRenderView();
+ if (!render_view)
+ return NULL;
+ return render_view->CreateMediaStreamCenter(client);
+}

Powered by Google App Engine
This is Rietveld 408576698