summaryrefslogtreecommitdiffstats
path: root/chrome/browser/browser_focus_uitest.cc
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-05-19 22:21:26 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-05-19 22:21:26 +0000
commit216813957f67962e1c50fcbbad0d3e8fcd17760e (patch)
tree273740c80787aa384f3271aae447b8b2a135e65f /chrome/browser/browser_focus_uitest.cc
parent061c8a500fdcd398614a369093d1f80d7ac8190d (diff)
downloadchromium_src-216813957f67962e1c50fcbbad0d3e8fcd17760e.zip
chromium_src-216813957f67962e1c50fcbbad0d3e8fcd17760e.tar.gz
chromium_src-216813957f67962e1c50fcbbad0d3e8fcd17760e.tar.bz2
Remove functions in RenderViewHost and RenderWidgetHost that just send an IPC message and are called by one or two places. Have the callers send the message instead. Also remove functions which dispatch an IPC only to call TabContents. Dispatch in TabContents instead.
Review URL: http://codereview.chromium.org/7037041 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85990 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_focus_uitest.cc')
-rw-r--r--chrome/browser/browser_focus_uitest.cc12
1 files changed, 11 insertions, 1 deletions
diff --git a/chrome/browser/browser_focus_uitest.cc b/chrome/browser/browser_focus_uitest.cc
index 4ef0bec..6e9e102 100644
--- a/chrome/browser/browser_focus_uitest.cc
+++ b/chrome/browser/browser_focus_uitest.cc
@@ -24,6 +24,7 @@
#include "content/browser/tab_contents/interstitial_page.h"
#include "content/browser/tab_contents/tab_contents.h"
#include "content/browser/tab_contents/tab_contents_view.h"
+#include "content/common/view_messages.h"
#include "net/test/test_server.h"
#if defined(TOOLKIT_VIEWS) || defined(OS_WIN)
@@ -170,7 +171,16 @@ class TestInterstitialPage : public InterstitialPage {
}
protected:
- virtual void FocusedNodeChanged(bool is_editable_node) {
+ bool OnMessageReceived(const IPC::Message& message) {
+ bool handled = true;
+ IPC_BEGIN_MESSAGE_MAP(TestInterstitialPage, message)
+ IPC_MESSAGE_HANDLER(ViewHostMsg_FocusedNodeChanged, OnFocusedNodeChanged)
+ IPC_MESSAGE_UNHANDLED(handled = false)
+ IPC_END_MESSAGE_MAP()
+ return handled;
+ }
+
+ void OnFocusedNodeChanged(bool is_editable_node) {
NotificationService::current()->Notify(
NotificationType::FOCUS_CHANGED_IN_PAGE,
Source<TabContents>(tab()),