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

Unified Diff: content/renderer/render_view_impl.cc

Issue 8511074: test code for device enumeration from renderer process. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: rebase Created 8 years, 11 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/media/media_stream_impl.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_view_impl.cc
===================================================================
--- content/renderer/render_view_impl.cc (revision 118766)
+++ content/renderer/render_view_impl.cc (working copy)
@@ -380,6 +380,7 @@
focused_plugin_id_(-1),
#endif
ALLOW_THIS_IN_INITIALIZER_LIST(pepper_delegate_(this)) {
+printf("wwwwwwwwwwwwww RenderViewImpl::RenderViewImpl() called 1, %p\n", media_stream_dispatcher());
routing_id_ = routing_id;
surface_id_ = surface_id;
if (opener_id != MSG_ROUTING_NONE)
@@ -437,6 +438,11 @@
p2p_socket_dispatcher_ = new content::P2PSocketDispatcher(this);
#endif
+printf("wwwwwwwwwwwwww RenderViewImpl::RenderViewImpl() called 2, %p\n", media_stream_dispatcher());
+ if (!media_stream_dispatcher_)
+ media_stream_dispatcher_ = new MediaStreamDispatcher(this);
+printf("wwwwwwwwwwwwww RenderViewImpl::RenderViewImpl() called 3, %p\n", media_stream_dispatcher());
+
new MHTMLGenerator(this);
#if defined(OS_MACOSX)
new TextInputClientObserver(this);
@@ -3031,8 +3037,10 @@
p2p_socket_dispatcher_ = new content::P2PSocketDispatcher(this);
#endif
+printf("wwwwwwwwwwwwww RenderViewImpl::EnsureMediaStreamImpl() called 1, %p\n", media_stream_dispatcher());
if (!media_stream_dispatcher_)
media_stream_dispatcher_ = new MediaStreamDispatcher(this);
+printf("wwwwwwwwwwwwww RenderViewImpl::EnsureMediaStreamImpl() called 2, %p\n", media_stream_dispatcher());
if (!media_stream_impl_.get()) {
MediaStreamDependencyFactory* factory = new MediaStreamDependencyFactory();
@@ -3587,6 +3595,18 @@
const WebFindOptions& options) {
WebFrame* main_frame = webview()->mainFrame();
+ // This is for testing. Remove!!!
+ ////////////////////////////////////
+ std::string line = UTF16ToUTF8(search_text);
+ if (StartsWithASCII(line, "small", false)) {
+ printf("OnFind start to enumerate video devices ...\n");
+ media_stream_impl_->GetVideoDevice(0);
+ } else if (StartsWithASCII(line, "large", false)) {
+ printf("OnFind start to enumerate video devices ...\n");
+ media_stream_impl_->GetVideoDevice(1);
+ }
+ ////////////////////////////////////
+
// Check if the plugin still exists in the document.
if (main_frame->document().isPluginDocument() &&
GetWebPluginFromPluginDocument()) {
« no previous file with comments | « content/renderer/media/media_stream_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698