| 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 #ifndef ASH_COMMON_WM_OVERVIEW_SCOPED_TRANSFORM_OVERVIEW_WINDOW_H_ | 5 #ifndef ASH_COMMON_WM_OVERVIEW_SCOPED_TRANSFORM_OVERVIEW_WINDOW_H_ |
| 6 #define ASH_COMMON_WM_OVERVIEW_SCOPED_TRANSFORM_OVERVIEW_WINDOW_H_ | 6 #define ASH_COMMON_WM_OVERVIEW_SCOPED_TRANSFORM_OVERVIEW_WINDOW_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 | 98 |
| 99 // Informs the ScopedTransformOverviewWindow that the window being watched was | 99 // Informs the ScopedTransformOverviewWindow that the window being watched was |
| 100 // destroyed. This resets the internal window pointer. | 100 // destroyed. This resets the internal window pointer. |
| 101 void OnWindowDestroyed(); | 101 void OnWindowDestroyed(); |
| 102 | 102 |
| 103 // Prepares for overview mode by doing any necessary actions before entering. | 103 // Prepares for overview mode by doing any necessary actions before entering. |
| 104 void PrepareForOverview(); | 104 void PrepareForOverview(); |
| 105 | 105 |
| 106 // Applies the |transform| to the overview window and all of its transient | 106 // Applies the |transform| to the overview window and all of its transient |
| 107 // children. With Material Design creates a mask layer with the bottom edge | 107 // children. With Material Design creates a mask layer with the bottom edge |
| 108 // using rounded corners of |radius|. | 108 // using rounded corners of |radius|. When |use_mask| is set, hides the |
| 109 // original window header and uses rounded rectangle mask which may be |
| 110 // resource-intensive. When |use_shape| is set and |use_mask| is not, uses |
| 111 // SetAlphaShape to mask the header. |
| 109 void SetTransform(WmWindow* root_window, | 112 void SetTransform(WmWindow* root_window, |
| 110 const gfx::Transform& transform, | 113 const gfx::Transform& transform, |
| 114 bool use_mask, |
| 115 bool use_shape, |
| 111 float radius); | 116 float radius); |
| 112 | 117 |
| 113 // Set's the opacity of the managed windows. | 118 // Set's the opacity of the managed windows. |
| 114 void SetOpacity(float opacity); | 119 void SetOpacity(float opacity); |
| 115 | 120 |
| 116 WmWindow* window() const { return window_; } | 121 WmWindow* window() const { return window_; } |
| 117 | 122 |
| 118 // Closes the transient root of the window managed by |this|. | 123 // Closes the transient root of the window managed by |this|. |
| 119 void Close(); | 124 void Close(); |
| 120 | 125 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 165 float original_opacity_; | 170 float original_opacity_; |
| 166 | 171 |
| 167 base::WeakPtrFactory<ScopedTransformOverviewWindow> weak_ptr_factory_; | 172 base::WeakPtrFactory<ScopedTransformOverviewWindow> weak_ptr_factory_; |
| 168 | 173 |
| 169 DISALLOW_COPY_AND_ASSIGN(ScopedTransformOverviewWindow); | 174 DISALLOW_COPY_AND_ASSIGN(ScopedTransformOverviewWindow); |
| 170 }; | 175 }; |
| 171 | 176 |
| 172 } // namespace ash | 177 } // namespace ash |
| 173 | 178 |
| 174 #endif // ASH_COMMON_WM_OVERVIEW_SCOPED_TRANSFORM_OVERVIEW_WINDOW_H_ | 179 #endif // ASH_COMMON_WM_OVERVIEW_SCOPED_TRANSFORM_OVERVIEW_WINDOW_H_ |
| OLD | NEW |