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

Unified Diff: chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm

Issue 1722883002: Adjust toolbar height on Retina (Mac). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 | chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm
diff --git a/chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm b/chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm
index eeea542b33073fca4bc9042cdd20e1755500113c..6b65fddbb2827814d8d73cb5bbbd7eb7817a03c0 100644
--- a/chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm
+++ b/chrome/browser/ui/cocoa/bookmarks/bookmark_bar_controller.mm
@@ -63,6 +63,7 @@
#include "extensions/common/extension_set.h"
#include "grit/theme_resources.h"
#import "ui/base/cocoa/cocoa_base_utils.h"
+#import "ui/base/cocoa/nsview_additions.h"
#include "ui/base/l10n/l10n_util_mac.h"
#include "ui/base/resource/resource_bundle.h"
#include "ui/gfx/image/image.h"
@@ -1041,7 +1042,11 @@ void RecordAppLaunch(Profile* profile, GURL url) {
switch (currentState_) {
case BookmarkBar::SHOW:
- return chrome::kBookmarkBarHeight;
+ // When on a Retina display the toolbar is 1pt shorter than normal so the
+ // bookmark bar needs to be 1pt taller in order for the bookmark icons to
+ // appear in the right place. See https://crbug.com/326245 .
Alexei Svitkine (slow) 2016/02/23 01:20:34 Nit: Please make this comment refer to the change
shrike 2016/02/23 01:23:54 If I understand you correctly, you are saying that
+ return [[self view] cr_lineWidth] == 0.5 ? chrome::kBookmarkBarHeight + 1
+ : chrome::kBookmarkBarHeight;
case BookmarkBar::DETACHED:
return chrome::kNTPBookmarkBarHeight;
case BookmarkBar::HIDDEN:
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698