| OLD | NEW |
| 1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2009 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 | 8 |
| 9 #include "app/l10n_util.h" | 9 #include "app/l10n_util.h" |
| 10 #include "app/resource_bundle.h" | 10 #include "app/resource_bundle.h" |
| (...skipping 847 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 858 // on recording, but not reporting, otherwise tests fail. | 858 // on recording, but not reporting, otherwise tests fail. |
| 859 if (record_only) { | 859 if (record_only) { |
| 860 metrics->StartRecordingOnly(); | 860 metrics->StartRecordingOnly(); |
| 861 } else { | 861 } else { |
| 862 // If the user permits metrics reporting with the checkbox in the | 862 // If the user permits metrics reporting with the checkbox in the |
| 863 // prefs, we turn on recording. | 863 // prefs, we turn on recording. |
| 864 metrics->SetUserPermitsUpload(enabled); | 864 metrics->SetUserPermitsUpload(enabled); |
| 865 if (enabled) | 865 if (enabled) |
| 866 metrics->Start(); | 866 metrics->Start(); |
| 867 } | 867 } |
| 868 // TODO(ukai): Bug 28096: Implement ExperimentRunner so that it does not | |
| 869 // tear down histograms early, and cause a crash. | |
| 870 /* | |
| 871 chrome_browser_net_websocket_experiment::WebSocketExperimentRunner::Start(); | 868 chrome_browser_net_websocket_experiment::WebSocketExperimentRunner::Start(); |
| 872 */ | |
| 873 } | 869 } |
| 874 | 870 |
| 875 InstallJankometer(parsed_command_line); | 871 InstallJankometer(parsed_command_line); |
| 876 | 872 |
| 877 #if defined(OS_WIN) && !defined(GOOGLE_CHROME_BUILD) | 873 #if defined(OS_WIN) && !defined(GOOGLE_CHROME_BUILD) |
| 878 if (parsed_command_line.HasSwitch(switches::kDebugPrint)) { | 874 if (parsed_command_line.HasSwitch(switches::kDebugPrint)) { |
| 879 printing::PrintedDocument::set_debug_dump_path( | 875 printing::PrintedDocument::set_debug_dump_path( |
| 880 parsed_command_line.GetSwitchValue(switches::kDebugPrint)); | 876 parsed_command_line.GetSwitchValue(switches::kDebugPrint)); |
| 881 } | 877 } |
| 882 #endif | 878 #endif |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 930 if (metrics) | 926 if (metrics) |
| 931 metrics->Stop(); | 927 metrics->Stop(); |
| 932 | 928 |
| 933 // browser_shutdown takes care of deleting browser_process, so we need to | 929 // browser_shutdown takes care of deleting browser_process, so we need to |
| 934 // release it. | 930 // release it. |
| 935 browser_process.release(); | 931 browser_process.release(); |
| 936 browser_shutdown::Shutdown(); | 932 browser_shutdown::Shutdown(); |
| 937 | 933 |
| 938 return result_code; | 934 return result_code; |
| 939 } | 935 } |
| OLD | NEW |