| OLD | NEW |
| 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 419 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 430 object:[notification object]]; | 430 object:[notification object]]; |
| 431 [self releaseBarVisibilityForOwner:[notification object] | 431 [self releaseBarVisibilityForOwner:[notification object] |
| 432 withAnimation:YES | 432 withAnimation:YES |
| 433 delay:YES]; | 433 delay:YES]; |
| 434 } | 434 } |
| 435 | 435 |
| 436 - (void)configurePresentationModeController { | 436 - (void)configurePresentationModeController { |
| 437 BOOL fullscreen_for_tab = | 437 BOOL fullscreen_for_tab = |
| 438 browser_->fullscreen_controller()->IsWindowFullscreenForTabOrPending(); | 438 browser_->fullscreen_controller()->IsWindowFullscreenForTabOrPending(); |
| 439 BOOL kiosk_mode = | 439 BOOL kiosk_mode = |
| 440 CommandLine::ForCurrentProcess()->HasSwitch(switches::kKioskMode); | 440 base::CommandLine::ForCurrentProcess()->HasSwitch(switches::kKioskMode); |
| 441 BOOL showDropdown = | 441 BOOL showDropdown = |
| 442 !fullscreen_for_tab && !kiosk_mode && ([self floatingBarHasFocus]); | 442 !fullscreen_for_tab && !kiosk_mode && ([self floatingBarHasFocus]); |
| 443 if (permissionBubbleCocoa_ && permissionBubbleCocoa_->IsVisible()) { | 443 if (permissionBubbleCocoa_ && permissionBubbleCocoa_->IsVisible()) { |
| 444 DCHECK(permissionBubbleCocoa_->window()); | 444 DCHECK(permissionBubbleCocoa_->window()); |
| 445 // A visible permission bubble will force the dropdown to remain visible. | 445 // A visible permission bubble will force the dropdown to remain visible. |
| 446 [self lockBarVisibilityForOwner:permissionBubbleCocoa_->window() | 446 [self lockBarVisibilityForOwner:permissionBubbleCocoa_->window() |
| 447 withAnimation:NO | 447 withAnimation:NO |
| 448 delay:NO]; | 448 delay:NO]; |
| 449 showDropdown = YES; | 449 showDropdown = YES; |
| 450 // Register to be notified when the permission bubble is closed, to | 450 // Register to be notified when the permission bubble is closed, to |
| (...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1020 } | 1020 } |
| 1021 if (!enteringAppKitFullscreen_) | 1021 if (!enteringAppKitFullscreen_) |
| 1022 return NO; | 1022 return NO; |
| 1023 if (enteringAppKitFullscreenOnPrimaryScreen_) | 1023 if (enteringAppKitFullscreenOnPrimaryScreen_) |
| 1024 return NO; | 1024 return NO; |
| 1025 | 1025 |
| 1026 return YES; | 1026 return YES; |
| 1027 } | 1027 } |
| 1028 | 1028 |
| 1029 @end // @implementation BrowserWindowController(Private) | 1029 @end // @implementation BrowserWindowController(Private) |
| OLD | NEW |