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

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

Issue 1413473004: Ensure that when we are entering Immersive Fullscreen, the fullscreen window redraws the new layout… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2526
Patch Set: Created 5 years, 1 month 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #import "chrome/browser/ui/cocoa/browser_window_controller_private.h" 5 #import "chrome/browser/ui/cocoa/browser_window_controller_private.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/mac/bind_objc_block.h" 10 #include "base/mac/bind_objc_block.h"
(...skipping 520 matching lines...) Expand 10 before | Expand all | Expand 10 after
531 savedRegularWindow_ = [[self window] retain]; 531 savedRegularWindow_ = [[self window] retain];
532 savedRegularWindowFrame_ = [savedRegularWindow_ frame]; 532 savedRegularWindowFrame_ = [savedRegularWindow_ frame];
533 533
534 [self moveViewsForImmersiveFullscreen:YES 534 [self moveViewsForImmersiveFullscreen:YES
535 regularWindow:[self window] 535 regularWindow:[self window]
536 fullscreenWindow:fullscreenWindow_.get()]; 536 fullscreenWindow:fullscreenWindow_.get()];
537 537
538 fullscreen_mac::SlidingStyle style = fullscreen_mac::OMNIBOX_TABS_HIDDEN; 538 fullscreen_mac::SlidingStyle style = fullscreen_mac::OMNIBOX_TABS_HIDDEN;
539 [self adjustUIForSlidingFullscreenStyle:style]; 539 [self adjustUIForSlidingFullscreenStyle:style];
540 540
541 [fullscreenWindow_ display];
542
541 // AppKit is helpful and prevents NSWindows from having the same height as 543 // AppKit is helpful and prevents NSWindows from having the same height as
542 // the screen while the menu bar is showing. This only applies to windows on 544 // the screen while the menu bar is showing. This only applies to windows on
543 // a secondary screen, in a separate space. Calling [NSWindow 545 // a secondary screen, in a separate space. Calling [NSWindow
544 // setFrame:display:] with the screen's height will always reduce the 546 // setFrame:display:] with the screen's height will always reduce the
545 // height by the height of the MenuBar. Calling the method with any other 547 // height by the height of the MenuBar. Calling the method with any other
546 // height works fine. The relevant method in the 10.10 AppKit SDK is called: 548 // height works fine. The relevant method in the 10.10 AppKit SDK is called:
547 // _canAdjustSizeForScreensHaveSeparateSpacesIfFillingSecondaryScreen 549 // _canAdjustSizeForScreensHaveSeparateSpacesIfFillingSecondaryScreen
548 // 550 //
549 // TODO(erikchen): Refactor the logic to allow the window to be shown after 551 // TODO(erikchen): Refactor the logic to allow the window to be shown after
550 // the menubar has been hidden. This would remove the need for this hack. 552 // the menubar has been hidden. This would remove the need for this hack.
(...skipping 602 matching lines...) Expand 10 before | Expand all | Expand 10 after
1153 return browser_->tab_strip_model()->GetActiveWebContents(); 1155 return browser_->tab_strip_model()->GetActiveWebContents();
1154 } 1156 }
1155 1157
1156 - (PermissionBubbleManager*)permissionBubbleManager { 1158 - (PermissionBubbleManager*)permissionBubbleManager {
1157 if (WebContents* contents = [self webContents]) 1159 if (WebContents* contents = [self webContents])
1158 return PermissionBubbleManager::FromWebContents(contents); 1160 return PermissionBubbleManager::FromWebContents(contents);
1159 return nil; 1161 return nil;
1160 } 1162 }
1161 1163
1162 @end // @implementation BrowserWindowController(Private) 1164 @end // @implementation BrowserWindowController(Private)
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698