summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autofill_manager.cc
diff options
context:
space:
mode:
authordarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-16 03:53:39 +0000
committerdarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-16 03:53:39 +0000
commitacca2a1fc734142de039f65405ef259737d7a8fc (patch)
tree6275718b90618e1445cb824e615aeca7c21e6956 /chrome/browser/autofill_manager.cc
parent923bd8b63206d79cdfb0e5eba5b49e5a6f7eee7d (diff)
downloadchromium_src-acca2a1fc734142de039f65405ef259737d7a8fc.zip
chromium_src-acca2a1fc734142de039f65405ef259737d7a8fc.tar.gz
chromium_src-acca2a1fc734142de039f65405ef259737d7a8fc.tar.bz2
Move autofill related WebView{Delegate} methods into the WebKit API.
This CL also changes a bunch of autofill related wstring values to string16. R=jcampan BUG=24595 TEST=none Review URL: http://codereview.chromium.org/279001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@29244 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autofill_manager.cc')
-rw-r--r--chrome/browser/autofill_manager.cc22
1 files changed, 11 insertions, 11 deletions
diff --git a/chrome/browser/autofill_manager.cc b/chrome/browser/autofill_manager.cc
index ee274df..6c5c6c7 100644
--- a/chrome/browser/autofill_manager.cc
+++ b/chrome/browser/autofill_manager.cc
@@ -23,7 +23,7 @@ void AutofillManager::RegisterUserPrefs(PrefService* prefs) {
AutofillManager::AutofillManager(TabContents* tab_contents)
: tab_contents_(tab_contents),
pending_query_handle_(0),
- request_id_(0) {
+ query_id_(0) {
form_autofill_enabled_.Init(prefs::kFormAutofillEnabled,
profile()->GetPrefs(), NULL);
}
@@ -55,9 +55,9 @@ void AutofillManager::AutofillFormSubmitted(
StoreFormEntriesInWebDatabase(form);
}
-bool AutofillManager::GetAutofillSuggestions(int request_id,
- const std::wstring& name,
- const std::wstring& prefix) {
+bool AutofillManager::GetAutofillSuggestions(int query_id,
+ const string16& name,
+ const string16& prefix) {
if (!*form_autofill_enabled_)
return false;
@@ -70,15 +70,15 @@ bool AutofillManager::GetAutofillSuggestions(int request_id,
CancelPendingQuery();
- request_id_ = request_id;
+ query_id_ = query_id;
pending_query_handle_ = web_data_service->GetFormValuesForElementName(
name, prefix, kMaxAutofillMenuItems, this);
return true;
}
-void AutofillManager::RemoveAutofillEntry(const std::wstring& name,
- const std::wstring& value) {
+void AutofillManager::RemoveAutofillEntry(const string16& name,
+ const string16& value) {
WebDataService* web_data_service =
profile()->GetWebDataService(Profile::EXPLICIT_ACCESS);
if (!web_data_service) {
@@ -120,12 +120,12 @@ void AutofillManager::SendSuggestions(const WDTypedResult* result) {
return;
if (result) {
DCHECK(result->GetType() == AUTOFILL_VALUE_RESULT);
- const WDResult<std::vector<std::wstring> >* autofill_result =
- static_cast<const WDResult<std::vector<std::wstring> >*>(result);
+ const WDResult<std::vector<string16> >* autofill_result =
+ static_cast<const WDResult<std::vector<string16> >*>(result);
host->AutofillSuggestionsReturned(
- request_id_, autofill_result->GetValue(), -1);
+ query_id_, autofill_result->GetValue(), -1);
} else {
host->AutofillSuggestionsReturned(
- request_id_, std::vector<std::wstring>(), -1);
+ query_id_, std::vector<string16>(), -1);
}
}