| 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/prefs/browser_prefs.h" | 5 #include "chrome/browser/prefs/browser_prefs.h" |
| 6 | 6 |
| 7 #include "chrome/browser/about_flags.h" | 7 #include "chrome/browser/about_flags.h" |
| 8 #include "chrome/browser/accessibility/invert_bubble_prefs.h" | 8 #include "chrome/browser/accessibility/invert_bubble_prefs.h" |
| 9 #include "chrome/browser/autofill/autofill_manager.h" | 9 #include "chrome/browser/autofill/autofill_manager.h" |
| 10 #include "chrome/browser/background/background_mode_manager.h" | 10 #include "chrome/browser/background/background_mode_manager.h" |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 #include "chrome/browser/ui/webui/plugins_ui.h" | 69 #include "chrome/browser/ui/webui/plugins_ui.h" |
| 70 #include "chrome/browser/ui/webui/print_preview/sticky_settings.h" | 70 #include "chrome/browser/ui/webui/print_preview/sticky_settings.h" |
| 71 #include "chrome/browser/ui/webui/sync_promo/sync_promo_ui.h" | 71 #include "chrome/browser/ui/webui/sync_promo/sync_promo_ui.h" |
| 72 #include "chrome/browser/upgrade_detector.h" | 72 #include "chrome/browser/upgrade_detector.h" |
| 73 #include "chrome/browser/web_resource/promo_resource_service.h" | 73 #include "chrome/browser/web_resource/promo_resource_service.h" |
| 74 #include "chrome/common/pref_names.h" | 74 #include "chrome/common/pref_names.h" |
| 75 #include "content/public/browser/render_process_host.h" | 75 #include "content/public/browser/render_process_host.h" |
| 76 | 76 |
| 77 #if defined(OS_MACOSX) | 77 #if defined(OS_MACOSX) |
| 78 #include "chrome/browser/ui/cocoa/confirm_quit.h" | 78 #include "chrome/browser/ui/cocoa/confirm_quit.h" |
| 79 #include "chrome/browser/ui/cocoa/presentation_mode_prefs.h" | |
| 80 #include "chrome/browser/ui/startup/obsolete_os_prompt.h" | 79 #include "chrome/browser/ui/startup/obsolete_os_prompt.h" |
| 81 #endif | 80 #endif |
| 82 | 81 |
| 83 #if defined(TOOLKIT_VIEWS) | 82 #if defined(TOOLKIT_VIEWS) |
| 84 #include "chrome/browser/ui/browser_view_prefs.h" | 83 #include "chrome/browser/ui/browser_view_prefs.h" |
| 85 #include "chrome/browser/ui/tabs/tab_strip_layout_type_prefs.h" | 84 #include "chrome/browser/ui/tabs/tab_strip_layout_type_prefs.h" |
| 86 #endif | 85 #endif |
| 87 | 86 |
| 88 #if defined(TOOLKIT_GTK) | 87 #if defined(TOOLKIT_GTK) |
| 89 #include "chrome/browser/ui/gtk/browser_window_gtk.h" | 88 #include "chrome/browser/ui/gtk/browser_window_gtk.h" |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 255 | 254 |
| 256 #if !defined(OS_ANDROID) && !defined(OS_CHROMEOS) | 255 #if !defined(OS_ANDROID) && !defined(OS_CHROMEOS) |
| 257 default_apps::RegisterUserPrefs(user_prefs); | 256 default_apps::RegisterUserPrefs(user_prefs); |
| 258 #endif | 257 #endif |
| 259 | 258 |
| 260 #if defined(OS_CHROMEOS) | 259 #if defined(OS_CHROMEOS) |
| 261 chromeos::Preferences::RegisterUserPrefs(user_prefs); | 260 chromeos::Preferences::RegisterUserPrefs(user_prefs); |
| 262 chromeos::ProxyConfigServiceImpl::RegisterPrefs(user_prefs); | 261 chromeos::ProxyConfigServiceImpl::RegisterPrefs(user_prefs); |
| 263 #endif | 262 #endif |
| 264 | 263 |
| 265 #if defined(OS_MACOSX) | |
| 266 PresentationModePrefs::RegisterUserPrefs(user_prefs); | |
| 267 #endif | |
| 268 | |
| 269 #if defined(OS_WIN) | 264 #if defined(OS_WIN) |
| 270 NetworkProfileBubble::RegisterPrefs(user_prefs); | 265 NetworkProfileBubble::RegisterPrefs(user_prefs); |
| 271 #endif | 266 #endif |
| 272 } | 267 } |
| 273 | 268 |
| 274 void MigrateBrowserPrefs(Profile* profile, PrefService* local_state) { | 269 void MigrateBrowserPrefs(Profile* profile, PrefService* local_state) { |
| 275 // Copy pref values which have been migrated to user_prefs from local_state, | 270 // Copy pref values which have been migrated to user_prefs from local_state, |
| 276 // or remove them from local_state outright, if copying is not required. | 271 // or remove them from local_state outright, if copying is not required. |
| 277 int current_version = | 272 int current_version = |
| 278 local_state->GetInteger(prefs::kMultipleProfilePrefMigration); | 273 local_state->GetInteger(prefs::kMultipleProfilePrefMigration); |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 332 } | 327 } |
| 333 local_state->ClearPref(prefs::kLastPromptedGoogleURL); | 328 local_state->ClearPref(prefs::kLastPromptedGoogleURL); |
| 334 | 329 |
| 335 current_version |= GOOGLE_URL_TRACKER_PREFS; | 330 current_version |= GOOGLE_URL_TRACKER_PREFS; |
| 336 local_state->SetInteger(prefs::kMultipleProfilePrefMigration, | 331 local_state->SetInteger(prefs::kMultipleProfilePrefMigration, |
| 337 current_version); | 332 current_version); |
| 338 } | 333 } |
| 339 } | 334 } |
| 340 | 335 |
| 341 } // namespace chrome | 336 } // namespace chrome |
| OLD | NEW |