summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrsesek@chromium.org <rsesek@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-15 19:25:41 +0000
committerrsesek@chromium.org <rsesek@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-15 19:25:41 +0000
commit83a3459aba0fe30d1771c38d42412b0cf7c8fbd9 (patch)
treeec2477172eb5f78902af9adfbc59c05e5b590564
parentee405c220b9c2551c6138c79375bf0f553cdb8c4 (diff)
downloadchromium_src-83a3459aba0fe30d1771c38d42412b0cf7c8fbd9.zip
chromium_src-83a3459aba0fe30d1771c38d42412b0cf7c8fbd9.tar.gz
chromium_src-83a3459aba0fe30d1771c38d42412b0cf7c8fbd9.tar.bz2
[Mac] Remove the Lion fullscreen button until proper fullscreen support is added.
BUG=74056,74065 TEST=Run on Lion. No fullscreen button in upper right. Review URL: http://codereview.chromium.org/7390012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92728 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/ui/cocoa/browser_window_controller_private.mm23
-rw-r--r--chrome/browser/ui/cocoa/tabs/tab_strip_controller.mm11
2 files changed, 4 insertions, 30 deletions
diff --git a/chrome/browser/ui/cocoa/browser_window_controller_private.mm b/chrome/browser/ui/cocoa/browser_window_controller_private.mm
index dd1a17e..85b230f 100644
--- a/chrome/browser/ui/cocoa/browser_window_controller_private.mm
+++ b/chrome/browser/ui/cocoa/browser_window_controller_private.mm
@@ -306,15 +306,6 @@ willPositionSheet:(NSWindow*)sheet
// Now lay out incognito badge together with the tab strip.
if (avatarButton_.get()) {
- // Avoid the full-screen button.
- CGFloat extraPadding = 0;
- if ([[self window] respondsToSelector:@selector(toggleFullScreen:)]) {
- NSButton* fullscreenButton =
- [[self window] standardWindowButton:NSWindowFullScreenButton];
- if (fullscreenButton)
- extraPadding += [fullscreenButton frame].size.width;
- }
-
// Set the size of the avatar to be the (height of the tabstrip) - (padding)
// to let large icons fit.
CGFloat sizeSquare = tabStripHeight - 5.0;
@@ -322,7 +313,7 @@ willPositionSheet:(NSWindow*)sheet
// Actually place the badge *above* |maxY|, by +2 to miss the divider.
NSPoint origin = NSMakePoint(width - NSWidth([avatarButton_ frame]) -
- kIncognitoBadgeOffset - extraPadding,
+ kIncognitoBadgeOffset,
maxY + 2);
[avatarButton_ setFrameOrigin:origin];
[avatarButton_ setHidden:NO]; // Make sure it's shown.
@@ -549,17 +540,7 @@ willPositionSheet:(NSWindow*)sheet
}
- (void)setUpOSFullScreenButton {
- NSWindow* window = [self window];
- if ([window respondsToSelector:@selector(toggleFullScreen:)]) {
- NSWindowCollectionBehavior behavior = [window collectionBehavior];
- behavior |= NSWindowCollectionBehaviorFullScreenPrimary;
- [window setCollectionBehavior:behavior];
-
- NSButton* fullscreenButton =
- [window standardWindowButton:NSWindowFullScreenButton];
- [fullscreenButton setAction:@selector(enterFullscreen:)];
- [fullscreenButton setTarget:self];
- }
+ // TOOD(rsesek): Properly implement Lion fullscreen <http://crbug.com/74065>.
}
@end // @implementation BrowserWindowController(Private)
diff --git a/chrome/browser/ui/cocoa/tabs/tab_strip_controller.mm b/chrome/browser/ui/cocoa/tabs/tab_strip_controller.mm
index 6ad6d41..06927ea 100644
--- a/chrome/browser/ui/cocoa/tabs/tab_strip_controller.mm
+++ b/chrome/browser/ui/cocoa/tabs/tab_strip_controller.mm
@@ -844,20 +844,13 @@ private:
BrowserWindowController* controller =
(BrowserWindowController*)[[tabStripView_ window] windowController];
- // Account for the widths of the new tab button, the avatar, and the
- // fullscreen button if any/all are present.
+ // Account for the widths of the new tab button or the avatar, if any/all
+ // are present.
availableSpace -= NSWidth([newTabButton_ frame]) + kNewTabButtonOffset;
if ([controller respondsToSelector:@selector(shouldShowAvatar)] &&
[controller shouldShowAvatar]) {
availableSpace -= kAvatarTabStripShrink;
}
- if ([[tabStripView_ window]
- respondsToSelector:@selector(toggleFullScreen:)]) {
- NSButton* fullscreenButton = [[tabStripView_ window]
- standardWindowButton:NSWindowFullScreenButton];
- if (fullscreenButton)
- availableSpace -= [fullscreenButton frame].size.width;
- }
}
availableSpace -= [self indentForControls];
}