| 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/browser_process_impl.h" | 5 #include "chrome/browser/browser_process_impl.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <map> | 10 #include <map> |
| (...skipping 785 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 796 // Initialize ResourceBundle which handles files loaded from external | 796 // Initialize ResourceBundle which handles files loaded from external |
| 797 // sources. This has to be done before uninstall code path and before prefs | 797 // sources. This has to be done before uninstall code path and before prefs |
| 798 // are registered. | 798 // are registered. |
| 799 registry->RegisterStringPref(prefs::kApplicationLocale, std::string()); | 799 registry->RegisterStringPref(prefs::kApplicationLocale, std::string()); |
| 800 #if defined(OS_CHROMEOS) | 800 #if defined(OS_CHROMEOS) |
| 801 registry->RegisterStringPref(prefs::kOwnerLocale, std::string()); | 801 registry->RegisterStringPref(prefs::kOwnerLocale, std::string()); |
| 802 registry->RegisterStringPref(prefs::kHardwareKeyboardLayout, | 802 registry->RegisterStringPref(prefs::kHardwareKeyboardLayout, |
| 803 std::string()); | 803 std::string()); |
| 804 #endif // defined(OS_CHROMEOS) | 804 #endif // defined(OS_CHROMEOS) |
| 805 | 805 |
| 806 #if defined(ENABLE_REPORTING_BLIMP) | |
| 807 // Enables reporting for the (headless) blimp engine. Defined in | |
| 808 // components/metrics/BUILD.gn | |
| 809 registry->RegisterBooleanPref(metrics::prefs::kMetricsReportingEnabled, true); | |
| 810 #else | |
| 811 registry->RegisterBooleanPref(metrics::prefs::kMetricsReportingEnabled, | 806 registry->RegisterBooleanPref(metrics::prefs::kMetricsReportingEnabled, |
| 812 GoogleUpdateSettings::GetCollectStatsConsent()); | 807 GoogleUpdateSettings::GetCollectStatsConsent()); |
| 813 #endif // defined(ENABLE_REPORTING_HEADLESS) | |
| 814 | 808 |
| 815 #if BUILDFLAG(ANDROID_JAVA_UI) | 809 #if BUILDFLAG(ANDROID_JAVA_UI) |
| 816 registry->RegisterBooleanPref( | 810 registry->RegisterBooleanPref( |
| 817 prefs::kCrashReportingEnabled, false); | 811 prefs::kCrashReportingEnabled, false); |
| 818 #endif // BUILDFLAG(ANDROID_JAVA_UI) | 812 #endif // BUILDFLAG(ANDROID_JAVA_UI) |
| 819 } | 813 } |
| 820 | 814 |
| 821 DownloadRequestLimiter* BrowserProcessImpl::download_request_limiter() { | 815 DownloadRequestLimiter* BrowserProcessImpl::download_request_limiter() { |
| 822 DCHECK(CalledOnValidThread()); | 816 DCHECK(CalledOnValidThread()); |
| 823 if (!download_request_limiter_.get()) | 817 if (!download_request_limiter_.get()) |
| (...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1311 } | 1305 } |
| 1312 | 1306 |
| 1313 void BrowserProcessImpl::OnAutoupdateTimer() { | 1307 void BrowserProcessImpl::OnAutoupdateTimer() { |
| 1314 if (CanAutorestartForUpdate()) { | 1308 if (CanAutorestartForUpdate()) { |
| 1315 DLOG(WARNING) << "Detected update. Restarting browser."; | 1309 DLOG(WARNING) << "Detected update. Restarting browser."; |
| 1316 RestartBackgroundInstance(); | 1310 RestartBackgroundInstance(); |
| 1317 } | 1311 } |
| 1318 } | 1312 } |
| 1319 | 1313 |
| 1320 #endif // (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) | 1314 #endif // (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) |
| OLD | NEW |