Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(251)

Side by Side Diff: chrome/browser/ui/panels/panel_window_controller_cocoa.h

Issue 7538010: Make BrowserWindow::CreateFindBar non-static so that it can be overridden by Panels. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove underscore. Created 9 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_PANELS_PANEL_WINDOW_CONTROLLER_COCOA_H_ 5 #ifndef CHROME_BROWSER_UI_PANELS_PANEL_WINDOW_CONTROLLER_COCOA_H_
6 #define CHROME_BROWSER_UI_PANELS_PANEL_WINDOW_CONTROLLER_COCOA_H_ 6 #define CHROME_BROWSER_UI_PANELS_PANEL_WINDOW_CONTROLLER_COCOA_H_
7 7
8 // A class acting as the Objective-C controller for the Panel window 8 // A class acting as the Objective-C controller for the Panel window
9 // object. Handles interactions between Cocoa and the cross-platform 9 // object. Handles interactions between Cocoa and the cross-platform
10 // code. Each window has a single titlebar and is managed/owned by Panel. 10 // code. Each window has a single titlebar and is managed/owned by Panel.
11 11
12 #import <Cocoa/Cocoa.h> 12 #import <Cocoa/Cocoa.h>
13 13
14 #import "base/mac/cocoa_protocols.h" 14 #import "base/mac/cocoa_protocols.h"
15 #include "base/memory/scoped_ptr.h" 15 #include "base/memory/scoped_ptr.h"
16 16
17 @class FindBarCocoaController;
17 class PanelBrowserWindowCocoa; 18 class PanelBrowserWindowCocoa;
18 @class PanelTitlebarViewCocoa; 19 @class PanelTitlebarViewCocoa;
19 20
20 @interface PanelWindowControllerCocoa : NSWindowController<NSWindowDelegate> { 21 @interface PanelWindowControllerCocoa : NSWindowController<NSWindowDelegate> {
21 @private 22 @private
22 IBOutlet PanelTitlebarViewCocoa* titlebar_view_; 23 IBOutlet PanelTitlebarViewCocoa* titlebar_view_;
23 scoped_ptr<PanelBrowserWindowCocoa> windowShim_; 24 scoped_ptr<PanelBrowserWindowCocoa> windowShim_;
24 } 25 }
25 26
26 // Load the browser window nib and do any Cocoa-specific initialization. 27 // Load the browser window nib and do any Cocoa-specific initialization.
27 - (id)initWithBrowserWindow:(PanelBrowserWindowCocoa*)window; 28 - (id)initWithBrowserWindow:(PanelBrowserWindowCocoa*)window;
28 29
29 // Returns the TabContents' native view. It renders the content of the web page 30 // Returns the TabContents' native view. It renders the content of the web page
30 // in the Panel. 31 // in the Panel.
31 - (NSView*)tabContentsView; 32 - (NSView*)tabContentsView;
32 33
33 // Sometimes (when we animate the size of the window) we want to stop resizing 34 // Sometimes (when we animate the size of the window) we want to stop resizing
34 // the TabContents's cocoa view to avoid unnecessary churn and issues 35 // the TabContents's cocoa view to avoid unnecessary churn and issues
35 // that can be caused by sizes near 0. 36 // that can be caused by sizes near 0.
36 - (void)disableTabContentsViewAutosizing; 37 - (void)disableTabContentsViewAutosizing;
37 - (void)enableTabContentsViewAutosizing; 38 - (void)enableTabContentsViewAutosizing;
38 39
39 // Shows the window for the first time. Only happens once. 40 // Shows the window for the first time. Only happens once.
40 - (void)revealAnimatedWithFrame:(const NSRect&)frame; 41 - (void)revealAnimatedWithFrame:(const NSRect&)frame;
41 42
43 // Retains the given FindBarCocoaController and adds its view to this
Dmitry Titov 2011/08/08 20:08:31 In the comment, no need to say "Retains", since t
jennb 2011/08/08 21:21:21 Oops. Forgot to update that comment. Good catch. F
44 // Panel. Must only be called once per PanelWindowControllerCocoa.
45 - (void)addFindBar:(FindBarCocoaController*)findBarCocoaController;
46
42 // Initiate the closing of the panel, starting from the platform-independent 47 // Initiate the closing of the panel, starting from the platform-independent
43 // layer. This will take care of PanelManager, other panels and close the 48 // layer. This will take care of PanelManager, other panels and close the
44 // native window at the end. 49 // native window at the end.
45 - (void)closePanel; 50 - (void)closePanel;
46 51
47 // Accessor for titlebar view. 52 // Accessor for titlebar view.
48 - (PanelTitlebarViewCocoa*)titlebarView; 53 - (PanelTitlebarViewCocoa*)titlebarView;
49 54
50 @end // @interface PanelWindowController 55 @end // @interface PanelWindowController
51 56
52 #endif // CHROME_BROWSER_UI_PANELS_PANEL_WINDOW_CONTROLLER_COCOA_H_ 57 #endif // CHROME_BROWSER_UI_PANELS_PANEL_WINDOW_CONTROLLER_COCOA_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698