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

Side by Side Diff: chrome/browser/prefs/browser_prefs.cc

Issue 25034003: Moved apps metro code from apps to chrome/browser/apps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase and fix unit test Created 7 years, 2 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 | Annotate | Revision Log
OLDNEW
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 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 #if defined(OS_ANDROID) 172 #if defined(OS_ANDROID)
173 #include "chrome/browser/ui/webui/ntp/android/promo_handler.h" 173 #include "chrome/browser/ui/webui/ntp/android/promo_handler.h"
174 #else 174 #else
175 #include "chrome/browser/ui/autofill/generated_credit_card_bubble_controller.h" 175 #include "chrome/browser/ui/autofill/generated_credit_card_bubble_controller.h"
176 #endif 176 #endif
177 177
178 #if defined(ENABLE_PLUGIN_INSTALLATION) 178 #if defined(ENABLE_PLUGIN_INSTALLATION)
179 #include "chrome/browser/plugins/plugins_resource_service.h" 179 #include "chrome/browser/plugins/plugins_resource_service.h"
180 #endif 180 #endif
181 181
182 #if defined(OS_WIN)
183 #include "chrome/browser/apps/app_launch_for_metro_restart_win.h"
184 #endif
185
182 namespace { 186 namespace {
183 187
184 enum MigratedPreferences { 188 enum MigratedPreferences {
185 NO_PREFS = 0, 189 NO_PREFS = 0,
186 DNS_PREFS = 1 << 0, 190 DNS_PREFS = 1 << 0,
187 WINDOWS_PREFS = 1 << 1, 191 WINDOWS_PREFS = 1 << 1,
188 GOOGLE_URL_TRACKER_PREFS = 1 << 2, 192 GOOGLE_URL_TRACKER_PREFS = 1 << 2,
189 }; 193 };
190 194
191 // A previous feature (see 195 // A previous feature (see
(...skipping 15 matching lines...) Expand all
207 } // namespace 211 } // namespace
208 212
209 namespace chrome { 213 namespace chrome {
210 214
211 void RegisterLocalState(PrefRegistrySimple* registry) { 215 void RegisterLocalState(PrefRegistrySimple* registry) {
212 // Prefs in Local State. 216 // Prefs in Local State.
213 registry->RegisterIntegerPref(prefs::kMultipleProfilePrefMigration, 0); 217 registry->RegisterIntegerPref(prefs::kMultipleProfilePrefMigration, 0);
214 218
215 // Please keep this list alphabetized. 219 // Please keep this list alphabetized.
216 AppListService::RegisterPrefs(registry); 220 AppListService::RegisterPrefs(registry);
217 apps::RegisterPrefs(registry);
218 browser_shutdown::RegisterPrefs(registry); 221 browser_shutdown::RegisterPrefs(registry);
219 BrowserProcessImpl::RegisterPrefs(registry); 222 BrowserProcessImpl::RegisterPrefs(registry);
220 RegisterScreenshotPrefs(registry); 223 RegisterScreenshotPrefs(registry);
221 ExternalProtocolHandler::RegisterPrefs(registry); 224 ExternalProtocolHandler::RegisterPrefs(registry);
222 FlagsUI::RegisterPrefs(registry); 225 FlagsUI::RegisterPrefs(registry);
223 geolocation::RegisterPrefs(registry); 226 geolocation::RegisterPrefs(registry);
224 GLStringManager::RegisterPrefs(registry); 227 GLStringManager::RegisterPrefs(registry);
225 GpuModeManager::RegisterPrefs(registry); 228 GpuModeManager::RegisterPrefs(registry);
226 IntranetRedirectDetector::RegisterPrefs(registry); 229 IntranetRedirectDetector::RegisterPrefs(registry);
227 IOThread::RegisterPrefs(registry); 230 IOThread::RegisterPrefs(registry);
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
297 chromeos::StartupUtils::RegisterPrefs(registry); 300 chromeos::StartupUtils::RegisterPrefs(registry);
298 chromeos::echo_offer::RegisterPrefs(registry); 301 chromeos::echo_offer::RegisterPrefs(registry);
299 policy::AutoEnrollmentClient::RegisterPrefs(registry); 302 policy::AutoEnrollmentClient::RegisterPrefs(registry);
300 policy::DeviceCloudPolicyManagerChromeOS::RegisterPrefs(registry); 303 policy::DeviceCloudPolicyManagerChromeOS::RegisterPrefs(registry);
301 policy::DeviceStatusCollector::RegisterPrefs(registry); 304 policy::DeviceStatusCollector::RegisterPrefs(registry);
302 #endif 305 #endif
303 306
304 #if defined(OS_MACOSX) 307 #if defined(OS_MACOSX)
305 confirm_quit::RegisterLocalState(registry); 308 confirm_quit::RegisterLocalState(registry);
306 #endif 309 #endif
310
311 #if defined(OS_WIN)
312 app_metro_launch::RegisterPrefs(registry);
313 #endif
307 } 314 }
308 315
309 // Register prefs applicable to all profiles. 316 // Register prefs applicable to all profiles.
310 void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry) { 317 void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry) {
311 TRACE_EVENT0("browser", "chrome::RegisterUserPrefs"); 318 TRACE_EVENT0("browser", "chrome::RegisterUserPrefs");
312 // User prefs. Please keep this list alphabetized. 319 // User prefs. Please keep this list alphabetized.
313 AlternateErrorPageTabObserver::RegisterProfilePrefs(registry); 320 AlternateErrorPageTabObserver::RegisterProfilePrefs(registry);
314 apps::RegisterProfilePrefs(registry); 321 apps::RegisterProfilePrefs(registry);
315 #if !defined(OS_ANDROID) 322 #if !defined(OS_ANDROID)
316 AppShortcutManager::RegisterProfilePrefs(registry); 323 AppShortcutManager::RegisterProfilePrefs(registry);
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
560 } 567 }
561 local_state->ClearPref(prefs::kLastPromptedGoogleURL); 568 local_state->ClearPref(prefs::kLastPromptedGoogleURL);
562 569
563 current_version |= GOOGLE_URL_TRACKER_PREFS; 570 current_version |= GOOGLE_URL_TRACKER_PREFS;
564 local_state->SetInteger(prefs::kMultipleProfilePrefMigration, 571 local_state->SetInteger(prefs::kMultipleProfilePrefMigration,
565 current_version); 572 current_version);
566 } 573 }
567 } 574 }
568 575
569 } // namespace chrome 576 } // namespace chrome
OLDNEW
« no previous file with comments | « chrome/browser/apps/chrome_apps_client.cc ('k') | chrome/browser/ui/app_list/app_list_service_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698