OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // For WinDDK ATL compatibility, these ATL headers must come first. | 5 // For WinDDK ATL compatibility, these ATL headers must come first. |
6 #include "build/build_config.h" | 6 #include "build/build_config.h" |
7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
8 #include <atlbase.h> // NOLINT | 8 #include <atlbase.h> // NOLINT |
9 #include <atlwin.h> // NOLINT | 9 #include <atlwin.h> // NOLINT |
10 #endif | 10 #endif |
11 | 11 |
12 #include "chrome/browser/ui/views/omnibox/omnibox_result_view.h" | 12 #include "chrome/browser/ui/views/omnibox/omnibox_result_view.h" |
13 | 13 |
14 #include <algorithm> // NOLINT | 14 #include <algorithm> // NOLINT |
15 | 15 |
16 #include "base/i18n/bidi_line_iterator.h" | 16 #include "base/i18n/bidi_line_iterator.h" |
17 #include "base/memory/scoped_vector.h" | |
18 #include "base/strings/string_number_conversions.h" | 17 #include "base/strings/string_number_conversions.h" |
19 #include "base/strings/string_util.h" | 18 #include "base/strings/string_util.h" |
20 #include "chrome/browser/themes/theme_properties.h" | 19 #include "chrome/browser/themes/theme_properties.h" |
21 #include "chrome/browser/ui/views/location_bar/location_bar_view.h" | 20 #include "chrome/browser/ui/views/location_bar/location_bar_view.h" |
22 #include "chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.h" | 21 #include "chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.h" |
23 #include "chrome/grit/generated_resources.h" | 22 #include "chrome/grit/generated_resources.h" |
24 #include "components/omnibox/browser/omnibox_popup_model.h" | 23 #include "components/omnibox/browser/omnibox_popup_model.h" |
25 #include "grit/components_scaled_resources.h" | 24 #include "grit/components_scaled_resources.h" |
26 #include "grit/theme_resources.h" | 25 #include "grit/theme_resources.h" |
27 #include "third_party/skia/include/core/SkColor.h" | 26 #include "third_party/skia/include/core/SkColor.h" |
(...skipping 765 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
793 gfx::Range range(offset, offset + text.length()); | 792 gfx::Range range(offset, offset + text.length()); |
794 destination->AppendText(text); | 793 destination->AppendText(text); |
795 const TextStyle& text_style = GetTextStyle(text_type); | 794 const TextStyle& text_style = GetTextStyle(text_type); |
796 // TODO(dschuyler): follow up on the problem of different font sizes within | 795 // TODO(dschuyler): follow up on the problem of different font sizes within |
797 // one RenderText. Maybe with destination->SetFontList(...). | 796 // one RenderText. Maybe with destination->SetFontList(...). |
798 destination->ApplyStyle(gfx::BOLD, is_bold, range); | 797 destination->ApplyStyle(gfx::BOLD, is_bold, range); |
799 destination->ApplyColor( | 798 destination->ApplyColor( |
800 GetNativeTheme()->GetSystemColor(text_style.colors[GetState()]), range); | 799 GetNativeTheme()->GetSystemColor(text_style.colors[GetState()]), range); |
801 destination->ApplyBaselineStyle(text_style.baseline, range); | 800 destination->ApplyBaselineStyle(text_style.baseline, range); |
802 } | 801 } |
OLD | NEW |