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

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

Issue 2729603008: [Mac] Remove bookmark bar NIB (Closed)
Patch Set: Cleanup Created 3 years, 9 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
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #import "chrome/browser/ui/cocoa/browser_window_controller.h" 5 #import "chrome/browser/ui/cocoa/browser_window_controller.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 #include <numeric> 8 #include <numeric>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
324 browser:browser]); 324 browser:browser]);
325 [[toolbarController_ toolbarView] setResizeDelegate:self]; 325 [[toolbarController_ toolbarView] setResizeDelegate:self];
326 [toolbarController_ setHasToolbar:[self hasToolbar] 326 [toolbarController_ setHasToolbar:[self hasToolbar]
327 hasLocationBar:[self hasLocationBar]]; 327 hasLocationBar:[self hasLocationBar]];
328 328
329 // Create a sub-controller for the bookmark bar. 329 // Create a sub-controller for the bookmark bar.
330 bookmarkBarController_.reset([[BookmarkBarController alloc] 330 bookmarkBarController_.reset([[BookmarkBarController alloc]
331 initWithBrowser:browser_.get() 331 initWithBrowser:browser_.get()
332 initialWidth:NSWidth([[[self window] contentView] frame]) 332 initialWidth:NSWidth([[[self window] contentView] frame])
333 delegate:self]); 333 delegate:self]);
334 // This call triggers an -awakeFromNib for ToolbarView.xib. 334 // This call loads the view.
335 [[bookmarkBarController_ controlledView] setResizeDelegate:self]; 335 [[bookmarkBarController_ controlledView] setResizeDelegate:self];
Elly Fong-Jones 2017/03/07 16:21:54 why does a function called "setResizeDelegate:" lo
lgrey 2017/03/07 22:07:32 It doesn't. |controlledView| calls [self view] whi
336 336
337 [bookmarkBarController_ setBookmarkBarEnabled:[self supportsBookmarkBar]]; 337 [bookmarkBarController_ setBookmarkBarEnabled:[self supportsBookmarkBar]];
338 338
339 // Create the infobar container view, so we can pass it to the 339 // Create the infobar container view, so we can pass it to the
340 // ToolbarController. 340 // ToolbarController.
341 infoBarContainerController_.reset( 341 infoBarContainerController_.reset(
342 [[InfoBarContainerController alloc] initWithResizeDelegate:self]); 342 [[InfoBarContainerController alloc] initWithResizeDelegate:self]);
343 [self updateInfoBarTipVisibility]; 343 [self updateInfoBarTipVisibility];
344 344
345 // We don't want to try and show the bar before it gets placed in its parent 345 // We don't want to try and show the bar before it gets placed in its parent
(...skipping 1682 matching lines...) Expand 10 before | Expand all | Expand 10 after
2028 2028
2029 - (NSRect)savedRegularWindowFrame { 2029 - (NSRect)savedRegularWindowFrame {
2030 return savedRegularWindowFrame_; 2030 return savedRegularWindowFrame_;
2031 } 2031 }
2032 2032
2033 - (BOOL)isFullscreenTransitionInProgress { 2033 - (BOOL)isFullscreenTransitionInProgress {
2034 return enteringAppKitFullscreen_ || exitingAppKitFullscreen_; 2034 return enteringAppKitFullscreen_ || exitingAppKitFullscreen_;
2035 } 2035 }
2036 2036
2037 @end // @implementation BrowserWindowController(WindowType) 2037 @end // @implementation BrowserWindowController(WindowType)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698