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

Unified Diff: chrome/browser/ui/cocoa/tabs/tab_controller.mm

Issue 476313003: Mac: Improve tab strip layout in case of overflow (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase again Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/tabs/tab_controller.mm
diff --git a/chrome/browser/ui/cocoa/tabs/tab_controller.mm b/chrome/browser/ui/cocoa/tabs/tab_controller.mm
index eb62a073eafa4cb81064befc38d841bc0c89e8f5..c7ab22310e9b27978c284db33caa92b9e1a0793a 100644
--- a/chrome/browser/ui/cocoa/tabs/tab_controller.mm
+++ b/chrome/browser/ui/cocoa/tabs/tab_controller.mm
@@ -71,7 +71,7 @@ class MenuDelegate : public ui::SimpleMenuModel::Delegate {
// of the two tab edge bitmaps because these bitmaps have a few transparent
// pixels on the side. The selected tab width includes the close button width.
+ (CGFloat)minTabWidth { return 36; }
-+ (CGFloat)minSelectedTabWidth { return 52; }
++ (CGFloat)minActiveTabWidth { return 52; }
+ (CGFloat)maxTabWidth { return 214; }
+ (CGFloat)miniTabWidth { return 58; }
+ (CGFloat)appTabWidth { return 66; }
@@ -187,7 +187,7 @@ class MenuDelegate : public ui::SimpleMenuModel::Delegate {
TabView* tabView = [self tabView];
[tabView setTitle:title];
- if ([self mini] && ![self selected]) {
+ if ([self mini] && ![self active]) {
[tabView startAlert];
}
[super setTitle:title];
@@ -273,7 +273,7 @@ class MenuDelegate : public ui::SimpleMenuModel::Delegate {
- (BOOL)shouldShowIcon {
return chrome::ShouldTabShowFavicon(
- [self iconCapacity], [self mini], [self selected], iconView_ != nil,
+ [self iconCapacity], [self mini], [self active], iconView_ != nil,
!mediaIndicatorView_ ? TAB_MEDIA_STATE_NONE :
[mediaIndicatorView_ animatingMediaState]);
}
@@ -282,13 +282,13 @@ class MenuDelegate : public ui::SimpleMenuModel::Delegate {
if (!mediaIndicatorView_)
return NO;
return chrome::ShouldTabShowMediaIndicator(
- [self iconCapacity], [self mini], [self selected], iconView_ != nil,
+ [self iconCapacity], [self mini], [self active], iconView_ != nil,
[mediaIndicatorView_ animatingMediaState]);
}
- (BOOL)shouldShowCloseButton {
return chrome::ShouldTabShowCloseButton(
- [self iconCapacity], [self mini], [self selected]);
+ [self iconCapacity], [self mini], [self active]);
}
- (void)setIconImage:(NSImage*)image {

Powered by Google App Engine
This is Rietveld 408576698