OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/browser_tab_contents.h" | 5 #include "chrome/browser/ui/browser_tab_contents.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/extensions/api/web_navigation/web_navigation_api.h" | 10 #include "chrome/browser/extensions/api/web_navigation/web_navigation_api.h" |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
137 PasswordManagerDelegateImpl::CreateForWebContents(web_contents); | 137 PasswordManagerDelegateImpl::CreateForWebContents(web_contents); |
138 PasswordManager::CreateForWebContentsAndDelegate( | 138 PasswordManager::CreateForWebContentsAndDelegate( |
139 web_contents, PasswordManagerDelegateImpl::FromWebContents(web_contents)); | 139 web_contents, PasswordManagerDelegateImpl::FromWebContents(web_contents)); |
140 PDFTabHelper::CreateForWebContents(web_contents); | 140 PDFTabHelper::CreateForWebContents(web_contents); |
141 PluginObserver::CreateForWebContents(web_contents); | 141 PluginObserver::CreateForWebContents(web_contents); |
142 if (!CommandLine::ForCurrentProcess()->HasSwitch( | 142 if (!CommandLine::ForCurrentProcess()->HasSwitch( |
143 switches::kDisableBetterPopupBlocking)) { | 143 switches::kDisableBetterPopupBlocking)) { |
144 PopupBlockerTabHelper::CreateForWebContents(web_contents); | 144 PopupBlockerTabHelper::CreateForWebContents(web_contents); |
145 } | 145 } |
146 PrefsTabHelper::CreateForWebContents(web_contents); | 146 PrefsTabHelper::CreateForWebContents(web_contents); |
147 prerender::PrerenderTabHelper::CreateForWebContents(web_contents); | 147 prerender::PrerenderTabHelper::CreateForWebContentsWithPasswordManager( |
| 148 web_contents, PasswordManager::FromWebContents(web_contents)); |
148 SadTabHelper::CreateForWebContents(web_contents); | 149 SadTabHelper::CreateForWebContents(web_contents); |
149 safe_browsing::SafeBrowsingTabObserver::CreateForWebContents(web_contents); | 150 safe_browsing::SafeBrowsingTabObserver::CreateForWebContents(web_contents); |
150 SearchEngineTabHelper::CreateForWebContents(web_contents); | 151 SearchEngineTabHelper::CreateForWebContents(web_contents); |
151 SearchTabHelper::CreateForWebContents(web_contents); | 152 SearchTabHelper::CreateForWebContents(web_contents); |
152 SSLTabHelper::CreateForWebContents(web_contents); | 153 SSLTabHelper::CreateForWebContents(web_contents); |
153 TabContentsSyncedTabDelegate::CreateForWebContents(web_contents); | 154 TabContentsSyncedTabDelegate::CreateForWebContents(web_contents); |
154 TabSpecificContentSettings::CreateForWebContents(web_contents); | 155 TabSpecificContentSettings::CreateForWebContents(web_contents); |
155 ThumbnailTabHelper::CreateForWebContents(web_contents); | 156 ThumbnailTabHelper::CreateForWebContents(web_contents); |
156 TranslateTabHelper::CreateForWebContents(web_contents); | 157 TranslateTabHelper::CreateForWebContents(web_contents); |
157 ZoomController::CreateForWebContents(web_contents); | 158 ZoomController::CreateForWebContents(web_contents); |
(...skipping 18 matching lines...) Expand all Loading... |
176 #if defined(ENABLE_ONE_CLICK_SIGNIN) | 177 #if defined(ENABLE_ONE_CLICK_SIGNIN) |
177 // If this is not an incognito window, setup to handle one-click login. | 178 // If this is not an incognito window, setup to handle one-click login. |
178 // We don't want to check that the profile is already connected at this time | 179 // We don't want to check that the profile is already connected at this time |
179 // because the connected state may change while this tab is open. Having a | 180 // because the connected state may change while this tab is open. Having a |
180 // one-click signin helper attached does not cause problems if the profile | 181 // one-click signin helper attached does not cause problems if the profile |
181 // happens to be already connected. | 182 // happens to be already connected. |
182 if (OneClickSigninHelper::CanOffer(web_contents, | 183 if (OneClickSigninHelper::CanOffer(web_contents, |
183 OneClickSigninHelper::CAN_OFFER_FOR_ALL, | 184 OneClickSigninHelper::CAN_OFFER_FOR_ALL, |
184 std::string(), | 185 std::string(), |
185 NULL)) { | 186 NULL)) { |
186 OneClickSigninHelper::CreateForWebContents(web_contents); | 187 OneClickSigninHelper::CreateForWebContentsWithPasswordManager( |
| 188 web_contents, PasswordManager::FromWebContents(web_contents)); |
187 } | 189 } |
188 #endif | 190 #endif |
189 | 191 |
190 #if defined(OS_WIN) | 192 #if defined(OS_WIN) |
191 MetroPinTabHelper::CreateForWebContents(web_contents); | 193 MetroPinTabHelper::CreateForWebContents(web_contents); |
192 #endif | 194 #endif |
193 } | 195 } |
OLD | NEW |