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 // Implementation of ChromeActiveDocument | 5 // Implementation of ChromeActiveDocument |
6 #include "chrome_frame/chrome_active_document.h" | 6 #include "chrome_frame/chrome_active_document.h" |
7 | 7 |
8 #include <hlink.h> | 8 #include <hlink.h> |
9 #include <htiface.h> | 9 #include <htiface.h> |
10 #include <initguid.h> | 10 #include <initguid.h> |
(...skipping 855 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
866 | 866 |
867 // Call base class (adds 'About' item) | 867 // Call base class (adds 'About' item) |
868 return BaseActiveX::PreProcessContextMenu(menu); | 868 return BaseActiveX::PreProcessContextMenu(menu); |
869 } | 869 } |
870 | 870 |
871 bool ChromeActiveDocument::HandleContextMenuCommand(UINT cmd, | 871 bool ChromeActiveDocument::HandleContextMenuCommand(UINT cmd, |
872 const IPC::ContextMenuParams& params) { | 872 const IPC::ContextMenuParams& params) { |
873 ScopedComPtr<IWebBrowser2> web_browser2; | 873 ScopedComPtr<IWebBrowser2> web_browser2; |
874 DoQueryService(SID_SWebBrowserApp, m_spClientSite, web_browser2.Receive()); | 874 DoQueryService(SID_SWebBrowserApp, m_spClientSite, web_browser2.Receive()); |
875 | 875 |
876 if (cmd == static_cast<UINT>(context_menu_IDC_BACK)) { | 876 if (cmd == context_menu_IDC_BACK) { |
877 web_browser2->GoBack(); | 877 web_browser2->GoBack(); |
878 } else if (cmd == static_cast<UINT>(context_menu_IDC_FORWARD)) { | 878 } else if (cmd == context_menu_IDC_FORWARD) { |
879 web_browser2->GoForward(); | 879 web_browser2->GoForward(); |
880 } else if (cmd == static_cast<UINT>(context_menu_IDC_RELOAD)) { | 880 } else if (cmd == context_menu_IDC_RELOAD) { |
881 web_browser2->Refresh(); | 881 web_browser2->Refresh(); |
882 } else { | 882 } else { |
883 return BaseActiveX::HandleContextMenuCommand(cmd, params); | 883 return BaseActiveX::HandleContextMenuCommand(cmd, params); |
884 } | 884 } |
885 | 885 |
886 return true; | 886 return true; |
887 } | 887 } |
888 | 888 |
889 HRESULT ChromeActiveDocument::IEExec(const GUID* cmd_group_guid, | 889 HRESULT ChromeActiveDocument::IEExec(const GUID* cmd_group_guid, |
890 DWORD command_id, DWORD cmd_exec_opt, | 890 DWORD command_id, DWORD cmd_exec_opt, |
(...skipping 355 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1246 ScopedComPtr<ITridentService2> trident_services; | 1246 ScopedComPtr<ITridentService2> trident_services; |
1247 trident_services.QueryFrom(shell_browser); | 1247 trident_services.QueryFrom(shell_browser); |
1248 if (trident_services) { | 1248 if (trident_services) { |
1249 trident_services->FirePrivacyImpactedStateChange(wparam); | 1249 trident_services->FirePrivacyImpactedStateChange(wparam); |
1250 } else { | 1250 } else { |
1251 NOTREACHED() << "Failed to retrieve IWebBrowser2 interface."; | 1251 NOTREACHED() << "Failed to retrieve IWebBrowser2 interface."; |
1252 } | 1252 } |
1253 return 0; | 1253 return 0; |
1254 } | 1254 } |
1255 | 1255 |
OLD | NEW |