| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/chromeos/chrome_browser_main_chromeos.h" | 5 #include "chrome/browser/chromeos/chrome_browser_main_chromeos.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 #include "chrome/common/chrome_version_info.h" | 85 #include "chrome/common/chrome_version_info.h" |
| 86 #include "chrome/common/logging_chrome.h" | 86 #include "chrome/common/logging_chrome.h" |
| 87 #include "chrome/common/pref_names.h" | 87 #include "chrome/common/pref_names.h" |
| 88 #include "chromeos/chromeos_switches.h" | 88 #include "chromeos/chromeos_switches.h" |
| 89 #include "chromeos/cryptohome/async_method_caller.h" | 89 #include "chromeos/cryptohome/async_method_caller.h" |
| 90 #include "chromeos/dbus/dbus_thread_manager.h" | 90 #include "chromeos/dbus/dbus_thread_manager.h" |
| 91 #include "chromeos/dbus/power_manager_client.h" | 91 #include "chromeos/dbus/power_manager_client.h" |
| 92 #include "chromeos/dbus/session_manager_client.h" | 92 #include "chromeos/dbus/session_manager_client.h" |
| 93 #include "chromeos/disks/disk_mount_manager.h" | 93 #include "chromeos/disks/disk_mount_manager.h" |
| 94 #include "chromeos/ime/xkeyboard.h" | 94 #include "chromeos/ime/xkeyboard.h" |
| 95 #include "chromeos/login/login_state.h" |
| 95 #include "chromeos/network/geolocation_handler.h" | 96 #include "chromeos/network/geolocation_handler.h" |
| 96 #include "chromeos/network/network_change_notifier_chromeos.h" | 97 #include "chromeos/network/network_change_notifier_chromeos.h" |
| 97 #include "chromeos/network/network_change_notifier_factory_chromeos.h" | 98 #include "chromeos/network/network_change_notifier_factory_chromeos.h" |
| 98 #include "chromeos/network/network_configuration_handler.h" | 99 #include "chromeos/network/network_configuration_handler.h" |
| 99 #include "chromeos/network/network_event_log.h" | 100 #include "chromeos/network/network_event_log.h" |
| 100 #include "chromeos/network/network_state_handler.h" | 101 #include "chromeos/network/network_state_handler.h" |
| 101 #include "content/public/browser/browser_thread.h" | 102 #include "content/public/browser/browser_thread.h" |
| 102 #include "content/public/browser/notification_service.h" | 103 #include "content/public/browser/notification_service.h" |
| 103 #include "content/public/browser/power_save_blocker.h" | 104 #include "content/public/browser/power_save_blocker.h" |
| 104 #include "content/public/common/main_function_params.h" | 105 #include "content/public/common/main_function_params.h" |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 285 | 286 |
| 286 // This function and SystemKeyEventListener use InputMethodManager. | 287 // This function and SystemKeyEventListener use InputMethodManager. |
| 287 chromeos::input_method::Initialize( | 288 chromeos::input_method::Initialize( |
| 288 content::BrowserThread::GetMessageLoopProxyForThread( | 289 content::BrowserThread::GetMessageLoopProxyForThread( |
| 289 content::BrowserThread::UI), | 290 content::BrowserThread::UI), |
| 290 content::BrowserThread::GetMessageLoopProxyForThread( | 291 content::BrowserThread::GetMessageLoopProxyForThread( |
| 291 content::BrowserThread::FILE)); | 292 content::BrowserThread::FILE)); |
| 292 disks::DiskMountManager::Initialize(); | 293 disks::DiskMountManager::Initialize(); |
| 293 cryptohome::AsyncMethodCaller::Initialize(); | 294 cryptohome::AsyncMethodCaller::Initialize(); |
| 294 | 295 |
| 296 chromeos::LoginState::Initialize(); |
| 297 |
| 295 // Always initialize these handlers which should not conflict with | 298 // Always initialize these handlers which should not conflict with |
| 296 // NetworkLibrary. | 299 // NetworkLibrary. |
| 297 chromeos::network_event_log::Initialize(); | 300 chromeos::network_event_log::Initialize(); |
| 298 chromeos::GeolocationHandler::Initialize(); | 301 chromeos::GeolocationHandler::Initialize(); |
| 299 chromeos::NetworkStateHandler::Initialize(); | 302 chromeos::NetworkStateHandler::Initialize(); |
| 300 | 303 |
| 301 chromeos::NetworkConfigurationHandler::Initialize(); | 304 chromeos::NetworkConfigurationHandler::Initialize(); |
| 302 chromeos::ManagedNetworkConfigurationHandler::Initialize(); | 305 chromeos::ManagedNetworkConfigurationHandler::Initialize(); |
| 303 | 306 |
| 304 // Initialize the network change notifier for Chrome OS. The network | 307 // Initialize the network change notifier for Chrome OS. The network |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 339 if (cros_initialized_ && CrosLibrary::Get()) | 342 if (cros_initialized_ && CrosLibrary::Get()) |
| 340 CrosLibrary::Shutdown(); | 343 CrosLibrary::Shutdown(); |
| 341 | 344 |
| 342 chromeos::ManagedNetworkConfigurationHandler::Shutdown(); | 345 chromeos::ManagedNetworkConfigurationHandler::Shutdown(); |
| 343 chromeos::NetworkConfigurationHandler::Shutdown(); | 346 chromeos::NetworkConfigurationHandler::Shutdown(); |
| 344 | 347 |
| 345 chromeos::NetworkStateHandler::Shutdown(); | 348 chromeos::NetworkStateHandler::Shutdown(); |
| 346 chromeos::GeolocationHandler::Shutdown(); | 349 chromeos::GeolocationHandler::Shutdown(); |
| 347 chromeos::network_event_log::Shutdown(); | 350 chromeos::network_event_log::Shutdown(); |
| 348 | 351 |
| 352 chromeos::LoginState::Shutdown(); |
| 353 |
| 349 cryptohome::AsyncMethodCaller::Shutdown(); | 354 cryptohome::AsyncMethodCaller::Shutdown(); |
| 350 disks::DiskMountManager::Shutdown(); | 355 disks::DiskMountManager::Shutdown(); |
| 351 input_method::Shutdown(); | 356 input_method::Shutdown(); |
| 352 CrosDBusService::Shutdown(); | 357 CrosDBusService::Shutdown(); |
| 353 // NOTE: This must only be called if Initialize() was called. | 358 // NOTE: This must only be called if Initialize() was called. |
| 354 DBusThreadManager::Shutdown(); | 359 DBusThreadManager::Shutdown(); |
| 355 } | 360 } |
| 356 | 361 |
| 357 private: | 362 private: |
| 358 bool cros_initialized_; | 363 bool cros_initialized_; |
| (...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 873 trial->AppendGroup("4GB_RAM_4GB_swap", zram_group == '4' ? 1 : 0); | 878 trial->AppendGroup("4GB_RAM_4GB_swap", zram_group == '4' ? 1 : 0); |
| 874 trial->AppendGroup("4GB_RAM_6GB_swap", zram_group == '5' ? 1 : 0); | 879 trial->AppendGroup("4GB_RAM_6GB_swap", zram_group == '5' ? 1 : 0); |
| 875 trial->AppendGroup("snow_no_swap", zram_group == '6' ? 1 : 0); | 880 trial->AppendGroup("snow_no_swap", zram_group == '6' ? 1 : 0); |
| 876 trial->AppendGroup("snow_1GB_swap", zram_group == '7' ? 1 : 0); | 881 trial->AppendGroup("snow_1GB_swap", zram_group == '7' ? 1 : 0); |
| 877 trial->AppendGroup("snow_2GB_swap", zram_group == '8' ? 1 : 0); | 882 trial->AppendGroup("snow_2GB_swap", zram_group == '8' ? 1 : 0); |
| 878 // This is necessary to start the experiment as a side effect. | 883 // This is necessary to start the experiment as a side effect. |
| 879 trial->group(); | 884 trial->group(); |
| 880 } | 885 } |
| 881 | 886 |
| 882 } // namespace chromeos | 887 } // namespace chromeos |
| OLD | NEW |