| 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 #ifndef CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ | 5 #ifndef CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ |
| 6 #define CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ | 6 #define CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <vector> |
| 9 | 10 |
| 10 #include "base/macros.h" | 11 #include "base/macros.h" |
| 11 #include "base/metrics/field_trial.h" | 12 #include "base/metrics/field_trial.h" |
| 12 #include "base/profiler/stack_sampling_profiler.h" | 13 #include "base/profiler/stack_sampling_profiler.h" |
| 13 #include "base/tracked_objects.h" | 14 #include "base/tracked_objects.h" |
| 14 #include "build/build_config.h" | 15 #include "build/build_config.h" |
| 15 #include "chrome/browser/chrome_browser_field_trials.h" | 16 #include "chrome/browser/chrome_browser_field_trials.h" |
| 16 #include "chrome/browser/chrome_process_singleton.h" | 17 #include "chrome/browser/chrome_process_singleton.h" |
| 17 #include "chrome/browser/first_run/first_run.h" | 18 #include "chrome/browser/first_run/first_run.h" |
| 18 #include "chrome/browser/process_singleton.h" | 19 #include "chrome/browser/process_singleton.h" |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 // A monitor for attributing power consumption to origins. | 150 // A monitor for attributing power consumption to origins. |
| 150 std::unique_ptr<ProcessPowerCollector> process_power_collector_; | 151 std::unique_ptr<ProcessPowerCollector> process_power_collector_; |
| 151 | 152 |
| 152 std::unique_ptr<WebUsbDetector> web_usb_detector_; | 153 std::unique_ptr<WebUsbDetector> web_usb_detector_; |
| 153 #endif | 154 #endif |
| 154 | 155 |
| 155 // Vector of additional ChromeBrowserMainExtraParts. | 156 // Vector of additional ChromeBrowserMainExtraParts. |
| 156 // Parts are deleted in the inverse order they are added. | 157 // Parts are deleted in the inverse order they are added. |
| 157 std::vector<ChromeBrowserMainExtraParts*> chrome_extra_parts_; | 158 std::vector<ChromeBrowserMainExtraParts*> chrome_extra_parts_; |
| 158 | 159 |
| 159 // The configuration to use for the stack sampling profiler below. | |
| 160 StackSamplingConfiguration sampling_profiler_config_; | |
| 161 | |
| 162 // A profiler that periodically samples stack traces. Used to sample startup | 160 // A profiler that periodically samples stack traces. Used to sample startup |
| 163 // behavior. | 161 // behavior. |
| 164 base::StackSamplingProfiler sampling_profiler_; | 162 base::StackSamplingProfiler sampling_profiler_; |
| 165 | 163 |
| 166 // Members initialized after / released before main_message_loop_ ------------ | 164 // Members initialized after / released before main_message_loop_ ------------ |
| 167 | 165 |
| 168 std::unique_ptr<BrowserProcessImpl> browser_process_; | 166 std::unique_ptr<BrowserProcessImpl> browser_process_; |
| 169 scoped_refptr<metrics::TrackingSynchronizer> tracking_synchronizer_; | 167 scoped_refptr<metrics::TrackingSynchronizer> tracking_synchronizer_; |
| 170 | 168 |
| 171 #if !defined(OS_ANDROID) | 169 #if !defined(OS_ANDROID) |
| (...skipping 23 matching lines...) Expand all Loading... |
| 195 | 193 |
| 196 // Members initialized in PreMainMessageLoopRun, needed in | 194 // Members initialized in PreMainMessageLoopRun, needed in |
| 197 // PreMainMessageLoopRunThreadsCreated. | 195 // PreMainMessageLoopRunThreadsCreated. |
| 198 PrefService* local_state_; | 196 PrefService* local_state_; |
| 199 base::FilePath user_data_dir_; | 197 base::FilePath user_data_dir_; |
| 200 | 198 |
| 201 DISALLOW_COPY_AND_ASSIGN(ChromeBrowserMainParts); | 199 DISALLOW_COPY_AND_ASSIGN(ChromeBrowserMainParts); |
| 202 }; | 200 }; |
| 203 | 201 |
| 204 #endif // CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ | 202 #endif // CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ |
| OLD | NEW |