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 "base/debug/trace_event.h" | 7 #include "base/debug/trace_event.h" |
8 #include "base/prefs/pref_registry_simple.h" | 8 #include "base/prefs/pref_registry_simple.h" |
9 #include "base/prefs/pref_service.h" | 9 #include "base/prefs/pref_service.h" |
10 #include "chrome/browser/about_flags.h" | 10 #include "chrome/browser/about_flags.h" |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
105 | 105 |
106 #if defined(ENABLE_EXTENSIONS) | 106 #if defined(ENABLE_EXTENSIONS) |
107 #include "apps/prefs.h" | 107 #include "apps/prefs.h" |
108 #include "chrome/browser/extensions/activity_log/activity_log.h" | 108 #include "chrome/browser/extensions/activity_log/activity_log.h" |
109 #include "chrome/browser/extensions/api/commands/command_service.h" | 109 #include "chrome/browser/extensions/api/commands/command_service.h" |
110 #include "chrome/browser/extensions/api/tabs/tabs_api.h" | 110 #include "chrome/browser/extensions/api/tabs/tabs_api.h" |
111 #include "chrome/browser/extensions/launch_util.h" | 111 #include "chrome/browser/extensions/launch_util.h" |
112 #endif | 112 #endif |
113 | 113 |
114 #if defined(ENABLE_MANAGED_USERS) | 114 #if defined(ENABLE_MANAGED_USERS) |
115 #include "chrome/browser/managed_mode/managed_user_service.h" | 115 #include "chrome/browser/supervised_user/supervised_user_service.h" |
116 #include "chrome/browser/managed_mode/managed_user_shared_settings_service.h" | 116 #include "chrome/browser/supervised_user/supervised_user_shared_settings_service
.h" |
117 #include "chrome/browser/managed_mode/managed_user_sync_service.h" | 117 #include "chrome/browser/supervised_user/supervised_user_sync_service.h" |
118 #endif | 118 #endif |
119 | 119 |
120 #if defined(ENABLE_SERVICE_DISCOVERY) | 120 #if defined(ENABLE_SERVICE_DISCOVERY) |
121 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui.h" | 121 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui.h" |
122 #endif | 122 #endif |
123 | 123 |
124 #if defined(ENABLE_PLUGIN_INSTALLATION) | 124 #if defined(ENABLE_PLUGIN_INSTALLATION) |
125 #include "chrome/browser/plugins/plugins_resource_service.h" | 125 #include "chrome/browser/plugins/plugins_resource_service.h" |
126 #endif | 126 #endif |
127 | 127 |
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
391 // still expects it to be registered. | 391 // still expects it to be registered. |
392 ExtensionWebUI::RegisterProfilePrefs(registry); | 392 ExtensionWebUI::RegisterProfilePrefs(registry); |
393 extensions::ExtensionPrefs::RegisterProfilePrefs(registry); | 393 extensions::ExtensionPrefs::RegisterProfilePrefs(registry); |
394 | 394 |
395 #if defined(ENABLE_FULL_PRINTING) | 395 #if defined(ENABLE_FULL_PRINTING) |
396 print_dialog_cloud::RegisterProfilePrefs(registry); | 396 print_dialog_cloud::RegisterProfilePrefs(registry); |
397 printing::StickySettings::RegisterProfilePrefs(registry); | 397 printing::StickySettings::RegisterProfilePrefs(registry); |
398 #endif | 398 #endif |
399 | 399 |
400 #if defined(ENABLE_MANAGED_USERS) | 400 #if defined(ENABLE_MANAGED_USERS) |
401 ManagedUserService::RegisterProfilePrefs(registry); | 401 SupervisedUserService::RegisterProfilePrefs(registry); |
402 ManagedUserSharedSettingsService::RegisterProfilePrefs(registry); | 402 SupervisedUserSharedSettingsService::RegisterProfilePrefs(registry); |
403 ManagedUserSyncService::RegisterProfilePrefs(registry); | 403 SupervisedUserSyncService::RegisterProfilePrefs(registry); |
404 #endif | 404 #endif |
405 | 405 |
406 #if defined(ENABLE_NOTIFICATIONS) | 406 #if defined(ENABLE_NOTIFICATIONS) |
407 DesktopNotificationService::RegisterProfilePrefs(registry); | 407 DesktopNotificationService::RegisterProfilePrefs(registry); |
408 #endif | 408 #endif |
409 | 409 |
410 #if defined(ENABLE_SERVICE_DISCOVERY) | 410 #if defined(ENABLE_SERVICE_DISCOVERY) |
411 LocalDiscoveryUI::RegisterProfilePrefs(registry); | 411 LocalDiscoveryUI::RegisterProfilePrefs(registry); |
412 #endif | 412 #endif |
413 | 413 |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
513 #if !defined(OS_ANDROID) | 513 #if !defined(OS_ANDROID) |
514 // Cleanup now-removed sync promo error message preference. | 514 // Cleanup now-removed sync promo error message preference. |
515 // TODO(fdoray): Remove this when it's safe to do so (crbug.com/268442). | 515 // TODO(fdoray): Remove this when it's safe to do so (crbug.com/268442). |
516 prefs->ClearPref(kSyncPromoErrorMessage); | 516 prefs->ClearPref(kSyncPromoErrorMessage); |
517 #endif | 517 #endif |
518 | 518 |
519 PromoResourceService::MigrateUserPrefs(prefs); | 519 PromoResourceService::MigrateUserPrefs(prefs); |
520 TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); | 520 TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); |
521 | 521 |
522 #if defined(ENABLE_MANAGED_USERS) | 522 #if defined(ENABLE_MANAGED_USERS) |
523 ManagedUserService::MigrateUserPrefs(prefs); | 523 SupervisedUserService::MigrateUserPrefs(prefs); |
524 #endif | 524 #endif |
525 | 525 |
526 #if defined(OS_MACOSX) && !defined(OS_IOS) | 526 #if defined(OS_MACOSX) && !defined(OS_IOS) |
527 autofill::AutofillManager::MigrateUserPrefs(prefs); | 527 autofill::AutofillManager::MigrateUserPrefs(prefs); |
528 #endif // defined(OS_MACOSX) && !defined(OS_IOS) | 528 #endif // defined(OS_MACOSX) && !defined(OS_IOS) |
529 } | 529 } |
530 | 530 |
531 void MigrateBrowserPrefs(Profile* profile, PrefService* local_state) { | 531 void MigrateBrowserPrefs(Profile* profile, PrefService* local_state) { |
532 // Copy pref values which have been migrated to user_prefs from local_state, | 532 // Copy pref values which have been migrated to user_prefs from local_state, |
533 // or remove them from local_state outright, if copying is not required. | 533 // or remove them from local_state outright, if copying is not required. |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
591 #if defined(OS_CHROMEOS) | 591 #if defined(OS_CHROMEOS) |
592 chromeos::default_pinned_apps_field_trial::MigratePrefs(local_state); | 592 chromeos::default_pinned_apps_field_trial::MigratePrefs(local_state); |
593 #endif | 593 #endif |
594 | 594 |
595 #if defined(TOOLKIT_VIEWS) | 595 #if defined(TOOLKIT_VIEWS) |
596 MigrateBrowserTabStripPrefs(local_state); | 596 MigrateBrowserTabStripPrefs(local_state); |
597 #endif | 597 #endif |
598 } | 598 } |
599 | 599 |
600 } // namespace chrome | 600 } // namespace chrome |
OLD | NEW |