summaryrefslogtreecommitdiffstats
path: root/chrome/browser/views/about_ipc_dialog.cc
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-10 19:14:33 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-10 19:14:33 +0000
commit08658a41d004daaf4183537fe2314eb2532881ee (patch)
tree118bbbd7944c714098d1aa289ed1dd4cb7d5d42b /chrome/browser/views/about_ipc_dialog.cc
parent0a14d3db1762fb2e309e5f0e07279f91ed2bb128 (diff)
downloadchromium_src-08658a41d004daaf4183537fe2314eb2532881ee.zip
chromium_src-08658a41d004daaf4183537fe2314eb2532881ee.tar.gz
chromium_src-08658a41d004daaf4183537fe2314eb2532881ee.tar.bz2
Fix ipc logging for non browser processes. I broke this in my last refactoring, since the logger functions only got registered in the browser. This fix registers them using a global object for each message type (that's only compiled when debugging is enabled). One less thing to take care of when creating new message types.
Review URL: http://codereview.chromium.org/20213 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9492 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views/about_ipc_dialog.cc')
-rw-r--r--chrome/browser/views/about_ipc_dialog.cc21
1 files changed, 2 insertions, 19 deletions
diff --git a/chrome/browser/views/about_ipc_dialog.cc b/chrome/browser/views/about_ipc_dialog.cc
index e5f39d9..2042bae 100644
--- a/chrome/browser/views/about_ipc_dialog.cc
+++ b/chrome/browser/views/about_ipc_dialog.cc
@@ -2,16 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// Need to include this before any other file because it defines
-// IPC_MESSAGE_LOG_ENABLED. We need to use it to define
-// IPC_MESSAGE_MACROS_LOG_ENABLED so render_messages.h will generate the
-// ViewMsgLog et al. functions.
-#include "chrome/common/ipc_message.h"
+#include "chrome/browser/views/about_ipc_dialog.h"
#ifdef IPC_MESSAGE_LOG_ENABLED
-#define IPC_MESSAGE_MACROS_LOG_ENABLED
-
-#include "chrome/browser/views/about_ipc_dialog.h"
#include <set>
@@ -268,17 +261,7 @@ AboutIPCDialog::AboutIPCDialog()
table_(NULL),
tracking_(false) {
SetupControls();
-
- IPC::Logging* log = IPC::Logging::current();
- log->RegisterMessageLogger(ViewStart, ViewMsgLog);
- log->RegisterMessageLogger(ViewHostStart, ViewHostMsgLog);
- log->RegisterMessageLogger(PluginProcessStart, PluginProcessMsgLog);
- log->RegisterMessageLogger(PluginProcessHostStart, PluginProcessHostMsgLog);
- log->RegisterMessageLogger(PluginStart, PluginMsgLog);
- log->RegisterMessageLogger(PluginHostStart, PluginHostMsgLog);
- log->RegisterMessageLogger(NPObjectStart, NPObjectMsgLog);
-
- log->SetConsumer(this);
+ IPC::Logging::current()->SetConsumer(this);
}
AboutIPCDialog::~AboutIPCDialog() {