summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-22 22:39:43 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-22 22:39:43 +0000
commitb507ff57fff61c3b525e62c1166ce3417fbd26df (patch)
tree2b55c08347fa9d22e7235aaff6890c66ec143d97
parent9426d30c1c3e2d9e972ce4a497f440909a777fd4 (diff)
downloadchromium_src-b507ff57fff61c3b525e62c1166ce3417fbd26df.zip
chromium_src-b507ff57fff61c3b525e62c1166ce3417fbd26df.tar.gz
chromium_src-b507ff57fff61c3b525e62c1166ce3417fbd26df.tar.bz2
Make RenderViewHostObserver interface not use a struct from view_messages.h
BUG=98716 Review URL: http://codereview.chromium.org/8636023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@111236 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/renderer_host/chrome_render_view_host_observer.cc5
-rw-r--r--chrome/browser/renderer_host/chrome_render_view_host_observer.h2
-rw-r--r--content/browser/renderer_host/render_view_host.cc3
-rw-r--r--content/browser/renderer_host/render_view_host_observer.cc2
-rw-r--r--content/browser/renderer_host/render_view_host_observer.h4
5 files changed, 6 insertions, 10 deletions
diff --git a/chrome/browser/renderer_host/chrome_render_view_host_observer.cc b/chrome/browser/renderer_host/chrome_render_view_host_observer.cc
index 01ef4a67..ce09654 100644
--- a/chrome/browser/renderer_host/chrome_render_view_host_observer.cc
+++ b/chrome/browser/renderer_host/chrome_render_view_host_observer.cc
@@ -20,7 +20,6 @@
#include "content/browser/renderer_host/render_view_host.h"
#include "content/browser/site_instance.h"
#include "content/public/browser/notification_service.h"
-#include "content/common/view_messages.h"
ChromeRenderViewHostObserver::ChromeRenderViewHostObserver(
RenderViewHost* render_view_host, chrome_browser_net::Predictor* predictor)
@@ -47,9 +46,7 @@ void ChromeRenderViewHostObserver::RenderViewHostDestroyed(
delete this;
}
-void ChromeRenderViewHostObserver::Navigate(
- const ViewMsg_Navigate_Params& params) {
- const GURL& url = params.url;
+void ChromeRenderViewHostObserver::Navigate(const GURL& url) {
if (!predictor_)
return;
if (!CommandLine::ForCurrentProcess()->HasSwitch(switches::kChromeFrame) &&
diff --git a/chrome/browser/renderer_host/chrome_render_view_host_observer.h b/chrome/browser/renderer_host/chrome_render_view_host_observer.h
index 8fdf3ef..7fac8fe 100644
--- a/chrome/browser/renderer_host/chrome_render_view_host_observer.h
+++ b/chrome/browser/renderer_host/chrome_render_view_host_observer.h
@@ -26,7 +26,7 @@ class ChromeRenderViewHostObserver : public RenderViewHostObserver {
// RenderViewHostObserver overrides.
virtual void RenderViewHostInitialized() OVERRIDE;
virtual void RenderViewHostDestroyed(RenderViewHost* rvh) OVERRIDE;
- virtual void Navigate(const ViewMsg_Navigate_Params& params) OVERRIDE;
+ virtual void Navigate(const GURL& url) OVERRIDE;
virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
private:
diff --git a/content/browser/renderer_host/render_view_host.cc b/content/browser/renderer_host/render_view_host.cc
index 68cab78..f72f29f 100644
--- a/content/browser/renderer_host/render_view_host.cc
+++ b/content/browser/renderer_host/render_view_host.cc
@@ -247,8 +247,7 @@ void RenderViewHost::Navigate(const ViewMsg_Navigate_Params& params) {
if (!params.url.SchemeIs(chrome::kJavaScriptScheme))
delegate_->DidStartLoading();
- FOR_EACH_OBSERVER(
- RenderViewHostObserver, observers_, Navigate(params));
+ FOR_EACH_OBSERVER(RenderViewHostObserver, observers_, Navigate(params.url));
}
void RenderViewHost::NavigateToURL(const GURL& url) {
diff --git a/content/browser/renderer_host/render_view_host_observer.cc b/content/browser/renderer_host/render_view_host_observer.cc
index cb19206..d0fe61e 100644
--- a/content/browser/renderer_host/render_view_host_observer.cc
+++ b/content/browser/renderer_host/render_view_host_observer.cc
@@ -24,7 +24,7 @@ void RenderViewHostObserver::RenderViewHostDestroyed(RenderViewHost* rvh) {
delete this;
}
-void RenderViewHostObserver::Navigate(const ViewMsg_Navigate_Params& params) {
+void RenderViewHostObserver::Navigate(const GURL& url) {
}
bool RenderViewHostObserver::OnMessageReceived(const IPC::Message& message) {
diff --git a/content/browser/renderer_host/render_view_host_observer.h b/content/browser/renderer_host/render_view_host_observer.h
index 2710e48..3067f43 100644
--- a/content/browser/renderer_host/render_view_host_observer.h
+++ b/content/browser/renderer_host/render_view_host_observer.h
@@ -8,8 +8,8 @@
#include "ipc/ipc_channel.h"
#include "content/common/content_export.h"
+class GURL;
class RenderViewHost;
-struct ViewMsg_Navigate_Params;
// An observer API implemented by classes which want to filter IPC messages from
// RenderViewHost.
@@ -33,7 +33,7 @@ class CONTENT_EXPORT RenderViewHostObserver : public IPC::Channel::Listener,
virtual void RenderViewHostDestroyed(RenderViewHost* render_view_host);
// Notifies that a navigation is starting.
- virtual void Navigate(const ViewMsg_Navigate_Params& params);
+ virtual void Navigate(const GURL& url);
// IPC::Channel::Listener implementation.
virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;