| Index: chrome/browser/chromeos/login/user_manager_impl.cc
|
| diff --git a/chrome/browser/chromeos/login/user_manager_impl.cc b/chrome/browser/chromeos/login/user_manager_impl.cc
|
| index 2cdd827c95c3318099e7bf118acb85cbf151108d..a51279348b7f0973e287f982e6c7ff7454084bdc 100644
|
| --- a/chrome/browser/chromeos/login/user_manager_impl.cc
|
| +++ b/chrome/browser/chromeos/login/user_manager_impl.cc
|
| @@ -376,11 +376,18 @@ void UserManagerImpl::EphemeralUserLoggedIn(const std::string& email) {
|
|
|
| void UserManagerImpl::InitializeWallpaper() {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
|
| +
|
| + if (WizardController::IsZeroDelayEnabled())
|
| + return;
|
| +
|
| + bool disable_new_oobe = CommandLine::ForCurrentProcess()->
|
| + HasSwitch(switches::kDisableNewOobe);
|
| + bool disable_boot_animation = CommandLine::ForCurrentProcess()->
|
| + HasSwitch(switches::kDisableBootAnimation);
|
| +
|
| if (!IsUserLoggedIn()) {
|
| - if (!CommandLine::ForCurrentProcess()->HasSwitch(
|
| - switches::kDisableNewOobe)) {
|
| - if (!WizardController::IsDeviceRegistered() &&
|
| - !WizardController::IsZeroDelayEnabled()) {
|
| + if (!disable_new_oobe) {
|
| + if (!WizardController::IsDeviceRegistered()) {
|
| // TODO(nkostylev): Add switch to disable wallpaper transition on OOBE.
|
| // Should be used on test images so that they are not slowed down.
|
| ash::Shell::GetInstance()->desktop_background_controller()->
|
| @@ -392,8 +399,18 @@ void UserManagerImpl::InitializeWallpaper() {
|
| DCHECK(result) << "Unable to fetch setting "
|
| << kAccountsPrefShowUserNamesOnSignIn;
|
| if (!show_users) {
|
| + // Boot into sign in form, preload default wallpaper.
|
| ash::Shell::GetInstance()->desktop_background_controller()->
|
| - SetDefaultWallpaper(ash::GetSolidColorIndex());
|
| + SetDefaultWallpaper(kDefaultOOBEWallpaperIndex);
|
| + } else if (!disable_boot_animation) {
|
| + // Normal boot, load user wallpaper.
|
| + const chromeos::UserList& users = GetUsers();
|
| + if (!users.empty()) {
|
| + UserSelected(users[0]->email());
|
| + } else {
|
| + ash::Shell::GetInstance()->desktop_background_controller()->
|
| + SetDefaultWallpaper(kDefaultOOBEWallpaperIndex);
|
| + }
|
| }
|
| }
|
| }
|
|
|