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/ash_switches.h" | 10 #include "ash/ash_switches.h" |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
77 #include "chrome/browser/chromeos/upgrade_detector_chromeos.h" | 77 #include "chrome/browser/chromeos/upgrade_detector_chromeos.h" |
78 #include "chrome/browser/chromeos/web_socket_proxy_controller.h" | 78 #include "chrome/browser/chromeos/web_socket_proxy_controller.h" |
79 #include "chrome/browser/chromeos/xinput_hierarchy_changed_event_listener.h" | 79 #include "chrome/browser/chromeos/xinput_hierarchy_changed_event_listener.h" |
80 #include "chrome/browser/defaults.h" | 80 #include "chrome/browser/defaults.h" |
81 #include "chrome/browser/metrics/metrics_service.h" | 81 #include "chrome/browser/metrics/metrics_service.h" |
82 #include "chrome/browser/net/chrome_network_delegate.h" | 82 #include "chrome/browser/net/chrome_network_delegate.h" |
83 #include "chrome/browser/policy/browser_policy_connector.h" | 83 #include "chrome/browser/policy/browser_policy_connector.h" |
84 #include "chrome/browser/profiles/profile.h" | 84 #include "chrome/browser/profiles/profile.h" |
85 #include "chrome/browser/profiles/profile_manager.h" | 85 #include "chrome/browser/profiles/profile_manager.h" |
86 #include "chrome/browser/rlz/rlz.h" | 86 #include "chrome/browser/rlz/rlz.h" |
87 #include "chrome/browser/storage_monitor/storage_monitor_chromeos.h" | |
88 #include "chrome/common/chrome_paths.h" | 87 #include "chrome/common/chrome_paths.h" |
89 #include "chrome/common/chrome_switches.h" | 88 #include "chrome/common/chrome_switches.h" |
90 #include "chrome/common/chrome_version_info.h" | 89 #include "chrome/common/chrome_version_info.h" |
91 #include "chrome/common/logging_chrome.h" | 90 #include "chrome/common/logging_chrome.h" |
92 #include "chrome/common/pref_names.h" | 91 #include "chrome/common/pref_names.h" |
93 #include "chromeos/audio/audio_devices_pref_handler.h" | 92 #include "chromeos/audio/audio_devices_pref_handler.h" |
94 #include "chromeos/audio/audio_pref_handler.h" | 93 #include "chromeos/audio/audio_pref_handler.h" |
95 #include "chromeos/audio/cras_audio_handler.h" | 94 #include "chromeos/audio/cras_audio_handler.h" |
96 #include "chromeos/chromeos_paths.h" | 95 #include "chromeos/chromeos_paths.h" |
97 #include "chromeos/chromeos_switches.h" | 96 #include "chromeos/chromeos_switches.h" |
(...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
547 MagnificationManager::Initialize(); | 546 MagnificationManager::Initialize(); |
548 | 547 |
549 // Add observers for WallpaperManager. This depends on PowerManagerClient, | 548 // Add observers for WallpaperManager. This depends on PowerManagerClient, |
550 // TimezoneSettings and CrosSettings. | 549 // TimezoneSettings and CrosSettings. |
551 WallpaperManager::Get()->AddObservers(); | 550 WallpaperManager::Get()->AddObservers(); |
552 | 551 |
553 cros_version_loader_.GetVersion(VersionLoader::VERSION_FULL, | 552 cros_version_loader_.GetVersion(VersionLoader::VERSION_FULL, |
554 base::Bind(&ChromeOSVersionCallback), | 553 base::Bind(&ChromeOSVersionCallback), |
555 &tracker_); | 554 &tracker_); |
556 | 555 |
557 storage_monitor_.reset(new StorageMonitorCros()); | |
558 | |
559 // Make sure that wallpaper boot transition and other delays in OOBE | 556 // Make sure that wallpaper boot transition and other delays in OOBE |
560 // are disabled for tests and kiosk app launch by default. | 557 // are disabled for tests and kiosk app launch by default. |
561 // Individual tests may enable them if they want. | 558 // Individual tests may enable them if they want. |
562 if (parsed_command_line().HasSwitch(::switches::kTestType) || | 559 if (parsed_command_line().HasSwitch(::switches::kTestType) || |
563 ShouldAutoLaunchKioskApp(parsed_command_line())) { | 560 ShouldAutoLaunchKioskApp(parsed_command_line())) { |
564 WizardController::SetZeroDelays(); | 561 WizardController::SetZeroDelays(); |
565 } | 562 } |
566 | 563 |
567 // In Aura builds this will initialize ash::Shell. | 564 // In Aura builds this will initialize ash::Shell. |
568 ChromeBrowserMainPartsLinux::PreProfileInit(); | 565 ChromeBrowserMainPartsLinux::PreProfileInit(); |
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
796 // Let classes unregister themselves as observers of the ash::Shell singleton | 793 // Let classes unregister themselves as observers of the ash::Shell singleton |
797 // before the shell is destroyed. | 794 // before the shell is destroyed. |
798 user_activity_notifier_.reset(); | 795 user_activity_notifier_.reset(); |
799 video_activity_notifier_.reset(); | 796 video_activity_notifier_.reset(); |
800 display_configuration_observer_.reset(); | 797 display_configuration_observer_.reset(); |
801 | 798 |
802 // Detach D-Bus clients before DBusThreadManager is shut down. | 799 // Detach D-Bus clients before DBusThreadManager is shut down. |
803 power_button_observer_.reset(); | 800 power_button_observer_.reset(); |
804 screensaver_controller_.reset(); | 801 screensaver_controller_.reset(); |
805 idle_action_warning_observer_.reset(); | 802 idle_action_warning_observer_.reset(); |
806 storage_monitor_.reset(); | |
807 | 803 |
808 // Delete ContactManager while |g_browser_process| is still alive. | 804 // Delete ContactManager while |g_browser_process| is still alive. |
809 contact_manager_.reset(); | 805 contact_manager_.reset(); |
810 | 806 |
811 MagnificationManager::Shutdown(); | 807 MagnificationManager::Shutdown(); |
812 AccessibilityManager::Shutdown(); | 808 AccessibilityManager::Shutdown(); |
813 | 809 |
814 // Let the UserManager and WallpaperManager unregister itself as an observer | 810 // Let the UserManager and WallpaperManager unregister itself as an observer |
815 // of the CrosSettings singleton before it is destroyed. | 811 // of the CrosSettings singleton before it is destroyed. |
816 UserManager::Get()->Shutdown(); | 812 UserManager::Get()->Shutdown(); |
(...skipping 19 matching lines...) Expand all Loading... |
836 ChromeBrowserMainPartsLinux::PostDestroyThreads(); | 832 ChromeBrowserMainPartsLinux::PostDestroyThreads(); |
837 // Destroy DeviceSettingsService after g_browser_process. | 833 // Destroy DeviceSettingsService after g_browser_process. |
838 DeviceSettingsService::Shutdown(); | 834 DeviceSettingsService::Shutdown(); |
839 } | 835 } |
840 | 836 |
841 void ChromeBrowserMainPartsChromeos::SetupPlatformFieldTrials() { | 837 void ChromeBrowserMainPartsChromeos::SetupPlatformFieldTrials() { |
842 default_pinned_apps_field_trial::SetupTrial(); | 838 default_pinned_apps_field_trial::SetupTrial(); |
843 } | 839 } |
844 | 840 |
845 } // namespace chromeos | 841 } // namespace chromeos |
OLD | NEW |