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 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_MANAGER_H_ |
6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_MANAGER_H_ | 6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_MANAGER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 // conceivable that a user (or ui test) could attempt to submit a login | 64 // conceivable that a user (or ui test) could attempt to submit a login |
65 // prompt before the callback has occured, which would InvokeLater a call to | 65 // prompt before the callback has occured, which would InvokeLater a call to |
66 // PasswordManager::ProvisionallySave, which would interact with this object | 66 // PasswordManager::ProvisionallySave, which would interact with this object |
67 // before the db has had time to answer with matching password entries. | 67 // before the db has had time to answer with matching password entries. |
68 // This is intended to be a one-time check; if the return value is false the | 68 // This is intended to be a one-time check; if the return value is false the |
69 // expectation is caller will give up. This clearly won't work if you put it | 69 // expectation is caller will give up. This clearly won't work if you put it |
70 // in a loop and wait for matching to complete; you're (supposed to be) on | 70 // in a loop and wait for matching to complete; you're (supposed to be) on |
71 // the same thread! | 71 // the same thread! |
72 bool HasCompletedMatching(); | 72 bool HasCompletedMatching(); |
73 | 73 |
| 74 // Save password according to current password_form. If the user has chosen |
| 75 // to blacklist the password previously this will undo this action and save |
| 76 // the password. |
| 77 void SavePassword(); |
| 78 |
74 // Determines if the user opted to 'never remember' passwords for this form. | 79 // Determines if the user opted to 'never remember' passwords for this form. |
75 bool IsBlacklisted(); | 80 bool IsBlacklisted(); |
76 | 81 |
77 // Used by PasswordManager to determine whether or not to display | 82 // Used by PasswordManager to determine whether or not to display |
78 // a SavePasswordBar when given the green light to save the PasswordForm | 83 // a SavePasswordBar when given the green light to save the PasswordForm |
79 // managed by this. | 84 // managed by this. |
80 bool IsNewLogin(); | 85 bool IsNewLogin(); |
81 | 86 |
82 // Returns true if the current pending credentials were found using | 87 // Returns true if the current pending credentials were found using |
83 // origin matching of the public suffix, instead of the signon realm of the | 88 // origin matching of the public suffix, instead of the signon realm of the |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
288 // These three fields record the "ActionsTaken" by the browser and | 293 // These three fields record the "ActionsTaken" by the browser and |
289 // the user with this form, and the result. They are combined and | 294 // the user with this form, and the result. They are combined and |
290 // recorded in UMA when the manager is destroyed. | 295 // recorded in UMA when the manager is destroyed. |
291 ManagerAction manager_action_; | 296 ManagerAction manager_action_; |
292 UserAction user_action_; | 297 UserAction user_action_; |
293 SubmitResult submit_result_; | 298 SubmitResult submit_result_; |
294 | 299 |
295 DISALLOW_COPY_AND_ASSIGN(PasswordFormManager); | 300 DISALLOW_COPY_AND_ASSIGN(PasswordFormManager); |
296 }; | 301 }; |
297 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_MANAGER_H_ | 302 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_MANAGER_H_ |
OLD | NEW |