OLD | NEW |
1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2009 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_BROWSER_H_ | 5 #ifndef CHROME_BROWSER_BROWSER_H_ |
6 #define CHROME_BROWSER_BROWSER_H_ | 6 #define CHROME_BROWSER_BROWSER_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 static Browser* CreateForApp(const std::wstring& app_name, Profile* profile, | 95 static Browser* CreateForApp(const std::wstring& app_name, Profile* profile, |
96 bool is_popup); | 96 bool is_popup); |
97 | 97 |
98 // Set overrides for the initial window bounds and maximized state. | 98 // Set overrides for the initial window bounds and maximized state. |
99 void set_override_bounds(const gfx::Rect& bounds) { | 99 void set_override_bounds(const gfx::Rect& bounds) { |
100 override_bounds_ = bounds; | 100 override_bounds_ = bounds; |
101 } | 101 } |
102 void set_maximized_state(MaximizedState state) { | 102 void set_maximized_state(MaximizedState state) { |
103 maximized_state_ = state; | 103 maximized_state_ = state; |
104 } | 104 } |
| 105 // Return true if the initial window bounds have been overridden. |
| 106 bool bounds_overridden() const { |
| 107 return !override_bounds_.IsEmpty(); |
| 108 } |
105 | 109 |
106 // Creates the Browser Window. Prefer to use the static helpers above where | 110 // Creates the Browser Window. Prefer to use the static helpers above where |
107 // possible. This does not show the window. You need to call window()->Show() | 111 // possible. This does not show the window. You need to call window()->Show() |
108 // to show it. | 112 // to show it. |
109 void CreateBrowserWindow(); | 113 void CreateBrowserWindow(); |
110 | 114 |
111 // Accessors //////////////////////////////////////////////////////////////// | 115 // Accessors //////////////////////////////////////////////////////////////// |
112 | 116 |
113 Type type() const { return type_; } | 117 Type type() const { return type_; } |
114 Profile* profile() const { return profile_; } | 118 Profile* profile() const { return profile_; } |
(...skipping 646 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
761 // The browser idle task helps cleanup unused memory resources when idle. | 765 // The browser idle task helps cleanup unused memory resources when idle. |
762 scoped_ptr<BrowserIdleTimer> idle_task_; | 766 scoped_ptr<BrowserIdleTimer> idle_task_; |
763 | 767 |
764 // Keep track of the encoding auto detect pref. | 768 // Keep track of the encoding auto detect pref. |
765 BooleanPrefMember encoding_auto_detect_; | 769 BooleanPrefMember encoding_auto_detect_; |
766 | 770 |
767 DISALLOW_COPY_AND_ASSIGN(Browser); | 771 DISALLOW_COPY_AND_ASSIGN(Browser); |
768 }; | 772 }; |
769 | 773 |
770 #endif // CHROME_BROWSER_BROWSER_H_ | 774 #endif // CHROME_BROWSER_BROWSER_H_ |
OLD | NEW |