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/root_window_controller.h" | 5 #include "ash/root_window_controller.h" |
6 | 6 |
7 #include <queue> | 7 #include <queue> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ash/ash_constants.h" | 10 #include "ash/ash_constants.h" |
(...skipping 942 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
953 SetUsesScreenCoordinates(modal_container); | 953 SetUsesScreenCoordinates(modal_container); |
954 SetUsesEasyResizeTargeter(modal_container); | 954 SetUsesEasyResizeTargeter(modal_container); |
955 | 955 |
956 // TODO(beng): Figure out if we can make this use | 956 // TODO(beng): Figure out if we can make this use |
957 // SystemModalContainerEventFilter instead of stops_event_propagation. | 957 // SystemModalContainerEventFilter instead of stops_event_propagation. |
958 aura::Window* lock_container = CreateContainer( | 958 aura::Window* lock_container = CreateContainer( |
959 kShellWindowId_LockScreenContainer, | 959 kShellWindowId_LockScreenContainer, |
960 "LockScreenContainer", | 960 "LockScreenContainer", |
961 lock_screen_containers); | 961 lock_screen_containers); |
962 wm::SetSnapsChildrenToPhysicalPixelBoundary(lock_container); | 962 wm::SetSnapsChildrenToPhysicalPixelBoundary(lock_container); |
963 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 963 lock_container->SetLayoutManager(new LockLayoutManager(lock_container)); |
964 switches::kAshDisableLockLayoutManager)) { | |
965 lock_container->SetLayoutManager( | |
966 new WorkspaceLayoutManager(lock_container)); | |
967 } else { | |
968 lock_container->SetLayoutManager(new LockLayoutManager(lock_container)); | |
969 } | |
970 SetUsesScreenCoordinates(lock_container); | 964 SetUsesScreenCoordinates(lock_container); |
971 // TODO(beng): stopsevents | 965 // TODO(beng): stopsevents |
972 | 966 |
973 aura::Window* lock_modal_container = CreateContainer( | 967 aura::Window* lock_modal_container = CreateContainer( |
974 kShellWindowId_LockSystemModalContainer, | 968 kShellWindowId_LockSystemModalContainer, |
975 "LockSystemModalContainer", | 969 "LockSystemModalContainer", |
976 lock_screen_containers); | 970 lock_screen_containers); |
977 wm::SetSnapsChildrenToPhysicalPixelBoundary(lock_modal_container); | 971 wm::SetSnapsChildrenToPhysicalPixelBoundary(lock_modal_container); |
978 lock_modal_container->SetLayoutManager( | 972 lock_modal_container->SetLayoutManager( |
979 new SystemModalContainerLayoutManager(lock_modal_container)); | 973 new SystemModalContainerLayoutManager(lock_modal_container)); |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1063 else | 1057 else |
1064 DisableTouchHudProjection(); | 1058 DisableTouchHudProjection(); |
1065 } | 1059 } |
1066 | 1060 |
1067 RootWindowController* GetRootWindowController( | 1061 RootWindowController* GetRootWindowController( |
1068 const aura::Window* root_window) { | 1062 const aura::Window* root_window) { |
1069 return root_window ? GetRootWindowSettings(root_window)->controller : NULL; | 1063 return root_window ? GetRootWindowSettings(root_window)->controller : NULL; |
1070 } | 1064 } |
1071 | 1065 |
1072 } // namespace ash | 1066 } // namespace ash |
OLD | NEW |