summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autofill_manager.h
diff options
context:
space:
mode:
authorpetersont@google.com <petersont@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-11-11 01:01:09 +0000
committerpetersont@google.com <petersont@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-11-11 01:01:09 +0000
commit8d0f15cbef041e318ddf691c1e2cc711c14a160e (patch)
treeeb92487eb0f96ed7d4d398ab0725b867eff0795e /chrome/browser/autofill_manager.h
parent621af4ffdbeeaee2785750258d90b096eb6c7551 (diff)
downloadchromium_src-8d0f15cbef041e318ddf691c1e2cc711c14a160e.zip
chromium_src-8d0f15cbef041e318ddf691c1e2cc711c14a160e.tar.gz
chromium_src-8d0f15cbef041e318ddf691c1e2cc711c14a160e.tar.bz2
Review URL: http://codereview.chromium.org/10005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5151 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autofill_manager.h')
-rw-r--r--chrome/browser/autofill_manager.h28
1 files changed, 16 insertions, 12 deletions
diff --git a/chrome/browser/autofill_manager.h b/chrome/browser/autofill_manager.h
index fac533f..72a04d4 100644
--- a/chrome/browser/autofill_manager.h
+++ b/chrome/browser/autofill_manager.h
@@ -9,22 +9,22 @@
#include <string>
#include "chrome/browser/webdata/web_data_service.h"
-#include "chrome/browser/web_contents.h"
+#include "chrome/common/pref_member.h"
#include "webkit/glue/autofill_form.h"
class Profile;
+class WebContents;
// Per-tab autofill manager. Handles receiving form data from the renderer and
// the storing and retrieving of form data through WebDataService.
class AutofillManager : public WebDataServiceConsumer {
public:
- explicit AutofillManager(WebContents* web_contents)
- : query_is_pending_(false), web_contents_(web_contents) {}
+ explicit AutofillManager(WebContents* web_contents);
virtual ~AutofillManager();
- void ClearPendingQuery();
+ void CancelPendingQuery();
- Profile* profile() { return web_contents_->profile(); }
+ Profile* profile();
// Called when a form is submitted (i.e. when the user hits the submit button)
// to store the form entries in the profile's sql database.
@@ -32,8 +32,11 @@ class AutofillManager : public WebDataServiceConsumer {
// Starts a query into the database for the values corresponding to name.
// OnWebDataServiceRequestDone gets called when the query completes.
- void FetchValuesForName(const std::wstring& name, const std::wstring& prefix,
- int limit);
+ void FetchValuesForName(const std::wstring& name,
+ const std::wstring& prefix,
+ int limit,
+ int64 node_id,
+ int request_id);
// WebDataServiceConsumer implementation.
virtual void OnWebDataServiceRequestDone(WebDataService::Handle h,
@@ -43,14 +46,15 @@ class AutofillManager : public WebDataServiceConsumer {
void StoreFormEntriesInWebDatabase(const AutofillForm& form);
WebContents* web_contents_;
-
+
+ BooleanPrefMember form_autofill_enabled_;
+
// When the manager makes a request from WebDataService, the database
- // is queried on another thread, we record the query in this map until we
+ // is queried on another thread, we record the query handle until we
// get called back.
- bool query_is_pending_;
WebDataService::Handle pending_query_handle_;
- std::wstring pending_query_name_;
- std::wstring pending_query_prefix_;
+ int64 node_id_;
+ int request_id_;
DISALLOW_COPY_AND_ASSIGN(AutofillManager);
};