| 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 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 | 117 |
| 118 // Exclude X11 dependents for ozone | 118 // Exclude X11 dependents for ozone |
| 119 #if defined(USE_X11) | 119 #if defined(USE_X11) |
| 120 #include "chrome/browser/chromeos/device_uma.h" | 120 #include "chrome/browser/chromeos/device_uma.h" |
| 121 #endif | 121 #endif |
| 122 | 122 |
| 123 namespace chromeos { | 123 namespace chromeos { |
| 124 | 124 |
| 125 namespace { | 125 namespace { |
| 126 | 126 |
| 127 #if defined(USE_LINUX_BREAKPAD) | |
| 128 void ChromeOSVersionCallback(const std::string& version) { | 127 void ChromeOSVersionCallback(const std::string& version) { |
| 129 base::SetLinuxDistro(std::string("CrOS ") + version); | 128 base::SetLinuxDistro(std::string("CrOS ") + version); |
| 130 } | 129 } |
| 131 | 130 |
| 132 #endif | |
| 133 | |
| 134 class MessageLoopObserver : public base::MessageLoopForUI::Observer { | 131 class MessageLoopObserver : public base::MessageLoopForUI::Observer { |
| 135 virtual base::EventStatus WillProcessEvent( | 132 virtual base::EventStatus WillProcessEvent( |
| 136 const base::NativeEvent& event) OVERRIDE { | 133 const base::NativeEvent& event) OVERRIDE { |
| 137 return base::EVENT_CONTINUE; | 134 return base::EVENT_CONTINUE; |
| 138 } | 135 } |
| 139 | 136 |
| 140 virtual void DidProcessEvent( | 137 virtual void DidProcessEvent( |
| 141 const base::NativeEvent& event) OVERRIDE { | 138 const base::NativeEvent& event) OVERRIDE { |
| 142 } | 139 } |
| 143 }; | 140 }; |
| (...skipping 408 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 552 | 549 |
| 553 // Initialize magnification manager before ash tray is created. And this must | 550 // Initialize magnification manager before ash tray is created. And this must |
| 554 // be placed after UserManager::SessionStarted(); | 551 // be placed after UserManager::SessionStarted(); |
| 555 AccessibilityManager::Initialize(); | 552 AccessibilityManager::Initialize(); |
| 556 MagnificationManager::Initialize(); | 553 MagnificationManager::Initialize(); |
| 557 | 554 |
| 558 // Add observers for WallpaperManager. This depends on PowerManagerClient, | 555 // Add observers for WallpaperManager. This depends on PowerManagerClient, |
| 559 // TimezoneSettings and CrosSettings. | 556 // TimezoneSettings and CrosSettings. |
| 560 WallpaperManager::Get()->AddObservers(); | 557 WallpaperManager::Get()->AddObservers(); |
| 561 | 558 |
| 562 #if defined(USE_LINUX_BREAKPAD) | |
| 563 cros_version_loader_.GetVersion(VersionLoader::VERSION_FULL, | 559 cros_version_loader_.GetVersion(VersionLoader::VERSION_FULL, |
| 564 base::Bind(&ChromeOSVersionCallback), | 560 base::Bind(&ChromeOSVersionCallback), |
| 565 &tracker_); | 561 &tracker_); |
| 566 #endif | |
| 567 | 562 |
| 568 storage_monitor_.reset(new StorageMonitorCros()); | 563 storage_monitor_.reset(new StorageMonitorCros()); |
| 569 | 564 |
| 570 // Make sure that wallpaper boot transition and other delays in OOBE | 565 // Make sure that wallpaper boot transition and other delays in OOBE |
| 571 // are disabled for tests and kiosk app launch by default. | 566 // are disabled for tests and kiosk app launch by default. |
| 572 // Individual tests may enable them if they want. | 567 // Individual tests may enable them if they want. |
| 573 if (parsed_command_line().HasSwitch(::switches::kTestType) || | 568 if (parsed_command_line().HasSwitch(::switches::kTestType) || |
| 574 ShouldAutoLaunchKioskApp(parsed_command_line())) { | 569 ShouldAutoLaunchKioskApp(parsed_command_line())) { |
| 575 WizardController::SetZeroDelays(); | 570 WizardController::SetZeroDelays(); |
| 576 } | 571 } |
| (...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 847 ChromeBrowserMainPartsLinux::PostDestroyThreads(); | 842 ChromeBrowserMainPartsLinux::PostDestroyThreads(); |
| 848 // Destroy DeviceSettingsService after g_browser_process. | 843 // Destroy DeviceSettingsService after g_browser_process. |
| 849 DeviceSettingsService::Shutdown(); | 844 DeviceSettingsService::Shutdown(); |
| 850 } | 845 } |
| 851 | 846 |
| 852 void ChromeBrowserMainPartsChromeos::SetupPlatformFieldTrials() { | 847 void ChromeBrowserMainPartsChromeos::SetupPlatformFieldTrials() { |
| 853 default_pinned_apps_field_trial::SetupTrial(); | 848 default_pinned_apps_field_trial::SetupTrial(); |
| 854 } | 849 } |
| 855 | 850 |
| 856 } // namespace chromeos | 851 } // namespace chromeos |
| OLD | NEW |