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

Side by Side Diff: chrome/browser/ui/cocoa/browser_window_controller.h

Issue 10823176: Cocoa: Support constrained windows for platform apps (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comment Created 8 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) 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_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_H_
7 7
8 // A class acting as the Objective-C controller for the Browser 8 // A class acting as the Objective-C controller for the Browser
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 toolbar and, by virtue of being a 10 // code. Each window has a single toolbar and, by virtue of being a
11 // TabWindowController, a tab strip along the top. 11 // TabWindowController, a tab strip along the top.
12 12
13 #import <Cocoa/Cocoa.h> 13 #import <Cocoa/Cocoa.h>
14 14
15 #include "base/memory/scoped_nsobject.h" 15 #include "base/memory/scoped_nsobject.h"
16 #include "base/memory/scoped_ptr.h" 16 #include "base/memory/scoped_ptr.h"
17 #include "chrome/browser/sync/sync_ui_util.h" 17 #include "chrome/browser/sync/sync_ui_util.h"
18 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.h" 18 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.h"
19 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bubble_controller.h" 19 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bubble_controller.h"
20 #import "chrome/browser/ui/cocoa/browser_command_executor.h" 20 #import "chrome/browser/ui/cocoa/browser_command_executor.h"
21 #import "chrome/browser/ui/cocoa/constrained_window_mac.h"
21 #import "chrome/browser/ui/cocoa/fullscreen_exit_bubble_controller.h" 22 #import "chrome/browser/ui/cocoa/fullscreen_exit_bubble_controller.h"
22 #import "chrome/browser/ui/cocoa/tabs/tab_strip_controller.h" 23 #import "chrome/browser/ui/cocoa/tabs/tab_strip_controller.h"
23 #import "chrome/browser/ui/cocoa/tabs/tab_window_controller.h" 24 #import "chrome/browser/ui/cocoa/tabs/tab_window_controller.h"
24 #import "chrome/browser/ui/cocoa/themed_window.h" 25 #import "chrome/browser/ui/cocoa/themed_window.h"
25 #import "chrome/browser/ui/cocoa/url_drop_target.h" 26 #import "chrome/browser/ui/cocoa/url_drop_target.h"
26 #import "chrome/browser/ui/cocoa/view_resizer.h" 27 #import "chrome/browser/ui/cocoa/view_resizer.h"
27 #include "ui/gfx/rect.h" 28 #include "ui/gfx/rect.h"
28 29
29 @class AvatarButtonController; 30 @class AvatarButtonController;
30 class Browser; 31 class Browser;
31 class BrowserWindow; 32 class BrowserWindow;
32 class BrowserWindowCocoa; 33 class BrowserWindowCocoa;
33 @class ChromeToMobileBubbleController; 34 @class ChromeToMobileBubbleController;
34 class ConstrainedWindowMac;
35 @class DevToolsController; 35 @class DevToolsController;
36 @class DownloadShelfController; 36 @class DownloadShelfController;
37 @class FindBarCocoaController; 37 @class FindBarCocoaController;
38 @class FullscreenWindow; 38 @class FullscreenWindow;
39 @class GTMWindowSheetController; 39 @class GTMWindowSheetController;
40 @class InfoBarContainerController; 40 @class InfoBarContainerController;
41 class LocationBarViewMac; 41 class LocationBarViewMac;
42 @class PresentationModeController; 42 @class PresentationModeController;
43 @class PreviewableContentsController; 43 @class PreviewableContentsController;
44 class StatusBubbleMac; 44 class StatusBubbleMac;
45 @class TabStripController; 45 @class TabStripController;
46 @class TabStripView; 46 @class TabStripView;
47 @class ToolbarController; 47 @class ToolbarController;
48 48
49 namespace content { 49 namespace content {
50 class WebContents; 50 class WebContents;
51 } 51 }
52 52
53 @interface BrowserWindowController : 53 @interface BrowserWindowController :
54 TabWindowController<NSUserInterfaceValidations, 54 TabWindowController<NSUserInterfaceValidations,
55 BookmarkBarControllerDelegate, 55 BookmarkBarControllerDelegate,
56 BrowserCommandExecutor, 56 BrowserCommandExecutor,
57 ViewResizer, 57 ViewResizer,
58 TabStripControllerDelegate> { 58 TabStripControllerDelegate,
59 ConstrainedWindowSupport> {
59 @private 60 @private
60 // The ordering of these members is important as it determines the order in 61 // The ordering of these members is important as it determines the order in
61 // which they are destroyed. |browser_| needs to be destroyed last as most of 62 // which they are destroyed. |browser_| needs to be destroyed last as most of
62 // the other objects hold weak references to it or things it owns 63 // the other objects hold weak references to it or things it owns
63 // (tab/toolbar/bookmark models, profiles, etc). 64 // (tab/toolbar/bookmark models, profiles, etc).
64 scoped_ptr<Browser> browser_; 65 scoped_ptr<Browser> browser_;
65 NSWindow* savedRegularWindow_; 66 NSWindow* savedRegularWindow_;
66 scoped_ptr<BrowserWindowCocoa> windowShim_; 67 scoped_ptr<BrowserWindowCocoa> windowShim_;
67 scoped_nsobject<ToolbarController> toolbarController_; 68 scoped_nsobject<ToolbarController> toolbarController_;
68 scoped_nsobject<TabStripController> tabStripController_; 69 scoped_nsobject<TabStripController> tabStripController_;
(...skipping 403 matching lines...) Expand 10 before | Expand all | Expand 10 after
472 // |source| rect doesn't fit into |target|. 473 // |source| rect doesn't fit into |target|.
473 - (NSSize)overflowFrom:(NSRect)source 474 - (NSSize)overflowFrom:(NSRect)source
474 to:(NSRect)target; 475 to:(NSRect)target;
475 476
476 // The fullscreen exit bubble controller, or nil if the bubble isn't showing. 477 // The fullscreen exit bubble controller, or nil if the bubble isn't showing.
477 - (FullscreenExitBubbleController*)fullscreenExitBubbleController; 478 - (FullscreenExitBubbleController*)fullscreenExitBubbleController;
478 @end // @interface BrowserWindowController (TestingAPI) 479 @end // @interface BrowserWindowController (TestingAPI)
479 480
480 481
481 #endif // CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_H_ 482 #endif // CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/constrained_window_mac.h » ('j') | chrome/browser/ui/cocoa/constrained_window_mac.mm » ('J')

Powered by Google App Engine
This is Rietveld 408576698