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

Unified Diff: chrome/browser/ui/views/toolbar/toolbar_view.cc

Issue 1036173002: Animate showing / hiding the location bar for bookmark apps. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix stuffup Created 5 years, 8 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 | « chrome/browser/ui/views/location_bar/location_bar_view.cc ('k') | chrome/chrome_browser_ui.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/toolbar/toolbar_view.cc
diff --git a/chrome/browser/ui/views/toolbar/toolbar_view.cc b/chrome/browser/ui/views/toolbar/toolbar_view.cc
index 7c743394e3e3d22b9d3e7013be9f1082822d0491..4a725f7a69e795446421217c7e846e4f2b4dee8f 100644
--- a/chrome/browser/ui/views/toolbar/toolbar_view.cc
+++ b/chrome/browser/ui/views/toolbar/toolbar_view.cc
@@ -739,6 +739,13 @@ gfx::Size ToolbarView::SizeForContentSize(gfx::Size size) const {
GetThemeProvider()->GetImageSkiaNamed(IDR_CONTENT_TOP_CENTER);
size.SetToMax(
gfx::Size(0, normal_background->height() - content_shadow_height()));
+ } else if (size.height() == 0) {
+ // Location mode with a 0 height location bar. If on ash, expand by one
+ // pixel to show a border in the title bar, otherwise leave the size as zero
+ // height.
+ const int kAshBorderSpacing = 1;
+ if (browser_->host_desktop_type() == chrome::HOST_DESKTOP_TYPE_ASH)
+ size.Enlarge(0, kAshBorderSpacing);
} else {
const int kPopupBottomSpacingGlass = 1;
const int kPopupBottomSpacingNonGlass = 2;
« no previous file with comments | « chrome/browser/ui/views/location_bar/location_bar_view.cc ('k') | chrome/chrome_browser_ui.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698