OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/overview/window_selector_window.h" | 5 #include "ash/wm/overview/window_selector_window.h" |
6 | 6 |
7 #include "ash/screen_util.h" | 7 #include "ash/screen_util.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/overview/scoped_transform_overview_window.h" | 10 #include "ash/wm/overview/scoped_transform_overview_window.h" |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 const gfx::Rect& target_bounds, | 68 const gfx::Rect& target_bounds, |
69 bool animate) { | 69 bool animate) { |
70 gfx::Rect src_rect = transform_window_.GetBoundsInScreen(); | 70 gfx::Rect src_rect = transform_window_.GetBoundsInScreen(); |
71 set_bounds(ScopedTransformOverviewWindow:: | 71 set_bounds(ScopedTransformOverviewWindow:: |
72 ShrinkRectToFitPreservingAspectRatio(src_rect, target_bounds)); | 72 ShrinkRectToFitPreservingAspectRatio(src_rect, target_bounds)); |
73 transform_window_.SetTransform(root_window, | 73 transform_window_.SetTransform(root_window, |
74 ScopedTransformOverviewWindow::GetTransformForRect(src_rect, bounds()), | 74 ScopedTransformOverviewWindow::GetTransformForRect(src_rect, bounds()), |
75 animate); | 75 animate); |
76 } | 76 } |
77 | 77 |
| 78 void WindowSelectorWindow::SetOpacity(float opacity) { |
| 79 transform_window_.window()->layer()->SetOpacity(opacity); |
| 80 WindowSelectorItem::SetOpacity(opacity); |
| 81 } |
| 82 |
78 } // namespace ash | 83 } // namespace ash |
OLD | NEW |