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/workspace/workspace_layout_manager.h" | 5 #include "ash/wm/workspace/workspace_layout_manager.h" |
6 | 6 |
7 #include "ash/display/display_controller.h" | 7 #include "ash/display/display_controller.h" |
8 #include "ash/root_window_controller.h" | 8 #include "ash/root_window_controller.h" |
9 #include "ash/screen_ash.h" | 9 #include "ash/screen_ash.h" |
10 #include "ash/shelf/shelf_layout_manager.h" | 10 #include "ash/shelf/shelf_layout_manager.h" |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 void WorkspaceLayoutManager::OnWindowPropertyChanged(Window* window, | 150 void WorkspaceLayoutManager::OnWindowPropertyChanged(Window* window, |
151 const void* key, | 151 const void* key, |
152 intptr_t old) { | 152 intptr_t old) { |
153 if (key == aura::client::kAlwaysOnTopKey && | 153 if (key == aura::client::kAlwaysOnTopKey && |
154 window->GetProperty(aura::client::kAlwaysOnTopKey)) { | 154 window->GetProperty(aura::client::kAlwaysOnTopKey)) { |
155 GetRootWindowController(window->GetRootWindow())-> | 155 GetRootWindowController(window->GetRootWindow())-> |
156 always_on_top_controller()->GetContainer(window)->AddChild(window); | 156 always_on_top_controller()->GetContainer(window)->AddChild(window); |
157 } | 157 } |
158 } | 158 } |
159 | 159 |
| 160 void WorkspaceLayoutManager::OnWindowStackingChanged(aura::Window* window) { |
| 161 BaseLayoutManager::OnWindowStackingChanged(window); |
| 162 UpdateDesktopVisibility(); |
| 163 } |
| 164 |
160 void WorkspaceLayoutManager::OnTrackedByWorkspaceChanged( | 165 void WorkspaceLayoutManager::OnTrackedByWorkspaceChanged( |
161 wm::WindowState* window_state, | 166 wm::WindowState* window_state, |
162 bool old){ | 167 bool old){ |
163 if (window_state->tracked_by_workspace()) { | 168 if (window_state->tracked_by_workspace()) { |
164 if (!SetMaximizedOrFullscreenBounds(window_state)) { | 169 if (!SetMaximizedOrFullscreenBounds(window_state)) { |
165 gfx::Rect bounds = window_state->window()->bounds(); | 170 gfx::Rect bounds = window_state->window()->bounds(); |
166 AdjustSnappedBounds(window_state, &bounds); | 171 AdjustSnappedBounds(window_state, &bounds); |
167 if (window_state->window()->bounds() != bounds) | 172 if (window_state->window()->bounds() != bounds) |
168 SetChildBoundsDirect(window_state->window(), bounds); | 173 SetChildBoundsDirect(window_state->window(), bounds); |
169 } | 174 } |
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
433 ui::ScopedLayerAnimationSettings slide_settings(layer->GetAnimator()); | 438 ui::ScopedLayerAnimationSettings slide_settings(layer->GetAnimator()); |
434 slide_settings.SetPreemptionStrategy( | 439 slide_settings.SetPreemptionStrategy( |
435 ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET); | 440 ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET); |
436 slide_settings.SetTransitionDuration( | 441 slide_settings.SetTransitionDuration( |
437 base::TimeDelta::FromMilliseconds(kBoundsChangeSlideDurationMs)); | 442 base::TimeDelta::FromMilliseconds(kBoundsChangeSlideDurationMs)); |
438 SetChildBoundsDirect(child, bounds); | 443 SetChildBoundsDirect(child, bounds); |
439 } | 444 } |
440 | 445 |
441 } // namespace internal | 446 } // namespace internal |
442 } // namespace ash | 447 } // namespace ash |
OLD | NEW |