OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_BROWSER_H_ | 5 #ifndef CHROME_BROWSER_UI_BROWSER_H_ |
6 #define CHROME_BROWSER_UI_BROWSER_H_ | 6 #define CHROME_BROWSER_UI_BROWSER_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 // Possible elements of the Browser window. | 131 // Possible elements of the Browser window. |
132 enum WindowFeature { | 132 enum WindowFeature { |
133 FEATURE_NONE = 0, | 133 FEATURE_NONE = 0, |
134 FEATURE_TITLEBAR = 1, | 134 FEATURE_TITLEBAR = 1, |
135 FEATURE_TABSTRIP = 2, | 135 FEATURE_TABSTRIP = 2, |
136 FEATURE_TOOLBAR = 4, | 136 FEATURE_TOOLBAR = 4, |
137 FEATURE_LOCATIONBAR = 8, | 137 FEATURE_LOCATIONBAR = 8, |
138 FEATURE_BOOKMARKBAR = 16, | 138 FEATURE_BOOKMARKBAR = 16, |
139 FEATURE_INFOBAR = 32, | 139 FEATURE_INFOBAR = 32, |
140 FEATURE_DOWNLOADSHELF = 64, | 140 FEATURE_DOWNLOADSHELF = 64, |
141 FEATURE_WEBAPPFRAME = 128 | |
142 }; | 141 }; |
143 | 142 |
144 // The context for a download blocked notification from | 143 // The context for a download blocked notification from |
145 // OkToCloseWithInProgressDownloads. | 144 // OkToCloseWithInProgressDownloads. |
146 enum DownloadClosePreventionType { | 145 enum DownloadClosePreventionType { |
147 // Browser close is not blocked by download state. | 146 // Browser close is not blocked by download state. |
148 DOWNLOAD_CLOSE_OK, | 147 DOWNLOAD_CLOSE_OK, |
149 | 148 |
150 // The browser is shutting down and there are active downloads | 149 // The browser is shutting down and there are active downloads |
151 // that would be cancelled. | 150 // that would be cancelled. |
(...skipping 673 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
825 // Shared code between Reload() and ReloadBypassingCache(). | 824 // Shared code between Reload() and ReloadBypassingCache(). |
826 void ReloadInternal(WindowOpenDisposition disposition, bool bypass_cache); | 825 void ReloadInternal(WindowOpenDisposition disposition, bool bypass_cache); |
827 | 826 |
828 // Returns true if the Browser window supports a location bar. Having support | 827 // Returns true if the Browser window supports a location bar. Having support |
829 // for the location bar does not mean it will be visible. | 828 // for the location bar does not mean it will be visible. |
830 bool SupportsLocationBar() const; | 829 bool SupportsLocationBar() const; |
831 | 830 |
832 // Returns true if the Browser window should show the location bar. | 831 // Returns true if the Browser window should show the location bar. |
833 bool ShouldShowLocationBar() const; | 832 bool ShouldShowLocationBar() const; |
834 | 833 |
835 // Returns true if the Browser window should use a web app style frame. | |
836 bool ShouldUseWebAppFrame() const; | |
837 | |
838 // Implementation of SupportsWindowFeature and CanSupportWindowFeature. If | 834 // Implementation of SupportsWindowFeature and CanSupportWindowFeature. If |
839 // |check_fullscreen| is true, the set of features reflect the actual state of | 835 // |check_fullscreen| is true, the set of features reflect the actual state of |
840 // the browser, otherwise the set of features reflect the possible state of | 836 // the browser, otherwise the set of features reflect the possible state of |
841 // the browser. | 837 // the browser. |
842 bool SupportsWindowFeatureImpl(WindowFeature feature, | 838 bool SupportsWindowFeatureImpl(WindowFeature feature, |
843 bool check_fullscreen) const; | 839 bool check_fullscreen) const; |
844 | 840 |
845 // Resets |bookmark_bar_state_| based on the active tab. Notifies the | 841 // Resets |bookmark_bar_state_| based on the active tab. Notifies the |
846 // BrowserWindow if necessary. | 842 // BrowserWindow if necessary. |
847 void UpdateBookmarkBarState(BookmarkBarStateChangeReason reason); | 843 void UpdateBookmarkBarState(BookmarkBarStateChangeReason reason); |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1010 // The following factory is used for chrome update coalescing. | 1006 // The following factory is used for chrome update coalescing. |
1011 base::WeakPtrFactory<Browser> chrome_updater_factory_; | 1007 base::WeakPtrFactory<Browser> chrome_updater_factory_; |
1012 | 1008 |
1013 // The following factory is used to close the frame at a later time. | 1009 // The following factory is used to close the frame at a later time. |
1014 base::WeakPtrFactory<Browser> weak_factory_; | 1010 base::WeakPtrFactory<Browser> weak_factory_; |
1015 | 1011 |
1016 DISALLOW_COPY_AND_ASSIGN(Browser); | 1012 DISALLOW_COPY_AND_ASSIGN(Browser); |
1017 }; | 1013 }; |
1018 | 1014 |
1019 #endif // CHROME_BROWSER_UI_BROWSER_H_ | 1015 #endif // CHROME_BROWSER_UI_BROWSER_H_ |
OLD | NEW |