Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(152)

Side by Side Diff: chrome/browser/ui/tab_helpers.cc

Issue 477263003: pdf: Create a separate component for using the pdf pepper plugin. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/ui/tab_helpers.h" 5 #include "chrome/browser/ui/tab_helpers.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "chrome/browser/browser_process.h" 8 #include "chrome/browser/browser_process.h"
9 #include "chrome/browser/content_settings/tab_specific_content_settings.h" 9 #include "chrome/browser/content_settings/tab_specific_content_settings.h"
10 #include "chrome/browser/favicon/favicon_tab_helper.h" 10 #include "chrome/browser/favicon/favicon_tab_helper.h"
11 #include "chrome/browser/history/history_tab_helper.h" 11 #include "chrome/browser/history/history_tab_helper.h"
12 #include "chrome/browser/infobars/infobar_service.h" 12 #include "chrome/browser/infobars/infobar_service.h"
13 #include "chrome/browser/net/net_error_tab_helper.h" 13 #include "chrome/browser/net/net_error_tab_helper.h"
14 #include "chrome/browser/password_manager/chrome_password_manager_client.h" 14 #include "chrome/browser/password_manager/chrome_password_manager_client.h"
15 #include "chrome/browser/prerender/prerender_tab_helper.h" 15 #include "chrome/browser/prerender/prerender_tab_helper.h"
16 #include "chrome/browser/sessions/session_tab_helper.h" 16 #include "chrome/browser/sessions/session_tab_helper.h"
17 #include "chrome/browser/tab_contents/navigation_metrics_recorder.h" 17 #include "chrome/browser/tab_contents/navigation_metrics_recorder.h"
18 #include "chrome/browser/translate/chrome_translate_client.h" 18 #include "chrome/browser/translate/chrome_translate_client.h"
19 #include "chrome/browser/ui/autofill/chrome_autofill_client.h" 19 #include "chrome/browser/ui/autofill/chrome_autofill_client.h"
20 #include "chrome/browser/ui/blocked_content/popup_blocker_tab_helper.h" 20 #include "chrome/browser/ui/blocked_content/popup_blocker_tab_helper.h"
21 #include "chrome/browser/ui/bookmarks/bookmark_tab_helper.h" 21 #include "chrome/browser/ui/bookmarks/bookmark_tab_helper.h"
22 #include "chrome/browser/ui/find_bar/find_tab_helper.h" 22 #include "chrome/browser/ui/find_bar/find_tab_helper.h"
23 #include "chrome/browser/ui/navigation_correction_tab_observer.h" 23 #include "chrome/browser/ui/navigation_correction_tab_observer.h"
24 #include "chrome/browser/ui/pdf/chrome_pdf_tab_helper_delegate.h"
24 #include "chrome/browser/ui/prefs/prefs_tab_helper.h" 25 #include "chrome/browser/ui/prefs/prefs_tab_helper.h"
25 #include "chrome/browser/ui/search/search_tab_helper.h" 26 #include "chrome/browser/ui/search/search_tab_helper.h"
26 #include "chrome/browser/ui/tab_contents/core_tab_helper.h" 27 #include "chrome/browser/ui/tab_contents/core_tab_helper.h"
27 #include "chrome/common/chrome_switches.h" 28 #include "chrome/common/chrome_switches.h"
28 #include "components/autofill/content/browser/content_autofill_driver.h" 29 #include "components/autofill/content/browser/content_autofill_driver.h"
29 #include "components/autofill/core/browser/autofill_manager.h" 30 #include "components/autofill/core/browser/autofill_manager.h"
30 #include "components/dom_distiller/content/web_contents_main_frame_observer.h" 31 #include "components/dom_distiller/content/web_contents_main_frame_observer.h"
31 #include "components/password_manager/core/browser/password_manager.h" 32 #include "components/password_manager/core/browser/password_manager.h"
32 #include "content/public/browser/web_contents.h" 33 #include "content/public/browser/web_contents.h"
33 34
34 #if defined(OS_ANDROID) 35 #if defined(OS_ANDROID)
35 #include "chrome/browser/android/webapps/single_tab_mode_tab_helper.h" 36 #include "chrome/browser/android/webapps/single_tab_mode_tab_helper.h"
36 #include "chrome/browser/ui/android/context_menu_helper.h" 37 #include "chrome/browser/ui/android/context_menu_helper.h"
37 #include "chrome/browser/ui/android/window_android_helper.h" 38 #include "chrome/browser/ui/android/window_android_helper.h"
38 #else 39 #else
39 #include "chrome/browser/external_protocol/external_protocol_observer.h" 40 #include "chrome/browser/external_protocol/external_protocol_observer.h"
40 #include "chrome/browser/net/predictor_tab_helper.h" 41 #include "chrome/browser/net/predictor_tab_helper.h"
41 #include "chrome/browser/plugins/plugin_observer.h" 42 #include "chrome/browser/plugins/plugin_observer.h"
42 #include "chrome/browser/safe_browsing/safe_browsing_tab_observer.h" 43 #include "chrome/browser/safe_browsing/safe_browsing_tab_observer.h"
43 #include "chrome/browser/thumbnails/thumbnail_tab_helper.h" 44 #include "chrome/browser/thumbnails/thumbnail_tab_helper.h"
44 #include "chrome/browser/ui/hung_plugin_tab_helper.h" 45 #include "chrome/browser/ui/hung_plugin_tab_helper.h"
45 #include "chrome/browser/ui/passwords/manage_passwords_ui_controller.h" 46 #include "chrome/browser/ui/passwords/manage_passwords_ui_controller.h"
46 #include "chrome/browser/ui/pdf/pdf_tab_helper.h"
47 #include "chrome/browser/ui/sad_tab_helper.h" 47 #include "chrome/browser/ui/sad_tab_helper.h"
48 #include "chrome/browser/ui/search_engines/search_engine_tab_helper.h" 48 #include "chrome/browser/ui/search_engines/search_engine_tab_helper.h"
49 #include "chrome/browser/ui/sync/tab_contents_synced_tab_delegate.h" 49 #include "chrome/browser/ui/sync/tab_contents_synced_tab_delegate.h"
50 #include "chrome/browser/ui/website_settings/permission_bubble_manager.h" 50 #include "chrome/browser/ui/website_settings/permission_bubble_manager.h"
51 #include "chrome/browser/ui/zoom/zoom_controller.h" 51 #include "chrome/browser/ui/zoom/zoom_controller.h"
52 #include "components/pdf/browser/pdf_tab_helper.h"
52 #include "components/web_modal/web_contents_modal_dialog_manager.h" 53 #include "components/web_modal/web_contents_modal_dialog_manager.h"
53 #endif // defined(OS_ANDROID) 54 #endif // defined(OS_ANDROID)
54 55
55 #if defined(OS_WIN) 56 #if defined(OS_WIN)
56 #include "chrome/browser/ui/metro_pin_tab_helper_win.h" 57 #include "chrome/browser/ui/metro_pin_tab_helper_win.h"
57 #endif 58 #endif
58 59
59 #if defined(ENABLE_CAPTIVE_PORTAL_DETECTION) 60 #if defined(ENABLE_CAPTIVE_PORTAL_DETECTION)
60 #include "chrome/browser/captive_portal/captive_portal_tab_helper.h" 61 #include "chrome/browser/captive_portal/captive_portal_tab_helper.h"
61 #endif 62 #endif
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 SingleTabModeTabHelper::CreateForWebContents(web_contents); 158 SingleTabModeTabHelper::CreateForWebContents(web_contents);
158 WindowAndroidHelper::CreateForWebContents(web_contents); 159 WindowAndroidHelper::CreateForWebContents(web_contents);
159 #else 160 #else
160 chrome_browser_net::PredictorTabHelper::CreateForWebContents(web_contents); 161 chrome_browser_net::PredictorTabHelper::CreateForWebContents(web_contents);
161 extensions::ChromeExtensionWebContentsObserver::CreateForWebContents( 162 extensions::ChromeExtensionWebContentsObserver::CreateForWebContents(
162 web_contents); 163 web_contents);
163 extensions::WebNavigationTabObserver::CreateForWebContents(web_contents); 164 extensions::WebNavigationTabObserver::CreateForWebContents(web_contents);
164 ExternalProtocolObserver::CreateForWebContents(web_contents); 165 ExternalProtocolObserver::CreateForWebContents(web_contents);
165 HungPluginTabHelper::CreateForWebContents(web_contents); 166 HungPluginTabHelper::CreateForWebContents(web_contents);
166 ManagePasswordsUIController::CreateForWebContents(web_contents); 167 ManagePasswordsUIController::CreateForWebContents(web_contents);
167 PDFTabHelper::CreateForWebContents(web_contents); 168 pdf::PDFTabHelper::CreateForWebContentsWithDelegate(
169 web_contents,
170 scoped_ptr<pdf::PDFTabHelperDelegate>(new ChromePDFTabHelperDelegate()));
168 PermissionBubbleManager::CreateForWebContents(web_contents); 171 PermissionBubbleManager::CreateForWebContents(web_contents);
169 PluginObserver::CreateForWebContents(web_contents); 172 PluginObserver::CreateForWebContents(web_contents);
170 SadTabHelper::CreateForWebContents(web_contents); 173 SadTabHelper::CreateForWebContents(web_contents);
171 safe_browsing::SafeBrowsingTabObserver::CreateForWebContents(web_contents); 174 safe_browsing::SafeBrowsingTabObserver::CreateForWebContents(web_contents);
172 SearchEngineTabHelper::CreateForWebContents(web_contents); 175 SearchEngineTabHelper::CreateForWebContents(web_contents);
173 TabContentsSyncedTabDelegate::CreateForWebContents(web_contents); 176 TabContentsSyncedTabDelegate::CreateForWebContents(web_contents);
174 ThumbnailTabHelper::CreateForWebContents(web_contents); 177 ThumbnailTabHelper::CreateForWebContents(web_contents);
175 web_modal::WebContentsModalDialogManager::CreateForWebContents(web_contents); 178 web_modal::WebContentsModalDialogManager::CreateForWebContents(web_contents);
176 #endif 179 #endif
177 180
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 if (OneClickSigninHelper::CanOffer(web_contents, 220 if (OneClickSigninHelper::CanOffer(web_contents,
218 OneClickSigninHelper::CAN_OFFER_FOR_ALL, 221 OneClickSigninHelper::CAN_OFFER_FOR_ALL,
219 std::string(), 222 std::string(),
220 NULL)) { 223 NULL)) {
221 OneClickSigninHelper::CreateForWebContentsWithPasswordManager( 224 OneClickSigninHelper::CreateForWebContentsWithPasswordManager(
222 web_contents, 225 web_contents,
223 ChromePasswordManagerClient::GetManagerFromWebContents(web_contents)); 226 ChromePasswordManagerClient::GetManagerFromWebContents(web_contents));
224 } 227 }
225 #endif 228 #endif
226 } 229 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698