Chromium Code Reviews| Index: chrome/browser/ui/views/omnibox/omnibox_result_view.cc |
| diff --git a/chrome/browser/ui/views/omnibox/omnibox_result_view.cc b/chrome/browser/ui/views/omnibox/omnibox_result_view.cc |
| index 6d29e0a88eb076eed56a869c07f408f5eeb59282..138a174643a07d0f4c73a33304593b8abc2ed36c 100644 |
| --- a/chrome/browser/ui/views/omnibox/omnibox_result_view.cc |
| +++ b/chrome/browser/ui/views/omnibox/omnibox_result_view.cc |
| @@ -739,8 +739,14 @@ const gfx::FontList& OmniboxResultView::GetAnswerFont() const { |
| match_.answer && !match_.answer->second_line().text_fields().empty() |
| ? match_.answer->second_line().text_fields()[0].type() |
| : SuggestionAnswer::SUGGESTION; |
| - return ui::ResourceBundle::GetSharedInstance().GetFontList( |
| - GetTextStyle(text_type).font); |
| + |
| + // When BaseFont is specified, reuse font_list_, which may have had size |
| + // adjustments from BaseFont before it was provided to this class. |
| + ui::ResourceBundle::FontStyle font_style = GetTextStyle(text_type).font; |
| + if (font_style == ui::ResourceBundle::BaseFont) |
|
Peter Kasting
2017/06/16 23:47:21
Nit: Or just:
return (font_style == ui::Resourc
Justin Donnelly
2017/06/21 21:13:49
Done.
|
| + return font_list_; |
| + |
| + return ui::ResourceBundle::GetSharedInstance().GetFontList(font_style); |
| } |
| int OmniboxResultView::GetAnswerHeight() const { |