Chromium Code Reviews| Index: chrome/browser/ui/views/omnibox/omnibox_result_view.h |
| diff --git a/chrome/browser/ui/views/omnibox/omnibox_result_view.h b/chrome/browser/ui/views/omnibox/omnibox_result_view.h |
| index 099027c6c88594f248a8c95723570b1f8d1ff9f1..be5b3592db45f869aaaeb4236697b298a3708494 100644 |
| --- a/chrome/browser/ui/views/omnibox/omnibox_result_view.h |
| +++ b/chrome/browser/ui/views/omnibox/omnibox_result_view.h |
| @@ -10,11 +10,13 @@ |
| #include "base/gtest_prod_util.h" |
| #include "chrome/browser/bitmap_fetcher/bitmap_fetcher_service.h" |
| #include "components/omnibox/autocomplete_match.h" |
| +#include "components/omnibox/suggestion_answer.h" |
| #include "third_party/skia/include/core/SkColor.h" |
| #include "ui/gfx/animation/animation_delegate.h" |
| #include "ui/gfx/animation/slide_animation.h" |
| #include "ui/gfx/font_list.h" |
| #include "ui/gfx/geometry/rect.h" |
| +#include "ui/native_theme/native_theme.h" |
| #include "ui/views/controls/image_view.h" |
| #include "ui/views/view.h" |
| @@ -47,6 +49,12 @@ class OmniboxResultView : public views::View, |
| NUM_KINDS |
| }; |
| + typedef ui::NativeTheme::ColorId StateColors[NUM_STATES]; |
|
Peter Kasting
2015/03/18 02:10:35
This typedef doesn't need to be here since no one
dschuyler
2015/03/18 03:59:52
Done.
|
| + |
| + // The minimum distance between the top and bottom of the text and the |
| + // top or bottom of the row. |
| + static const int kMinimumTextVerticalPadding = 3; |
| + |
| OmniboxResultView(OmniboxPopupContentsView* model, |
| int model_index, |
| LocationBarView* location_bar_view, |
| @@ -117,9 +125,6 @@ class OmniboxResultView : public views::View, |
| void set_edge_item_padding(int value) { edge_item_padding_ = value; } |
| void set_item_padding(int value) { item_padding_ = value; } |
| - void set_minimum_text_vertical_padding(int value) { |
| - minimum_text_vertical_padding_ = value; |
| - } |
| private: |
| // views::View: |
| @@ -155,12 +160,21 @@ class OmniboxResultView : public views::View, |
| bool is_ui_rtl, |
| bool is_match_contents_rtl) const; |
| + int StyleAnswerText(gfx::RenderText* render_text, |
|
Peter Kasting
2015/03/18 02:10:35
Nit: I suggest ordering these so that the two XXXA
dschuyler
2015/03/18 03:59:52
One of the answer text function declarations was r
|
| + int offset, |
| + const SuggestionAnswer::TextField& text_field) const; |
| + |
| + int GetAnswerLineHeight() const; |
| + int GetContentLineHeight() const; |
| + |
| + void AppendAnswerText(gfx::RenderText* render_text, |
| + const SuggestionAnswer::TextField& text_field); |
| + |
| static int default_icon_size_; |
| // Default values cached here, may be overridden using the setters above. |
| int edge_item_padding_; |
| int item_padding_; |
| - int minimum_text_vertical_padding_; |
| // This row's model and model index. |
| OmniboxPopupContentsView* model_; |