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

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

Issue 117533002: [Mac] Redesign of the avatar menu button (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 11 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
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 // restrict the amount of shrinking by the amounts specified above. Reset to 97 // restrict the amount of shrinking by the amounts specified above. Reset to
98 // NO on growth. 98 // NO on growth.
99 BOOL isShrinkingFromZoomed_; 99 BOOL isShrinkingFromZoomed_;
100 100
101 // The raw accumulated zoom value and the actual zoom increments made for an 101 // The raw accumulated zoom value and the actual zoom increments made for an
102 // an in-progress pinch gesture. 102 // an in-progress pinch gesture.
103 CGFloat totalMagnifyGestureAmount_; 103 CGFloat totalMagnifyGestureAmount_;
104 NSInteger currentZoomStepDelta_; 104 NSInteger currentZoomStepDelta_;
105 105
106 // The view controller that manages the incognito badge or the multi-profile 106 // The view controller that manages the incognito badge or the multi-profile
107 // avatar icon. The view is always in the view hierarchy, but will be hidden 107 // avatar button. Depending on whether the --new-profile-management flag is
108 // unless it's appropriate to show it. 108 // used, the multi-profile button can either be the avatar's icon badge or a
109 // button with the profile's name. If the flag is used, the button is always
110 // shown, otherwise the view will always be in the view hierarchy but will
111 // be hidden unless it's appropriate to show it (i.e. if there's more than
112 // one profile).
109 base::scoped_nsobject<AvatarButtonController> avatarButtonController_; 113 base::scoped_nsobject<AvatarButtonController> avatarButtonController_;
110 114
111 // Lazily created view which draws the background for the floating set of bars 115 // Lazily created view which draws the background for the floating set of bars
112 // in presentation mode (for window types having a floating bar; it remains 116 // in presentation mode (for window types having a floating bar; it remains
113 // nil for those which don't). 117 // nil for those which don't).
114 base::scoped_nsobject<NSView> floatingBarBackingView_; 118 base::scoped_nsobject<NSView> floatingBarBackingView_;
115 119
116 // The borderless window used in fullscreen mode. Lion reuses the original 120 // The borderless window used in fullscreen mode. Lion reuses the original
117 // window in fullscreen mode, so this is always nil on Lion. 121 // window in fullscreen mode, so this is always nil on Lion.
118 base::scoped_nsobject<NSWindow> fullscreenWindow_; 122 base::scoped_nsobject<NSWindow> fullscreenWindow_;
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 261
258 // Returns the frame of the regular (non-fullscreened) window (even if the 262 // Returns the frame of the regular (non-fullscreened) window (even if the
259 // window is currently in fullscreen mode). The frame is returned in Cocoa 263 // window is currently in fullscreen mode). The frame is returned in Cocoa
260 // coordinates (origin in bottom-left). 264 // coordinates (origin in bottom-left).
261 - (NSRect)regularWindowFrame; 265 - (NSRect)regularWindowFrame;
262 266
263 // Whether or not to show the avatar, which is either the incognito guy or the 267 // Whether or not to show the avatar, which is either the incognito guy or the
264 // user's profile avatar. 268 // user's profile avatar.
265 - (BOOL)shouldShowAvatar; 269 - (BOOL)shouldShowAvatar;
266 270
271 // Whether or not to show the new avatar button used by --new-profile-maagement.
272 - (BOOL)shouldUseNewAvatarButton;
273
267 - (BOOL)isBookmarkBarVisible; 274 - (BOOL)isBookmarkBarVisible;
268 275
269 // Returns YES if the bookmark bar is currently animating. 276 // Returns YES if the bookmark bar is currently animating.
270 - (BOOL)isBookmarkBarAnimating; 277 - (BOOL)isBookmarkBarAnimating;
271 278
272 - (BookmarkBarController*)bookmarkBarController; 279 - (BookmarkBarController*)bookmarkBarController;
273 280
274 - (DevToolsController*)devToolsController; 281 - (DevToolsController*)devToolsController;
275 282
276 - (BOOL)isDownloadShelfVisible; 283 - (BOOL)isDownloadShelfVisible;
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
496 // positioned relative to. 503 // positioned relative to.
497 - (NSRect)omniboxPopupAnchorRect; 504 - (NSRect)omniboxPopupAnchorRect;
498 505
499 // Force a layout of info bars. 506 // Force a layout of info bars.
500 - (void)layoutInfoBars; 507 - (void)layoutInfoBars;
501 508
502 @end // @interface BrowserWindowController (TestingAPI) 509 @end // @interface BrowserWindowController (TestingAPI)
503 510
504 511
505 #endif // CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_H_ 512 #endif // CHROME_BROWSER_UI_COCOA_BROWSER_WINDOW_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698