| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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_WINDOW_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_BROWSER_WINDOW_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_BROWSER_WINDOW_CONTROLLER_H_ | 6 #define CHROME_BROWSER_BROWSER_WINDOW_CONTROLLER_H_ |
| 7 | 7 |
| 8 // A class acting as the Objective-C controller for the Browser object. Handles | 8 // A class acting as the Objective-C controller for the Browser object. Handles |
| 9 // interactions between Cocoa and the cross-platform code. | 9 // interactions between Cocoa and the cross-platform code. |
| 10 | 10 |
| 11 #import <Cocoa/Cocoa.h> | 11 #import <Cocoa/Cocoa.h> |
| 12 | 12 |
| 13 class Browser; | 13 class Browser; |
| 14 class BrowserWindow; | 14 class BrowserWindow; |
| 15 | 15 |
| 16 @interface BrowserWindowController : | 16 @interface BrowserWindowController : |
| 17 NSWindowController<NSUserInterfaceValidations> { | 17 NSWindowController<NSUserInterfaceValidations> { |
| 18 @private | 18 @private |
| 19 Browser* browser_; // strong | 19 Browser* browser_; // strong |
| 20 BrowserWindow* window_shim_; // strong | 20 BrowserWindow* windowShim_; // strong |
| 21 | 21 |
| 22 // Some toolbar items for IB. We can remove these if we stop using IB for | 22 // Views for the toolbar |
| 23 // NSToolbar support (it only half works). | 23 IBOutlet NSView* toolbarView_; |
| 24 IBOutlet NSToolbarItem* back_button_; | 24 IBOutlet NSTextField* urlBarView_; |
| 25 IBOutlet NSToolbarItem* forward_button_; | |
| 26 IBOutlet NSToolbarItem* url_bar_; | |
| 27 | 25 |
| 28 // This will become its own view at some point. | 26 // Views for the tabs |
| 29 IBOutlet NSView* tab_bar_view_; | 27 IBOutlet NSView* tabBarView_; |
| 30 } | 28 } |
| 31 | 29 |
| 32 // Load the browser window nib and do any Cocoa-specific initialization. | 30 // Load the browser window nib and do any Cocoa-specific initialization. |
| 33 // Takes ownership of |browser|. | 31 // Takes ownership of |browser|. |
| 34 - (id)initWithBrowser:(Browser*)browser; | 32 - (id)initWithBrowser:(Browser*)browser; |
| 35 | 33 |
| 36 // call to make the browser go away from other places in the cross-platform | 34 // call to make the browser go away from other places in the cross-platform |
| 37 // code. | 35 // code. |
| 38 - (void)destroyBrowser; | 36 - (void)destroyBrowser; |
| 39 | 37 |
| 40 // Access the C++ bridge between the NSWindow and the rest of Chromium | 38 // Access the C++ bridge between the NSWindow and the rest of Chromium |
| 41 - (BrowserWindow*)browserWindow; | 39 - (BrowserWindow*)browserWindow; |
| 42 | 40 |
| 43 @end | 41 @end |
| 44 | 42 |
| 45 #endif // CHROME_BROWSER_BROWSER_WINDOW_CONTROLLER_H_ | 43 #endif // CHROME_BROWSER_BROWSER_WINDOW_CONTROLLER_H_ |
| OLD | NEW |