Commit 57166b42 authored by Xiyuan Xia's avatar Xiyuan Xia Committed by Commit Bot

ash: Fix transparent shelf with stub user

Regression caused by https://crrev.com/c/1603484. The shelf
background type is not initialized corresponding to the initial
session state. When starting with stub user or an existing user
(crash-n-restore), ShelfLayoutManager thinks it paints the default
background but ShelfWidget actually paints the login background
(i.e. transparent).

Bug: 958214
Test: Run chrome with stub user and observer shelf background.
Change-Id: I6e33e02e4213052ea90ecb0ae94c3dc8b9568dd7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1604489
Commit-Queue: Xiyuan Xia <xiyuan@chromium.org>
Reviewed-by: default avatarScott Violet <sky@chromium.org>
Cr-Commit-Position: refs/heads/master@{#658721}
parent 2bacf20a
...@@ -277,6 +277,7 @@ void ShelfLayoutManager::InitObservers() { ...@@ -277,6 +277,7 @@ void ShelfLayoutManager::InitObservers() {
Shell::Get()->activation_client()->AddObserver(this); Shell::Get()->activation_client()->AddObserver(this);
Shell::Get()->locale_update_controller()->AddObserver(this); Shell::Get()->locale_update_controller()->AddObserver(this);
state_.session_state = Shell::Get()->session_controller()->GetSessionState(); state_.session_state = Shell::Get()->session_controller()->GetSessionState();
shelf_background_type_ = GetShelfBackgroundType();
wallpaper_controller_observer_.Add(Shell::Get()->wallpaper_controller()); wallpaper_controller_observer_.Add(Shell::Get()->wallpaper_controller());
display::Screen::GetScreen()->AddObserver(this); display::Screen::GetScreen()->AddObserver(this);
ScreenRotationAnimator::GetForRootWindow( ScreenRotationAnimator::GetForRootWindow(
......
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