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

Unified Diff: ios/clean/chrome/browser/ui/toolbar/toolbar_button+factory.mm

Issue 2892113002: [ios clean] Fixes Toolbar constraints. (Closed)
Patch Set: Created 3 years, 7 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
« no previous file with comments | « no previous file | ios/clean/chrome/browser/ui/toolbar/toolbar_constants.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/clean/chrome/browser/ui/toolbar/toolbar_button+factory.mm
diff --git a/ios/clean/chrome/browser/ui/toolbar/toolbar_button+factory.mm b/ios/clean/chrome/browser/ui/toolbar/toolbar_button+factory.mm
index 076c0ab39c4998fd8abbd73f48adfcfc74a048a9..4676ee6307cd0db42dbc61c3029726b50ef64bb2 100644
--- a/ios/clean/chrome/browser/ui/toolbar/toolbar_button+factory.mm
+++ b/ios/clean/chrome/browser/ui/toolbar/toolbar_button+factory.mm
@@ -12,11 +12,6 @@
#error "This file requires ARC support."
#endif
-namespace {
-// ToolbarButton fixed width.
-CGFloat kToolbarButtonWidth = 42.0f;
-} // namespace
-
@implementation ToolbarButton (Factory)
#pragma mark - ToolbarButton Setup
@@ -31,8 +26,6 @@ CGFloat kToolbarButtonWidth = 42.0f;
imageForDisabledState:
NativeReversableImage(
IDR_IOS_TOOLBAR_LIGHT_BACK_DISABLED, YES)];
- [backButton.widthAnchor constraintEqualToConstant:kToolbarButtonWidth]
- .active = YES;
return backButton;
}
@@ -47,8 +40,6 @@ CGFloat kToolbarButtonWidth = 42.0f;
imageForDisabledState:
NativeReversableImage(
IDR_IOS_TOOLBAR_LIGHT_FORWARD_DISABLED, YES)];
- [forwardButton.widthAnchor constraintEqualToConstant:kToolbarButtonWidth]
- .active = YES;
return forwardButton;
}
@@ -58,9 +49,6 @@ CGFloat kToolbarButtonWidth = 42.0f;
[UIImage imageNamed:@"tabswitcher_open_tabs"]
imageForHighlightedState:nil
imageForDisabledState:nil];
- [tabSwitcherStripButton.widthAnchor
- constraintEqualToConstant:kToolbarButtonWidth]
- .active = YES;
return tabSwitcherStripButton;
}
@@ -70,9 +58,6 @@ CGFloat kToolbarButtonWidth = 42.0f;
[UIImage imageNamed:@"tabswitcher_tab_switcher_button"]
imageForHighlightedState:nil
imageForDisabledState:nil];
- [tabSwitcherGridButton.widthAnchor
- constraintEqualToConstant:kToolbarButtonWidth]
- .active = YES;
return tabSwitcherGridButton;
}
@@ -83,8 +68,6 @@ CGFloat kToolbarButtonWidth = 42.0f;
imageForHighlightedState:nil
imageForDisabledState:nil];
[toolsMenuButton setImageEdgeInsets:UIEdgeInsetsMakeDirected(0, -3, 0, 0)];
- [toolsMenuButton.widthAnchor constraintEqualToConstant:kToolbarButtonWidth]
- .active = YES;
return toolsMenuButton;
}
@@ -96,8 +79,6 @@ CGFloat kToolbarButtonWidth = 42.0f;
NativeImage(IDR_IOS_TOOLBAR_LIGHT_SHARE_PRESSED)
imageForDisabledState:
NativeImage(IDR_IOS_TOOLBAR_LIGHT_SHARE_DISABLED)];
- [shareButton.widthAnchor constraintEqualToConstant:kToolbarButtonWidth]
- .active = YES;
return shareButton;
}
@@ -112,8 +93,6 @@ CGFloat kToolbarButtonWidth = 42.0f;
imageForDisabledState:
NativeReversableImage(
IDR_IOS_TOOLBAR_LIGHT_RELOAD_DISABLED, YES)];
- [reloadButton.widthAnchor constraintEqualToConstant:kToolbarButtonWidth]
- .active = YES;
return reloadButton;
}
@@ -125,8 +104,6 @@ CGFloat kToolbarButtonWidth = 42.0f;
NativeImage(IDR_IOS_TOOLBAR_LIGHT_STOP_PRESSED)
imageForDisabledState:
NativeImage(IDR_IOS_TOOLBAR_LIGHT_STOP_DISABLED)];
- [stopButton.widthAnchor constraintEqualToConstant:kToolbarButtonWidth]
- .active = YES;
return stopButton;
}
« no previous file with comments | « no previous file | ios/clean/chrome/browser/ui/toolbar/toolbar_constants.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698