| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/common/wm/overview/window_grid.h" | 5 #include "ash/common/wm/overview/window_grid.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <functional> | 8 #include <functional> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 765 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 776 void WindowGrid::OnWindowBoundsChanged(WmWindow* window, | 776 void WindowGrid::OnWindowBoundsChanged(WmWindow* window, |
| 777 const gfx::Rect& old_bounds, | 777 const gfx::Rect& old_bounds, |
| 778 const gfx::Rect& new_bounds) { | 778 const gfx::Rect& new_bounds) { |
| 779 auto iter = std::find_if(window_list_.begin(), window_list_.end(), | 779 auto iter = std::find_if(window_list_.begin(), window_list_.end(), |
| 780 WindowSelectorItemComparator(window)); | 780 WindowSelectorItemComparator(window)); |
| 781 DCHECK(iter != window_list_.end()); | 781 DCHECK(iter != window_list_.end()); |
| 782 | 782 |
| 783 // Immediately finish any active bounds animation. | 783 // Immediately finish any active bounds animation. |
| 784 window->StopAnimatingProperty(ui::LayerAnimationElement::BOUNDS); | 784 window->StopAnimatingProperty(ui::LayerAnimationElement::BOUNDS); |
| 785 | 785 |
| 786 if (ash::MaterialDesignController::IsOverviewMaterial()) { |
| 787 PositionWindows(false); |
| 788 return; |
| 789 } |
| 786 // Recompute the transform for the window. | 790 // Recompute the transform for the window. |
| 787 (*iter)->RecomputeWindowTransforms(); | 791 (*iter)->RecomputeWindowTransforms(); |
| 788 } | 792 } |
| 789 | 793 |
| 790 void WindowGrid::InitShieldWidget() { | 794 void WindowGrid::InitShieldWidget() { |
| 791 shield_widget_.reset(CreateBackgroundWidget(root_window_, kShieldColor, 0, 0, | 795 shield_widget_.reset(CreateBackgroundWidget(root_window_, kShieldColor, 0, 0, |
| 792 SK_ColorTRANSPARENT)); | 796 SK_ColorTRANSPARENT)); |
| 793 | 797 |
| 794 WmWindow* widget_window = | 798 WmWindow* widget_window = |
| 795 WmLookup::Get()->GetWindowForWidget(shield_widget_.get()); | 799 WmLookup::Get()->GetWindowForWidget(shield_widget_.get()); |
| (...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 957 *min_right = left; | 961 *min_right = left; |
| 958 if (*max_right < left) | 962 if (*max_right < left) |
| 959 *max_right = left; | 963 *max_right = left; |
| 960 } | 964 } |
| 961 *max_bottom = top + height; | 965 *max_bottom = top + height; |
| 962 } | 966 } |
| 963 return windows_fit; | 967 return windows_fit; |
| 964 } | 968 } |
| 965 | 969 |
| 966 } // namespace ash | 970 } // namespace ash |
| OLD | NEW |