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

Unified Diff: webkit/glue/password_autocomplete_listener.h

Issue 155399: Add autofill dropdown support for password forms. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 5 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
« no previous file with comments | « webkit/glue/editor_client_impl.cc ('k') | webkit/glue/password_autocomplete_listener.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/password_autocomplete_listener.h
===================================================================
--- webkit/glue/password_autocomplete_listener.h (revision 19957)
+++ webkit/glue/password_autocomplete_listener.h (working copy)
@@ -32,6 +32,9 @@
virtual void SetValue(const std::wstring& value);
virtual void SetSelectionRange(size_t start, size_t end);
virtual void OnFinishedAutocompleting();
+ virtual void RefreshAutofillPopup(
+ const std::vector<std::wstring>& suggestions,
+ int default_suggestion_index);
private:
// The underlying DOM element we're wrapping. We reference the underlying
@@ -54,7 +57,9 @@
virtual void OnBlur(WebCore::HTMLInputElement* element,
const std::wstring& user_input);
virtual void OnInlineAutocompleteNeeded(WebCore::HTMLInputElement* element,
- const std::wstring& user_input);
+ const std::wstring& user_input,
+ bool backspace_or_delete,
+ bool with_suggestion_popup);
private:
// Check if the input string resembles a potential matching login
@@ -64,6 +69,10 @@
const std::wstring& username,
const std::wstring& password);
+ // Scan |data_| for prefix matches of |input| and add each to |suggestions|.
+ void GetSuggestions(const std::wstring& input,
+ std::vector<std::wstring>* suggestions);
+
// Access to password field to autocomplete on blur/username updates.
scoped_ptr<HTMLInputDelegate> password_delegate_;
scoped_ptr<HTMLInputDelegate> username_delegate_;
« no previous file with comments | « webkit/glue/editor_client_impl.cc ('k') | webkit/glue/password_autocomplete_listener.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698