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 502 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
513 // TODO(fdoray): Remove this when it's safe to do so (crbug.com/268442). | 513 // TODO(fdoray): Remove this when it's safe to do so (crbug.com/268442). |
514 prefs->ClearPref(kSyncPromoErrorMessage); | 514 prefs->ClearPref(kSyncPromoErrorMessage); |
515 #endif | 515 #endif |
516 | 516 |
517 PromoResourceService::MigrateUserPrefs(prefs); | 517 PromoResourceService::MigrateUserPrefs(prefs); |
518 TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); | 518 TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); |
519 | 519 |
520 #if defined(ENABLE_MANAGED_USERS) | 520 #if defined(ENABLE_MANAGED_USERS) |
521 ManagedUserService::MigrateUserPrefs(prefs); | 521 ManagedUserService::MigrateUserPrefs(prefs); |
522 #endif | 522 #endif |
| 523 |
| 524 #if defined(OS_MACOSX) && !defined(OS_IOS) |
| 525 autofill::AutofillManager::MigrateUserPrefs(prefs); |
| 526 #endif // defined(OS_MACOSX) && !defined(OS_IOS) |
523 } | 527 } |
524 | 528 |
525 void MigrateBrowserPrefs(Profile* profile, PrefService* local_state) { | 529 void MigrateBrowserPrefs(Profile* profile, PrefService* local_state) { |
526 // Copy pref values which have been migrated to user_prefs from local_state, | 530 // Copy pref values which have been migrated to user_prefs from local_state, |
527 // or remove them from local_state outright, if copying is not required. | 531 // or remove them from local_state outright, if copying is not required. |
528 int current_version = | 532 int current_version = |
529 local_state->GetInteger(prefs::kMultipleProfilePrefMigration); | 533 local_state->GetInteger(prefs::kMultipleProfilePrefMigration); |
530 PrefRegistrySimple* registry = static_cast<PrefRegistrySimple*>( | 534 PrefRegistrySimple* registry = static_cast<PrefRegistrySimple*>( |
531 local_state->DeprecatedGetPrefRegistry()); | 535 local_state->DeprecatedGetPrefRegistry()); |
532 | 536 |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
585 #if defined(OS_CHROMEOS) | 589 #if defined(OS_CHROMEOS) |
586 chromeos::default_pinned_apps_field_trial::MigratePrefs(local_state); | 590 chromeos::default_pinned_apps_field_trial::MigratePrefs(local_state); |
587 #endif | 591 #endif |
588 | 592 |
589 #if defined(TOOLKIT_VIEWS) | 593 #if defined(TOOLKIT_VIEWS) |
590 MigrateBrowserTabStripPrefs(local_state); | 594 MigrateBrowserTabStripPrefs(local_state); |
591 #endif | 595 #endif |
592 } | 596 } |
593 | 597 |
594 } // namespace chrome | 598 } // namespace chrome |
OLD | NEW |