diff options
Diffstat (limited to 'chrome/browser/tab_contents')
-rw-r--r-- | chrome/browser/tab_contents/tab_contents.cc | 5 | ||||
-rw-r--r-- | chrome/browser/tab_contents/tab_contents.h | 1 | ||||
-rw-r--r-- | chrome/browser/tab_contents/tab_contents_delegate.cc | 4 | ||||
-rw-r--r-- | chrome/browser/tab_contents/tab_contents_delegate.h | 3 |
4 files changed, 13 insertions, 0 deletions
diff --git a/chrome/browser/tab_contents/tab_contents.cc b/chrome/browser/tab_contents/tab_contents.cc index 3c35e61..01a303f 100644 --- a/chrome/browser/tab_contents/tab_contents.cc +++ b/chrome/browser/tab_contents/tab_contents.cc @@ -2112,6 +2112,11 @@ void TabContents::OnPageTranslated(int32 page_id, Details<PageTranslatedDetails>(&details)); } +void TabContents::OnSetSuggestResult(int32 page_id, const std::string& result) { + if (delegate()) + delegate()->OnSetSuggestResult(page_id, result); +} + void TabContents::DidStartProvisionalLoadForFrame( RenderViewHost* render_view_host, bool is_main_frame, diff --git a/chrome/browser/tab_contents/tab_contents.h b/chrome/browser/tab_contents/tab_contents.h index 94b2ca7..56b2844 100644 --- a/chrome/browser/tab_contents/tab_contents.h +++ b/chrome/browser/tab_contents/tab_contents.h @@ -864,6 +864,7 @@ class TabContents : public PageNavigator, const std::string& original_lang, const std::string& translated_lang, TranslateErrors::Type error_type); + virtual void OnSetSuggestResult(int32 page_id, const std::string& result); // RenderViewHostDelegate::Resource implementation. virtual void DidStartProvisionalLoadForFrame(RenderViewHost* render_view_host, diff --git a/chrome/browser/tab_contents/tab_contents_delegate.cc b/chrome/browser/tab_contents/tab_contents_delegate.cc index 2735a2c..615a438 100644 --- a/chrome/browser/tab_contents/tab_contents_delegate.cc +++ b/chrome/browser/tab_contents/tab_contents_delegate.cc @@ -168,5 +168,9 @@ void TabContentsDelegate::ContentTypeChanged(TabContents* source) { void TabContentsDelegate::CommitMatchPreview(TabContents* source) { } +void TabContentsDelegate::OnSetSuggestResult(int32 page_id, + const std::string& result) { +} + TabContentsDelegate::~TabContentsDelegate() { } diff --git a/chrome/browser/tab_contents/tab_contents_delegate.h b/chrome/browser/tab_contents/tab_contents_delegate.h index 629a8d4..56b4c9f 100644 --- a/chrome/browser/tab_contents/tab_contents_delegate.h +++ b/chrome/browser/tab_contents/tab_contents_delegate.h @@ -290,6 +290,9 @@ class TabContentsDelegate : public AutomationResourceRoutingDelegate { // preview TabContents. virtual void CommitMatchPreview(TabContents* source); + // Notifies the delegate that the page has a suggest result. + virtual void OnSetSuggestResult(int32 page_id, const std::string& result); + protected: virtual ~TabContentsDelegate(); }; |