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

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

Issue 2419733005: Extract a base class from CommandLinePrefStore (Closed)
Patch Set: nit in comment Created 4 years, 2 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
« no previous file with comments | « chrome/browser/BUILD.gn ('k') | chrome/browser/prefs/chrome_command_line_pref_store.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) 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 <algorithm> 10 #include <algorithm>
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 #include "chrome/browser/media/webrtc/media_capture_devices_dispatcher.h" 74 #include "chrome/browser/media/webrtc/media_capture_devices_dispatcher.h"
75 #include "chrome/browser/memory/tab_manager.h" 75 #include "chrome/browser/memory/tab_manager.h"
76 #include "chrome/browser/metrics/chrome_metrics_service_accessor.h" 76 #include "chrome/browser/metrics/chrome_metrics_service_accessor.h"
77 #include "chrome/browser/metrics/field_trial_synchronizer.h" 77 #include "chrome/browser/metrics/field_trial_synchronizer.h"
78 #include "chrome/browser/metrics/thread_watcher.h" 78 #include "chrome/browser/metrics/thread_watcher.h"
79 #include "chrome/browser/nacl_host/nacl_browser_delegate_impl.h" 79 #include "chrome/browser/nacl_host/nacl_browser_delegate_impl.h"
80 #include "chrome/browser/net/crl_set_fetcher.h" 80 #include "chrome/browser/net/crl_set_fetcher.h"
81 #include "chrome/browser/performance_monitor/performance_monitor.h" 81 #include "chrome/browser/performance_monitor/performance_monitor.h"
82 #include "chrome/browser/plugins/plugin_prefs.h" 82 #include "chrome/browser/plugins/plugin_prefs.h"
83 #include "chrome/browser/power/process_power_collector.h" 83 #include "chrome/browser/power/process_power_collector.h"
84 #include "chrome/browser/prefs/chrome_command_line_pref_store.h"
84 #include "chrome/browser/prefs/chrome_pref_service_factory.h" 85 #include "chrome/browser/prefs/chrome_pref_service_factory.h"
85 #include "chrome/browser/prefs/command_line_pref_store.h"
86 #include "chrome/browser/prefs/incognito_mode_prefs.h" 86 #include "chrome/browser/prefs/incognito_mode_prefs.h"
87 #include "chrome/browser/prefs/pref_metrics_service.h" 87 #include "chrome/browser/prefs/pref_metrics_service.h"
88 #include "chrome/browser/printing/cloud_print/cloud_print_proxy_service.h" 88 #include "chrome/browser/printing/cloud_print/cloud_print_proxy_service.h"
89 #include "chrome/browser/printing/cloud_print/cloud_print_proxy_service_factory. h" 89 #include "chrome/browser/printing/cloud_print/cloud_print_proxy_service_factory. h"
90 #include "chrome/browser/process_singleton.h" 90 #include "chrome/browser/process_singleton.h"
91 #include "chrome/browser/profiles/profile.h" 91 #include "chrome/browser/profiles/profile.h"
92 #include "chrome/browser/profiles/profile_attributes_entry.h" 92 #include "chrome/browser/profiles/profile_attributes_entry.h"
93 #include "chrome/browser/profiles/profile_attributes_storage.h" 93 #include "chrome/browser/profiles/profile_attributes_storage.h"
94 #include "chrome/browser/profiles/profile_manager.h" 94 #include "chrome/browser/profiles/profile_manager.h"
95 #include "chrome/browser/profiles/profiles_state.h" 95 #include "chrome/browser/profiles/profiles_state.h"
(...skipping 1087 matching lines...) Expand 10 before | Expand all | Expand 10 after
1183 // is present on the command line but flags in about:flags are converted only 1183 // is present on the command line but flags in about:flags are converted only
1184 // after this function runs. Note that this starts exporting later which 1184 // after this function runs. Note that this starts exporting later which
1185 // affects tracing the browser startup. Also, this is only relevant for the 1185 // affects tracing the browser startup. Also, this is only relevant for the
1186 // browser process, as other processes will get all the flags on their command 1186 // browser process, as other processes will get all the flags on their command
1187 // line regardless of the origin (command line or about:flags). 1187 // line regardless of the origin (command line or about:flags).
1188 if (parsed_command_line().HasSwitch(switches::kTraceExportEventsToETW)) 1188 if (parsed_command_line().HasSwitch(switches::kTraceExportEventsToETW))
1189 base::trace_event::TraceEventETWExport::EnableETWExport(); 1189 base::trace_event::TraceEventETWExport::EnableETWExport();
1190 #endif // OS_WIN 1190 #endif // OS_WIN
1191 1191
1192 local_state_->UpdateCommandLinePrefStore( 1192 local_state_->UpdateCommandLinePrefStore(
1193 new CommandLinePrefStore(base::CommandLine::ForCurrentProcess())); 1193 new ChromeCommandLinePrefStore(base::CommandLine::ForCurrentProcess()));
1194 1194
1195 // Reset the command line in the crash report details, since we may have 1195 // Reset the command line in the crash report details, since we may have
1196 // just changed it to include experiments. 1196 // just changed it to include experiments.
1197 crash_keys::SetCrashKeysFromCommandLine( 1197 crash_keys::SetCrashKeysFromCommandLine(
1198 *base::CommandLine::ForCurrentProcess()); 1198 *base::CommandLine::ForCurrentProcess());
1199 1199
1200 // Mac starts it earlier in |PreMainMessageLoopStart()| (because it is 1200 // Mac starts it earlier in |PreMainMessageLoopStart()| (because it is
1201 // needed when loading the MainMenu.nib and the language doesn't depend on 1201 // needed when loading the MainMenu.nib and the language doesn't depend on
1202 // anything since it comes from Cocoa. 1202 // anything since it comes from Cocoa.
1203 #if defined(OS_MACOSX) 1203 #if defined(OS_MACOSX)
(...skipping 1024 matching lines...) Expand 10 before | Expand all | Expand 10 after
2228 chromeos::CrosSettings::Shutdown(); 2228 chromeos::CrosSettings::Shutdown();
2229 #endif // defined(OS_CHROMEOS) 2229 #endif // defined(OS_CHROMEOS)
2230 #endif // defined(OS_ANDROID) 2230 #endif // defined(OS_ANDROID)
2231 } 2231 }
2232 2232
2233 // Public members: 2233 // Public members:
2234 2234
2235 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { 2235 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) {
2236 chrome_extra_parts_.push_back(parts); 2236 chrome_extra_parts_.push_back(parts);
2237 } 2237 }
OLDNEW
« no previous file with comments | « chrome/browser/BUILD.gn ('k') | chrome/browser/prefs/chrome_command_line_pref_store.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698