Commit e2b59c4c authored by merkulova's avatar merkulova Committed by Commit bot

Special check on Supervised User creation flow added to prevent misleading shelf alignment.

BUG=405361

Review URL: https://codereview.chromium.org/783663003

Cr-Commit-Position: refs/heads/master@{#309555}
parent 4353cae3
......@@ -252,7 +252,8 @@ bool ShelfLayoutManager::SetAlignment(ShelfAlignment alignment) {
return false;
alignment_ = alignment;
if (state_.is_screen_locked || state_.is_adding_user_screen) {
if (Shell::GetInstance()->session_state_delegate()->IsUserSessionBlocked() ||
state_.is_adding_user_screen) {
// The shelf will itself move to the bottom while locked. If a request is
// sent to move while being locked, we postpone the move until the lock
// screen goes away.
......@@ -270,7 +271,8 @@ ShelfAlignment ShelfLayoutManager::GetAlignment() const {
// bottom alignment. Note: We cannot use state_.is_screen_locked here since
// that flag gets set later than the SessionStateDelegate reports a locked
// screen which leads in
if (state_.is_screen_locked || state_.is_adding_user_screen)
if (Shell::GetInstance()->session_state_delegate()->IsUserSessionBlocked() ||
state_.is_adding_user_screen)
return SHELF_ALIGNMENT_BOTTOM;
return alignment_;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment