OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/login/supervised/supervised_user_creation_scre
en.h" | 5 #include "chrome/browser/chromeos/login/supervised/supervised_user_creation_scre
en.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
| 9 #include "ash/common/shelf/wm_shelf.h" |
9 #include "ash/common/wallpaper/wallpaper_controller.h" | 10 #include "ash/common/wallpaper/wallpaper_controller.h" |
10 #include "ash/common/wm_shell.h" | 11 #include "ash/common/wm_shell.h" |
11 #include "base/memory/ptr_util.h" | 12 #include "base/memory/ptr_util.h" |
12 #include "base/rand_util.h" | 13 #include "base/rand_util.h" |
13 #include "base/values.h" | 14 #include "base/values.h" |
14 #include "chrome/browser/chromeos/camera_detector.h" | 15 #include "chrome/browser/chromeos/camera_detector.h" |
15 #include "chrome/browser/chromeos/login/error_screens_histogram_helper.h" | 16 #include "chrome/browser/chromeos/login/error_screens_histogram_helper.h" |
16 #include "chrome/browser/chromeos/login/existing_user_controller.h" | 17 #include "chrome/browser/chromeos/login/existing_user_controller.h" |
17 #include "chrome/browser/chromeos/login/screen_manager.h" | 18 #include "chrome/browser/chromeos/login/screen_manager.h" |
18 #include "chrome/browser/chromeos/login/screens/base_screen_delegate.h" | 19 #include "chrome/browser/chromeos/login/screens/base_screen_delegate.h" |
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
361 void SupervisedUserCreationScreen::OnManagerFullyAuthenticated( | 362 void SupervisedUserCreationScreen::OnManagerFullyAuthenticated( |
362 Profile* manager_profile) { | 363 Profile* manager_profile) { |
363 DBusThreadManager::Get() | 364 DBusThreadManager::Get() |
364 ->GetSessionManagerClient() | 365 ->GetSessionManagerClient() |
365 ->NotifySupervisedUserCreationStarted(); | 366 ->NotifySupervisedUserCreationStarted(); |
366 manager_signin_in_progress_ = false; | 367 manager_signin_in_progress_ = false; |
367 DCHECK(controller_.get()); | 368 DCHECK(controller_.get()); |
368 // For manager user, move wallpaper to locked container so that windows | 369 // For manager user, move wallpaper to locked container so that windows |
369 // created during the user image picker step are below it. | 370 // created during the user image picker step are below it. |
370 ash::WmShell::Get()->wallpaper_controller()->MoveToLockedContainer(); | 371 ash::WmShell::Get()->wallpaper_controller()->MoveToLockedContainer(); |
| 372 ash::WmShelf::ForWindow(ash::WmShell::Get()->GetPrimaryRootWindow()) |
| 373 ->SetAlignment(ash::ShelfAlignment::SHELF_ALIGNMENT_BOTTOM_LOCKED); |
371 | 374 |
372 controller_->SetManagerProfile(manager_profile); | 375 controller_->SetManagerProfile(manager_profile); |
373 if (actor_) | 376 if (actor_) |
374 actor_->ShowUsernamePage(); | 377 actor_->ShowUsernamePage(); |
375 | 378 |
376 last_page_ = kNameOfNewUserParametersScreen; | 379 last_page_ = kNameOfNewUserParametersScreen; |
377 CHECK(!sync_service_); | 380 CHECK(!sync_service_); |
378 sync_service_ = SupervisedUserSyncServiceFactory::GetForProfile( | 381 sync_service_ = SupervisedUserSyncServiceFactory::GetForProfile( |
379 manager_profile); | 382 manager_profile); |
380 sync_service_->AddObserver(this); | 383 sync_service_->AddObserver(this); |
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
618 selected_image_ = user_manager::User::USER_IMAGE_EXTERNAL; | 621 selected_image_ = user_manager::User::USER_IMAGE_EXTERNAL; |
619 } else { | 622 } else { |
620 NOTREACHED() << "Unexpected image type: " << image_type; | 623 NOTREACHED() << "Unexpected image type: " << image_type; |
621 } | 624 } |
622 } | 625 } |
623 | 626 |
624 void SupervisedUserCreationScreen::OnImageAccepted() { | 627 void SupervisedUserCreationScreen::OnImageAccepted() { |
625 } | 628 } |
626 | 629 |
627 } // namespace chromeos | 630 } // namespace chromeos |
OLD | NEW |