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

Unified Diff: content/renderer/media/media_stream_impl.h

Issue 10917167: Refactor the P2PSocketDispatcher to be created on the RenderThread instead of the RenderView. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed nits Created 8 years, 3 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/common/p2p_messages.h ('k') | content/renderer/media/media_stream_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/media_stream_impl.h
diff --git a/content/renderer/media/media_stream_impl.h b/content/renderer/media/media_stream_impl.h
index 131a27fa785c7e4fce6f7cd4bb2d0d0f7f5b2bcb..374f6efb60756b09b4770dd18b2f74f0dd2c28c6 100644
--- a/content/renderer/media/media_stream_impl.h
+++ b/content/renderer/media/media_stream_impl.h
@@ -74,7 +74,6 @@ class CONTENT_EXPORT MediaStreamImpl
NON_EXPORTED_BASE(public webkit_media::MediaStreamClient),
public MediaStreamDispatcherEventHandler,
public base::SupportsWeakPtr<MediaStreamImpl>,
- NON_EXPORTED_BASE(public content::P2PSocketDispatcherDestructionObserver),
NON_EXPORTED_BASE(public base::NonThreadSafe) {
public:
MediaStreamImpl(
@@ -136,11 +135,6 @@ class CONTENT_EXPORT MediaStreamImpl
// content::RenderViewObserver OVERRIDE
virtual void FrameWillClose(WebKit::WebFrame* frame) OVERRIDE;
- // content P2PSocketDispatcherDestructionObserver implementation.
- // This is needed since all IpcNetworkManager must be deleted before the
- // P2PSocketDispatcher is destroyed. MediaStreamImpl owns a IpcNetworkManager.
- virtual void OnSocketDispatcherDestroyed() OVERRIDE;
-
protected:
// This function is virtual for test purposes. A test can override this to
// test requesting local media streams. The function notifies WebKit that the
@@ -195,9 +189,7 @@ class CONTENT_EXPORT MediaStreamImpl
// valid for the lifetime of RenderView.
MediaStreamDispatcher* media_stream_dispatcher_;
- // p2p_socket_dispatcher_ is a weak reference, owned by RenderView. It's valid
- // for the lifetime of RenderView.
- content::P2PSocketDispatcher* p2p_socket_dispatcher_;
+ scoped_refptr<content::P2PSocketDispatcher> p2p_socket_dispatcher_;
// We own network_manager_, must be deleted on the worker thread.
// The network manager uses |p2p_socket_dispatcher_|.
« no previous file with comments | « content/common/p2p_messages.h ('k') | content/renderer/media/media_stream_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698