Index: ash/wm/shelf_layout_manager.cc |
diff --git a/ash/wm/shelf_layout_manager.cc b/ash/wm/shelf_layout_manager.cc |
index 0251f844eb65c52190ea299a41ba43e6aa8fbe9e..9d1099e309cfc623d165b2e0af808452dd16c3e9 100644 |
--- a/ash/wm/shelf_layout_manager.cc |
+++ b/ash/wm/shelf_layout_manager.cc |
@@ -271,9 +271,11 @@ void ShelfLayoutManager::OnWindowPropertyChanged(aura::Window* window, |
// ShelfLayoutManager, private: |
void ShelfLayoutManager::SetState(VisibilityState visibility_state) { |
+ ShellDelegate* delegate = Shell::GetInstance()->delegate(); |
State state; |
state.visibility_state = visibility_state; |
state.auto_hide_state = CalculateAutoHideState(visibility_state); |
+ state.locked_state = delegate && delegate->IsScreenLocked(); |
if (state_.Equals(state)) |
return; // Nothing changed. |
@@ -383,7 +385,8 @@ void ShelfLayoutManager::UpdateShelfBackground( |
} |
bool ShelfLayoutManager::GetLauncherPaintsBackground() const { |
- return window_overlaps_shelf_ || state_.visibility_state == AUTO_HIDE; |
+ return (!state_.locked_state && window_overlaps_shelf_) || |
+ state_.visibility_state == AUTO_HIDE; |
} |
void ShelfLayoutManager::UpdateAutoHideStateNow() { |