OLD | NEW |
---|---|
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 CHROME_BROWSER_UI_PANELS_PANEL_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_UI_PANELS_PANEL_MANAGER_H_ |
6 #define CHROME_BROWSER_UI_PANELS_PANEL_MANAGER_H_ | 6 #define CHROME_BROWSER_UI_PANELS_PANEL_MANAGER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
77 bool ComputeBoundsForNextPanel(gfx::Rect* bounds, bool allow_size_change); | 77 bool ComputeBoundsForNextPanel(gfx::Rect* bounds, bool allow_size_change); |
78 | 78 |
79 // Finds one panel to close so that we may have space for the new panel | 79 // Finds one panel to close so that we may have space for the new panel |
80 // created by |extension|. | 80 // created by |extension|. |
81 void FindAndClosePanelOnOverflow(const Extension* extension); | 81 void FindAndClosePanelOnOverflow(const Extension* extension); |
82 | 82 |
83 // Help functions to drag the given panel. | 83 // Help functions to drag the given panel. |
84 void DragLeft(); | 84 void DragLeft(); |
85 void DragRight(); | 85 void DragRight(); |
86 | 86 |
87 static int horizontal_spacing(); | |
jennb
2011/08/23 17:14:16
Need comment explaining what this is.
jianli
2011/08/23 17:27:12
Since this is only needed by the test, you should
prasadt
2011/08/23 18:05:10
Done.
prasadt
2011/08/23 18:05:10
This is private.
Can't use UNIT_TEST because the d
| |
88 | |
87 Panels panels_; | 89 Panels panels_; |
88 | 90 |
89 // Stores the panels that are pending to remove. We want to delay the removal | 91 // Stores the panels that are pending to remove. We want to delay the removal |
90 // when we're in the process of the dragging. | 92 // when we're in the process of the dragging. |
91 Panels panels_pending_to_remove_; | 93 Panels panels_pending_to_remove_; |
92 | 94 |
93 // Current work area used in computing the panel bounds. | 95 // Current work area used in computing the panel bounds. |
94 gfx::Rect work_area_; | 96 gfx::Rect work_area_; |
95 | 97 |
96 // Used in computing the bounds of the next panel. | 98 // Used in computing the bounds of the next panel. |
(...skipping 12 matching lines...) Expand all Loading... | |
109 | 111 |
110 // Bounds of the panel to drag. It is first set to the original bounds when | 112 // Bounds of the panel to drag. It is first set to the original bounds when |
111 // the dragging happens. Then it is updated to the position that will be set | 113 // the dragging happens. Then it is updated to the position that will be set |
112 // to when the dragging ends. | 114 // to when the dragging ends. |
113 gfx::Rect dragging_panel_bounds_; | 115 gfx::Rect dragging_panel_bounds_; |
114 | 116 |
115 DISALLOW_COPY_AND_ASSIGN(PanelManager); | 117 DISALLOW_COPY_AND_ASSIGN(PanelManager); |
116 }; | 118 }; |
117 | 119 |
118 #endif // CHROME_BROWSER_UI_PANELS_PANEL_MANAGER_H_ | 120 #endif // CHROME_BROWSER_UI_PANELS_PANEL_MANAGER_H_ |
OLD | NEW |