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

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

Issue 16632009: Set AllowOverlappingViews for history overlay (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix comment Created 7 years, 6 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 #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 #import "base/memory/scoped_nsobject.h" 10 #import "base/memory/scoped_nsobject.h"
(...skipping 1012 matching lines...) Expand 10 before | Expand all | Expand 10 after
1023 if (chrome::IsInstantExtendedAPIEnabled()) 1023 if (chrome::IsInstantExtendedAPIEnabled())
1024 return YES; 1024 return YES;
1025 1025
1026 if (inPresentationMode) 1026 if (inPresentationMode)
1027 return YES; 1027 return YES;
1028 1028
1029 if (findBarCocoaController_ && 1029 if (findBarCocoaController_ &&
1030 ![[findBarCocoaController_ findBarView] isHidden]) 1030 ![[findBarCocoaController_ findBarView] isHidden])
1031 return YES; 1031 return YES;
1032 1032
1033 if (historyOverlayCount_)
1034 return YES;
1035
1033 return NO; 1036 return NO;
1034 } 1037 }
1035 1038
1036 - (void)updateAllowOverlappingViews:(BOOL)inPresentationMode { 1039 - (void)updateAllowOverlappingViews:(BOOL)inPresentationMode {
1037 WebContents* contents = browser_->tab_strip_model()->GetActiveWebContents(); 1040 WebContents* contents = browser_->tab_strip_model()->GetActiveWebContents();
1038 if (!contents) 1041 if (!contents)
1039 return; 1042 return;
1040 contents->GetView()->SetAllowOverlappingViews( 1043 contents->GetView()->SetAllowOverlappingViews(
1041 [self shouldAllowOverlappingViews:inPresentationMode]); 1044 [self shouldAllowOverlappingViews:inPresentationMode]);
1042 } 1045 }
1043 1046
1044 - (void)updateInfoBarTipVisibility { 1047 - (void)updateInfoBarTipVisibility {
1045 // If the overlay is open or if there's no toolbar then hide the infobar tip. 1048 // If the overlay is open or if there's no toolbar then hide the infobar tip.
1046 BOOL suppressInfoBarTip = 1049 BOOL suppressInfoBarTip =
1047 [self currentInstantUIState] != 1050 [self currentInstantUIState] !=
1048 browser_window_controller::kInstantUINone || ![self hasToolbar]; 1051 browser_window_controller::kInstantUINone || ![self hasToolbar];
1049 [infoBarContainerController_ 1052 [infoBarContainerController_
1050 setShouldSuppressTopInfoBarTip:suppressInfoBarTip]; 1053 setShouldSuppressTopInfoBarTip:suppressInfoBarTip];
1051 } 1054 }
1052 1055
1053 @end // @implementation BrowserWindowController(Private) 1056 @end // @implementation BrowserWindowController(Private)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698