Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: ash/shell.cc

Issue 2777103005: Using WmDisplayObserver in ScreenPinningController. (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | ash/wm/screen_pinning_controller.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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
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 if (!is_mash)
982 screen_pinning_controller_.reset( 982 screen_pinning_controller_ = base::MakeUnique<ScreenPinningController>();
983 new ScreenPinningController(window_tree_host_manager_.get()));
984 }
985 983
986 lock_state_controller_ = 984 lock_state_controller_ =
987 base::MakeUnique<LockStateController>(shutdown_controller_.get()); 985 base::MakeUnique<LockStateController>(shutdown_controller_.get());
988 power_button_controller_.reset( 986 power_button_controller_.reset(
989 new PowerButtonController(lock_state_controller_.get())); 987 new PowerButtonController(lock_state_controller_.get()));
990 // Pass the initial display state to PowerButtonController. 988 // Pass the initial display state to PowerButtonController.
991 power_button_controller_->OnDisplayModeChanged( 989 power_button_controller_->OnDisplayModeChanged(
992 display_configurator_->cached_displays()); 990 display_configurator_->cached_displays());
993 991
994 AddShellObserver(lock_state_controller_.get()); 992 AddShellObserver(lock_state_controller_.get());
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
1244 1242
1245 // Only trigger an update in mash because with classic ash chrome calls 1243 // Only trigger an update in mash because with classic ash chrome calls
1246 // UpdateAfterLoginStatusChange() directly. 1244 // UpdateAfterLoginStatusChange() directly.
1247 if (wm_shell_->IsRunningInMash()) { 1245 if (wm_shell_->IsRunningInMash()) {
1248 // TODO(jamescook): Should this call Shell::OnLoginStatusChanged() too? 1246 // TODO(jamescook): Should this call Shell::OnLoginStatusChanged() too?
1249 UpdateAfterLoginStatusChange(session_controller_->GetLoginStatus()); 1247 UpdateAfterLoginStatusChange(session_controller_->GetLoginStatus());
1250 } 1248 }
1251 } 1249 }
1252 1250
1253 } // namespace ash 1251 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | ash/wm/screen_pinning_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698