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

Side by Side Diff: chrome/browser/browser_main.cc

Issue 6262010: Revert 72225 - This patch moves the experiments settings from the user profil... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 11 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
« no previous file with comments | « no previous file | chrome/browser/dom_ui/flags_ui.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_main.h" 5 #include "chrome/browser/browser_main.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 1226 matching lines...) Expand 10 before | Expand all | Expand 10 after
1237 // Initialize histogram synchronizer system. This is a singleton and is used 1237 // Initialize histogram synchronizer system. This is a singleton and is used
1238 // for posting tasks via NewRunnableMethod. Its deleted when it goes out of 1238 // for posting tasks via NewRunnableMethod. Its deleted when it goes out of
1239 // scope. Even though NewRunnableMethod does AddRef and Release, the object 1239 // scope. Even though NewRunnableMethod does AddRef and Release, the object
1240 // will not be deleted after the Task is executed. 1240 // will not be deleted after the Task is executed.
1241 scoped_refptr<HistogramSynchronizer> histogram_synchronizer( 1241 scoped_refptr<HistogramSynchronizer> histogram_synchronizer(
1242 new HistogramSynchronizer()); 1242 new HistogramSynchronizer());
1243 1243
1244 // Initialize the prefs of the local state. 1244 // Initialize the prefs of the local state.
1245 browser::RegisterLocalState(local_state); 1245 browser::RegisterLocalState(local_state);
1246 1246
1247 // Convert active labs into switches. Modifies the current command line.
1248 about_flags::ConvertFlagsToSwitches(local_state,
1249 CommandLine::ForCurrentProcess());
1250
1251 // Now that all preferences have been registered, set the install date 1247 // Now that all preferences have been registered, set the install date
1252 // for the uninstall metrics if this is our first run. This only actually 1248 // for the uninstall metrics if this is our first run. This only actually
1253 // gets used if the user has metrics reporting enabled at uninstall time. 1249 // gets used if the user has metrics reporting enabled at uninstall time.
1254 int64 install_date = 1250 int64 install_date =
1255 local_state->GetInt64(prefs::kUninstallMetricsInstallDate); 1251 local_state->GetInt64(prefs::kUninstallMetricsInstallDate);
1256 if (install_date == 0) { 1252 if (install_date == 0) {
1257 local_state->SetInt64(prefs::kUninstallMetricsInstallDate, 1253 local_state->SetInt64(prefs::kUninstallMetricsInstallDate,
1258 base::Time::Now().ToTimeT()); 1254 base::Time::Now().ToTimeT());
1259 } 1255 }
1260 1256
(...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after
1576 #if defined(OS_WIN) && !defined(GOOGLE_CHROME_BUILD) 1572 #if defined(OS_WIN) && !defined(GOOGLE_CHROME_BUILD)
1577 if (parsed_command_line.HasSwitch(switches::kDebugPrint)) { 1573 if (parsed_command_line.HasSwitch(switches::kDebugPrint)) {
1578 FilePath path = 1574 FilePath path =
1579 parsed_command_line.GetSwitchValuePath(switches::kDebugPrint); 1575 parsed_command_line.GetSwitchValuePath(switches::kDebugPrint);
1580 printing::PrintedDocument::set_debug_dump_path(path); 1576 printing::PrintedDocument::set_debug_dump_path(path);
1581 } 1577 }
1582 #endif 1578 #endif
1583 1579
1584 HandleTestParameters(parsed_command_line); 1580 HandleTestParameters(parsed_command_line);
1585 RecordBreakpadStatusUMA(metrics); 1581 RecordBreakpadStatusUMA(metrics);
1586 about_flags::RecordUMAStatistics(local_state); 1582 about_flags::RecordUMAStatistics(user_prefs);
1587 1583
1588 // Stat the directory with the inspector's files so that we can know if we 1584 // Stat the directory with the inspector's files so that we can know if we
1589 // should display the entry in the context menu or not. 1585 // should display the entry in the context menu or not.
1590 browser_process->CheckForInspectorFiles(); 1586 browser_process->CheckForInspectorFiles();
1591 1587
1592 #if defined(OS_CHROMEOS) 1588 #if defined(OS_CHROMEOS)
1593 metrics->StartExternalMetrics(); 1589 metrics->StartExternalMetrics();
1594 #endif 1590 #endif
1595 1591
1596 // Initialize extension event routers. Note that on Chrome OS, this will 1592 // Initialize extension event routers. Note that on Chrome OS, this will
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
1753 #if defined(OS_CHROMEOS) 1749 #if defined(OS_CHROMEOS)
1754 // To be precise, logout (browser shutdown) is not yet done, but the 1750 // To be precise, logout (browser shutdown) is not yet done, but the
1755 // remaining work is negligible, hence we say LogoutDone here. 1751 // remaining work is negligible, hence we say LogoutDone here.
1756 chromeos::BootTimesLoader::Get()->AddLogoutTimeMarker("LogoutDone", 1752 chromeos::BootTimesLoader::Get()->AddLogoutTimeMarker("LogoutDone",
1757 false); 1753 false);
1758 chromeos::BootTimesLoader::Get()->WriteLogoutTimes(); 1754 chromeos::BootTimesLoader::Get()->WriteLogoutTimes();
1759 #endif 1755 #endif
1760 TRACE_EVENT_END("BrowserMain", 0, 0); 1756 TRACE_EVENT_END("BrowserMain", 0, 0);
1761 return result_code; 1757 return result_code;
1762 } 1758 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/dom_ui/flags_ui.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698