| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_WINDOW_SIZER_H_ | 5 #ifndef CHROME_BROWSER_UI_WINDOW_SIZER_H_ |
| 6 #define CHROME_BROWSER_UI_WINDOW_SIZER_H_ | 6 #define CHROME_BROWSER_UI_WINDOW_SIZER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 gfx::Rect* bounds, | 114 gfx::Rect* bounds, |
| 115 bool* maximized) const; | 115 bool* maximized) const; |
| 116 | 116 |
| 117 // Determines the size, position and maximized state for the browser window. | 117 // Determines the size, position and maximized state for the browser window. |
| 118 // See documentation for DetermineWindowBounds above. Normally, | 118 // See documentation for DetermineWindowBounds above. Normally, |
| 119 // |window_bounds| is calculated by calling GetLastActiveWindowState(). To | 119 // |window_bounds| is calculated by calling GetLastActiveWindowState(). To |
| 120 // explicitly specify a particular window to base the bounds on, pass in a | 120 // explicitly specify a particular window to base the bounds on, pass in a |
| 121 // non-NULL value for |browser|. | 121 // non-NULL value for |browser|. |
| 122 static void GetBrowserWindowBounds(const std::string& app_name, | 122 static void GetBrowserWindowBounds(const std::string& app_name, |
| 123 const gfx::Rect& specified_bounds, | 123 const gfx::Rect& specified_bounds, |
| 124 const Browser* browser, | 124 Browser* browser, |
| 125 gfx::Rect* window_bounds, | 125 gfx::Rect* window_bounds, |
| 126 bool* maximized); | 126 bool* maximized); |
| 127 | 127 |
| 128 // Returns the default origin for popups of the given size. | 128 // Returns the default origin for popups of the given size. |
| 129 static gfx::Point GetDefaultPopupOrigin(const gfx::Size& size); | 129 static gfx::Point GetDefaultPopupOrigin(const gfx::Size& size); |
| 130 | 130 |
| 131 // How much horizontal and vertical offset there is between newly | 131 // How much horizontal and vertical offset there is between newly |
| 132 // opened windows. This value may be different on each platform. | 132 // opened windows. This value may be different on each platform. |
| 133 static const int kWindowTilePixels; | 133 static const int kWindowTilePixels; |
| 134 | 134 |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 174 const gfx::Rect& saved_work_area, | 174 const gfx::Rect& saved_work_area, |
| 175 gfx::Rect* bounds) const; | 175 gfx::Rect* bounds) const; |
| 176 | 176 |
| 177 // Providers for persistent storage and monitor metrics. | 177 // Providers for persistent storage and monitor metrics. |
| 178 StateProvider* state_provider_; | 178 StateProvider* state_provider_; |
| 179 MonitorInfoProvider* monitor_info_provider_; | 179 MonitorInfoProvider* monitor_info_provider_; |
| 180 | 180 |
| 181 DISALLOW_COPY_AND_ASSIGN(WindowSizer); | 181 DISALLOW_COPY_AND_ASSIGN(WindowSizer); |
| 182 }; | 182 }; |
| 183 | 183 |
| 184 #endif // CHROME_BROWSER_UI_WINDOW_SIZER_H_ | 184 #endif // CHROME_BROWSER_WINDOW_SIZER_H_ |
| 185 | |
| OLD | NEW |