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 #ifndef ASH_WM_OVERVIEW_WINDOW_GRID_H_ | 5 #ifndef ASH_WM_OVERVIEW_WINDOW_GRID_H_ |
6 #define ASH_WM_OVERVIEW_WINDOW_GRID_H_ | 6 #define ASH_WM_OVERVIEW_WINDOW_GRID_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ash/wm/overview/window_selector.h" | 10 #include "ash/wm/overview/window_selector.h" |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 // 0, 3, 6, 1, 4, 2, 5 | 44 // 0, 3, 6, 1, 4, 2, 5 |
45 // The selector is switched to the next window grid (if available) or wrapped if | 45 // The selector is switched to the next window grid (if available) or wrapped if |
46 // it reaches the end of its movement sequence. | 46 // it reaches the end of its movement sequence. |
47 class ASH_EXPORT WindowGrid : public aura::WindowObserver { | 47 class ASH_EXPORT WindowGrid : public aura::WindowObserver { |
48 public: | 48 public: |
49 WindowGrid(aura::Window* root_window, | 49 WindowGrid(aura::Window* root_window, |
50 const std::vector<aura::Window*>& window_list, | 50 const std::vector<aura::Window*>& window_list, |
51 WindowSelector* window_selector); | 51 WindowSelector* window_selector); |
52 virtual ~WindowGrid(); | 52 virtual ~WindowGrid(); |
53 | 53 |
| 54 // Prepares the windows in this grid for overview. This will restore all |
| 55 // minimized windows and ensure they are visible. |
| 56 void PrepareForOverview(); |
| 57 |
54 // Positions all the windows in the grid. | 58 // Positions all the windows in the grid. |
55 void PositionWindows(bool animate); | 59 void PositionWindows(bool animate); |
56 | 60 |
57 // Updates |selected_index_| according to the specified |direction| and calls | 61 // Updates |selected_index_| according to the specified |direction| and calls |
58 // MoveSelectionWidget(). Returns |true| if the new selection index is out of | 62 // MoveSelectionWidget(). Returns |true| if the new selection index is out of |
59 // this window grid bounds. | 63 // this window grid bounds. |
60 bool Move(WindowSelector::Direction direction); | 64 bool Move(WindowSelector::Direction direction); |
61 | 65 |
62 // Returns the target selected window, or NULL if there is none selected. | 66 // Returns the target selected window, or NULL if there is none selected. |
63 WindowSelectorItem* SelectedWindow() const; | 67 WindowSelectorItem* SelectedWindow() const; |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
126 | 130 |
127 // Number of columns in the grid. | 131 // Number of columns in the grid. |
128 size_t num_columns_; | 132 size_t num_columns_; |
129 | 133 |
130 DISALLOW_COPY_AND_ASSIGN(WindowGrid); | 134 DISALLOW_COPY_AND_ASSIGN(WindowGrid); |
131 }; | 135 }; |
132 | 136 |
133 } // namespace ash | 137 } // namespace ash |
134 | 138 |
135 #endif // ASH_WM_OVERVIEW_WINDOW_GRID_H_ | 139 #endif // ASH_WM_OVERVIEW_WINDOW_GRID_H_ |
OLD | NEW |