Commit 0cdb7dd4 authored by Peter Boström's avatar Peter Boström Committed by Commit Bot

Decrease available ToolbarButton height for font

The current 18dp fixed height results in pushing the total button height
on Mac. This doesn't happen by default on Windows as the default font
results in equal size_delta values for 18dp and 17dp available height.

This probably means that 17dp is the actual available height that
doesn't increase the toolbar-button height.

Bug: chromium:862514, chromium:868442
Change-Id: I7c07eb987cb5e4f7a0f200dcbe77b2ac72a751f3
Reviewed-on: https://chromium-review.googlesource.com/1153574Reviewed-by: default avatarPeter Kasting <pkasting@chromium.org>
Commit-Queue: Peter Boström <pbos@chromium.org>
Cr-Commit-Position: refs/heads/master@{#578947}
parent 87f42283
...@@ -55,7 +55,7 @@ void ApplyCommonFontStyles(int context, ...@@ -55,7 +55,7 @@ void ApplyCommonFontStyles(int context,
// consider dynamically resizing all of the toolbar based on the actual // consider dynamically resizing all of the toolbar based on the actual
// final item height. // final item height.
static const int fixed_height = static const int fixed_height =
ui::MaterialDesignController::IsTouchOptimizedUiEnabled() ? 22 : 18; ui::MaterialDesignController::IsTouchOptimizedUiEnabled() ? 22 : 17;
static const int toolbar_button_delta = static const int toolbar_button_delta =
GetFontSizeDeltaBoundedByAvailableHeight(fixed_height, fixed_height); GetFontSizeDeltaBoundedByAvailableHeight(fixed_height, fixed_height);
*size_delta = toolbar_button_delta; *size_delta = toolbar_button_delta;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment