| 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 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 #include "components/ownership/owner_key_util.h" | 109 #include "components/ownership/owner_key_util.h" |
| 110 #include "components/session_manager/core/session_manager.h" | 110 #include "components/session_manager/core/session_manager.h" |
| 111 #include "components/user_manager/user.h" | 111 #include "components/user_manager/user.h" |
| 112 #include "components/user_manager/user_manager.h" | 112 #include "components/user_manager/user_manager.h" |
| 113 #include "content/public/browser/browser_thread.h" | 113 #include "content/public/browser/browser_thread.h" |
| 114 #include "content/public/browser/notification_service.h" | 114 #include "content/public/browser/notification_service.h" |
| 115 #include "content/public/browser/power_save_blocker.h" | 115 #include "content/public/browser/power_save_blocker.h" |
| 116 #include "content/public/common/main_function_params.h" | 116 #include "content/public/common/main_function_params.h" |
| 117 #include "media/audio/sounds/sounds_manager.h" | 117 #include "media/audio/sounds/sounds_manager.h" |
| 118 #include "net/base/network_change_notifier.h" | 118 #include "net/base/network_change_notifier.h" |
| 119 #include "net/socket/ssl_server_socket.h" | |
| 120 #include "net/url_request/url_request.h" | 119 #include "net/url_request/url_request.h" |
| 121 #include "net/url_request/url_request_context_getter.h" | 120 #include "net/url_request/url_request_context_getter.h" |
| 122 #include "ui/base/touch/touch_device.h" | 121 #include "ui/base/touch/touch_device.h" |
| 123 #include "ui/events/event_utils.h" | 122 #include "ui/events/event_utils.h" |
| 124 | 123 |
| 125 // Exclude X11 dependents for ozone | 124 // Exclude X11 dependents for ozone |
| 126 #if defined(USE_X11) | 125 #if defined(USE_X11) |
| 127 #include "chrome/browser/chromeos/device_uma.h" | 126 #include "chrome/browser/chromeos/device_uma.h" |
| 128 #include "chrome/browser/chromeos/events/system_key_event_listener.h" | 127 #include "chrome/browser/chromeos/events/system_key_event_listener.h" |
| 129 #include "chrome/browser/chromeos/events/xinput_hierarchy_changed_event_listener
.h" | 128 #include "chrome/browser/chromeos/events/xinput_hierarchy_changed_event_listener
.h" |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 304 if (!base::SysInfo::IsRunningOnChromeOS() && | 303 if (!base::SysInfo::IsRunningOnChromeOS() && |
| 305 PathService::Get(chrome::DIR_USER_DATA, &user_data_dir)) { | 304 PathService::Get(chrome::DIR_USER_DATA, &user_data_dir)) { |
| 306 // Override some paths with stub locations so that cloud policy and | 305 // Override some paths with stub locations so that cloud policy and |
| 307 // enterprise enrollment work on desktop builds, for ease of | 306 // enterprise enrollment work on desktop builds, for ease of |
| 308 // development. | 307 // development. |
| 309 chromeos::RegisterStubPathOverrides(user_data_dir); | 308 chromeos::RegisterStubPathOverrides(user_data_dir); |
| 310 } | 309 } |
| 311 | 310 |
| 312 dbus_services_.reset(new internal::DBusServices(parameters())); | 311 dbus_services_.reset(new internal::DBusServices(parameters())); |
| 313 | 312 |
| 314 // Enable support for SSL server sockets, which must be done while still | |
| 315 // single-threaded. This is required for remote assistance host on Chrome OS. | |
| 316 net::EnableSSLServerSockets(); | |
| 317 | |
| 318 ChromeBrowserMainPartsLinux::PostMainMessageLoopStart(); | 313 ChromeBrowserMainPartsLinux::PostMainMessageLoopStart(); |
| 319 } | 314 } |
| 320 | 315 |
| 321 // Threads are initialized between MainMessageLoopStart and MainMessageLoopRun. | 316 // Threads are initialized between MainMessageLoopStart and MainMessageLoopRun. |
| 322 // about_flags settings are applied in ChromeBrowserMainParts::PreCreateThreads. | 317 // about_flags settings are applied in ChromeBrowserMainParts::PreCreateThreads. |
| 323 void ChromeBrowserMainPartsChromeos::PreMainMessageLoopRun() { | 318 void ChromeBrowserMainPartsChromeos::PreMainMessageLoopRun() { |
| 324 // Set the crypto thread after the IO thread has been created/started. | 319 // Set the crypto thread after the IO thread has been created/started. |
| 325 TPMTokenLoader::Get()->SetCryptoTaskRunner( | 320 TPMTokenLoader::Get()->SetCryptoTaskRunner( |
| 326 content::BrowserThread::GetMessageLoopProxyForThread( | 321 content::BrowserThread::GetMessageLoopProxyForThread( |
| 327 content::BrowserThread::IO)); | 322 content::BrowserThread::IO)); |
| (...skipping 457 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 785 // Destroy DBus services immediately after threads are stopped. | 780 // Destroy DBus services immediately after threads are stopped. |
| 786 dbus_services_.reset(); | 781 dbus_services_.reset(); |
| 787 | 782 |
| 788 ChromeBrowserMainPartsLinux::PostDestroyThreads(); | 783 ChromeBrowserMainPartsLinux::PostDestroyThreads(); |
| 789 | 784 |
| 790 // Destroy DeviceSettingsService after g_browser_process. | 785 // Destroy DeviceSettingsService after g_browser_process. |
| 791 DeviceSettingsService::Shutdown(); | 786 DeviceSettingsService::Shutdown(); |
| 792 } | 787 } |
| 793 | 788 |
| 794 } // namespace chromeos | 789 } // namespace chromeos |
| OLD | NEW |