| 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/stacking_controller.h" | 5 #include "ash/wm/stacking_controller.h" |
| 6 | 6 |
| 7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
| 8 #include "ash/shell_window_ids.h" | 8 #include "ash/shell_window_ids.h" |
| 9 #include "ash/wm/always_on_top_controller.h" | 9 #include "ash/wm/always_on_top_controller.h" |
| 10 #include "ui/aura/client/aura_constants.h" | 10 #include "ui/aura/client/aura_constants.h" |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 GetContainer(internal::kShellWindowId_AlwaysOnTopContainer)); | 38 GetContainer(internal::kShellWindowId_AlwaysOnTopContainer)); |
| 39 } | 39 } |
| 40 | 40 |
| 41 StackingController::~StackingController() { | 41 StackingController::~StackingController() { |
| 42 } | 42 } |
| 43 | 43 |
| 44 //////////////////////////////////////////////////////////////////////////////// | 44 //////////////////////////////////////////////////////////////////////////////// |
| 45 // StackingController, aura::StackingClient implementation: | 45 // StackingController, aura::StackingClient implementation: |
| 46 | 46 |
| 47 aura::Window* StackingController::GetDefaultParent(aura::Window* window) { | 47 aura::Window* StackingController::GetDefaultParent(aura::Window* window) { |
| 48 if (window->stops_event_propagation()) |
| 49 return GetContainer(internal::kShellWindowId_LockScreenContainer); |
| 48 switch (window->type()) { | 50 switch (window->type()) { |
| 49 case aura::client::WINDOW_TYPE_NORMAL: | 51 case aura::client::WINDOW_TYPE_NORMAL: |
| 50 case aura::client::WINDOW_TYPE_POPUP: | 52 case aura::client::WINDOW_TYPE_POPUP: |
| 51 if (IsSystemModal(window)) | 53 if (IsSystemModal(window)) |
| 52 return GetModalContainer(window); | 54 return GetModalContainer(window); |
| 53 return always_on_top_controller_->GetContainer(window); | 55 return always_on_top_controller_->GetContainer(window); |
| 54 case aura::client::WINDOW_TYPE_PANEL: | 56 case aura::client::WINDOW_TYPE_PANEL: |
| 55 return GetContainer(internal::kShellWindowId_PanelContainer); | 57 return GetContainer(internal::kShellWindowId_PanelContainer); |
| 56 case aura::client::WINDOW_TYPE_MENU: | 58 case aura::client::WINDOW_TYPE_MENU: |
| 57 case aura::client::WINDOW_TYPE_TOOLTIP: | 59 case aura::client::WINDOW_TYPE_TOOLTIP: |
| (...skipping 30 matching lines...) Expand all Loading... |
| 88 if (window_container_id < lock_container_id) | 90 if (window_container_id < lock_container_id) |
| 89 container = GetContainer(internal::kShellWindowId_ModalContainer); | 91 container = GetContainer(internal::kShellWindowId_ModalContainer); |
| 90 else | 92 else |
| 91 container = GetContainer(internal::kShellWindowId_LockModalContainer); | 93 container = GetContainer(internal::kShellWindowId_LockModalContainer); |
| 92 | 94 |
| 93 return container; | 95 return container; |
| 94 } | 96 } |
| 95 | 97 |
| 96 } // namespace internal | 98 } // namespace internal |
| 97 } // namespace ash | 99 } // namespace ash |
| OLD | NEW |