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

Unified Diff: chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm

Issue 546053003: [Mac] Fix the height of the email address field in the new avatar button. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
diff --git a/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm b/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
index f2427ea1952ece88c950a120c35f7ea768cb0e47..b17a44beb9ff64a6d8bd95add1f4bdcc4d678876 100644
--- a/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
+++ b/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
@@ -1574,7 +1574,6 @@ class ActiveProfileObserverBridge : public AvatarMenuObserver,
// The available links depend on the type of profile that is active.
if (item.signed_in) {
- rect.size.height = kBlueButtonHeight / 2;
// Signed in profiles with no authentication errors do not have a clickable
// email link.
NSButton* link = nil;
@@ -1610,8 +1609,10 @@ class ActiveProfileObserverBridge : public AvatarMenuObserver,
[link setEnabled:NO];
}
}
- // -linkButtonWithTitle sizeToFit's the link, so re-stretch it so that it
- // can be centered correctly in the view.
+ // -linkButtonWithTitle sizeToFit's the link. We can use the height, but
+ // need to re-stretch the width so that the link can be centered correctly
+ // in the view.
+ rect.size.height = [link frame].size.height;
[link setAlignment:NSCenterTextAlignment];
[link setFrame:rect];
[container addSubview:link];
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698