OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "ash/aura/wm_shell_aura.h" | 5 #include "ash/aura/wm_shell_aura.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "ash/accelerators/accelerator_controller_delegate_aura.h" | 9 #include "ash/accelerators/accelerator_controller_delegate_aura.h" |
10 #include "ash/aura/key_event_watcher_aura.h" | 10 #include "ash/aura/key_event_watcher_aura.h" |
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
284 | 284 |
285 std::unique_ptr<AcceleratorController> | 285 std::unique_ptr<AcceleratorController> |
286 WmShellAura::CreateAcceleratorController() { | 286 WmShellAura::CreateAcceleratorController() { |
287 DCHECK(!accelerator_controller_delegate_); | 287 DCHECK(!accelerator_controller_delegate_); |
288 accelerator_controller_delegate_ = | 288 accelerator_controller_delegate_ = |
289 base::MakeUnique<AcceleratorControllerDelegateAura>(); | 289 base::MakeUnique<AcceleratorControllerDelegateAura>(); |
290 return base::MakeUnique<AcceleratorController>( | 290 return base::MakeUnique<AcceleratorController>( |
291 accelerator_controller_delegate_.get(), nullptr); | 291 accelerator_controller_delegate_.get(), nullptr); |
292 } | 292 } |
293 | 293 |
294 void WmShellAura::SessionStateChanged(session_manager::SessionState state) { | |
295 // Create the shelf if necessary. | |
296 WmShell::SessionStateChanged(state); | |
297 | |
298 // Recreate the keyboard after initial login and after multiprofile login. | |
299 if (state == session_manager::SessionState::ACTIVE) | |
300 Shell::GetInstance()->CreateKeyboard(); | |
301 } | |
302 | |
303 void WmShellAura::OnDisplayConfigurationChanging() { | 294 void WmShellAura::OnDisplayConfigurationChanging() { |
304 for (auto& observer : display_observers_) | 295 for (auto& observer : display_observers_) |
305 observer.OnDisplayConfigurationChanging(); | 296 observer.OnDisplayConfigurationChanging(); |
306 } | 297 } |
307 | 298 |
308 void WmShellAura::OnDisplayConfigurationChanged() { | 299 void WmShellAura::OnDisplayConfigurationChanged() { |
309 for (auto& observer : display_observers_) | 300 for (auto& observer : display_observers_) |
310 observer.OnDisplayConfigurationChanged(); | 301 observer.OnDisplayConfigurationChanged(); |
311 } | 302 } |
312 | 303 |
313 } // namespace ash | 304 } // namespace ash |
OLD | NEW |