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

Unified Diff: components/password_manager/core/browser/password_autofill_manager.h

Issue 208453002: Add "previewing on hover" support for password field. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update code as per further review comments. Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: components/password_manager/core/browser/password_autofill_manager.h
diff --git a/components/password_manager/core/browser/password_autofill_manager.h b/components/password_manager/core/browser/password_autofill_manager.h
index 23c0a5e6e504ab9a750b90c12b64b0d1fe767f9b..88ab80144198afc48436b6fff92a74fa1c05f940 100644
--- a/components/password_manager/core/browser/password_autofill_manager.h
+++ b/components/password_manager/core/browser/password_autofill_manager.h
@@ -55,9 +55,13 @@ class PasswordAutofillManager : public autofill::AutofillPopupDelegate {
// Invoked to clear any page specific cached values.
void Reset();
- // A public version of AcceptSuggestion(), only for use in tests.
- bool AcceptSuggestionForTest(const autofill::FormFieldData& field,
- const base::string16& username);
+ // A public version of FillSuggestion(), only for use in tests.
+ bool FillSuggestionForTest(const autofill::FormFieldData& field,
+ const base::string16& username);
+
+ // A public version of PreviewSuggestion(), only for use in tests.
+ bool PreviewSuggestionForTest(const autofill::FormFieldData& field,
+ const base::string16& username);
private:
typedef std::map<autofill::FormFieldData, autofill::PasswordFormFillData>
@@ -65,8 +69,13 @@ class PasswordAutofillManager : public autofill::AutofillPopupDelegate {
// Attempts to fill the password associated with user name |username|, and
// returns true if it was successful.
- bool AcceptSuggestion(const autofill::FormFieldData& field,
- const base::string16& username);
+ bool FillSuggestion(const autofill::FormFieldData& field,
+ const base::string16& username);
+
+ // Attempts to preview the password associated with user name |username|, and
+ // returns true if it was successful.
+ bool PreviewSuggestion(const autofill::FormFieldData& field,
+ const base::string16& username);
// If |current_username| matches a username for one of the login mappings in
// |fill_data|, returns true and assigns the password to |out_password|.

Powered by Google App Engine
This is Rietveld 408576698