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_TOOLBAR_TOOLBAR_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_UI_COCOA_TOOLBAR_TOOLBAR_CONTROLLER_H_ |
6 #define CHROME_BROWSER_UI_COCOA_TOOLBAR_TOOLBAR_CONTROLLER_H_ | 6 #define CHROME_BROWSER_UI_COCOA_TOOLBAR_TOOLBAR_CONTROLLER_H_ |
7 | 7 |
8 #import <Cocoa/Cocoa.h> | 8 #import <Cocoa/Cocoa.h> |
9 | 9 |
10 #include "base/mac/scoped_nsobject.h" | 10 #include "base/mac/scoped_nsobject.h" |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 | 104 |
105 // Get the C++ bridge object representing the location bar for this tab. | 105 // Get the C++ bridge object representing the location bar for this tab. |
106 - (LocationBarViewMac*)locationBarBridge; | 106 - (LocationBarViewMac*)locationBarBridge; |
107 | 107 |
108 // Called by the Window delegate so we can provide a custom field editor if | 108 // Called by the Window delegate so we can provide a custom field editor if |
109 // needed. | 109 // needed. |
110 // Note that this may be called for objects unrelated to the toolbar. | 110 // Note that this may be called for objects unrelated to the toolbar. |
111 // returns nil if we don't want to override the custom field editor for |obj|. | 111 // returns nil if we don't want to override the custom field editor for |obj|. |
112 - (id)customFieldEditorForObject:(id)obj; | 112 - (id)customFieldEditorForObject:(id)obj; |
113 | 113 |
| 114 // Called by the |locationBar_| when it has been added to its window. |
| 115 - (void)locationBarWasAddedToWindow; |
| 116 |
114 // Make the location bar the first responder, if possible. | 117 // Make the location bar the first responder, if possible. |
115 - (void)focusLocationBar:(BOOL)selectAll; | 118 - (void)focusLocationBar:(BOOL)selectAll; |
116 | 119 |
117 // Called by CommandObserverBridge when there is a state change for the given | 120 // Called by CommandObserverBridge when there is a state change for the given |
118 // command. | 121 // command. |
119 - (void)enabledStateChangedForCommand:(int)command enabled:(bool)enabled; | 122 - (void)enabledStateChangedForCommand:(int)command enabled:(bool)enabled; |
120 | 123 |
121 // Forces the toolbar (and transitively the location bar) to update its current | 124 // Forces the toolbar (and transitively the location bar) to update its current |
122 // state. If |tab| is non-NULL, we're switching (back?) to this tab and should | 125 // state. If |tab| is non-NULL, we're switching (back?) to this tab and should |
123 // restore any previous location bar state (such as user editing) as well. | 126 // restore any previous location bar state (such as user editing) as well. |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
186 @interface ToolbarController(PrivateTestMethods) | 189 @interface ToolbarController(PrivateTestMethods) |
187 // Returns an array of views in the order of the outlets above. | 190 // Returns an array of views in the order of the outlets above. |
188 - (NSArray*)toolbarViews; | 191 - (NSArray*)toolbarViews; |
189 - (void)showOptionalHomeButton; | 192 - (void)showOptionalHomeButton; |
190 - (void)installAppMenu; | 193 - (void)installAppMenu; |
191 // Return a hover button for the current event. | 194 // Return a hover button for the current event. |
192 - (NSButton*)hoverButtonForEvent:(NSEvent*)theEvent; | 195 - (NSButton*)hoverButtonForEvent:(NSEvent*)theEvent; |
193 @end | 196 @end |
194 | 197 |
195 #endif // CHROME_BROWSER_UI_COCOA_TOOLBAR_TOOLBAR_CONTROLLER_H_ | 198 #endif // CHROME_BROWSER_UI_COCOA_TOOLBAR_TOOLBAR_CONTROLLER_H_ |
OLD | NEW |