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 | 8 |
9 #include "ash/accelerators/accelerator_controller.h" | 9 #include "ash/accelerators/accelerator_controller.h" |
10 #include "ash/accelerators/accelerator_filter.h" | 10 #include "ash/accelerators/accelerator_filter.h" |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
109 modal_container->set_id(internal::kShellWindowId_SystemModalContainer); | 109 modal_container->set_id(internal::kShellWindowId_SystemModalContainer); |
110 SetChildWindowVisibilityChangesAnimated(modal_container); | 110 SetChildWindowVisibilityChangesAnimated(modal_container); |
111 containers->push_back(modal_container); | 111 containers->push_back(modal_container); |
112 | 112 |
113 // TODO(beng): Figure out if we can make this use | 113 // TODO(beng): Figure out if we can make this use |
114 // SystemModalContainerEventFilter instead of stops_event_propagation. | 114 // SystemModalContainerEventFilter instead of stops_event_propagation. |
115 aura::Window* lock_container = new aura::Window(NULL); | 115 aura::Window* lock_container = new aura::Window(NULL); |
116 lock_container->SetLayoutManager(new internal::BaseLayoutManager); | 116 lock_container->SetLayoutManager(new internal::BaseLayoutManager); |
117 lock_container->set_stops_event_propagation(true); | 117 lock_container->set_stops_event_propagation(true); |
118 lock_container->set_id(internal::kShellWindowId_LockScreenContainer); | 118 lock_container->set_id(internal::kShellWindowId_LockScreenContainer); |
| 119 SetChildWindowVisibilityChangesAnimated(lock_container); |
119 containers->push_back(lock_container); | 120 containers->push_back(lock_container); |
120 | 121 |
121 aura::Window* lock_modal_container = new aura::Window(NULL); | 122 aura::Window* lock_modal_container = new aura::Window(NULL); |
122 lock_modal_container->SetEventFilter( | 123 lock_modal_container->SetEventFilter( |
123 new ToplevelWindowEventFilter(lock_modal_container)); | 124 new ToplevelWindowEventFilter(lock_modal_container)); |
124 lock_modal_container->SetLayoutManager( | 125 lock_modal_container->SetLayoutManager( |
125 new internal::SystemModalContainerLayoutManager(lock_modal_container)); | 126 new internal::SystemModalContainerLayoutManager(lock_modal_container)); |
126 lock_modal_container->set_id( | 127 lock_modal_container->set_id( |
127 internal::kShellWindowId_LockSystemModalContainer); | 128 internal::kShellWindowId_LockSystemModalContainer); |
128 SetChildWindowVisibilityChangesAnimated(lock_modal_container); | 129 SetChildWindowVisibilityChangesAnimated(lock_modal_container); |
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
508 | 509 |
509 // Create the desktop background image. | 510 // Create the desktop background image. |
510 root_window_layout_->SetBackgroundWidget(internal::CreateDesktopBackground()); | 511 root_window_layout_->SetBackgroundWidget(internal::CreateDesktopBackground()); |
511 } | 512 } |
512 | 513 |
513 void Shell::ResetLayoutManager(int container_id) { | 514 void Shell::ResetLayoutManager(int container_id) { |
514 GetContainer(container_id)->SetLayoutManager(NULL); | 515 GetContainer(container_id)->SetLayoutManager(NULL); |
515 } | 516 } |
516 | 517 |
517 } // namespace ash | 518 } // namespace ash |
OLD | NEW |