Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1099)

Side by Side Diff: ash/common/wm/overview/window_selector_item.h

Issue 2197773002: [ash-md] Properly scales windows with transient parents in overview (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: [ash-md] Disables rounded corners by default in overview mode (nits) Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ash/common/wm/overview/window_grid.cc ('k') | ash/common/wm/overview/window_selector_item.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_WINDOW_SELECTOR_ITEM_H_ 5 #ifndef ASH_COMMON_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_
6 #define ASH_COMMON_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ 6 #define ASH_COMMON_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "ash/ash_export.h" 10 #include "ash/ash_export.h"
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 77
78 // Dispatched before beginning window overview. This will do any necessary 78 // Dispatched before beginning window overview. This will do any necessary
79 // one time actions such as restoring minimized windows. 79 // one time actions such as restoring minimized windows.
80 void PrepareForOverview(); 80 void PrepareForOverview();
81 81
82 // Calculates and returns an optimal scale ratio. With MD this is only 82 // Calculates and returns an optimal scale ratio. With MD this is only
83 // taking into account |size.height()| as the width can vary. Without MD this 83 // taking into account |size.height()| as the width can vary. Without MD this
84 // returns the scale that allows the item to fully fit within |size|. 84 // returns the scale that allows the item to fully fit within |size|.
85 float GetItemScale(const gfx::Size& size); 85 float GetItemScale(const gfx::Size& size);
86 86
87 // Returns the union of the original target bounds of all transformed windows
88 // managed by |this| item, i.e. all regular (normal or panel transient
89 // descendants of the window returned by GetWindow()).
90 gfx::Rect GetTargetBoundsInScreen() const;
91
87 // Sets the bounds of this window selector item to |target_bounds| in the 92 // Sets the bounds of this window selector item to |target_bounds| in the
88 // |root_window_| root window. The bounds change will be animated as specified 93 // |root_window_| root window. The bounds change will be animated as specified
89 // by |animation_type|. 94 // by |animation_type|.
90 void SetBounds(const gfx::Rect& target_bounds, 95 void SetBounds(const gfx::Rect& target_bounds,
91 OverviewAnimationType animation_type); 96 OverviewAnimationType animation_type);
92 97
93 // Activates or deactivates selection depending on |selected|. 98 // Activates or deactivates selection depending on |selected|.
94 // Currently does nothing unless Material Design is enabled. With Material 99 // Currently does nothing unless Material Design is enabled. With Material
95 // Design the item's caption is shown transparent in selected state and blends 100 // Design the item's caption is shown transparent in selected state and blends
96 // with the selection widget. 101 // with the selection widget.
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
216 // shape. This has performance implications so it can be disabled when there 221 // shape. This has performance implications so it can be disabled when there
217 // are many windows. 222 // are many windows.
218 static bool use_shape_; 223 static bool use_shape_;
219 224
220 DISALLOW_COPY_AND_ASSIGN(WindowSelectorItem); 225 DISALLOW_COPY_AND_ASSIGN(WindowSelectorItem);
221 }; 226 };
222 227
223 } // namespace ash 228 } // namespace ash
224 229
225 #endif // ASH_COMMON_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ 230 #endif // ASH_COMMON_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_
OLDNEW
« no previous file with comments | « ash/common/wm/overview/window_grid.cc ('k') | ash/common/wm/overview/window_selector_item.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698