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

Unified Diff: chrome/browser/chromeos/chrome_browser_main_chromeos.cc

Issue 8575011: chrome: bluetooth: create BluetoothManager after about:flags parsed (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/chromeos/dbus/dbus_thread_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/chrome_browser_main_chromeos.cc
diff --git a/chrome/browser/chromeos/chrome_browser_main_chromeos.cc b/chrome/browser/chromeos/chrome_browser_main_chromeos.cc
index 2e676f4e4ba31a10d3399f2f646549a46cf0d4b3..91d28b963468a824fec02c153134778756bf491f 100644
--- a/chrome/browser/chromeos/chrome_browser_main_chromeos.cc
+++ b/chrome/browser/chromeos/chrome_browser_main_chromeos.cc
@@ -143,6 +143,16 @@ void ChromeBrowserMainPartsChromeos::PreMainMessageLoopRun() {
// Get the statistics provider instance here to start loading statistcs
// on the background FILE thread.
chromeos::system::StatisticsProvider::GetInstance();
+
+ // Initialize the Chrome OS bluetooth subsystem.
+ // We defer this to PreMainMessageLoopRun because we don't want to check the
+ // parsed command line until after about_flags::ConvertFlagsToSwitches has
+ // been called.
+ // TODO(vlaviano): Move this back to PostMainMessageLoopStart when we remove
+ // the --enable-bluetooth flag.
+ if (parsed_command_line().HasSwitch(switches::kEnableBluetooth)) {
+ chromeos::BluetoothManager::Initialize();
+ }
}
void ChromeBrowserMainPartsChromeos::PostMainMessageLoopStart() {
@@ -165,11 +175,6 @@ void ChromeBrowserMainPartsChromeos::PostMainMessageLoopStart() {
chromeos::DBusThreadManager::Get()->GetSessionManagerClient()->
AddObserver(session_manager_observer_.get());
- // Initialize the Chrome OS bluetooth subsystem
- if (parsed_command_line().HasSwitch(switches::kEnableBluetooth)) {
- chromeos::BluetoothManager::Initialize();
- }
-
// Initialize the network change notifier for Chrome OS. The network
// change notifier starts to monitor changes from the power manager and
// the network manager.
« no previous file with comments | « no previous file | chrome/browser/chromeos/dbus/dbus_thread_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698