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

Side by Side Diff: components/password_manager/core/browser/password_manager.cc

Issue 1213043003: Start the migration of passwords from the Keychain. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: vabr@ comments Created 5 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 unified diff | Download patch
OLDNEW
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 "components/password_manager/core/browser/password_manager.h" 5 #include "components/password_manager/core/browser/password_manager.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/metrics/field_trial.h" 8 #include "base/metrics/field_trial.h"
9 #include "base/metrics/histogram_macros.h" 9 #include "base/metrics/histogram_macros.h"
10 #include "base/prefs/pref_service.h" 10 #include "base/prefs/pref_service.h"
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 void PasswordManager::RegisterProfilePrefs( 135 void PasswordManager::RegisterProfilePrefs(
136 user_prefs::PrefRegistrySyncable* registry) { 136 user_prefs::PrefRegistrySyncable* registry) {
137 registry->RegisterBooleanPref( 137 registry->RegisterBooleanPref(
138 prefs::kPasswordManagerSavingEnabled, 138 prefs::kPasswordManagerSavingEnabled,
139 true, 139 true,
140 user_prefs::PrefRegistrySyncable::SYNCABLE_PREF); 140 user_prefs::PrefRegistrySyncable::SYNCABLE_PREF);
141 registry->RegisterBooleanPref(prefs::kPasswordManagerAutoSignin, true); 141 registry->RegisterBooleanPref(prefs::kPasswordManagerAutoSignin, true);
142 registry->RegisterBooleanPref(prefs::kPasswordManagerAllowShowPasswords, 142 registry->RegisterBooleanPref(prefs::kPasswordManagerAllowShowPasswords,
143 true); 143 true);
144 registry->RegisterListPref(prefs::kPasswordManagerGroupsForDomains); 144 registry->RegisterListPref(prefs::kPasswordManagerGroupsForDomains);
145 #if defined(OS_MACOSX)
146 registry->RegisterIntegerPref(prefs::kKeychainMigrationStatus,
147 static_cast<int>(MigrationStatus::NOT_STARTED));
148 #endif
145 } 149 }
146 150
147 #if defined(OS_WIN) 151 #if defined(OS_WIN)
148 // static 152 // static
149 void PasswordManager::RegisterLocalPrefs(PrefRegistrySimple* registry) { 153 void PasswordManager::RegisterLocalPrefs(PrefRegistrySimple* registry) {
150 registry->RegisterInt64Pref(prefs::kOsPasswordLastChanged, 0); 154 registry->RegisterInt64Pref(prefs::kOsPasswordLastChanged, 0);
151 registry->RegisterBooleanPref(prefs::kOsPasswordBlank, false); 155 registry->RegisterBooleanPref(prefs::kOsPasswordBlank, false);
152 } 156 }
153 #endif 157 #endif
154 158
(...skipping 602 matching lines...) Expand 10 before | Expand all | Expand 10 after
757 if (ServerTypeToPrediction((*field)->server_type(), &prediction_type)) 761 if (ServerTypeToPrediction((*field)->server_type(), &prediction_type))
758 predictions[form->ToFormData()][prediction_type] = *(*field); 762 predictions[form->ToFormData()][prediction_type] = *(*field);
759 } 763 }
760 } 764 }
761 if (predictions.empty()) 765 if (predictions.empty())
762 return; 766 return;
763 driver->AutofillDataReceived(predictions); 767 driver->AutofillDataReceived(predictions);
764 } 768 }
765 769
766 } // namespace password_manager 770 } // namespace password_manager
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698