diff options
author | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-02-27 03:17:20 +0000 |
---|---|---|
committer | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-02-27 03:17:20 +0000 |
commit | 0fd9c2ef7efa8b8abc45e5081a2f33c77596458c (patch) | |
tree | 1d22408149eb3a2ff694e20a7559941afad90c32 | |
parent | 703da7149c1c5d5aac592ed76a48fa676df39dad (diff) | |
download | chromium_src-0fd9c2ef7efa8b8abc45e5081a2f33c77596458c.zip chromium_src-0fd9c2ef7efa8b8abc45e5081a2f33c77596458c.tar.gz chromium_src-0fd9c2ef7efa8b8abc45e5081a2f33c77596458c.tar.bz2 |
Make WebRTCInternals no longer listen for events that it doesn't care about.
BUG=none
TEST=none
Review URL: https://codereview.chromium.org/176883004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253696 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | content/browser/media/webrtc_internals.cc | 9 | ||||
-rw-r--r-- | content/browser/media/webrtc_internals.h | 8 | ||||
-rw-r--r-- | content/public/browser/browser_child_process_observer.h | 5 |
3 files changed, 4 insertions, 18 deletions
diff --git a/content/browser/media/webrtc_internals.cc b/content/browser/media/webrtc_internals.cc index 996ff1b..4f64cce 100644 --- a/content/browser/media/webrtc_internals.cc +++ b/content/browser/media/webrtc_internals.cc @@ -7,7 +7,6 @@ #include "base/command_line.h" #include "content/browser/media/webrtc_internals_ui_observer.h" #include "content/public/browser/browser_thread.h" -#include "content/public/browser/child_process_data.h" #include "content/public/browser/notification_service.h" #include "content/public/browser/notification_types.h" #include "content/public/browser/render_process_host.h" @@ -38,7 +37,6 @@ WebRTCInternals::WebRTCInternals() : aec_dump_enabled_(false) { registrar_.Add(this, NOTIFICATION_RENDERER_PROCESS_TERMINATED, NotificationService::AllBrowserContextsAndSources()); - BrowserChildProcessObserver::Add(this); // TODO(grunell): Shouldn't all the webrtc_internals* files be excluded from the // build if WebRTC is disabled? #if defined(ENABLE_WEBRTC) @@ -62,7 +60,6 @@ WebRTCInternals::WebRTCInternals() } WebRTCInternals::~WebRTCInternals() { - BrowserChildProcessObserver::Remove(this); } WebRTCInternals* WebRTCInternals::GetInstance() { @@ -275,12 +272,6 @@ void WebRTCInternals::SendUpdate(const string& command, base::Value* value) { OnUpdate(command, value)); } -void WebRTCInternals::BrowserChildProcessCrashed( - const ChildProcessData& data) { - DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); - OnRendererExit(data.id); -} - void WebRTCInternals::Observe(int type, const NotificationSource& source, const NotificationDetails& details) { diff --git a/content/browser/media/webrtc_internals.h b/content/browser/media/webrtc_internals.h index 4ff190e..8110336 100644 --- a/content/browser/media/webrtc_internals.h +++ b/content/browser/media/webrtc_internals.h @@ -11,7 +11,6 @@ #include "base/process/process.h" #include "base/values.h" #include "content/common/content_export.h" -#include "content/public/browser/browser_child_process_observer.h" #include "content/public/browser/notification_observer.h" #include "content/public/browser/notification_registrar.h" #include "ui/shell_dialogs/select_file_dialog.h" @@ -24,8 +23,7 @@ class WebRTCInternalsUIObserver; // It collects peer connection infomation from the renderers, // forwards the data to WebRTCInternalsUIObserver and // sends data collecting commands to the renderers. -class CONTENT_EXPORT WebRTCInternals : public BrowserChildProcessObserver, - public NotificationObserver, +class CONTENT_EXPORT WebRTCInternals : public NotificationObserver, public ui::SelectFileDialog::Listener { public: static WebRTCInternals* GetInstance(); @@ -110,10 +108,6 @@ class CONTENT_EXPORT WebRTCInternals : public BrowserChildProcessObserver, void SendUpdate(const std::string& command, base::Value* value); - // BrowserChildProcessObserver implementation. - virtual void BrowserChildProcessCrashed( - const ChildProcessData& data) OVERRIDE; - // NotificationObserver implementation. virtual void Observe(int type, const NotificationSource& source, diff --git a/content/public/browser/browser_child_process_observer.h b/content/public/browser/browser_child_process_observer.h index 12e4355..41c9c9d 100644 --- a/content/public/browser/browser_child_process_observer.h +++ b/content/public/browser/browser_child_process_observer.h @@ -11,8 +11,9 @@ namespace content { struct ChildProcessData; -// An observer API implemented by classes which are interested -// in browser child process events. +// An observer API implemented by classes which are interested in browser child +// process events. Note that render processes cannot be observed through this +// interface; use RenderProcessHostObserver instead. class CONTENT_EXPORT BrowserChildProcessObserver { public: // Called when a child process host has connected to a child process. |