| Index: chrome/browser/ui/search/instant_page.cc
|
| diff --git a/chrome/browser/ui/search/instant_page.cc b/chrome/browser/ui/search/instant_page.cc
|
| index 9177352ceaf91302af700ebf926b2036c93d1002..1bdbd82e563013237e8f50f4eda39c84fa40f642 100644
|
| --- a/chrome/browser/ui/search/instant_page.cc
|
| +++ b/chrome/browser/ui/search/instant_page.cc
|
| @@ -117,6 +117,10 @@ bool InstantPage::ShouldProcessNavigateToURL() {
|
| return false;
|
| }
|
|
|
| +bool InstantPage::ShouldProcessPasteIntoOmnibox() {
|
| + return false;
|
| +}
|
| +
|
| bool InstantPage::ShouldProcessDeleteMostVisitedItem() {
|
| return false;
|
| }
|
| @@ -138,6 +142,8 @@ bool InstantPage::OnMessageReceived(const IPC::Message& message) {
|
| IPC_MESSAGE_HANDLER(ChromeViewHostMsg_FocusOmnibox, OnFocusOmnibox)
|
| IPC_MESSAGE_HANDLER(ChromeViewHostMsg_SearchBoxNavigate,
|
| OnSearchBoxNavigate);
|
| + IPC_MESSAGE_HANDLER(ChromeViewHostMsg_SearchBoxPaste,
|
| + OnSearchBoxPaste);
|
| IPC_MESSAGE_HANDLER(ChromeViewHostMsg_CountMouseover, OnCountMouseover);
|
| IPC_MESSAGE_HANDLER(ChromeViewHostMsg_SearchBoxDeleteMostVisitedItem,
|
| OnDeleteMostVisitedItem);
|
| @@ -236,6 +242,17 @@ void InstantPage::OnSearchBoxNavigate(int page_id,
|
| contents(), url, transition, disposition, is_search_type);
|
| }
|
|
|
| +void InstantPage::OnSearchBoxPaste(int page_id) {
|
| + if (!contents()->IsActiveEntry(page_id))
|
| + return;
|
| +
|
| + SearchTabHelper::FromWebContents(contents())->InstantSupportChanged(true);
|
| + if (!ShouldProcessPasteIntoOmnibox())
|
| + return;
|
| +
|
| + delegate_->PasteIntoOmnibox(contents());
|
| +}
|
| +
|
| void InstantPage::OnCountMouseover(int page_id) {
|
| if (!contents()->IsActiveEntry(page_id))
|
| return;
|
|
|