| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/chromeos/chromeos_version.h" | 9 #include "base/chromeos/chromeos_version.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 331 chromeos::ScreenLocker::InitClass(); | 331 chromeos::ScreenLocker::InitClass(); |
| 332 } | 332 } |
| 333 | 333 |
| 334 // This forces the ProfileManager to be created and register for the | 334 // This forces the ProfileManager to be created and register for the |
| 335 // notification it needs to track the logged in user. | 335 // notification it needs to track the logged in user. |
| 336 g_browser_process->profile_manager(); | 336 g_browser_process->profile_manager(); |
| 337 | 337 |
| 338 // TODO(abarth): Should this move to InitializeNetworkOptions()? | 338 // TODO(abarth): Should this move to InitializeNetworkOptions()? |
| 339 // Allow access to file:// on ChromeOS for tests. | 339 // Allow access to file:// on ChromeOS for tests. |
| 340 if (parsed_command_line().HasSwitch(switches::kAllowFileAccess)) | 340 if (parsed_command_line().HasSwitch(switches::kAllowFileAccess)) |
| 341 net::URLRequest::AllowFileAccess(); | 341 net::URLRequest::AllowAccessToAllFiles(); |
| 342 | 342 |
| 343 // There are two use cases for kLoginUser: | 343 // There are two use cases for kLoginUser: |
| 344 // 1) if passed in tandem with kLoginPassword, to drive a "StubLogin" | 344 // 1) if passed in tandem with kLoginPassword, to drive a "StubLogin" |
| 345 // 2) if passed alone, to signal that the indicated user has already | 345 // 2) if passed alone, to signal that the indicated user has already |
| 346 // logged in and we should behave accordingly. | 346 // logged in and we should behave accordingly. |
| 347 // This handles case 2. | 347 // This handles case 2. |
| 348 if (parsed_command_line().HasSwitch(switches::kLoginUser) && | 348 if (parsed_command_line().HasSwitch(switches::kLoginUser) && |
| 349 !parsed_command_line().HasSwitch(switches::kLoginPassword)) { | 349 !parsed_command_line().HasSwitch(switches::kLoginPassword)) { |
| 350 std::string username = | 350 std::string username = |
| 351 parsed_command_line().GetSwitchValueASCII(switches::kLoginUser); | 351 parsed_command_line().GetSwitchValueASCII(switches::kLoginUser); |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 493 | 493 |
| 494 // Let VideoPropertyWriter unregister itself as an observer of the ash::Shell | 494 // Let VideoPropertyWriter unregister itself as an observer of the ash::Shell |
| 495 // singleton before the shell is destroyed. | 495 // singleton before the shell is destroyed. |
| 496 video_property_writer_.reset(); | 496 video_property_writer_.reset(); |
| 497 // Remove PowerButtonObserver attached to a D-Bus client before | 497 // Remove PowerButtonObserver attached to a D-Bus client before |
| 498 // DBusThreadManager is shut down. | 498 // DBusThreadManager is shut down. |
| 499 power_button_observer_.reset(); | 499 power_button_observer_.reset(); |
| 500 | 500 |
| 501 ChromeBrowserMainPartsLinux::PostMainMessageLoopRun(); | 501 ChromeBrowserMainPartsLinux::PostMainMessageLoopRun(); |
| 502 } | 502 } |
| OLD | NEW |