Chromium Code Reviews| Index: chrome/browser/ui/views/location_bar/location_bar_view.cc |
| diff --git a/chrome/browser/ui/views/location_bar/location_bar_view.cc b/chrome/browser/ui/views/location_bar/location_bar_view.cc |
| index 3a3c56242912321467630f46248f638eaa92c0f5..332e977dd05bee06de27288c0ac4a4998ff9490a 100644 |
| --- a/chrome/browser/ui/views/location_bar/location_bar_view.cc |
| +++ b/chrome/browser/ui/views/location_bar/location_bar_view.cc |
| @@ -118,12 +118,6 @@ const int kDesktopScriptBadgeEdgeItemPadding = kDesktopScriptBadgeItemPadding; |
| const int kTouchItemPadding = 8; |
| const int kTouchEdgeItemPadding = kTouchItemPadding; |
| -#if defined(OS_CHROMEOS) |
|
msw
2012/12/04 18:40:07
Varun: Is this still needed? It's purpose isn't ex
varunjain
2012/12/04 23:05:31
This was done because we want the omnibox to have
msw
2012/12/05 02:09:56
I in-lined the CrOS case into GetColor, as explain
|
| -const SkColor kOmniboxBackgroundColor = SkColorSetARGB(0, 255, 255, 255); |
| -#else |
| -const SkColor kOmniboxBackgroundColor = SkColorSetARGB(255, 255, 255, 255); |
| -#endif |
| - |
| } // namespace |
| // static |
| @@ -325,26 +319,19 @@ bool LocationBarView::IsInitialized() const { |
| SkColor LocationBarView::GetColor(ToolbarModel::SecurityLevel security_level, |
| ColorKind kind) const { |
| -#if defined(OS_WIN) |
| - if (GetNativeTheme() == ui::NativeThemeWin::instance()) { |
| - switch (kind) { |
| - case BACKGROUND: |
| - return color_utils::GetSysSkColor(COLOR_WINDOW); |
| - case TEXT: |
| - return color_utils::GetSysSkColor(COLOR_WINDOWTEXT); |
| - case SELECTED_TEXT: |
| - return color_utils::GetSysSkColor(COLOR_HIGHLIGHTTEXT); |
| - default: |
| - // Other cases are handled below. |
| - break; |
| - } |
| - } |
| -#endif |
| + const ui::NativeTheme* native_theme = GetNativeTheme(); |
| switch (kind) { |
| - // TODO(beng): source from theme provider. |
| - case BACKGROUND: return kOmniboxBackgroundColor; |
| - case TEXT: return SK_ColorBLACK; |
| - case SELECTED_TEXT: return SK_ColorWHITE; |
| + case BACKGROUND: |
| + return native_theme->GetSystemColor( |
| + ui::NativeTheme::kColorId_TextfieldDefaultBackground); |
| + |
| + case TEXT: |
| + return native_theme->GetSystemColor( |
| + ui::NativeTheme::kColorId_TextfieldDefaultColor); |
| + |
| + case SELECTED_TEXT: |
| + return native_theme->GetSystemColor( |
| + ui::NativeTheme::kColorId_TextfieldSelectionColor); |
| case DEEMPHASIZED_TEXT: |
| return color_utils::AlphaBlend( |