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_COCOA_BROWSER_WINDOW_CONTROLLER_PRIVATE_H_ | 5 #ifndef CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_PRIVATE_H_ |
6 #define CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_PRIVATE_H_ | 6 #define CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_PRIVATE_H_ |
7 | 7 |
8 #import "chrome/browser/ui/cocoa/browser_window_controller.h" | 8 #import "chrome/browser/ui/cocoa/browser_window_controller.h" |
9 | 9 |
10 | 10 |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 // Also adjusts the bookmark bar's height by the opposite amount in order to | 103 // Also adjusts the bookmark bar's height by the opposite amount in order to |
104 // keep the total height of the two views constant. | 104 // keep the total height of the two views constant. |
105 - (void)adjustToolbarAndBookmarkBarForCompression:(CGFloat)compression; | 105 - (void)adjustToolbarAndBookmarkBarForCompression:(CGFloat)compression; |
106 | 106 |
107 // Whether to show the presentation mode toggle button in the UI. Returns YES | 107 // Whether to show the presentation mode toggle button in the UI. Returns YES |
108 // if in fullscreen mode on Lion or later. This method is safe to call on all | 108 // if in fullscreen mode on Lion or later. This method is safe to call on all |
109 // OS versions. | 109 // OS versions. |
110 - (BOOL)shouldShowPresentationModeToggle; | 110 - (BOOL)shouldShowPresentationModeToggle; |
111 | 111 |
112 // Moves views between windows in preparation for fullscreen mode on Snow | 112 // Moves views between windows in preparation for fullscreen mode on Snow |
113 // Leopard or earlier. (Lion and later reuses the original window for | 113 // Leopard. (Lion and later reuses the original window for |
114 // fullscreen mode, so there is no need to move views around.) This method does | 114 // fullscreen mode, so there is no need to move views around.) This method does |
115 // not position views; callers must also call |-layoutSubviews|. This method | 115 // not position views; callers must also call |-layoutSubviews|. This method |
116 // must not be called on Lion or later. | 116 // must not be called on Lion or later. |
117 - (void)moveViewsForFullscreenForSnowLeopardOrEarlier:(BOOL)fullscreen | 117 - (void)moveViewsForFullscreenForSnowLeopard:(BOOL)fullscreen |
118 regularWindow:(NSWindow*)regularWindow | 118 regularWindow:(NSWindow*)regularWindow |
119 fullscreenWindow:(NSWindow*)fullscreenWindow; | 119 fullscreenWindow:(NSWindow*)fullscreenWindow; |
120 | 120 |
121 // Sets presentation mode, creating the PresentationModeController if needed and | 121 // Sets presentation mode, creating the PresentationModeController if needed and |
122 // forcing a relayout. If |forceDropdown| is YES, this method will always | 122 // forcing a relayout. If |forceDropdown| is YES, this method will always |
123 // initially show the floating bar when entering presentation mode, even if the | 123 // initially show the floating bar when entering presentation mode, even if the |
124 // floating bar does not have focus. This method is safe to call on all OS | 124 // floating bar does not have focus. This method is safe to call on all OS |
125 // versions. | 125 // versions. |
126 - (void)setPresentationModeInternal:(BOOL)presentationMode | 126 - (void)setPresentationModeInternal:(BOOL)presentationMode |
127 forceDropdown:(BOOL)forceDropdown; | 127 forceDropdown:(BOOL)forceDropdown; |
128 | 128 |
129 // Called on Snow Leopard or earlier to enter or exit fullscreen. These methods | 129 // Called on Snow Leopard or earlier to enter or exit fullscreen. These methods |
130 // are internal implementations of |-setFullscreen:|. These methods must not be | 130 // are internal implementations of |-setFullscreen:|. These methods must not be |
131 // called on Lion or later. | 131 // called on Lion or later. |
132 - (void)enterFullscreenForSnowLeopardOrEarlier; | 132 - (void)enterFullscreenForSnowLeopard; |
133 - (void)exitFullscreenForSnowLeopardOrEarlier; | 133 - (void)exitFullscreenForSnowLeopard; |
134 | 134 |
135 // Register or deregister for content view resize notifications. These | 135 // Register or deregister for content view resize notifications. These |
136 // notifications are used while transitioning to fullscreen mode in Lion or | 136 // notifications are used while transitioning to fullscreen mode in Lion or |
137 // later. This method is safe to call on all OS versions. | 137 // later. This method is safe to call on all OS versions. |
138 - (void)registerForContentViewResizeNotifications; | 138 - (void)registerForContentViewResizeNotifications; |
139 - (void)deregisterForContentViewResizeNotifications; | 139 - (void)deregisterForContentViewResizeNotifications; |
140 | 140 |
141 // Adjust the UI when entering or leaving presentation mode. This method is | 141 // Adjust the UI when entering or leaving presentation mode. This method is |
142 // safe to call on all OS versions. | 142 // safe to call on all OS versions. |
143 - (void)adjustUIForPresentationMode:(BOOL)fullscreen; | 143 - (void)adjustUIForPresentationMode:(BOOL)fullscreen; |
144 | 144 |
145 // Allows/prevents bar visibility locks and releases from updating the visual | 145 // Allows/prevents bar visibility locks and releases from updating the visual |
146 // state. Enabling makes changes instantaneously; disabling cancels any | 146 // state. Enabling makes changes instantaneously; disabling cancels any |
147 // timers/animation. | 147 // timers/animation. |
148 - (void)enableBarVisibilityUpdates; | 148 - (void)enableBarVisibilityUpdates; |
149 - (void)disableBarVisibilityUpdates; | 149 - (void)disableBarVisibilityUpdates; |
150 | 150 |
151 @end // @interface BrowserWindowController(Private) | 151 @end // @interface BrowserWindowController(Private) |
152 | 152 |
153 #endif // CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_PRIVATE_H_ | 153 #endif // CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_PRIVATE_H_ |
OLD | NEW |