OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/external_tab_container_win.h" | 5 #include "chrome/browser/external_tab_container_win.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/debug/trace_event.h" | 9 #include "base/debug/trace_event.h" |
10 #include "base/i18n/rtl.h" | 10 #include "base/i18n/rtl.h" |
(...skipping 16 matching lines...) Expand all Loading... |
27 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" | 27 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" |
28 #include "chrome/browser/ui/views/browser_dialogs.h" | 28 #include "chrome/browser/ui/views/browser_dialogs.h" |
29 #include "chrome/browser/ui/views/infobars/infobar_container_view.h" | 29 #include "chrome/browser/ui/views/infobars/infobar_container_view.h" |
30 #include "chrome/browser/ui/views/page_info_bubble_view.h" | 30 #include "chrome/browser/ui/views/page_info_bubble_view.h" |
31 #include "chrome/browser/ui/views/tab_contents/render_view_context_menu_views.h" | 31 #include "chrome/browser/ui/views/tab_contents/render_view_context_menu_views.h" |
32 #include "chrome/browser/ui/views/tab_contents/tab_contents_container.h" | 32 #include "chrome/browser/ui/views/tab_contents/tab_contents_container.h" |
33 #include "chrome/common/automation_messages.h" | 33 #include "chrome/common/automation_messages.h" |
34 #include "chrome/common/chrome_constants.h" | 34 #include "chrome/common/chrome_constants.h" |
35 #include "chrome/common/render_messages.h" | 35 #include "chrome/common/render_messages.h" |
36 #include "chrome/common/url_constants.h" | 36 #include "chrome/common/url_constants.h" |
37 #include "content/browser/debugger/devtools_manager.h" | |
38 #include "content/browser/debugger/devtools_toggle_action.h" | 37 #include "content/browser/debugger/devtools_toggle_action.h" |
| 38 #include "content/browser/debugger/devtools_window.h" |
39 #include "content/browser/load_notification_details.h" | 39 #include "content/browser/load_notification_details.h" |
40 #include "content/browser/renderer_host/render_process_host.h" | 40 #include "content/browser/renderer_host/render_process_host.h" |
41 #include "content/browser/renderer_host/render_view_host.h" | 41 #include "content/browser/renderer_host/render_view_host.h" |
42 #include "content/browser/renderer_host/resource_dispatcher_host_request_info.h" | 42 #include "content/browser/renderer_host/resource_dispatcher_host_request_info.h" |
43 #include "content/browser/tab_contents/navigation_details.h" | 43 #include "content/browser/tab_contents/navigation_details.h" |
44 #include "content/browser/tab_contents/provisional_load_details.h" | 44 #include "content/browser/tab_contents/provisional_load_details.h" |
45 #include "content/common/bindings_policy.h" | 45 #include "content/common/bindings_policy.h" |
46 #include "content/common/native_web_keyboard_event.h" | 46 #include "content/common/native_web_keyboard_event.h" |
47 #include "content/common/notification_service.h" | 47 #include "content/common/notification_service.h" |
48 #include "content/common/page_transition_types.h" | 48 #include "content/common/page_transition_types.h" |
(...skipping 908 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
957 case IDC_ZOOM_PLUS: | 957 case IDC_ZOOM_PLUS: |
958 host->Send(new ViewMsg_Zoom(host->routing_id(), PageZoom::ZOOM_IN)); | 958 host->Send(new ViewMsg_Zoom(host->routing_id(), PageZoom::ZOOM_IN)); |
959 break; | 959 break; |
960 case IDC_ZOOM_NORMAL: | 960 case IDC_ZOOM_NORMAL: |
961 host->Send(new ViewMsg_Zoom(host->routing_id(), PageZoom::RESET)); | 961 host->Send(new ViewMsg_Zoom(host->routing_id(), PageZoom::RESET)); |
962 break; | 962 break; |
963 case IDC_ZOOM_MINUS: | 963 case IDC_ZOOM_MINUS: |
964 host->Send(new ViewMsg_Zoom(host->routing_id(), PageZoom::ZOOM_OUT)); | 964 host->Send(new ViewMsg_Zoom(host->routing_id(), PageZoom::ZOOM_OUT)); |
965 break; | 965 break; |
966 case IDC_DEV_TOOLS: | 966 case IDC_DEV_TOOLS: |
967 DevToolsManager::GetInstance()->ToggleDevToolsWindow( | 967 DevToolsWindow::ToggleDevToolsWindow( |
968 tab_contents_->render_view_host(), DEVTOOLS_TOGGLE_ACTION_NONE); | 968 tab_contents_->render_view_host(), DEVTOOLS_TOGGLE_ACTION_NONE); |
969 break; | 969 break; |
970 case IDC_DEV_TOOLS_CONSOLE: | 970 case IDC_DEV_TOOLS_CONSOLE: |
971 DevToolsManager::GetInstance()->ToggleDevToolsWindow( | 971 DevToolsWindow::ToggleDevToolsWindow( |
972 tab_contents_->render_view_host(), | 972 tab_contents_->render_view_host(), |
973 DEVTOOLS_TOGGLE_ACTION_SHOW_CONSOLE); | 973 DEVTOOLS_TOGGLE_ACTION_SHOW_CONSOLE); |
974 break; | 974 break; |
975 case IDC_DEV_TOOLS_INSPECT: | 975 case IDC_DEV_TOOLS_INSPECT: |
976 DevToolsManager::GetInstance()->ToggleDevToolsWindow( | 976 DevToolsWindow::ToggleDevToolsWindow( |
977 tab_contents_->render_view_host(), | 977 tab_contents_->render_view_host(), |
978 DEVTOOLS_TOGGLE_ACTION_INSPECT); | 978 DEVTOOLS_TOGGLE_ACTION_INSPECT); |
979 break; | 979 break; |
980 default: | 980 default: |
981 NOTREACHED() << "Unsupported accelerator: " << command_id; | 981 NOTREACHED() << "Unsupported accelerator: " << command_id; |
982 return false; | 982 return false; |
983 } | 983 } |
984 return true; | 984 return true; |
985 } | 985 } |
986 | 986 |
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1122 | 1122 |
1123 if (disposition == CURRENT_TAB) { | 1123 if (disposition == CURRENT_TAB) { |
1124 DCHECK(route_all_top_level_navigations_); | 1124 DCHECK(route_all_top_level_navigations_); |
1125 disposition = NEW_FOREGROUND_TAB; | 1125 disposition = NEW_FOREGROUND_TAB; |
1126 } | 1126 } |
1127 ExternalTabContainer::OpenURLFromTab(source, url, referrer, disposition, | 1127 ExternalTabContainer::OpenURLFromTab(source, url, referrer, disposition, |
1128 transition); | 1128 transition); |
1129 // support only one navigation for a dummy tab before it is killed. | 1129 // support only one navigation for a dummy tab before it is killed. |
1130 ::DestroyWindow(GetNativeView()); | 1130 ::DestroyWindow(GetNativeView()); |
1131 } | 1131 } |
OLD | NEW |