| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/shell.h" | 5 #include "ash/shell.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 960 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 971 | 971 |
| 972 toplevel_window_event_handler_.reset( | 972 toplevel_window_event_handler_.reset( |
| 973 new ToplevelWindowEventHandler(wm_shell_.get())); | 973 new ToplevelWindowEventHandler(wm_shell_.get())); |
| 974 | 974 |
| 975 if (!is_mash) { | 975 if (!is_mash) { |
| 976 system_gesture_filter_.reset(new SystemGestureEventFilter); | 976 system_gesture_filter_.reset(new SystemGestureEventFilter); |
| 977 AddPreTargetHandler(system_gesture_filter_.get()); | 977 AddPreTargetHandler(system_gesture_filter_.get()); |
| 978 } | 978 } |
| 979 | 979 |
| 980 sticky_keys_controller_.reset(new StickyKeysController); | 980 sticky_keys_controller_.reset(new StickyKeysController); |
| 981 if (!is_mash) | 981 screen_pinning_controller_ = base::MakeUnique<ScreenPinningController>(); |
| 982 screen_pinning_controller_ = base::MakeUnique<ScreenPinningController>(); | |
| 983 | 982 |
| 984 lock_state_controller_ = | 983 lock_state_controller_ = |
| 985 base::MakeUnique<LockStateController>(shutdown_controller_.get()); | 984 base::MakeUnique<LockStateController>(shutdown_controller_.get()); |
| 986 power_button_controller_.reset( | 985 power_button_controller_.reset( |
| 987 new PowerButtonController(lock_state_controller_.get())); | 986 new PowerButtonController(lock_state_controller_.get())); |
| 988 // Pass the initial display state to PowerButtonController. | 987 // Pass the initial display state to PowerButtonController. |
| 989 power_button_controller_->OnDisplayModeChanged( | 988 power_button_controller_->OnDisplayModeChanged( |
| 990 display_configurator_->cached_displays()); | 989 display_configurator_->cached_displays()); |
| 991 | 990 |
| 992 AddShellObserver(lock_state_controller_.get()); | 991 AddShellObserver(lock_state_controller_.get()); |
| (...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1242 | 1241 |
| 1243 // Only trigger an update in mash because with classic ash chrome calls | 1242 // Only trigger an update in mash because with classic ash chrome calls |
| 1244 // UpdateAfterLoginStatusChange() directly. | 1243 // UpdateAfterLoginStatusChange() directly. |
| 1245 if (wm_shell_->IsRunningInMash()) { | 1244 if (wm_shell_->IsRunningInMash()) { |
| 1246 // TODO(jamescook): Should this call Shell::OnLoginStatusChanged() too? | 1245 // TODO(jamescook): Should this call Shell::OnLoginStatusChanged() too? |
| 1247 UpdateAfterLoginStatusChange(session_controller_->GetLoginStatus()); | 1246 UpdateAfterLoginStatusChange(session_controller_->GetLoginStatus()); |
| 1248 } | 1247 } |
| 1249 } | 1248 } |
| 1250 | 1249 |
| 1251 } // namespace ash | 1250 } // namespace ash |
| OLD | NEW |