OLD | NEW |
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 #ifndef COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_CONTENT_PASSWORD_MANAGER_DRI
VER_H_ | 5 #ifndef COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_CONTENT_PASSWORD_MANAGER_DRI
VER_H_ |
6 #define COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_CONTENT_PASSWORD_MANAGER_DRI
VER_H_ | 6 #define COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_CONTENT_PASSWORD_MANAGER_DRI
VER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "components/password_manager/core/browser/password_autofill_manager.h" |
10 #include "components/password_manager/core/browser/password_generation_manager.h
" | 11 #include "components/password_manager/core/browser/password_generation_manager.h
" |
11 #include "components/password_manager/core/browser/password_manager.h" | 12 #include "components/password_manager/core/browser/password_manager.h" |
12 #include "components/password_manager/core/browser/password_manager_driver.h" | 13 #include "components/password_manager/core/browser/password_manager_driver.h" |
13 #include "content/public/browser/web_contents_observer.h" | 14 #include "content/public/browser/web_contents_observer.h" |
14 | 15 |
15 namespace autofill { | 16 namespace autofill { |
16 class AutofillManager; | 17 class AutofillManager; |
17 struct PasswordForm; | 18 struct PasswordForm; |
18 } | 19 } |
19 | 20 |
20 namespace content { | 21 namespace content { |
21 class WebContents; | 22 class WebContents; |
22 } | 23 } |
23 | 24 |
24 class ContentPasswordManagerDriver : public PasswordManagerDriver, | 25 class ContentPasswordManagerDriver : public PasswordManagerDriver, |
25 public content::WebContentsObserver { | 26 public content::WebContentsObserver { |
26 public: | 27 public: |
27 ContentPasswordManagerDriver(content::WebContents* web_contents, | 28 ContentPasswordManagerDriver(content::WebContents* web_contents, |
28 PasswordManagerClient* client); | 29 PasswordManagerClient* client); |
29 virtual ~ContentPasswordManagerDriver(); | 30 virtual ~ContentPasswordManagerDriver(); |
30 | 31 |
31 // PasswordManagerDriver implementation. | 32 // PasswordManagerDriver implementation. |
32 virtual void FillPasswordForm(const autofill::PasswordFormFillData& form_data) | 33 virtual void FillPasswordForm(const autofill::PasswordFormFillData& form_data) |
33 OVERRIDE; | 34 OVERRIDE; |
| 35 virtual bool DidLastPageLoadEncounterSSLErrors() OVERRIDE; |
| 36 virtual bool IsOffTheRecord() OVERRIDE; |
34 virtual void AllowPasswordGenerationForForm(autofill::PasswordForm* form) | 37 virtual void AllowPasswordGenerationForForm(autofill::PasswordForm* form) |
35 OVERRIDE; | 38 OVERRIDE; |
36 virtual void AccountCreationFormsFound( | 39 virtual void AccountCreationFormsFound( |
37 const std::vector<autofill::FormData>& forms) OVERRIDE; | 40 const std::vector<autofill::FormData>& forms) OVERRIDE; |
38 virtual bool DidLastPageLoadEncounterSSLErrors() OVERRIDE; | 41 virtual void AcceptPasswordAutofillSuggestion( |
39 virtual bool IsOffTheRecord() OVERRIDE; | 42 const base::string16& username, |
| 43 const base::string16& password) OVERRIDE; |
| 44 |
40 virtual PasswordGenerationManager* GetPasswordGenerationManager() OVERRIDE; | 45 virtual PasswordGenerationManager* GetPasswordGenerationManager() OVERRIDE; |
41 virtual PasswordManager* GetPasswordManager() OVERRIDE; | 46 virtual PasswordManager* GetPasswordManager() OVERRIDE; |
42 virtual autofill::AutofillManager* GetAutofillManager() OVERRIDE; | 47 virtual autofill::AutofillManager* GetAutofillManager() OVERRIDE; |
| 48 virtual PasswordAutofillManager* GetPasswordAutofillManager() OVERRIDE; |
43 | 49 |
44 // content::WebContentsObserver overrides. | 50 // content::WebContentsObserver overrides. |
45 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; | 51 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; |
46 virtual void DidNavigateMainFrame( | 52 virtual void DidNavigateMainFrame( |
47 const content::LoadCommittedDetails& details, | 53 const content::LoadCommittedDetails& details, |
48 const content::FrameNavigateParams& params) OVERRIDE; | 54 const content::FrameNavigateParams& params) OVERRIDE; |
49 | 55 |
50 private: | 56 private: |
51 PasswordManager password_manager_; | 57 PasswordManager password_manager_; |
52 PasswordGenerationManager password_generation_manager_; | 58 PasswordGenerationManager password_generation_manager_; |
| 59 PasswordAutofillManager password_autofill_manager_; |
53 | 60 |
54 DISALLOW_COPY_AND_ASSIGN(ContentPasswordManagerDriver); | 61 DISALLOW_COPY_AND_ASSIGN(ContentPasswordManagerDriver); |
55 }; | 62 }; |
56 | 63 |
57 #endif // COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_CONTENT_PASSWORD_MANAGER_
DRIVER_H_ | 64 #endif // COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_CONTENT_PASSWORD_MANAGER_
DRIVER_H_ |
OLD | NEW |