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

Unified Diff: chrome/browser/webdata/web_database.h

Issue 507053: Differentiate between ADD and CHANGED when adding new autofill entries. (Closed)
Patch Set: Created 11 years 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 | « chrome/browser/webdata/web_data_service_unittest.cc ('k') | chrome/browser/webdata/web_database.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/webdata/web_database.h
diff --git a/chrome/browser/webdata/web_database.h b/chrome/browser/webdata/web_database.h
index 24bba2dced61095635b2a4bd297b5badda1234df..22c482adcc67852013f146ba5cafab9578246f53 100644
--- a/chrome/browser/webdata/web_database.h
+++ b/chrome/browser/webdata/web_database.h
@@ -130,12 +130,17 @@ class WebDatabase {
//
//////////////////////////////////////////////////////////////////////////////
- // Records the form elements in |elements| in the database in the autofill
- // table.
- bool AddFormFieldValues(const std::vector<webkit_glue::FormField>& elements);
-
- // Records a single form element in in the database in the autofill table.
- bool AddFormFieldValue(const webkit_glue::FormField& element);
+ // Records the form elements in |elements| in the database in the
+ // autofill table. A list of all added and updated autofill entries
+ // is returned in the changes out parameter.
+ bool AddFormFieldValues(const std::vector<webkit_glue::FormField>& elements,
+ std::vector<AutofillChange>* changes);
+
+ // Records a single form element in in the database in the autofill
+ // table. A list of all added and updated autofill entries is
+ // returned in the changes out parameter.
+ bool AddFormFieldValue(const webkit_glue::FormField& element,
+ std::vector<AutofillChange>* changes);
// Retrieves a vector of all values which have been recorded in the autofill
// table as the value in a form element with name |name| and which start with
@@ -208,14 +213,17 @@ class WebDatabase {
private:
FRIEND_TEST(WebDatabaseTest, Autofill);
+ FRIEND_TEST(WebDatabaseTest, Autofill_AddChanges);
FRIEND_TEST(WebDatabaseTest, Autofill_RemoveBetweenChanges);
// Methods for adding autofill entries at a specified time. For
// testing only.
bool AddFormFieldValuesTime(
const std::vector<webkit_glue::FormField>& elements,
+ std::vector<AutofillChange>* changes,
base::Time time);
bool AddFormFieldValueTime(const webkit_glue::FormField& element,
+ std::vector<AutofillChange>* changes,
base::Time time);
// Removes empty values for autofill that were incorrectly stored in the DB
« no previous file with comments | « chrome/browser/webdata/web_data_service_unittest.cc ('k') | chrome/browser/webdata/web_database.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698