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

Side by Side Diff: chrome/browser/ui/autofill/tab_autofill_manager_delegate.cc

Issue 11000016: Move forms/ out of webkit/. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Response to review Created 8 years, 2 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
OLDNEW
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/autofill/tab_autofill_manager_delegate.h" 5 #include "chrome/browser/ui/autofill/tab_autofill_manager_delegate.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "chrome/browser/autofill/password_generator.h" 8 #include "chrome/browser/autofill/password_generator.h"
9 #include "chrome/browser/infobars/infobar_tab_helper.h" 9 #include "chrome/browser/infobars/infobar_tab_helper.h"
10 #include "chrome/browser/password_manager/password_manager.h" 10 #include "chrome/browser/password_manager/password_manager.h"
11 #include "chrome/browser/prefs/pref_service.h" 11 #include "chrome/browser/prefs/pref_service.h"
12 #include "chrome/browser/profiles/profile.h" 12 #include "chrome/browser/profiles/profile.h"
13 #include "chrome/browser/sync/profile_sync_service.h" 13 #include "chrome/browser/sync/profile_sync_service.h"
14 #include "chrome/browser/sync/profile_sync_service_factory.h" 14 #include "chrome/browser/sync/profile_sync_service_factory.h"
15 #include "chrome/browser/ui/browser.h" 15 #include "chrome/browser/ui/browser.h"
16 #include "chrome/browser/ui/browser_finder.h" 16 #include "chrome/browser/ui/browser_finder.h"
17 #include "chrome/browser/ui/browser_window.h" 17 #include "chrome/browser/ui/browser_window.h"
18 #include "chrome/browser/ui/chrome_pages.h" 18 #include "chrome/browser/ui/chrome_pages.h"
19 #include "chrome/browser/ui/tab_contents/tab_contents.h" 19 #include "chrome/browser/ui/tab_contents/tab_contents.h"
20 #include "chrome/common/url_constants.h" 20 #include "chrome/common/url_constants.h"
21 #include "content/public/common/password_form.h"
21 #include "ui/gfx/rect.h" 22 #include "ui/gfx/rect.h"
22 #include "webkit/forms/password_form.h"
23 23
24 TabAutofillManagerDelegate::TabAutofillManagerDelegate(TabContents* tab) 24 TabAutofillManagerDelegate::TabAutofillManagerDelegate(TabContents* tab)
25 : tab_(tab) { 25 : tab_(tab) {
26 DCHECK(tab_); 26 DCHECK(tab_);
27 } 27 }
28 28
29 content::BrowserContext* TabAutofillManagerDelegate::GetBrowserContext() const { 29 content::BrowserContext* TabAutofillManagerDelegate::GetBrowserContext() const {
30 return tab_->profile(); 30 return tab_->profile();
31 } 31 }
32 32
(...skipping 27 matching lines...) Expand all
60 NOTIMPLEMENTED(); 60 NOTIMPLEMENTED();
61 #else 61 #else
62 Browser* browser = browser::FindBrowserWithWebContents(tab_->web_contents()); 62 Browser* browser = browser::FindBrowserWithWebContents(tab_->web_contents());
63 if (browser) 63 if (browser)
64 chrome::ShowSettingsSubPage(browser, chrome::kAutofillSubPage); 64 chrome::ShowSettingsSubPage(browser, chrome::kAutofillSubPage);
65 #endif // #if defined(OS_ANDROID) 65 #endif // #if defined(OS_ANDROID)
66 } 66 }
67 67
68 void TabAutofillManagerDelegate::ShowPasswordGenerationBubble( 68 void TabAutofillManagerDelegate::ShowPasswordGenerationBubble(
69 const gfx::Rect& bounds, 69 const gfx::Rect& bounds,
70 const webkit::forms::PasswordForm& form, 70 const content::PasswordForm& form,
71 autofill::PasswordGenerator* generator) { 71 autofill::PasswordGenerator* generator) {
72 #if defined(OS_ANDROID) 72 #if defined(OS_ANDROID)
73 NOTIMPLEMENTED(); 73 NOTIMPLEMENTED();
74 #else 74 #else
75 Browser* browser = browser::FindBrowserWithWebContents(tab_->web_contents()); 75 Browser* browser = browser::FindBrowserWithWebContents(tab_->web_contents());
76 browser->window()->ShowPasswordGenerationBubble(bounds, form, generator); 76 browser->window()->ShowPasswordGenerationBubble(bounds, form, generator);
77 #endif // #if defined(OS_ANDROID) 77 #endif // #if defined(OS_ANDROID)
78 } 78 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/autofill/tab_autofill_manager_delegate.h ('k') | chrome/browser/ui/browser_window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698