| 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/chrome_browser_main.h" | 5 #include "chrome/browser/chrome_browser_main.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <set> | 10 #include <set> |
| 11 #include <string> | 11 #include <string> |
| 12 #include <utility> | 12 #include <utility> |
| 13 #include <vector> | 13 #include <vector> |
| 14 | 14 |
| 15 #include "base/at_exit.h" | 15 #include "base/at_exit.h" |
| 16 #include "base/base_switches.h" | 16 #include "base/base_switches.h" |
| 17 #include "base/bind.h" | 17 #include "base/bind.h" |
| 18 #include "base/command_line.h" | 18 #include "base/command_line.h" |
| 19 #include "base/debug/crash_logging.h" | 19 #include "base/debug/crash_logging.h" |
| 20 #include "base/debug/debugger.h" | 20 #include "base/debug/debugger.h" |
| 21 #include "base/feature_list.h" | 21 #include "base/feature_list.h" |
| 22 #include "base/files/file_path.h" | 22 #include "base/files/file_path.h" |
| 23 #include "base/files/file_util.h" | 23 #include "base/files/file_util.h" |
| 24 #include "base/logging.h" | 24 #include "base/logging.h" |
| 25 #include "base/memory/ptr_util.h" | 25 #include "base/memory/ptr_util.h" |
| 26 #include "base/metrics/field_trial.h" | 26 #include "base/metrics/field_trial.h" |
| 27 #include "base/metrics/histogram_macros.h" | 27 #include "base/metrics/histogram_macros.h" |
| 28 #include "base/path_service.h" | 28 #include "base/path_service.h" |
| 29 #include "base/profiler/scoped_tracker.h" | 29 #include "base/profiler/scoped_tracker.h" |
| 30 #include "base/profiler/stack_sampling_profiler.h" |
| 30 #include "base/run_loop.h" | 31 #include "base/run_loop.h" |
| 31 #include "base/strings/string16.h" | 32 #include "base/strings/string16.h" |
| 32 #include "base/strings/string_number_conversions.h" | 33 #include "base/strings/string_number_conversions.h" |
| 33 #include "base/strings/sys_string_conversions.h" | 34 #include "base/strings/sys_string_conversions.h" |
| 34 #include "base/strings/utf_string_conversions.h" | 35 #include "base/strings/utf_string_conversions.h" |
| 35 #include "base/sys_info.h" | 36 #include "base/sys_info.h" |
| 36 #include "base/threading/platform_thread.h" | 37 #include "base/threading/platform_thread.h" |
| 37 #include "base/time/default_tick_clock.h" | 38 #include "base/time/default_tick_clock.h" |
| 38 #include "base/time/time.h" | 39 #include "base/time/time.h" |
| 39 #include "base/trace_event/trace_event.h" | 40 #include "base/trace_event/trace_event.h" |
| (...skipping 2047 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2087 // to bypass this code. Perhaps we need a *final* hook that is called on all | 2088 // to bypass this code. Perhaps we need a *final* hook that is called on all |
| 2088 // paths from content/browser/browser_main. | 2089 // paths from content/browser/browser_main. |
| 2089 CHECK(metrics::MetricsService::UmaMetricsProperlyShutdown()); | 2090 CHECK(metrics::MetricsService::UmaMetricsProperlyShutdown()); |
| 2090 | 2091 |
| 2091 #if defined(OS_CHROMEOS) | 2092 #if defined(OS_CHROMEOS) |
| 2092 chromeos::CrosSettings::Shutdown(); | 2093 chromeos::CrosSettings::Shutdown(); |
| 2093 #endif // defined(OS_CHROMEOS) | 2094 #endif // defined(OS_CHROMEOS) |
| 2094 #endif // defined(OS_ANDROID) | 2095 #endif // defined(OS_ANDROID) |
| 2095 } | 2096 } |
| 2096 | 2097 |
| 2098 void ChromeBrowserMainParts::PreShutdown() { |
| 2099 base::StackSamplingProfiler::SetProcessMilestone( |
| 2100 metrics::CallStackProfileMetricsProvider::SHUTDOWN_START); |
| 2101 } |
| 2102 |
| 2097 // Public members: | 2103 // Public members: |
| 2098 | 2104 |
| 2099 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 2105 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
| 2100 chrome_extra_parts_.push_back(parts); | 2106 chrome_extra_parts_.push_back(parts); |
| 2101 } | 2107 } |
| OLD | NEW |