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/wm/system_modal_container_layout_manager.h" | 5 #include "ash/wm/system_modal_container_layout_manager.h" |
6 | 6 |
7 #include "ash/ash_switches.h" | 7 #include "ash/ash_switches.h" |
8 #include "ash/shell.h" | 8 #include "ash/shell.h" |
9 #include "ash/shell_window_ids.h" | 9 #include "ash/shell_window_ids.h" |
10 #include "ash/wm/system_modal_container_event_filter.h" | 10 #include "ash/wm/system_modal_container_event_filter.h" |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 } // namespace | 53 } // namespace |
54 | 54 |
55 //////////////////////////////////////////////////////////////////////////////// | 55 //////////////////////////////////////////////////////////////////////////////// |
56 // SystemModalContainerLayoutManager, public: | 56 // SystemModalContainerLayoutManager, public: |
57 | 57 |
58 SystemModalContainerLayoutManager::SystemModalContainerLayoutManager( | 58 SystemModalContainerLayoutManager::SystemModalContainerLayoutManager( |
59 aura::Window* container) | 59 aura::Window* container) |
60 : container_(container), | 60 : container_(container), |
61 modal_screen_(NULL), | 61 modal_screen_(NULL), |
62 ALLOW_THIS_IN_INITIALIZER_LIST(modality_filter_( | 62 ALLOW_THIS_IN_INITIALIZER_LIST(modality_filter_( |
63 new SystemModalContainerEventFilter(container, this))) { | 63 new SystemModalContainerEventFilter(this))) { |
64 } | 64 } |
65 | 65 |
66 SystemModalContainerLayoutManager::~SystemModalContainerLayoutManager() { | 66 SystemModalContainerLayoutManager::~SystemModalContainerLayoutManager() { |
67 } | 67 } |
68 | 68 |
69 //////////////////////////////////////////////////////////////////////////////// | 69 //////////////////////////////////////////////////////////////////////////////// |
70 // SystemModalContainerLayoutManager, aura::LayoutManager implementation: | 70 // SystemModalContainerLayoutManager, aura::LayoutManager implementation: |
71 | 71 |
72 void SystemModalContainerLayoutManager::OnWindowResized() { | 72 void SystemModalContainerLayoutManager::OnWindowResized() { |
73 if (modal_screen_) { | 73 if (modal_screen_) { |
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
205 | 205 |
206 void SystemModalContainerLayoutManager::HideModalScreen() { | 206 void SystemModalContainerLayoutManager::HideModalScreen() { |
207 Shell::GetInstance()->RemoveRootWindowEventFilter(modality_filter_.get()); | 207 Shell::GetInstance()->RemoveRootWindowEventFilter(modality_filter_.get()); |
208 ui::ScopedLayerAnimationSettings settings( | 208 ui::ScopedLayerAnimationSettings settings( |
209 modal_screen_->GetNativeView()->layer()->GetAnimator()); | 209 modal_screen_->GetNativeView()->layer()->GetAnimator()); |
210 modal_screen_->GetNativeView()->layer()->SetOpacity(0.0f); | 210 modal_screen_->GetNativeView()->layer()->SetOpacity(0.0f); |
211 } | 211 } |
212 | 212 |
213 } // namespace internal | 213 } // namespace internal |
214 } // namespace ash | 214 } // namespace ash |
OLD | NEW |