Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/autofill/personal_data_manager.h" | 5 #include "chrome/browser/autofill/personal_data_manager.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <functional> | 8 #include <functional> |
| 9 #include <iterator> | 9 #include <iterator> |
| 10 | 10 |
| (...skipping 912 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 923 iter != auxiliary_profiles_.end(); ++iter) { | 923 iter != auxiliary_profiles_.end(); ++iter) { |
| 924 if (imported_profile.IsSubsetOf(**iter)) | 924 if (imported_profile.IsSubsetOf(**iter)) |
| 925 return; | 925 return; |
| 926 } | 926 } |
| 927 | 927 |
| 928 std::vector<AutofillProfile> profiles; | 928 std::vector<AutofillProfile> profiles; |
| 929 MergeProfile(imported_profile, web_profiles_.get(), &profiles); | 929 MergeProfile(imported_profile, web_profiles_.get(), &profiles); |
| 930 SetProfiles(&profiles); | 930 SetProfiles(&profiles); |
| 931 } | 931 } |
| 932 | 932 |
| 933 | |
|
Ilya Sherman
2013/01/03 23:54:04
nit: This diff seems unrelated to this CL; please
Evan Stade
2013/01/04 02:16:58
that would be the saddest CL ever. Since you don't
| |
| 934 void PersonalDataManager::SaveImportedCreditCard( | 933 void PersonalDataManager::SaveImportedCreditCard( |
| 935 const CreditCard& imported_card) { | 934 const CreditCard& imported_card) { |
| 936 DCHECK(!imported_card.number().empty()); | 935 DCHECK(!imported_card.number().empty()); |
| 937 if (browser_context_->IsOffTheRecord()) { | 936 if (browser_context_->IsOffTheRecord()) { |
| 938 // The |IsOffTheRecord| check should happen earlier in the import process, | 937 // The |IsOffTheRecord| check should happen earlier in the import process, |
| 939 // upon form submission. | 938 // upon form submission. |
| 940 NOTREACHED(); | 939 NOTREACHED(); |
| 941 return; | 940 return; |
| 942 } | 941 } |
| 943 | 942 |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1003 | 1002 |
| 1004 void PersonalDataManager::set_metric_logger( | 1003 void PersonalDataManager::set_metric_logger( |
| 1005 const AutofillMetrics* metric_logger) { | 1004 const AutofillMetrics* metric_logger) { |
| 1006 metric_logger_.reset(metric_logger); | 1005 metric_logger_.reset(metric_logger); |
| 1007 } | 1006 } |
| 1008 | 1007 |
| 1009 void PersonalDataManager::set_browser_context( | 1008 void PersonalDataManager::set_browser_context( |
| 1010 content::BrowserContext* context) { | 1009 content::BrowserContext* context) { |
| 1011 browser_context_ = context; | 1010 browser_context_ = context; |
| 1012 } | 1011 } |
| OLD | NEW |