| 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 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 #include "chrome/browser/chromeos/upgrade_detector_chromeos.h" | 71 #include "chrome/browser/chromeos/upgrade_detector_chromeos.h" |
| 72 #include "chrome/browser/chromeos/web_socket_proxy_controller.h" | 72 #include "chrome/browser/chromeos/web_socket_proxy_controller.h" |
| 73 #include "chrome/browser/chromeos/xinput_hierarchy_changed_event_listener.h" | 73 #include "chrome/browser/chromeos/xinput_hierarchy_changed_event_listener.h" |
| 74 #include "chrome/browser/defaults.h" | 74 #include "chrome/browser/defaults.h" |
| 75 #include "chrome/browser/metrics/metrics_service.h" | 75 #include "chrome/browser/metrics/metrics_service.h" |
| 76 #include "chrome/browser/net/chrome_network_delegate.h" | 76 #include "chrome/browser/net/chrome_network_delegate.h" |
| 77 #include "chrome/browser/policy/browser_policy_connector.h" | 77 #include "chrome/browser/policy/browser_policy_connector.h" |
| 78 #include "chrome/browser/profiles/profile.h" | 78 #include "chrome/browser/profiles/profile.h" |
| 79 #include "chrome/browser/profiles/profile_manager.h" | 79 #include "chrome/browser/profiles/profile_manager.h" |
| 80 #include "chrome/browser/rlz/rlz.h" | 80 #include "chrome/browser/rlz/rlz.h" |
| 81 #include "chrome/browser/storage_monitor/removable_device_notifications_chromeos
.h" | 81 #include "chrome/browser/storage_monitor/storage_monitor_chromeos.h" |
| 82 #include "chrome/common/chrome_notification_types.h" | 82 #include "chrome/common/chrome_notification_types.h" |
| 83 #include "chrome/common/chrome_switches.h" | 83 #include "chrome/common/chrome_switches.h" |
| 84 #include "chrome/common/chrome_version_info.h" | 84 #include "chrome/common/chrome_version_info.h" |
| 85 #include "chrome/common/logging_chrome.h" | 85 #include "chrome/common/logging_chrome.h" |
| 86 #include "chrome/common/pref_names.h" | 86 #include "chrome/common/pref_names.h" |
| 87 #include "chromeos/chromeos_switches.h" | 87 #include "chromeos/chromeos_switches.h" |
| 88 #include "chromeos/cryptohome/async_method_caller.h" | 88 #include "chromeos/cryptohome/async_method_caller.h" |
| 89 #include "chromeos/dbus/dbus_thread_manager.h" | 89 #include "chromeos/dbus/dbus_thread_manager.h" |
| 90 #include "chromeos/dbus/power_manager_client.h" | 90 #include "chromeos/dbus/power_manager_client.h" |
| 91 #include "chromeos/dbus/session_manager_client.h" | 91 #include "chromeos/dbus/session_manager_client.h" |
| (...skipping 521 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 613 switches::kEnableScreensaverExtensions)) { | 613 switches::kEnableScreensaverExtensions)) { |
| 614 screensaver_controller_.reset(new ScreensaverController()); | 614 screensaver_controller_.reset(new ScreensaverController()); |
| 615 } | 615 } |
| 616 suspend_observer_.reset(new SuspendObserver()); | 616 suspend_observer_.reset(new SuspendObserver()); |
| 617 if (KioskModeSettings::Get()->IsKioskModeEnabled()) { | 617 if (KioskModeSettings::Get()->IsKioskModeEnabled()) { |
| 618 power_state_override_ = new PowerStateOverride( | 618 power_state_override_ = new PowerStateOverride( |
| 619 PowerStateOverride::BLOCK_DISPLAY_SLEEP); | 619 PowerStateOverride::BLOCK_DISPLAY_SLEEP); |
| 620 } | 620 } |
| 621 chromeos::accessibility::Initialize(); | 621 chromeos::accessibility::Initialize(); |
| 622 | 622 |
| 623 removable_device_notifications_ = | 623 storage_monitor_ = new StorageMonitorCros(); |
| 624 new RemovableDeviceNotificationsCros(); | |
| 625 | 624 |
| 626 // Initialize the network portal detector for Chrome OS. The network | 625 // Initialize the network portal detector for Chrome OS. The network |
| 627 // portal detector starts to listen for notifications from | 626 // portal detector starts to listen for notifications from |
| 628 // NetworkLibrary about changes in the NetworkManager and initiates | 627 // NetworkLibrary about changes in the NetworkManager and initiates |
| 629 // captive portal detection for active networks. | 628 // captive portal detection for active networks. |
| 630 if (NetworkPortalDetector::IsEnabled() && | 629 if (NetworkPortalDetector::IsEnabled() && |
| 631 NetworkPortalDetector::GetInstance()) { | 630 NetworkPortalDetector::GetInstance()) { |
| 632 NetworkPortalDetector::GetInstance()->Init(); | 631 NetworkPortalDetector::GetInstance()->Init(); |
| 633 } | 632 } |
| 634 | 633 |
| (...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 852 if (success) | 851 if (success) |
| 853 return; | 852 return; |
| 854 | 853 |
| 855 // If failed to launch, go back to login screen. | 854 // If failed to launch, go back to login screen. |
| 856 OptionallyRunChromeOSLoginManager(parsed_command_line(), profile()); | 855 OptionallyRunChromeOSLoginManager(parsed_command_line(), profile()); |
| 857 | 856 |
| 858 // TODO(xiyuan): Show error message. | 857 // TODO(xiyuan): Show error message. |
| 859 } | 858 } |
| 860 | 859 |
| 861 } // namespace chromeos | 860 } // namespace chromeos |
| OLD | NEW |