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

Unified Diff: chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.mm

Issue 2905513003: cocoa: move FRE search bubble up a bit (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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.mm
diff --git a/chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.mm b/chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.mm
index db3deadfa561678f2e6e5901f17dc3e91007407e..34466bebf20393fada096716d7317829d8a74ec9 100644
--- a/chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.mm
+++ b/chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.mm
@@ -77,10 +77,6 @@
namespace {
-// Vertical space between the bottom edge of the location_bar and the first run
-// bubble arrow point.
-const static int kFirstRunBubbleYOffset = 1;
-
const int kDefaultIconSize = 16;
// The minimum width the URL should have for the verbose state to be shown.
@@ -656,9 +652,13 @@ new ManagePasswordsDecoration(command_updater, this)),
if (!field_ || ![field_ window])
return;
- // Point the bubble's arrow at the middle of the bottom of the page info icon.
- const NSPoint kOffset =
- NSMakePoint(info_bubble::kBubbleArrowXOffset, kFirstRunBubbleYOffset);
+ // Point the bubble's arrow at the middle of the page info icon. The x offset
+ // isn't the exact center, but this behavior matches other platforms and it
+ // looks better in practice since the arrow ends up between the handle and
+ // lens of the magnifying glass.
+ const NSPoint kOffset = NSMakePoint(
+ info_bubble::kBubbleArrowXOffset,
+ NSHeight([field_ frame]) / 2.0 - info_bubble::kBubbleArrowHeight);
[FirstRunBubbleController showForView:field_
offset:kOffset
browser:browser_
« 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