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_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ | 5 #ifndef ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ |
6 #define ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ | 6 #define ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ |
7 | 7 |
8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
9 #include "ash/wm/overview/scoped_transform_overview_window.h" | 9 #include "ash/wm/overview/scoped_transform_overview_window.h" |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 // Sets the bounds of this window selector item to |target_bounds| in the | 79 // Sets the bounds of this window selector item to |target_bounds| in the |
80 // |root_window_| root window. The bounds change will be animated as specified | 80 // |root_window_| root window. The bounds change will be animated as specified |
81 // by |animation_type|. | 81 // by |animation_type|. |
82 void SetBounds(const gfx::Rect& target_bounds, | 82 void SetBounds(const gfx::Rect& target_bounds, |
83 OverviewAnimationType animation_type); | 83 OverviewAnimationType animation_type); |
84 | 84 |
85 // Recomputes the positions for the windows in this selection item. This is | 85 // Recomputes the positions for the windows in this selection item. This is |
86 // dispatched when the bounds of a window change. | 86 // dispatched when the bounds of a window change. |
87 void RecomputeWindowTransforms(); | 87 void RecomputeWindowTransforms(); |
88 | 88 |
89 // Sends an a11y focus alert so that, if chromevox is enabled, the window | 89 // Sends an accessibility event indicating that this window became selected |
90 // label is read. | 90 // so that it's highlighted and announced if accessibility features are |
91 void SendFocusAlert() const; | 91 // enabled. |
| 92 void SendAccessibleSelectionEvent(); |
92 | 93 |
93 // Sets if the item is dimmed in the overview. Changing the value will also | 94 // Sets if the item is dimmed in the overview. Changing the value will also |
94 // change the visibility of the transform windows. | 95 // change the visibility of the transform windows. |
95 void SetDimmed(bool dimmed); | 96 void SetDimmed(bool dimmed); |
96 bool dimmed() const { return dimmed_; } | 97 bool dimmed() const { return dimmed_; } |
97 | 98 |
98 const gfx::Rect& target_bounds() const { return target_bounds_; } | 99 const gfx::Rect& target_bounds() const { return target_bounds_; } |
99 | 100 |
100 // views::ButtonListener: | 101 // views::ButtonListener: |
101 void ButtonPressed(views::Button* sender, const ui::Event& event) override; | 102 void ButtonPressed(views::Button* sender, const ui::Event& event) override; |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
164 // Pointer to the WindowSelector that owns the WindowGrid containing |this|. | 165 // Pointer to the WindowSelector that owns the WindowGrid containing |this|. |
165 // Guaranteed to be non-null for the lifetime of |this|. | 166 // Guaranteed to be non-null for the lifetime of |this|. |
166 WindowSelector* window_selector_; | 167 WindowSelector* window_selector_; |
167 | 168 |
168 DISALLOW_COPY_AND_ASSIGN(WindowSelectorItem); | 169 DISALLOW_COPY_AND_ASSIGN(WindowSelectorItem); |
169 }; | 170 }; |
170 | 171 |
171 } // namespace ash | 172 } // namespace ash |
172 | 173 |
173 #endif // ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ | 174 #endif // ASH_WM_OVERVIEW_WINDOW_SELECTOR_ITEM_H_ |
OLD | NEW |