OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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/prefs/browser_prefs.h" | 5 #include "chrome/browser/prefs/browser_prefs.h" |
6 | 6 |
7 #include "apps/prefs.h" | 7 #include "apps/prefs.h" |
8 #include "base/debug/trace_event.h" | 8 #include "base/debug/trace_event.h" |
9 #include "base/prefs/pref_registry_simple.h" | 9 #include "base/prefs/pref_registry_simple.h" |
10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
507 // TODO(fdoray): Remove this when it's safe to do so (crbug.com/268442). | 507 // TODO(fdoray): Remove this when it's safe to do so (crbug.com/268442). |
508 prefs->ClearPref(kSyncPromoErrorMessage); | 508 prefs->ClearPref(kSyncPromoErrorMessage); |
509 #endif | 509 #endif |
510 | 510 |
511 PromoResourceService::MigrateUserPrefs(prefs); | 511 PromoResourceService::MigrateUserPrefs(prefs); |
512 TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); | 512 TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); |
513 | 513 |
514 #if defined(ENABLE_MANAGED_USERS) | 514 #if defined(ENABLE_MANAGED_USERS) |
515 ManagedUserService::MigrateUserPrefs(prefs); | 515 ManagedUserService::MigrateUserPrefs(prefs); |
516 #endif | 516 #endif |
| 517 |
| 518 #if defined(OS_MACOSX) && !defined(OS_IOS) |
| 519 autofill::AutofillManager::MigrateUserPrefs(prefs); |
| 520 #endif // defined(OS_MACOSX) && !defined(OS_IOS) |
517 } | 521 } |
518 | 522 |
519 void MigrateBrowserPrefs(Profile* profile, PrefService* local_state) { | 523 void MigrateBrowserPrefs(Profile* profile, PrefService* local_state) { |
520 // Copy pref values which have been migrated to user_prefs from local_state, | 524 // Copy pref values which have been migrated to user_prefs from local_state, |
521 // or remove them from local_state outright, if copying is not required. | 525 // or remove them from local_state outright, if copying is not required. |
522 int current_version = | 526 int current_version = |
523 local_state->GetInteger(prefs::kMultipleProfilePrefMigration); | 527 local_state->GetInteger(prefs::kMultipleProfilePrefMigration); |
524 PrefRegistrySimple* registry = static_cast<PrefRegistrySimple*>( | 528 PrefRegistrySimple* registry = static_cast<PrefRegistrySimple*>( |
525 local_state->DeprecatedGetPrefRegistry()); | 529 local_state->DeprecatedGetPrefRegistry()); |
526 | 530 |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
579 #if defined(OS_CHROMEOS) | 583 #if defined(OS_CHROMEOS) |
580 chromeos::default_pinned_apps_field_trial::MigratePrefs(local_state); | 584 chromeos::default_pinned_apps_field_trial::MigratePrefs(local_state); |
581 #endif | 585 #endif |
582 | 586 |
583 #if defined(TOOLKIT_VIEWS) | 587 #if defined(TOOLKIT_VIEWS) |
584 MigrateBrowserTabStripPrefs(local_state); | 588 MigrateBrowserTabStripPrefs(local_state); |
585 #endif | 589 #endif |
586 } | 590 } |
587 | 591 |
588 } // namespace chrome | 592 } // namespace chrome |
OLD | NEW |