diff options
author | brettw@google.com <brettw@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-14 20:23:36 +0000 |
---|---|---|
committer | brettw@google.com <brettw@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-14 20:23:36 +0000 |
commit | edc286198b90c629bbf6081440512d02aef603d8 (patch) | |
tree | 6a15f556b635515188002bf6296a5334bfb1cf7e /chrome/browser/render_view_host_delegate.h | |
parent | 3d840f473245973dac230a8d998c666e73348b1d (diff) | |
download | chromium_src-edc286198b90c629bbf6081440512d02aef603d8.zip chromium_src-edc286198b90c629bbf6081440512d02aef603d8.tar.gz chromium_src-edc286198b90c629bbf6081440512d02aef603d8.tar.bz2 |
Make the FindInPageController implement its own delegate interface for
RenderViewHost so that we can get rid of the pass-throughs in WebContents.
I removed some redundant checks in WebContents when calling view() for
render_view_host() since that internally checks the null-ness of
render_view_host().
BUG=1323267
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@881 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/render_view_host_delegate.h')
-rw-r--r-- | chrome/browser/render_view_host_delegate.h | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/chrome/browser/render_view_host_delegate.h b/chrome/browser/render_view_host_delegate.h index b80d328..959f427 100644 --- a/chrome/browser/render_view_host_delegate.h +++ b/chrome/browser/render_view_host_delegate.h @@ -72,6 +72,19 @@ enum LoadState; // class RenderViewHostDelegate { public: + class FindInPage { + public: + // A find operation in the current page completed. + virtual void FindReply(int request_id, + int number_of_matches, + const gfx::Rect& selection_rect, + int active_match_ordinal, + bool final_update) = 0; + }; + + // Returns the current find in page delegate, if any. + virtual FindInPage* GetFindInPageDelegate() { return NULL; } + // Retrieves the profile to be used. virtual Profile* GetProfile() const = 0; @@ -167,21 +180,10 @@ class RenderViewHostDelegate { const GURL& url, bool showing_repost_interstitial) { } - // A find operation in the current page completed. - virtual void FindReply(int request_id, - int number_of_matches, - const gfx::Rect& selection_rect, - int active_match_ordinal, - bool final_update) { } - // The URL for the FavIcon of a page has changed. virtual void UpdateFavIconURL(RenderViewHost* render_view_host, int32 page_id, const GURL& icon_url) { } - // The FavIcon for a page needs to be downloaded. - virtual void DownloadFavIcon(RenderViewHost* render_view_host, - int32 page_id) { } - // An image that was requested to be downloaded by DownloadImage has // completed. virtual void DidDownloadImage(RenderViewHost* render_view_host, |