OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/renderer_host/render_view_host.h" | 5 #include "chrome/browser/renderer_host/render_view_host.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 758 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
769 OnMsgShowModalHTMLDialog) | 769 OnMsgShowModalHTMLDialog) |
770 IPC_MESSAGE_HANDLER(ViewHostMsg_FormsSeen, OnMsgFormsSeen) | 770 IPC_MESSAGE_HANDLER(ViewHostMsg_FormsSeen, OnMsgFormsSeen) |
771 IPC_MESSAGE_HANDLER(ViewHostMsg_PasswordFormsFound, OnMsgPasswordFormsFound) | 771 IPC_MESSAGE_HANDLER(ViewHostMsg_PasswordFormsFound, OnMsgPasswordFormsFound) |
772 IPC_MESSAGE_HANDLER(ViewHostMsg_PasswordFormsVisible, | 772 IPC_MESSAGE_HANDLER(ViewHostMsg_PasswordFormsVisible, |
773 OnMsgPasswordFormsVisible) | 773 OnMsgPasswordFormsVisible) |
774 IPC_MESSAGE_HANDLER(ViewHostMsg_FormSubmitted, OnMsgFormSubmitted) | 774 IPC_MESSAGE_HANDLER(ViewHostMsg_FormSubmitted, OnMsgFormSubmitted) |
775 IPC_MESSAGE_HANDLER(ViewHostMsg_StartDragging, OnMsgStartDragging) | 775 IPC_MESSAGE_HANDLER(ViewHostMsg_StartDragging, OnMsgStartDragging) |
776 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateDragCursor, OnUpdateDragCursor) | 776 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateDragCursor, OnUpdateDragCursor) |
777 IPC_MESSAGE_HANDLER(ViewHostMsg_TakeFocus, OnTakeFocus) | 777 IPC_MESSAGE_HANDLER(ViewHostMsg_TakeFocus, OnTakeFocus) |
778 IPC_MESSAGE_HANDLER(ViewHostMsg_PageHasOSDD, OnMsgPageHasOSDD) | 778 IPC_MESSAGE_HANDLER(ViewHostMsg_PageHasOSDD, OnMsgPageHasOSDD) |
| 779 IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_GetSearchProviderInstallState, |
| 780 OnMsgGetSearchProviderInstallState) |
779 IPC_MESSAGE_HANDLER(ViewHostMsg_DidGetPrintedPagesCount, | 781 IPC_MESSAGE_HANDLER(ViewHostMsg_DidGetPrintedPagesCount, |
780 OnDidGetPrintedPagesCount) | 782 OnDidGetPrintedPagesCount) |
781 IPC_MESSAGE_HANDLER(ViewHostMsg_DidPrintPage, DidPrintPage) | 783 IPC_MESSAGE_HANDLER(ViewHostMsg_DidPrintPage, DidPrintPage) |
782 IPC_MESSAGE_HANDLER(ViewHostMsg_AddMessageToConsole, OnAddMessageToConsole) | 784 IPC_MESSAGE_HANDLER(ViewHostMsg_AddMessageToConsole, OnAddMessageToConsole) |
783 IPC_MESSAGE_HANDLER(ViewHostMsg_ForwardToDevToolsAgent, | 785 IPC_MESSAGE_HANDLER(ViewHostMsg_ForwardToDevToolsAgent, |
784 OnForwardToDevToolsAgent); | 786 OnForwardToDevToolsAgent); |
785 IPC_MESSAGE_HANDLER(ViewHostMsg_ForwardToDevToolsClient, | 787 IPC_MESSAGE_HANDLER(ViewHostMsg_ForwardToDevToolsClient, |
786 OnForwardToDevToolsClient); | 788 OnForwardToDevToolsClient); |
787 IPC_MESSAGE_HANDLER(ViewHostMsg_ActivateDevToolsWindow, | 789 IPC_MESSAGE_HANDLER(ViewHostMsg_ActivateDevToolsWindow, |
788 OnActivateDevToolsWindow); | 790 OnActivateDevToolsWindow); |
(...skipping 639 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1428 RenderViewHostDelegate::View* view = delegate_->GetViewDelegate(); | 1430 RenderViewHostDelegate::View* view = delegate_->GetViewDelegate(); |
1429 if (view) | 1431 if (view) |
1430 view->TakeFocus(reverse); | 1432 view->TakeFocus(reverse); |
1431 } | 1433 } |
1432 | 1434 |
1433 void RenderViewHost::OnMsgPageHasOSDD(int32 page_id, const GURL& doc_url, | 1435 void RenderViewHost::OnMsgPageHasOSDD(int32 page_id, const GURL& doc_url, |
1434 bool autodetected) { | 1436 bool autodetected) { |
1435 delegate_->PageHasOSDD(this, page_id, doc_url, autodetected); | 1437 delegate_->PageHasOSDD(this, page_id, doc_url, autodetected); |
1436 } | 1438 } |
1437 | 1439 |
| 1440 void RenderViewHost::OnMsgGetSearchProviderInstallState( |
| 1441 const GURL& url, IPC::Message* reply_msg) { |
| 1442 ViewHostMsg_GetSearchProviderInstallState::WriteReplyParams( |
| 1443 reply_msg, |
| 1444 delegate_->GetSearchProviderInstallState(url)); |
| 1445 Send(reply_msg); |
| 1446 } |
| 1447 |
1438 void RenderViewHost::OnDidGetPrintedPagesCount(int cookie, int number_pages) { | 1448 void RenderViewHost::OnDidGetPrintedPagesCount(int cookie, int number_pages) { |
1439 RenderViewHostDelegate::Printing* printing_delegate = | 1449 RenderViewHostDelegate::Printing* printing_delegate = |
1440 delegate_->GetPrintingDelegate(); | 1450 delegate_->GetPrintingDelegate(); |
1441 if (printing_delegate) | 1451 if (printing_delegate) |
1442 printing_delegate->DidGetPrintedPagesCount(cookie, number_pages); | 1452 printing_delegate->DidGetPrintedPagesCount(cookie, number_pages); |
1443 } | 1453 } |
1444 | 1454 |
1445 void RenderViewHost::DidPrintPage( | 1455 void RenderViewHost::DidPrintPage( |
1446 const ViewHostMsg_DidPrintPage_Params& params) { | 1456 const ViewHostMsg_DidPrintPage_Params& params) { |
1447 RenderViewHostDelegate::Printing* printing_delegate = | 1457 RenderViewHostDelegate::Printing* printing_delegate = |
(...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1935 const string16& name, | 1945 const string16& name, |
1936 const string16& display_name, | 1946 const string16& display_name, |
1937 unsigned long estimated_size, | 1947 unsigned long estimated_size, |
1938 bool blocked_by_policy) { | 1948 bool blocked_by_policy) { |
1939 RenderViewHostDelegate::ContentSettings* content_settings_delegate = | 1949 RenderViewHostDelegate::ContentSettings* content_settings_delegate = |
1940 delegate_->GetContentSettingsDelegate(); | 1950 delegate_->GetContentSettingsDelegate(); |
1941 if (content_settings_delegate) | 1951 if (content_settings_delegate) |
1942 content_settings_delegate->OnWebDatabaseAccessed( | 1952 content_settings_delegate->OnWebDatabaseAccessed( |
1943 url, name, display_name, estimated_size, blocked_by_policy); | 1953 url, name, display_name, estimated_size, blocked_by_policy); |
1944 } | 1954 } |
OLD | NEW |